public async Task <IActionResult> DeleteTour(int id,
                                                     [FromBody] TourInfoWriteDto tourInfo)
        {
            var deleteTour = new DeleteTour(id);

            var isCompletedSuccessfully = await _mediator.Send(deleteTour);

            return(isCompletedSuccessfully ? NoContent() : new StatusCodeResult(StatusCodes.Status500InternalServerError));
        }
        public async Task <IActionResult> UpdateTour(int id,
                                                     [FromBody] TourInfoWriteDto tourInfo)
        {
            var updateTour = new UpdateTourInfo(id, tourInfo.Number,
                                                tourInfo.StartDate, tourInfo.EndDate);

            var isCompletedSuccessfully = await _mediator.Send(updateTour);

            if (isCompletedSuccessfully)
            {
                return(new StatusCodeResult(StatusCodes.Status201Created));
            }
            else
            {
                return(new StatusCodeResult(StatusCodes.Status500InternalServerError));
            }
        }