Beispiel #1
0
        public HardwarePanelDto AddHardwarePanel(AddHardwarePanelDto hardwarePanelDto)
        {
            var hardwarePanel = new HardwarePanel
            {
                Name               = hardwarePanelDto.HardwarePanelName,
                AircraftModel      = _aircraftModelRepository.GetById(hardwarePanelDto.AircraftModel),
                CockpitArea        = (CockpitArea)hardwarePanelDto.CockpitArea,
                HardwarePanelOwner = (HardwarePanelOwner)hardwarePanelDto.HardwarePanelOwner
            };

            hardwarePanel = _hardwarePanelRepository.AddHardwarePanel(hardwarePanel);
            return(_mapper.Map <HardwarePanel, HardwarePanelDto>(hardwarePanel));
        }
 public HardwarePanelDto AddHardwarePanel(AddHardwarePanelDto hardwarePanelDto)
 {
     return(_hardwarePanelService.AddHardwarePanel(hardwarePanelDto));
 }