Exemplo n.º 1
0
        /// <summary>
        /// 編輯中商品
        /// </summary>
        /// <returns></returns>
        public ActionResult EditList(EditListModel model)
        {
            var queryInfo = new AuditProductListQueryInfo();

            queryInfo.SupplierID  = base.CurrentUser.SupplierID;
            queryInfo.BarCode     = model.BarCode.SafeTrim();
            queryInfo.EditType    = model.EditType;
            queryInfo.ProductName = model.ProductName.SafeTrim();
            queryInfo.Sku         = model.Sku.SafeTrim();
            if (model.SkuStatus.HasValue)
            {
                queryInfo.SkuStatus = new[] { model.SkuStatus.Value };
            }
            else
            {
                queryInfo.SkuStatus = new[] { 0, 2 };
            }
            queryInfo.EditTime = model.EditTime;
            var page = new PageDTO()
            {
                PageIndex = model.PageIndex, PageSize = 20
            };

            try
            {
                PageOf <ProductTempModel> dateList = bll.GetAuditProductList(queryInfo, LanguageEnum.SimplifiedChinese, page);
                ViewBag.DataList = dateList;
            }
            catch (Exception ex)
            {
                LogHelper.Error(ex);
            }
            return(View(model));
        }