예제 #1
0
 public JsonResult Delete(Game_Qrst _t)
 {
     if (WMFactory.Game_Qrst.Delete(s => s.Id == _t.Id ))
         return Json(ResultMsg.Success("删除成功!"));
     else
         return Json(ResultMsg.Failure("删除失败,请您重试!"));
 }
예제 #2
0
 public JsonResult Post(Game_Qrst _t)
 {
     if (WMFactory.Game_Qrst.Insert(_t))
         return Json(ResultMsg.Success("新增成功!"));
     else
         return Json(ResultMsg.Failure("新增失败,请您重试!"));
 }
예제 #3
0
 public JsonResult SumitQA(Game_Qrst qr)
 {
     qr.UseName = CookieHelper.GetCookie("AM_login");
     qr.CreateUser = "******";
     qr.ModifyUser = "******";
     qr.ModifyTime = DateTime.Now;
     WMFactory.Game_Qrst.Insert(qr);
     return Json(ResultMsg.Success(qr.total));
 }
예제 #4
0
 public JsonResult Put(Game_Qrst _t)
 {
     IGame_QrstService service = WMFactory.Game_Qrst;
     Game_Qrst entity = service.GetById(_t.Id.ToString());
     entity = AutoMapper<Game_Qrst, Game_Qrst>.Convert(_t, entity);
     if (service.Update(entity))
         return Json(ResultMsg.Success("更新成功!"));
     else
         return Json(ResultMsg.Failure("更新失败,请您重试!"));
 }