示例#1
0
 public void CreateGridData(JobModel model)
 {
     if (model != null)
     {
         var job = Mapper.Map<Job>(model);
         this.jobsRepo.SaveOrUpdate(job);
     }
 }
示例#2
0
 public void DeleteGridData(JobModel model)
 {
     if (model != null)
     {
         var job = this.jobsRepo.FindOne(new ByIdSpecify<Job>(model.Id));
         this.jobsRepo.Delete(job);
     }
 }
示例#3
0
        public void UpdateGridData(JobModel model)
        {
            if (model != null)
            {
                var job = this.jobsRepo.FindOne(new ByIdSpecify<Job>(model.Id));
                Mapper.Map(model, job);

                this.jobsRepo.SaveOrUpdate(job);
            }
        }