Пример #1
0
        public ActionResult Edit(InitForm initform)
        {
            if (ModelState.IsValid)
            {
                if(initform.File != null && !string.IsNullOrEmpty(initform.File.FileName)){
                    string path = Server.MapPath("/") + "favicon.ico";
                    initform.File.SaveAs(path);
                }
             
                bool flag = SysInitBll.SaveInitForm(initform);
                if (flag)
                {
                   return RedirectToAction("Index", "SyInit");
                }

            }
            else {
                initform = SysInitBll.GetInitForm();
            }
            return View(initform);
        }
Пример #2
0
 public ActionResult Edit()
 {
     InitForm initform = new InitForm();
     initform = SysInitBll.GetInitForm();
     return View(initform);
 }