Exemple #1
0
partial         void AfterUpdateData(EmploymentStudentVisitLog e, ref ActionResult ar)
        {
            ar = this.Json(new AjaxOperationResult {
                Data = this.ToJson(e),
                Successful = true
            });
        }
Exemple #2
0
 private object ToJson(EmploymentStudentVisitLog e)
 {
     return new {
             Id=e.Id,
         StudentId=e.StudentId,
         VisitorId=e.VisitorId,
         Time=e.Time,
         Position=e.Position,
         Objective=e.Objective,
         Content=e.Content
         };
 }
Exemple #3
0
 public ActionResult Add(EmploymentStudentVisitLog 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;
 }
Exemple #4
0
partial         void BeforeUpdateData(EmploymentStudentVisitLog e, ref ActionResult ar);
Exemple #5
0
partial         void BeforeShowEditView(EmploymentStudentVisitLog e);
Exemple #6
0
partial         void AfterAddData(EmploymentStudentVisitLog e, ref ActionResult ar);
Exemple #7
0
partial         void AddRowToGridModel(LigerGridModel m, EmploymentStudentVisitLog e);
Exemple #8
0
 public void Delete(EmploymentStudentVisitLog entity)
 {
     this.Repository.Delete(entity);
     this.Db.Save();
 }
Exemple #9
0
 public void Add(EmploymentStudentVisitLog entity)
 {
     this.Repository.Add(entity);
     this.Db.Save();
 }
Exemple #10
0
 public void Save(EmploymentStudentVisitLog entity)
 {
     if(entity.Id==0){
         this.Add(entity);
     }else{
         this.Db.Save();
     }
 }
Exemple #11
0
partial         void AddRowToGridModel(LigerGridModel m, EmploymentStudentVisitLog e)
        {
            m.Rows.Add(this.ToJson(e));
        }