Esempio n. 1
0
        public void MakeInquiry(CreateInquiryDto inquiryDto)
        {
            Inquiry inquiry = _mapper.Map <Inquiry>(inquiryDto);

            _repositoryFactory.InquiryRepository.Create(inquiry);
            _logger.LogInformation("Inquiry Successfully Created");
        }
Esempio n. 2
0
 public IActionResult MakeInquiry([FromBody] CreateInquiryDto createInquiry)
 {
     if (!ModelState.IsValid)
     {
         return(BadRequest(ModelState));
     }
     try
     {
         _inquiryService.MakeInquiry(createInquiry);
         return(Ok());
     }
     catch (Exception ex)
     {
         return(BadRequest(ex.Message));
     }
 }