Пример #1
0
        public DataTable GetPurchaseRecordById(string purchaseRecordId)
        {
            PurchaseToSCDAL purchaseRecord = new PurchaseToSCDAL();

            try
            {
                LumexDBPlayer db = LumexDBPlayer.Start();
                DataTable dt = purchaseRecord.GetPurchaseRecordById(purchaseRecordId, db);
                db.Stop();

                return dt;
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                purchaseRecord = null;
            }
        }
Пример #2
0
        public DataTable GetPurchaseRecordsListBySalesCenterDateRangeAndStatus(string salesCenterId, string fromDate, string toDate, string status)
        {
            PurchaseToSCDAL purchaseRecord = new PurchaseToSCDAL();

            try
            {
                LumexDBPlayer db = LumexDBPlayer.Start();
                DataTable dt = purchaseRecord.GetPurchaseRecordsListBySalesCenterDateRangeAndStatus(salesCenterId, fromDate, toDate, status, db);
                db.Stop();

                return dt;
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                purchaseRecord = null;
            }
        }
Пример #3
0
        public string SavePurchaseRecord(DataTable dtPrdList)
        {
            PurchaseToSCDAL purchaseRecord = new PurchaseToSCDAL();

            try
            {
                LumexDBPlayer db = LumexDBPlayer.Start(true);
                string Id = purchaseRecord.SavePurchaseRecord(this, dtPrdList, db);
                db.Stop();

                return Id;
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                purchaseRecord = null;
                dtPrdList = null;
            }
        }
Пример #4
0
        public bool rejectPurchaseRecord(string salesCenterId, string purchaseRecordId)
        {
            PurchaseToSCDAL purchaseRecord = new PurchaseToSCDAL();
            bool status = false;

            try
            {
                LumexDBPlayer db = LumexDBPlayer.Start();
                status = purchaseRecord.rejectPurchaseRecord(salesCenterId, purchaseRecordId, db);
                db.Stop();

                
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                purchaseRecord = null;
            }

            return status;
        }
Пример #5
0
        public DataTable GetPurchaseRecordsApprovalListBySalesCenter(string salesCenterId)
        {
            PurchaseToSCDAL purchaseRecord = new PurchaseToSCDAL();

            try
            {
                LumexDBPlayer db = LumexDBPlayer.Start();
                DataTable dt = purchaseRecord.GetPurchaseRecordsApprovalListBySalesCenter(salesCenterId, db);
                db.Stop();

                return dt;
            }
            catch (Exception)
            {
                throw;
            }
            finally
            {
                purchaseRecord = null;
            }
        }