コード例 #1
0
 public ActionResult Add(StudentTeleVisitRecord e)
 {
     ActionResult ar = null;
     try {
         this.BeforeAddData(e, ref ar);
         if (ar == null) {
             this.Service.Add(e);
             e = this.Service.FindById(e.Id);
             //ar = this.Json(new AjaxOperationResult { Data = e, Successful = true });
             this.AfterAddData(e, ref ar);
         }
     } catch (Exception ex) {
         ar = this.Json(new AjaxOperationResult { Successful = false, Message = ex.Message });
     }
     return ar;
 }
コード例 #2
0
partial         void BeforeShowEditView(StudentTeleVisitRecord e);
コード例 #3
0
partial         void BeforeUpdateData(StudentTeleVisitRecord e, ref ActionResult ar);
コード例 #4
0
partial         void AfterAddData(StudentTeleVisitRecord e, ref ActionResult ar);
コード例 #5
0
partial         void AddRowToGridModel(LigerGridModel m, StudentTeleVisitRecord e);
コード例 #6
0
 public void Delete(StudentTeleVisitRecord entity)
 {
     this.Repository.Delete(entity);
     this.Db.Save();
 }
コード例 #7
0
 public void Add(StudentTeleVisitRecord entity)
 {
     this.Repository.Add(entity);
     this.Db.Save();
 }
コード例 #8
0
 public void Save(StudentTeleVisitRecord entity)
 {
     if(entity.Id==0){
         this.Add(entity);
     }else{
         this.Db.Save();
     }
 }