Пример #1
0
        public static IList <BO_PaymentVoucherTable> LoadPaymentVoucher(JQueryDataTableParamModel Param)
        {
            using (AprosysAccountingEntities db_aa = new AprosysAccountingEntities())
            {
                var lst = db_aa.GetPaymentVoucherList("", Param.Start_Date, Param.End_Date);
                List <BO_PaymentVoucherTable> lst_paymentVoucherTable = new List <BO_PaymentVoucherTable>();
                BO_PaymentVoucherTable        obj;
                foreach (var item in lst.ToList())
                {
                    obj              = new BO_PaymentVoucherTable();
                    obj.invoiceNo    = item.InvoiceNo;
                    obj.activityDate = item.ActivityTimestamp;
                    obj.hEADTYPE     = item.HEADTYPE;
                    obj.amount       = item.Amount ?? 0;
                    obj.name         = item.Acting;
                    lst_paymentVoucherTable.Add(obj);
                }

                if (Param.SearchType != 0)
                {
                }
                return(lst_paymentVoucherTable.OrderByDescending(x => (Convert.ToInt32(x.invoiceNo.Remove(0, 4)))).ToList());
            }
        }