示例#1
0
        public ActionResult GetById(int id)
        {
            ImageManageBLL bll   = new ImageManageBLL();
            var            model = bll.GetById(id);

            return(Json(new { success = true, models = model }, JsonRequestBehavior.AllowGet));
        }
示例#2
0
        public ActionResult Save(ImageManageViewModel mode)
        {
            ImageManageBLL bll = new ImageManageBLL();
            string         msg = string.Empty;
            bool           b   = bll.Save(mode, out msg);

            return(Json(new { success = b, message = msg }, JsonRequestBehavior.AllowGet));
        }
示例#3
0
        public ActionResult Delete(int id, string fileName)
        {
            ImageManageBLL bll          = new ImageManageBLL();
            bool           b            = bll.Detele(id);
            string         PhysicalPath = Server.MapPath("/ImageManage/");

            deleteFile(PhysicalPath + fileName);
            return(Json(new { success = b }, JsonRequestBehavior.AllowGet));
        }
示例#4
0
        public ActionResult SearchImage(ImageManageViewModel model)
        {
            model.page = int.Parse(Request["page"]);
            model.rows = int.Parse(Request["rows"]);
            ImageManageBLL  bll  = new ImageManageBLL();
            ImageManageList list = bll.getList(model);

            return(Json(list, JsonRequestBehavior.AllowGet));
        }