Ejemplo n.º 1
0
 void frmEntryBill_Load(object sender, EventArgs e)
 {
     FillDropDown();
     if (BillId > 0)
     {
         var bill = BillBusinessLogic.Get(BillId); ;
         textbillno.Text = Convert.ToString(bill.BillNo);
         dateTimebilldate.Text = Convert.ToString(bill.BillDateString);
         cmbParty.SelectedItem = Convert.ToString(bill.PartyId);
         textbranchcode.Text = bill.BranchCode;
         dateTimeduedate.Text = Convert.ToString(bill.PaymentDueDateString);
         combotickbill.SelectedItem = bill.BillType;
         textbasicofchange.Text = bill.BasicOfChargesGC;
         textenclosure.Text = bill.Enclosure;
         comboservicetax.SelectedItem = bill.ServiceTaxThrough;
         textcheckedby.Text = bill.CheckedBy;
         texttaxregdno.Text = bill.ServiceTaxThrough;
         textservicetax.Text = bill.ServiceTaxRegdNo;
         int i = 1;
         foreach (var item in bill.BillEntryList)
         {
             item.SrNo = i++;
             CommonClass.tblBillEntryDTO.Add(item);
         }
         fillGridData();
     }
     else
     {
         textbillno.Text = Convert.ToString(BillBusinessLogic.GetBillNo() + 1);
     }
 }
Ejemplo n.º 2
0
        public ActionResult Save(int id)
        {
            tblBillDTO tblBillDTO = new tblBillDTO();

            if (id == 0)
            {
                tblBillDTO        = new tblBillDTO();
                tblBillDTO.BillNo = BillBusinessLogic.GetBillNo() + 1;
            }
            else
            {
                tblBillDTO = BillBusinessLogic.Get(id);
            }
            tblBillDTO = FillDropDown(tblBillDTO);
            return(View(tblBillDTO));
        }