Exemplo n.º 1
0
        public async Task <ActionResult <TripDto> > Create(CreatingTripDto obj)
        {
            var dto  = TripMapper.toDTO(obj);
            var trip = await _service.AddAsync(dto);

            return(CreatedAtAction(nameof(GetGetById), new { Id = trip.Id }, trip));
        }