public static string manageCustomerLedger(NameValueCollection strQuerystring)
        {
            int      intParser;
            decimal  decimalParser;
            DateTime dateTimeParser;


            var customerLedgerReconstruct = new CustomerLedgerReconstruct {
                CustomerLedgerID = int.TryParse(strQuerystring.Get("CustomerLedgerID"), out intParser) ? intParser : 0,
                ID             = int.TryParse(strQuerystring.Get("ID"), out intParser) ? intParser : 0,
                Type           = strQuerystring.Get("CustType"),
                Date           = DateTime.TryParse(strQuerystring.Get("Date"), out dateTimeParser) ? dateTimeParser.ToShortDateString() : "",
                Number         = strQuerystring.Get("RefDocNo"),
                Debit          = decimal.TryParse(strQuerystring.Get("Debit"), out decimalParser) ? decimalParser : 0,
                Credit         = decimal.TryParse(strQuerystring.Get("Credit"), out decimalParser) ? decimalParser : 0,
                PPR            = decimal.TryParse(strQuerystring.Get("Rebates"), out decimalParser) ? decimalParser : 0,
                Charges        = decimal.TryParse(strQuerystring.Get("Penalty"), out decimalParser) ? decimalParser : 0,
                RunningBalance = 0
            };

            string isInsert = strQuerystring.Get("TransType");
            string param    = WebCommon.ToXML(customerLedgerReconstruct);

            return(ReconstructDAL.ManageCustomerLedger(param, isInsert));
        }
        public static List <CustomerLedgerReconstruct> GetCustomerLedger(NameValueCollection querystring)
        {
            string referenceNumber = querystring.Get("ReferenceNumber");
            int    branchID        = int.TryParse(querystring.Get("BranchID"), out branchID) ? branchID : 0;

            return(ReconstructDAL.GetCustomerLedger(referenceNumber, branchID));
        }