public WorkShiftView(WorkShift model) { Mapper.CreateMap <WorkShift, WorkShiftView>(); Mapper.Map <WorkShift, WorkShiftView>(model, this); this.created = model.created.ToString().Replace('T', ' '); this.updated = model.updated.ToString().Replace('T', ' '); }
public WorkShiftView(WorkShift model) { Mapper.CreateMap<WorkShift, WorkShiftView>(); Mapper.Map<WorkShift, WorkShiftView>(model, this); this.created = model.created.ToString().Replace('T', ' '); this.updated = model.updated.ToString().Replace('T', ' '); }
public WorkShift getModel() { var model = new WorkShift(); Mapper.CreateMap <WorkShiftView, WorkShift>(); Mapper.Map <WorkShiftView, WorkShift>(this, model); return(model); }
public WorkShift getModel() { var model = new WorkShift(); Mapper.CreateMap<WorkShiftView, WorkShift>(); Mapper.Map<WorkShiftView, WorkShift>(this, model); return model; }
public WorkShift createWorkShift(WorkShift model) { db.workShifts.Add(model); db.SaveChanges(); return model; }