public ActionResult Index(UnitAndSpecificationsModel vm)
        {
            vm.CustomerItems = ApplicationConfigHelper.GetProjectUserCustomers(base.UserInfo.ProjectID, base.UserInfo.ID).Where(c => c.State && (c.StoreType == 2 || c.StoreType == 3))
                               .Select(c => new SelectListItem()
            {
                Value = c.CustomerID.ToString(), Text = c.CustomerName
            });

            StringBuilder sb = new StringBuilder();

            foreach (var i in vm.CustomerItems)
            {
                sb.Append("" + i.Value + ",");
            }
            if (sb.Length > 1)
            {
                vm.unitAndSpecificationsInfo.CustomerIDs = sb.Remove(sb.Length - 1, 1).ToString();
            }
            var response = new UnitAndSpecificationsService().GetUnitAndSpecifications(new UnitAndSpecificationsRequest()
            {
                unitAndSpecificationsInfo = vm.unitAndSpecificationsInfo
            });

            if (response.IsSuccess)
            {
                vm.unitAndSpecificationsInfos = response.Result.unitAndSpecificationsInfos;
            }
            #region 页面customerid读取
            //IEnumerable<WMS_Config_Type> ctype = null;
            //ctype = ApplicationConfigHelper.GetWMS_ConfigType("CustomerID", base.UserInfo.ProjectID, 0, 0);
            ViewBag.ctype = "";
            #endregion
            return(View(vm));
        }
        public JsonResult DeleteUnitAndSpecifications(int id = 0)
        {
            var response = new UnitAndSpecificationsService().DeleteUnitAndSpecifications(id);

            if (response)
            {
                return(Json(new { Code = 1 }));
            }
            return(Json(new { Code = 0 }));
        }