예제 #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);
            }
        }