public void JobItemLog(JobItem jobItemModel) { Jobs_Items jobItem = new Jobs_Items() { JobId = jobItemModel.JobId, StartDate = jobItemModel.StartDate, EndDate = jobItemModel.EndDate, Status = jobItemModel.Status, TaskName = jobItemModel.TaskName, Description = jobItemModel.Description }; _repository.JobItemLog(jobItem); }
public JobItem CreateJobItemModel(Jobs_Items entity) { JobItem model = new JobItem() { Id = entity.Id, JobId = entity.JobId, TaskName = entity.TaskName, Status = entity.Status, Description = entity.Description, //StartDate = entity.StartDate.HasValue ? TimeZoneInfo.ConvertTimeToUtc(entity.StartDate.Value, TimeZoneInfo.Local) : entity.StartDate, StartDate = entity.StartDate, //EndDate = entity.EndDate.HasValue ? TimeZoneInfo.ConvertTimeToUtc(entity.EndDate.Value, TimeZoneInfo.Local) : entity.EndDate EndDate = entity.EndDate }; return(model); }