public List <POCO.AccountsWithCentersCostsTable> M_AccountsWithCentersCostsTable_Get() { DataSet ds = new DataSet(); POCO.AccountsWithCentersCostsTable oAccountsWithCentersCostsTable = new POCO.AccountsWithCentersCostsTable(); List <POCO.AccountsWithCentersCostsTable> oLAccountsWithCentersCostsTable = new List <POCO.AccountsWithCentersCostsTable>(); ds = oAccountsWithCentersCostsTableDAL.M_AccountsWithCentersCostsTable_Get(); if (ds.Tables.Count > 0) { for (int i = 0; i < ds.Tables[0].Rows.Count; i++) { oAccountsWithCentersCostsTable = new POCO.AccountsWithCentersCostsTable(); oAccountsWithCentersCostsTable.ID = Int64.Parse(ds.Tables[0].Rows[i]["ID"].ToString()); oAccountsWithCentersCostsTable.AccountName = ds.Tables[0].Rows[i]["AccountName"].ToString(); oAccountsWithCentersCostsTable.CentersCostsName = ds.Tables[0].Rows[i]["CentersCostsName"].ToString(); oAccountsWithCentersCostsTable.AccountNo = Int64.Parse(ds.Tables[0].Rows[i]["AccountNo"].ToString()); oAccountsWithCentersCostsTable.CentersCostsNo = Int64.Parse(ds.Tables[0].Rows[i]["CentersCostsNo"].ToString()); oLAccountsWithCentersCostsTable.Add(oAccountsWithCentersCostsTable); } } return(oLAccountsWithCentersCostsTable); }
public ActionResult Edit(Int64 ParID, POCO.AccountsWithCentersCostsTable PoAccountsWithCentersCostsTable) { AccountsWithCentersCostsTableDBL oAccountsWithCentersCostsTableDBL = new AccountsWithCentersCostsTableDBL(); PoAccountsWithCentersCostsTable.ID = ParID; oAccountsWithCentersCostsTableDBL.M_AccountsWithCentersCostsTable_Update(ParID, PoAccountsWithCentersCostsTable.AccountNo, PoAccountsWithCentersCostsTable.CentersCostsNo); return(RedirectToAction("Index")); }
public ActionResult DeleteConfirmed(Int64 ParAccountNo, Int64 ParCentersCostsNo) { AccountsWithCentersCostsTableDBL oAccountsWithCentersCostsTableDBL = new AccountsWithCentersCostsTableDBL(); POCO.AccountsWithCentersCostsTable oAccountsWithCentersCostsTable = oAccountsWithCentersCostsTableDBL.M_AccountsWithCentersCostsTable_Delete(ParAccountNo, ParCentersCostsNo); return(RedirectToAction("Index")); }
public ActionResult Create(POCO.AccountsWithCentersCostsTable oAccountsWithCentersCostsTable) { if (ModelState.IsValid) { AccountsWithCentersCostsTableDBL oAccountsWithCentersCostsTableDBL = new AccountsWithCentersCostsTableDBL(); oAccountsWithCentersCostsTableDBL.M_AccountsWithCentersCostsTable_Insert(oAccountsWithCentersCostsTable); return(RedirectToAction("Index")); } return(View(oAccountsWithCentersCostsTable)); }
// GET: AccountsWithCentersCostsTable/Delete/5 public ActionResult Delete(Int64 ParAccountNo, Int64 ParCentersCostsNo) { AccountsWithCentersCostsTableDBL oAccountsWithCentersCostsTableDBL = new AccountsWithCentersCostsTableDBL(); POCO.AccountsWithCentersCostsTable oAccountsWithCentersCostsTable = oAccountsWithCentersCostsTableDBL.M_AccountsWithCentersCostsTable_Find(ParAccountNo, ParCentersCostsNo); if (oAccountsWithCentersCostsTable == null) { return(HttpNotFound()); } return(View(oAccountsWithCentersCostsTable)); }
public POCO.AccountsWithCentersCostsTable M_AccountsWithCentersCostsTable_Update(Int64 ID, Int64 AccountNo, Int64 CentersCostsNo) { DataSet ds = new DataSet(); POCO.AccountsWithCentersCostsTable oAccountsWithCentersCostsTable = new POCO.AccountsWithCentersCostsTable(); ds = oAccountsWithCentersCostsTableDAL.M_AccountsWithCentersCostsTable_Update(ID, AccountNo, CentersCostsNo); if (ds.Tables.Count > 0) { if (ds.Tables[0].Rows.Count > 0) { oAccountsWithCentersCostsTable.AccountNo = Int64.Parse(ds.Tables[0].Rows[0]["AccountNo"].ToString()); oAccountsWithCentersCostsTable.CentersCostsNo = Int64.Parse(ds.Tables[0].Rows[0]["CentersCostsNo"].ToString()); } } return(oAccountsWithCentersCostsTable); }