public async Task <IReportProblemResponse> ReportProblemAsync(ReportProblemView view)
        {
            try
            {
                logger.Info($"{ GetType().Name}  {  ExtensionUtility.GetCurrentMethod() }  input: {view.ToJsonString()} UserIPAddress: { _userIPAddress.GetUserIP().Result }");

                var email = await _appDbContext.UserInfos.Where(k => k.UserId == view.UserID).Select(k => k.Email).FirstOrDefaultAsync();

                if (email == null)
                {
                    return(new ReportProblemResponse(ClientMessageConstant.UserNotFound, HttpStatusCode.NotFound));
                }

                var firstName = await _appDbContext.Profiles.Where(k => k.Id == view.UserID).Select(k => k.FirstNameEn).FirstOrDefaultAsync();

                var lastName = await _appDbContext.Profiles.Where(k => k.Id == view.UserID).Select(k => k.LastNameEn).FirstOrDefaultAsync();

                var userName = firstName + " " + lastName;

                var data = new ReportProblem()
                {
                    UserID            = view.UserID,
                    ReportDescription = view.ReportDescription,
                    Created           = DateTime.Now,
                    Modified          = DateTime.Now,
                    CreatedBy         = userName,
                    ModifiedBy        = userName,
                };

                if (view.ReportFile != null)
                {
                    data.ReportFileID = (await SaveFileAsync(view.ReportFile, email)).Id;
                }

                await _appDbContext.ReportProblems.AddAsync(data);

                await _appDbContext.SaveChangesAsync();

                await _emailService.SendReportProblemEmailAsync(view.ReportDescription, email, userName);

                var reportProblem = _mapper.Map <ReportProblemModelView>(data);

                return(new ReportProblemResponse(reportProblem));
            }
            catch (Exception ex)
            {
                logger.Error(ex);
                throw ex;
            }
        }
        public async Task <IActionResult> ReportProblemAsync([FromForm] ReportProblemView view)
        {
            var data = await _reportProblemService.ReportProblemAsync(view);

            return(Ok(data));
        }