public ACC_ChartOfAccountLabel1 GetACC_ChartOfAccountLabel1FromReader(IDataReader reader) { try { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1 ( (int)reader["ACC_ChartOfAccountLabel1ID"], reader["Code"].ToString(), reader["ChartOfAccountLabel1Text"].ToString(), reader["ExtraField1"].ToString(), reader["ExtraField2"].ToString(), reader["ExtraField3"].ToString(), (int)reader["AddedBy"], (DateTime)reader["AddedDate"], (int)reader["UpdatedBy"], (DateTime)reader["UpdatedDate"], (int)reader["RowStatusID"] ); return aCC_ChartOfAccountLabel1; } catch(Exception ex) { return null; } }
public ACC_ChartOfAccountLabel1 GetACC_ChartOfAccountLabel1FromReader(IDataReader reader) { try { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1 ( (int)reader["ACC_ChartOfAccountLabel1ID"], reader["Code"].ToString(), reader["ChartOfAccountLabel1Text"].ToString(), reader["ExtraField1"].ToString(), reader["ExtraField2"].ToString(), reader["ExtraField3"].ToString(), (int)reader["AddedBy"], (DateTime)reader["AddedDate"], (int)reader["UpdatedBy"], (DateTime)reader["UpdatedDate"], (int)reader["RowStatusID"] ); return(aCC_ChartOfAccountLabel1); } catch (Exception ex) { return(null); } }
protected void btnUpdate_Click(object sender, EventArgs e) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1 = ACC_ChartOfAccountLabel1Manager.GetACC_ChartOfAccountLabel1ByID(Int32.Parse(hfaCC_ChartOfAccountLabel1ID.Value)); ACC_ChartOfAccountLabel1 tempACC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); tempACC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID = aCC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID; tempACC_ChartOfAccountLabel1.Code = txtCode.Text; tempACC_ChartOfAccountLabel1.ChartOfAccountLabel1Text = txtChartOfAccountLabel1Text.Text; tempACC_ChartOfAccountLabel1.ExtraField1 = ddlRoot.SelectedValue; tempACC_ChartOfAccountLabel1.ExtraField2 = txtExtraField2.Text; tempACC_ChartOfAccountLabel1.ExtraField3 = txtExtraField3.Text; tempACC_ChartOfAccountLabel1.AddedBy = getLogin().LoginID; tempACC_ChartOfAccountLabel1.AddedDate = DateTime.Now; tempACC_ChartOfAccountLabel1.UpdatedBy = getLogin().LoginID; tempACC_ChartOfAccountLabel1.UpdatedDate = DateTime.Now; tempACC_ChartOfAccountLabel1.RowStatusID = Int32.Parse(ddlRowStatus.SelectedValue); bool result = ACC_ChartOfAccountLabel1Manager.UpdateACC_ChartOfAccountLabel1(tempACC_ChartOfAccountLabel1); showACC_ChartOfAccountLabel1Grid(); btnUpdate.Visible = false; btnAdd.Visible = true; btnClear_Click(this, new EventArgs()); }
public static ACC_ChartOfAccountLabel1 GetACC_ChartOfAccountLabel1ByID(int id) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); aCC_ChartOfAccountLabel1 = sqlACC_ChartOfAccountLabel1Provider.GetACC_ChartOfAccountLabel1ByID(id); return aCC_ChartOfAccountLabel1; }
public static ACC_ChartOfAccountLabel1 GetACC_ChartOfAccountLabel1ByID(int id) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); aCC_ChartOfAccountLabel1 = sqlACC_ChartOfAccountLabel1Provider.GetACC_ChartOfAccountLabel1ByID(id); return(aCC_ChartOfAccountLabel1); }
private void showACC_ChartOfAccountLabel1Data() { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1 = ACC_ChartOfAccountLabel1Manager.GetACC_ChartOfAccountLabel1ByID(Int32.Parse(Request.QueryString["aCC_ChartOfAccountLabel1ID"])); txtCode.Text = aCC_ChartOfAccountLabel1.Code; txtChartOfAccountLabel1Text.Text = aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text; txtExtraField1.Text = aCC_ChartOfAccountLabel1.ExtraField1; txtExtraField2.Text = aCC_ChartOfAccountLabel1.ExtraField2; txtExtraField3.Text = aCC_ChartOfAccountLabel1.ExtraField3; txtAddedBy.Text = aCC_ChartOfAccountLabel1.AddedBy.ToString(); txtUpdatedBy.Text = aCC_ChartOfAccountLabel1.UpdatedBy.ToString(); //txtUpdatedDate.Text = aCC_ChartOfAccountLabel1.UpdatedDate; ddlRowStatus.SelectedValue = aCC_ChartOfAccountLabel1.RowStatusID.ToString(); }
protected void btnAdd_Click(object sender, EventArgs e) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1.Code = txtCode.Text; aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text = txtChartOfAccountLabel1Text.Text; aCC_ChartOfAccountLabel1.ExtraField1 = txtExtraField1.Text; aCC_ChartOfAccountLabel1.ExtraField2 = txtExtraField2.Text; aCC_ChartOfAccountLabel1.ExtraField3 = txtExtraField3.Text; aCC_ChartOfAccountLabel1.AddedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.AddedDate = DateTime.Now; aCC_ChartOfAccountLabel1.UpdatedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.UpdatedDate = DateTime.Now; aCC_ChartOfAccountLabel1.RowStatusID = Int32.Parse(ddlRowStatus.SelectedValue); int resutl = ACC_ChartOfAccountLabel1Manager.InsertACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1); Response.Redirect("AdminACC_ChartOfAccountLabel1Display.aspx"); }
protected void btnAdd_Click(object sender, EventArgs e) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1.Code = txtCode.Text; aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text = txtChartOfAccountLabel1Text.Text; aCC_ChartOfAccountLabel1.ExtraField1 = ddlRoot.SelectedValue; aCC_ChartOfAccountLabel1.ExtraField2 = txtExtraField2.Text; aCC_ChartOfAccountLabel1.ExtraField3 = txtExtraField3.Text; aCC_ChartOfAccountLabel1.AddedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.AddedDate = DateTime.Now; aCC_ChartOfAccountLabel1.UpdatedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.UpdatedDate = DateTime.Now; aCC_ChartOfAccountLabel1.RowStatusID = Int32.Parse(ddlRowStatus.SelectedValue); int resutl = ACC_ChartOfAccountLabel1Manager.InsertACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1); showACC_ChartOfAccountLabel1Grid(); btnClear_Click(this,new EventArgs()); }
protected void btnAdd_Click(object sender, EventArgs e) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1.Code = txtCode.Text; aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text = txtChartOfAccountLabel1Text.Text; aCC_ChartOfAccountLabel1.ExtraField1 = ddlRoot.SelectedValue; aCC_ChartOfAccountLabel1.ExtraField2 = txtExtraField2.Text; aCC_ChartOfAccountLabel1.ExtraField3 = txtExtraField3.Text; aCC_ChartOfAccountLabel1.AddedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.AddedDate = DateTime.Now; aCC_ChartOfAccountLabel1.UpdatedBy = getLogin().LoginID; aCC_ChartOfAccountLabel1.UpdatedDate = DateTime.Now; aCC_ChartOfAccountLabel1.RowStatusID = Int32.Parse(ddlRowStatus.SelectedValue); int resutl = ACC_ChartOfAccountLabel1Manager.InsertACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1); showACC_ChartOfAccountLabel1Grid(); btnClear_Click(this, new EventArgs()); }
protected void btnUpdate_Click(object sender, EventArgs e) { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1 = ACC_ChartOfAccountLabel1Manager.GetACC_ChartOfAccountLabel1ByID(Int32.Parse(Request.QueryString["aCC_ChartOfAccountLabel1ID"])); ACC_ChartOfAccountLabel1 tempACC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); tempACC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID = aCC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID; tempACC_ChartOfAccountLabel1.Code = txtCode.Text; tempACC_ChartOfAccountLabel1.ChartOfAccountLabel1Text = txtChartOfAccountLabel1Text.Text; tempACC_ChartOfAccountLabel1.ExtraField1 = txtExtraField1.Text; tempACC_ChartOfAccountLabel1.ExtraField2 = txtExtraField2.Text; tempACC_ChartOfAccountLabel1.ExtraField3 = txtExtraField3.Text; tempACC_ChartOfAccountLabel1.AddedBy = getLogin().LoginID; tempACC_ChartOfAccountLabel1.AddedDate = DateTime.Now; tempACC_ChartOfAccountLabel1.UpdatedBy = getLogin().LoginID; tempACC_ChartOfAccountLabel1.UpdatedDate = DateTime.Now; tempACC_ChartOfAccountLabel1.RowStatusID = Int32.Parse(ddlRowStatus.SelectedValue); bool result = ACC_ChartOfAccountLabel1Manager.UpdateACC_ChartOfAccountLabel1(tempACC_ChartOfAccountLabel1); Response.Redirect("AdminACC_ChartOfAccountLabel1Display.aspx"); }
public bool UpdateACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { using (SqlConnection connection = new SqlConnection(this.ConnectionString)) { SqlCommand cmd = new SqlCommand("GP_UpdateACC_ChartOfAccountLabel1", connection); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@ACC_ChartOfAccountLabel1ID", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID; cmd.Parameters.Add("@Code", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.Code; cmd.Parameters.Add("@ChartOfAccountLabel1Text", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text; cmd.Parameters.Add("@ExtraField1", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField1; cmd.Parameters.Add("@ExtraField2", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField2; cmd.Parameters.Add("@ExtraField3", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField3; cmd.Parameters.Add("@AddedBy", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.AddedBy; cmd.Parameters.Add("@AddedDate", SqlDbType.DateTime).Value = aCC_ChartOfAccountLabel1.AddedDate; cmd.Parameters.Add("@UpdatedBy", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.UpdatedBy; cmd.Parameters.Add("@UpdatedDate", SqlDbType.DateTime).Value = aCC_ChartOfAccountLabel1.UpdatedDate; cmd.Parameters.Add("@RowStatusID", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.RowStatusID; connection.Open(); int result = cmd.ExecuteNonQuery(); return(result == 1); } }
public static int InsertACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); return(sqlACC_ChartOfAccountLabel1Provider.InsertACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1)); }
public static bool UpdateACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); return(sqlACC_ChartOfAccountLabel1Provider.UpdateACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1)); }
private void showACC_ChartOfAccountLabel1Data() { ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1 = new ACC_ChartOfAccountLabel1(); aCC_ChartOfAccountLabel1 = ACC_ChartOfAccountLabel1Manager.GetACC_ChartOfAccountLabel1ByID(Int32.Parse(hfaCC_ChartOfAccountLabel1ID.Value)); txtCode.Text = aCC_ChartOfAccountLabel1.Code; txtChartOfAccountLabel1Text.Text = aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text; ddlRoot.SelectedValue = aCC_ChartOfAccountLabel1.ExtraField1; txtExtraField2.Text = aCC_ChartOfAccountLabel1.ExtraField2; txtExtraField3.Text = aCC_ChartOfAccountLabel1.ExtraField3; txtAddedBy.Text = aCC_ChartOfAccountLabel1.AddedBy.ToString(); txtUpdatedBy.Text = aCC_ChartOfAccountLabel1.UpdatedBy.ToString(); //txtUpdatedDate.Text = aCC_ChartOfAccountLabel1.UpdatedDate; ddlRowStatus.SelectedValue = aCC_ChartOfAccountLabel1.RowStatusID.ToString(); }
public bool UpdateACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { using (SqlConnection connection = new SqlConnection(this.ConnectionString)) { SqlCommand cmd = new SqlCommand("GP_UpdateACC_ChartOfAccountLabel1", connection); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@ACC_ChartOfAccountLabel1ID", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.ACC_ChartOfAccountLabel1ID; cmd.Parameters.Add("@Code", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.Code; cmd.Parameters.Add("@ChartOfAccountLabel1Text", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ChartOfAccountLabel1Text; cmd.Parameters.Add("@ExtraField1", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField1; cmd.Parameters.Add("@ExtraField2", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField2; cmd.Parameters.Add("@ExtraField3", SqlDbType.NVarChar).Value = aCC_ChartOfAccountLabel1.ExtraField3; cmd.Parameters.Add("@AddedBy", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.AddedBy; cmd.Parameters.Add("@AddedDate", SqlDbType.DateTime).Value = aCC_ChartOfAccountLabel1.AddedDate; cmd.Parameters.Add("@UpdatedBy", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.UpdatedBy; cmd.Parameters.Add("@UpdatedDate", SqlDbType.DateTime).Value = aCC_ChartOfAccountLabel1.UpdatedDate; cmd.Parameters.Add("@RowStatusID", SqlDbType.Int).Value = aCC_ChartOfAccountLabel1.RowStatusID; connection.Open(); int result = cmd.ExecuteNonQuery(); return result == 1; } }
public static bool UpdateACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); return sqlACC_ChartOfAccountLabel1Provider.UpdateACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1); }
public static int InsertACC_ChartOfAccountLabel1(ACC_ChartOfAccountLabel1 aCC_ChartOfAccountLabel1) { SqlACC_ChartOfAccountLabel1Provider sqlACC_ChartOfAccountLabel1Provider = new SqlACC_ChartOfAccountLabel1Provider(); return sqlACC_ChartOfAccountLabel1Provider.InsertACC_ChartOfAccountLabel1(aCC_ChartOfAccountLabel1); }