Beispiel #1
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        try
        {
            clsPaySlipOptions[] objOpt = new clsPaySlipOptions[1];
            objOpt[0]           = new clsPaySlipOptions();
            objOpt[0].OptID     = objOpt[0].PAYSLIP_VALIDITY;
            objOpt[0].OptName   = "PAYSLIP_VALIDITY";
            objOpt[0].OptValue  = ddlFiscalYear.SelectedValue.Trim();
            objOpt[0].ValidFrom = Common.ReturnDate(txtValidFrom.Text.Trim());
            objOpt[0].ValidTo   = Common.ReturnDate(txtValidTo.Text.Trim());

            //objOpt[1] = new clsPaySlipOptions();
            //objOpt[1].OptID = objOpt[1].FISCAL_VALIDITY;
            //objOpt[1].OptName = "FISCAL_VALIDITY";
            //objOpt[1].OptValue = "0";
            //objOpt[1].ValidFrom = Common.ReturnDate(txtFYStartDate.Text.Trim());
            //objOpt[1].ValidTo = Common.ReturnDate(txtFYEndDate.Text.Trim());

            //objOpt._OptID[1] = objOpt.PAYSLIP_TAXDEDEDUCTION_SALARYHEAD;
            //objOpt._OptName[1] = "taxDeducation";
            //objOpt._OptValue[1] = ddltaxdeducation.SelectedValue.ToString();

            Payroll_PaySlipOptionMgr objOptMgr = new Payroll_PaySlipOptionMgr();

            objOptMgr.InsertpaySlipOption(objOpt, Session["USERID"].ToString(), Common.SetDateTime(DateTime.Now.ToString()));

            lblMsg.Text = "Record Saved Successfully";
        }
        catch (Exception ex)
        {
            throw (ex);
        }
    }
Beispiel #2
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        clsPaySlipOptions[] objOpt = new clsPaySlipOptions[1];
        try
        {
            objOpt[0] = new clsPaySlipOptions();
            //objOpt[0].OptID = objOpt[0].PAYSLIP_RET_AGE;
            objOpt[0].OptName  = "RETIREMENT_AGE";
            objOpt[0].OptValue = txtRetAge.Text;

            //objOpt[1].OptID = objOpt[0].PAYSLIP_BAISC_PERCENT;
            objOpt[1].OptName  = "PAYSLIP_BAISC_PERCENT";
            objOpt[1].OptValue = txtBasicPercent.Text;

            Payroll_PaySlipOptionMgr objOptMgr = new Payroll_PaySlipOptionMgr();

            objOptMgr.InsertpaySlipOption(objOpt, Session["USERID"].ToString(), Common.SetDateTime(DateTime.Now.ToString()));

            lblMsg.Text = "Record Saved Successfully";
        }
        catch (Exception ex)
        {
            throw (ex);
        }
    }