Пример #1
0
 public BillingStatsSummary(string mONTH, string cODE, string nAME, BillingStatsBatch bsBat)
 {
     this.MONTH = mONTH;
     this.CODE  = cODE;
     this.NAME  = nAME;
     total      = bsBat;
 }
Пример #2
0
 public BillingStatsSummary(string mONTH, string cODE, string nAME, DataTable dt)
 {
     this.MONTH = mONTH;
     this.CODE  = cODE;
     this.NAME  = nAME;
     total      = GetBillStatBatchSummaryE(cODE, dt);
 }
Пример #3
0
        private BillingStatsSummary GetBillStatBatchSummary(string pMonth, string pCode, string pName)
        {
            string BATCH           = "TOTAL";
            string SDIV_CODE       = pCode;
            string SDIV_NAME       = pName;
            UInt32 TNOCONSUMERS    = 0;
            UInt32 NOUNBILLEDCASES = 0;
            UInt32 NOSTSREADING    = 0;
            UInt32 NODISCASES      = 0;
            UInt32 NORECCASES      = 0;
            UInt32 NOMCOCASES      = 0;
            UInt32 NODEFMETERS     = 0;
            UInt32 LOCKCASES       = 0;
            UInt32 NONEWCONN       = 0;
            Int64  CREDBALCONSM    = 0;
            UInt32 NOHEAVYBCASES   = 0;
            Int64  CREDBALAMT      = 0;

            foreach (BillingStatsSummary bs in billStatSummary)
            {
                BillingStatsBatch b = bs.total;
                if (b.BATCH == "TOTAL")
                {
                    TNOCONSUMERS    += UInt32.Parse(b.TNOCONSUMERS);
                    NOUNBILLEDCASES += UInt32.Parse(b.NOUNBILLEDCASES);
                    NOSTSREADING    += UInt32.Parse(b.NOSTSREADING);
                    NODISCASES      += UInt32.Parse(b.NODISCASES);
                    NORECCASES      += UInt32.Parse(b.NORECCASES);
                    NOMCOCASES      += UInt32.Parse(b.NOMCOCASES);
                    NODEFMETERS     += UInt32.Parse(b.NODEFMETERS);
                    LOCKCASES       += UInt32.Parse(b.LOCKCASES);
                    NONEWCONN       += UInt32.Parse(b.NONEWCONN);
                    CREDBALCONSM    += Int64.Parse(b.CREDBALCONSM);
                    NOHEAVYBCASES   += UInt32.Parse(b.NOHEAVYBCASES);
                    CREDBALAMT      += Int64.Parse(b.CREDBALAMT);
                }
            }

            return(new BillingStatsSummary(pMonth, pCode, pName, new BillingStatsBatch("TOTAL", TNOCONSUMERS.ToString(), NOUNBILLEDCASES.ToString(),
                                                                                       NOSTSREADING.ToString(), NODISCASES.ToString(), NORECCASES.ToString(), NOMCOCASES.ToString(),
                                                                                       NODEFMETERS.ToString(), LOCKCASES.ToString(), NONEWCONN.ToString(), CREDBALCONSM.ToString(),
                                                                                       NOHEAVYBCASES.ToString(), CREDBALAMT.ToString())));
        }