public List<DairyListItem> Select() { StoredProcedure storedProcedure = new StoredProcedure(); storedProcedure.Name = My.Resources.CreateSelectByNameSPList()[TableList.DiaryListItem].ToString(); storedProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForInsertDairyDateItem(DateItem); return dairyItemController.ExecuteSync(storedProcedure).ToList(); }
public List<DairyListItem> StartUpSelect() { StoredProcedure storedProcedure = new StoredProcedure(); storedProcedure.Name = My.Resources.CreateSelectByNameSPList()[TableList.DiaryListItem].ToString(); storedProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForInsertDairyDateItem(new DairyDateItem() { Date = DateTime.Now }); return (new TableController<DairyListItem>()).ExecuteSync(storedProcedure).ToList(); }
public void Insert() { StoredProcedure firstStoredProcedure = new StoredProcedure(); firstStoredProcedure.Name = My.Resources.CreateInsertSPList()[TableList.DiaryDate].ToString(); firstStoredProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForInsertDairyDateItem(DateItem); ListItem.DateID = dairyController.Execute(firstStoredProcedure); StoredProcedure secondStoredProcedure = new StoredProcedure(); secondStoredProcedure.Name = My.Resources.CreateInsertSPList()[TableList.DiaryListItem].ToString(); secondStoredProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForInsertDairyListItem(ListItem); dairyItemController.ExecuteAsync(secondStoredProcedure); }
public void Delete() { StoredProcedure storedProcedure = new StoredProcedure(); storedProcedure.Name = My.Resources.CreateDeleteSPList()[TableList.DiaryListItem].ToString(); storedProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForDeleteDairyItem(ListItem.ItemID); dairyItemController.ExecuteSync(storedProcedure); }
public int ComputeStatistic() { StoredProcedure storedProcedure = new StoredProcedure(); storedProcedure.Name = My.Resources.CreateInsertSPList()[TableList.DiaryDate].ToString(); storedProcedure.ParameterValueCollection = ParameterProvider.GetParameterListForInsertDairyDateItem(DateItem); return dairyController.Execute(storedProcedure); }