示例#1
0
        public ActionResult Index(string name, int status = -1)
        {
            List <BrandEntity> mList = null;

            if (!string.IsNullOrEmpty(name) || status > -1)
            {
                mList = BrandService.GetBrandByRule(name, status);
            }
            else
            {
                mList = BrandService.GetBrandAll();
            }
            ViewBag.Brands = mList;
            ViewBag.Name   = name ?? "";
            ViewBag.Status = status;
            return(View());
        }