コード例 #1
0
 public IHttpActionResult GetStockListDetail(string keyID)
 {
     Library.DTO.Notification            notification;
     BLL.ReportStockList                 bll  = new BLL.ReportStockList();
     DTO.ReportStockList.StockListDetail data = bll.GetStockListDetail(keyID, out notification);
     return(Ok(new Library.DTO.ReturnData <DTO.ReportStockList.StockListDetail>()
     {
         Data = data, Message = notification
     }));
 }
コード例 #2
0
        public IHttpActionResult GetStockReservation(int?goodsID, string productType, int?productStatusID)
        {
            Library.DTO.Notification notification;
            BLL.ReportStockList      bll = new BLL.ReportStockList();
            List <DTO.ReportStockList.StockReservation> data = bll.GetStockReservation(goodsID, productType, productStatusID, out notification);

            return(Ok(new Library.DTO.ReturnData <List <DTO.ReportStockList.StockReservation> >()
            {
                Data = data, Message = notification
            }));
        }
コード例 #3
0
        public IHttpActionResult SetFreeToSaleCategory(int productID, int?freeToSaleCategoryID)
        {
            Library.DTO.Notification notification;
            BLL.ReportStockList      bll = new BLL.ReportStockList();
            bool data = bll.SetFreeToSaleCategory(productID, freeToSaleCategoryID, out notification);

            return(Ok(new Library.DTO.ReturnData <bool>()
            {
                Data = data, Message = notification
            }));
        }
コード例 #4
0
        public IHttpActionResult ActiveFreeToSaleProduct(int productID, bool?isActiveFreeToSale)
        {
            Library.DTO.Notification notification;
            BLL.ReportStockList      bll = new BLL.ReportStockList();
            bool data = bll.ActiveFreeToSaleProduct(productID, isActiveFreeToSale, out notification);

            return(Ok(new Library.DTO.ReturnData <bool>()
            {
                Data = data, Message = notification
            }));
        }
コード例 #5
0
        public IHttpActionResult GetReportStockList(Hashtable filters)
        {
            Library.DTO.Notification notification;
            Module.Framework.BLL     fwBll = new Module.Framework.BLL();
            if (!fwBll.CanPerformAction(ControllerContext.GetAuthUserId(), moduleCode, Library.DTO.ModuleAction.CanPrint))
            {
                return(InternalServerError(new Exception(Properties.Resources.NOT_AUTHORIZED)));
            }
            BLL.ReportStockList bll = new BLL.ReportStockList();
            string dataFileName     = bll.GetReportStockList(ControllerContext.GetAuthUserId(), filters, out notification);

            return(Ok(new Library.DTO.ReturnData <string>()
            {
                Data = dataFileName, Message = notification
            }));
        }
コード例 #6
0
        public IHttpActionResult Gets(DTO.Search searchInput)
        {
            Module.Framework.BLL fwBll = new Module.Framework.BLL();
            if (!fwBll.CanPerformAction(ControllerContext.GetAuthUserId(), moduleCode, Library.DTO.ModuleAction.CanRead))
            {
                return(InternalServerError(new Exception(Properties.Resources.NOT_AUTHORIZED)));
            }
            BLL.ReportStockList      bll = new BLL.ReportStockList();
            Library.DTO.Notification notification;
            int totalRows = 0;

            DTO.ReportStockList.SearchFormData data = bll.GetStockListSearch(ControllerContext.GetAuthUserId(), searchInput.Filters, searchInput.PageSize, searchInput.PageIndex, searchInput.SortedBy, searchInput.SortedDirection, out totalRows, out notification);
            return(Ok(new Library.DTO.ReturnData <DTO.ReportStockList.SearchFormData>()
            {
                Data = data, Message = notification, TotalRows = totalRows
            }));
        }