Example #1
0
 public static Day Map(DayRecord record)
 {
     return(new Day(
                record.DayStarted,
                record.Break,
                record.Deposit,
                record.Tasks?.Select(t => TaskMapper.Map(t)).ToList() ?? new List <TaskEntry>()));
 }
Example #2
0
 public static DayRecord Map(Day day)
 {
     return(new DayRecord
     {
         Break = day.Break,
         Deposit = day.Deposit,
         DayStarted = day.DayStarted,
         Tasks = day.Tasks.Select(t => TaskMapper.Map(t)).ToList()
     });
 }