Example #1
0
        public ActionResult Edit(int ID)
        {
            FormatCateViewModel model = new FormatCateViewModel();
            var entity = FormatCateService.Find(ID);

            model.CateName = entity.CateName;
            model.ID       = entity.ID;
            model.Code     = entity.Code;

            model.Level      = entity.Level;
            model.OrderIndex = entity.OrderIndex;
            model.PID        = entity.PID;
            ViewBag.Data_PID = GetSelectList(entity.PID.HasValue ? entity.PID.Value : 0);
            return(View(model));
        }
 public ActionResult FormatCodeName(int key)
 {
     return(Content(FormatCateService.Find(key).CateName));
 }