Пример #1
0
 public Leg FromDTO(LegDTO legDto)
 {
    return new Leg(
       _locationRepository.Find(new UnLocode(legDto.From)),
       legDto.LoadTime,
       _locationRepository.Find(new UnLocode(legDto.To)),
       legDto.UnloadTime);
 }
 public Leg FromDTO(LegDTO legDto)
 {
     return(new Leg(
                _locationRepository.Find(new UnLocode(legDto.LoadLocation)),
                legDto.LoadDate,
                _locationRepository.Find(new UnLocode(legDto.UnloadLocation)),
                legDto.UnloadDate));
 }
Пример #3
0
 public Leg FromDTO(LegDTO legDto)
 {
    var voyage = _voyageRepository.Find(legDto.VoyageId);
    return new Leg(voyage, _locationRepository.Find(new UnLocode(legDto.From)),
       legDto.LoadTime,
       _locationRepository.Find(new UnLocode(legDto.To)),
       legDto.UnloadTime);
 }
Пример #4
0
 public Leg FromDTO(LegDTO legDto)
 {
     return(new Leg(
                _locationRepository.Find(new UnLocode(legDto.From)),
                legDto.LoadTime,
                _locationRepository.Find(new UnLocode(legDto.To)),
                legDto.UnloadTime));
 }
Пример #5
0
        public Leg FromDTO(LegDTO legDto)
        {
            var voyage = _voyageRepository.Find(legDto.VoyageId);

            return(new Leg(voyage, _locationRepository.Find(new UnLocode(legDto.From)),
                           legDto.LoadTime,
                           _locationRepository.Find(new UnLocode(legDto.To)),
                           legDto.UnloadTime));
        }