public ActionResult SKUStatusList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.SKUStatusList();

            if (!isNeedAll)
            {
                return(Json(list));
            }
            list.Insert(0, new SKU_Status_Model//插入第一个位置
            {
                StatusID   = 0,
                StatusName = "All",
            });

            /*Items requiring attention是一个复合状态,本身不应该直接出现在数据库,所以在这里用代码方式嵌入,所谓的复合的状态是指:
             * 冲突的状态:例如,那些有库存但是却处于离线,或者那些已经脱销没库存了,却任然在线的SKU产品。
             *   The intention behind "Items Requiring Attention" was to display the number of products in a
             * "conflicted status". For example, items in stock but not online, or items out of stock but still online.
             * Is it possible to aggregate that data into a single figure? If not, we can find a substitute metric for
             * this area.*/
            list.Insert(list.Count, new SKU_Status_Model//插入最后一个位置
            {
                StatusID   = 10,
                StatusName = "Items requiring attention",
            });
            return(Json(list));
        }
        public ActionResult SKUSubCategoryList(long ParentID)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.GetSKUCategoryList(ParentID);

            return(Json(list));
        }
        public ActionResult SKUColourList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.SKUColourList();

            if (isNeedAll)
            {
                list.Insert(0, new CMS_SKU_Colour_Model//插入第一个位置
                {
                    ColourID   = 0,
                    ColourName = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult SkuMaterialList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.SKUMaterialList();

            if (isNeedAll)
            {
                list.Insert(0, new CMS_SKU_Material_Model//插入第一个位置
                {
                    MaterialID   = 0,
                    MaterialName = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult SkuCategoryList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.GetSKUCategoryList(0);

            if (isNeedAll)
            {
                list.Insert(0, new CMS_SKU_Category_Model//插入第一个位置
                {
                    CategoryID   = 0,
                    CategoryName = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult CloudStatusList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.CloudStatusList();

            if (isNeedAll)
            {
                list.Insert(0, new MediaCloudStatus_Model//插入第一个位置
                {
                    CloudStatusId   = 0,
                    CloudStatusName = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult ShipViaTypeList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.ShipViaTypeList();

            if (isNeedAll)
            {
                list.Insert(0, new CMS_ShipViaType_Model//插入第一个位置
                {
                    ShipViaTypeID   = 0,
                    ShipViaTypeName = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult HmnumStatusList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = ccs.HMNUMStatusList();

            if (isNeedAll)
            {
                list.Insert(0, new CMS_HMNUM_Status_Model//插入第一个位置
                {
                    StatusID   = 0,
                    StatusName = "All",
                });
            }
            return(Json(list));
        }
        public async Task <ActionResult> BrandList(bool isNeedAll)
        {
            var ccs  = new CMSCacheableDataServices();
            var list = await ccs.BrandListAsync();

            if (isNeedAll)
            {
                list.Insert(0, new Brands_Info_Model//插入第一个位置
                {
                    Brand_Id   = 0,
                    Brand_Name = "All"
                });
            }
            return(Json(list));
        }
        public ActionResult GetGroupCategoryFromWebpo()
        {
            var ccs = new CMSCacheableDataServices();

            return(Json(ccs.GetGroupCategoryFromWEBPO()));
        }
        public List <SKU_Status_Model> SkuStatusListObject()
        {
            var ccs = new CMSCacheableDataServices();

            return(ccs.SKUStatusList());
        }