Пример #1
0
 public JsonResult GetMethod(string PointID)
 {
     int MethodID = EmedEvaluationProjectMapper.Get().QueryForObject<int>("Point.GetMethod", PointID);
     PointMethod pm = new PointMethodDao().Find(MethodID);
     return Json(new { ID = pm.ID, MethodName = pm.MethodName, Content = pm.MethodContent });
 }
 public ActionResult Index()
 {
     Dictionary<string, string> sitemaster = GetSiteMaster();
     ViewData["SiteMaster"] = sitemaster;
     if (Int32.Parse(sitemaster["isadmin"]) == 5)
     {
         IList<PointMethod> list=new PointMethodDao().FindAll();
         string html="<option value='0'>请选择指标计算方式</option>";
         foreach(PointMethod p in list)
         {
             html += "<option value='" + p.ID + "'>" + p.MethodName + "</option>";
         }
         ViewData["PointMethod"] = html;
         return View();
     }
     else
         return RedirectToAction("MemberLevelError", "Base");
 }