Example #1
0
 public IEnumerable <HourRateResponseDto> GetHourRate(CreateHourRateDto hourRate)
 {
     return(_storage.GetHourRates(new HourRateQuerySearch
     {
         FromDate = hourRate.FromDate,
         TaskId = hourRate.TaskId
     }));
 }
Example #2
0
        public HourRateResponseDto CreateHourRate(CreateHourRateDto hourRate)
        {
            if (!GetHourRate(hourRate).Any())
            {
                _storage.CreateHourRate(hourRate);
            }
            else
            {
                _storage.UpdateHourRate(hourRate);
            }

            return(GetHourRate(hourRate).Single());
        }