protected void GetFinancial() { FinancialYearListtbl fa = new FinancialYearListtbl(); List <FinancialYearListtbl> lst = new List <FinancialYearListtbl>(); lst = objFinanceBL.GetAllFinancial(fa).ToList(); gdvFinancial.DataSource = lst; gdvFinancial.DataBind(); btnSave.Visible = true; btnUpdate.Visible = false; }
protected void InsertFinancial() { FinancialYearListtbl fa = new FinancialYearListtbl(); fa.FromYear = ddlFromYear.SelectedValue; fa.ToYear = ddlToYear.SelectedValue; fa.FromMonth = ddlFromMonth.SelectedValue; fa.ToMonth = ddlToMonth.SelectedValue; fa.Status = 1; fa.CreatedBy = 1; fa.CreatedDate = DateTime.Now.ToString(); fa.UpdatedBy = 1; fa.UpdatedDate = DateTime.Now.ToString(); lfa = objFinanceBL.InsertFinancialList(fa).ToList(); ScriptManager.RegisterStartupScript(this, GetType(), "alertMessage", "alertMessage('Data Inserted Successfully');", true); btnSave.Visible = true; GetFinancial(); Reset(); }
protected void lbtnLMarkAsActive_Click(object sender, EventArgs e) { LinkButton lbtn = (LinkButton)sender; GridViewRow gvr = (GridViewRow)lbtn.NamingContainer; var val = gvr.DataItemIndex; var id = gvr.Cells[5].Text; FinancialYearListtbl fa = new FinancialYearListtbl(); fa.FyID = Convert.ToInt32(gvr.Cells[0].Text); if (id == "Active") { fa.Status = 0; } else if (id == "InActive") { fa.Status = 1; } objFinanceBL.UpdateFinancialListIsActive(fa); GetFinancial(); }
protected void GetFinanceById(int id) { FinancialYearListtbl fa = new FinancialYearListtbl(); fa.FyID = Convert.ToInt32(id.ToString()); List <FinancialYearListtbl> lfa = new List <FinancialYearListtbl>(); lfa = objFinanceBL.GetFinancebyId(fa).ToList(); foreach (var el in lfa) { hdnFyID.Value = Convert.ToString(el.FyID); hdnStatus.Value = el.Status.ToString(); ddlFromYear.SelectedValue = el.FromYear; ddlToYear.SelectedValue = el.ToYear; ddlFromMonth.SelectedValue = el.FromMonth; ddlToMonth.SelectedValue = el.ToMonth; } btnSave.Visible = false; btnUpdate.Visible = true; }
protected void updateFinancial() { FinancialYearListtbl fa = new FinancialYearListtbl(); fa.FyID = Convert.ToInt32(hdnFyID.Value); fa.FromYear = ddlFromYear.SelectedValue; fa.ToYear = ddlToYear.SelectedValue; fa.FromMonth = ddlFromMonth.SelectedValue; fa.ToMonth = ddlToMonth.SelectedValue; fa.Status = Convert.ToInt32(hdnStatus.Value); fa.CreatedBy = 1; fa.CreatedDate = DateTime.Now.ToString(); fa.UpdatedBy = 1; fa.UpdatedDate = DateTime.Now.ToString(); lfa = objFinanceBL.UpdateFinancialList(fa).ToList(); ScriptManager.RegisterStartupScript(this, GetType(), "alertMessage", "alertMessage('Accounts Updated Successfully');", true); GetFinancial(); Reset(); btnUpdate.Visible = false; btnSave.Visible = true; }
public IEnumerable <FinancialYearListtbl> GetFinancialListByStatus(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(7, fa)); }
public IEnumerable <FinancialYearListtbl> UpdateFinancialListIsActive(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(6, fa)); }
public IEnumerable <FinancialYearListtbl> DeleteFinancialList(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(5, fa)); }
public IEnumerable <FinancialYearListtbl> InsertFinancialList(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(3, fa)); }
public IEnumerable <FinancialYearListtbl> GetFinancebyId(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(2, fa)); }
public IEnumerable <FinancialYearListtbl> GetAllFinancial(FinancialYearListtbl fa) { return(objFinancialDA.FinancialListAll(1, fa)); }