Browse Source

Change Request #18887 Verify Your Account Feature

Mobile-pdf
shakun 1 year ago
parent
commit
b86de7c98c
  1. 10
      Business/Mobile/MobileServices.cs
  2. 11
      Business/SendMoney/SendMoneyBusiness.cs
  3. 3
      Common/Model/LoginResponse.cs
  4. 40
      JsonRx/Api/SendMoneyController.cs
  5. 4
      JsonRx/AuthFilter/TokenAuthenticationAttribute.cs
  6. 8
      JsonRx/Config/ResponseMsg.json
  7. 1
      JsonRx/Helper/Util.cs
  8. 3
      Repository/Mobile/MobileServicesRepo.cs

10
Business/Mobile/MobileServices.cs

@ -1972,8 +1972,11 @@ namespace Business.Mobile
if (res.ErrorCode == "0") if (res.ErrorCode == "0")
{ {
try
{
List<Notify.Mapping> bodyMappings = new List<Notify.Mapping>(); List<Notify.Mapping> bodyMappings = new List<Notify.Mapping>();
bodyMappings.Add(new Notify.Mapping() { SValue = "CustomerName", SText = pwdReset.Username });
bodyMappings.Add(new Notify.Mapping() { SValue = "CustomerName", SText = res.Extra2 });
bodyMappings.Add(new Notify.Mapping() { SValue = "EMAIL_ID", SText = pwdReset.Username });
bodyMappings.Add(new Notify.Mapping() { SValue = "PASS_WORD", SText = randomPassword }); bodyMappings.Add(new Notify.Mapping() { SValue = "PASS_WORD", SText = randomPassword });
SendNotificationRequest request = new SendNotificationRequest() SendNotificationRequest request = new SendNotificationRequest()
@ -2013,7 +2016,12 @@ namespace Business.Mobile
}; };
APIJsonResponse _resp = _sendAPI.SMSTPApi(_req); APIJsonResponse _resp = _sendAPI.SMSTPApi(_req);
res = NotifierV2.SendNotification(request, NOTIFICATION_TYPE.EMAIL); res = NotifierV2.SendNotification(request, NOTIFICATION_TYPE.EMAIL);
}
catch (Exception ex)
{
Log.Error("ResetPassword.SendNotification", ex);
}
var map = Utilities.GetLanguageMapping(RESPONSE_MSG.SEND_EMAIL_FOR_RESETPASSWORD_SUCCESS.ToString(), lang); var map = Utilities.GetLanguageMapping(RESPONSE_MSG.SEND_EMAIL_FOR_RESETPASSWORD_SUCCESS.ToString(), lang);
return new JsonRxResponse { ErrorCode = "0", Msg = map.Message }; return new JsonRxResponse { ErrorCode = "0", Msg = map.Message };

11
Business/SendMoney/SendMoneyBusiness.cs

@ -36,12 +36,13 @@ namespace Business.SendMoney
private readonly ThirdPartyAPI _tpApi = new ThirdPartyAPI(); private readonly ThirdPartyAPI _tpApi = new ThirdPartyAPI();
private static readonly ILog Log = LogManager.GetLogger(typeof(SendMoneyBusiness)); private static readonly ILog Log = LogManager.GetLogger(typeof(SendMoneyBusiness));
public SendMoneyBusiness(ISendMoneyRepository repo, IKftcProcessBusiness kftcBuss, IRewardRepository irewardrepo, ICouponRepository icouponrepo)
public SendMoneyBusiness(ISendMoneyRepository repo, IKftcProcessBusiness kftcBuss, IRewardRepository irewardrepo, ICouponRepository icouponrepo, IMobileServicesRepo requestServices)
{ {
_repo = repo; _repo = repo;
_kftcBuss = kftcBuss; _kftcBuss = kftcBuss;
_irewardrepo = irewardrepo; _irewardrepo = irewardrepo;
this.icouponrepo = icouponrepo; this.icouponrepo = icouponrepo;
_requestServices = requestServices;
} }
public JsonRxResponse LoadCountryServiceDetail(CountryServiceModel request) public JsonRxResponse LoadCountryServiceDetail(CountryServiceModel request)
@ -514,6 +515,8 @@ namespace Business.SendMoney
{ {
string email = model.User; string email = model.User;
try
{
UserDetails userDetails = _requestServices.GetUserDetails(email); UserDetails userDetails = _requestServices.GetUserDetails(email);
List<Notify.Mapping> bodyMappings = new List<Notify.Mapping>(); List<Notify.Mapping> bodyMappings = new List<Notify.Mapping>();
@ -539,8 +542,14 @@ namespace Business.SendMoney
} }
} }
}; };
NotifierV2.SendNotification(request, NOTIFICATION_TYPE.EMAIL);
} }
catch (Exception ex)
{
Log.Error("BankTransferTxnPendingStatus", ex);
}
}
return response; return response;
} }
catch (Exception ex) catch (Exception ex)

3
Common/Model/LoginResponse.cs

@ -63,6 +63,9 @@ namespace Common.Model
public string UseNFC { get; set; } public string UseNFC { get; set; }
public string SelfieDocPath { get; set; } public string SelfieDocPath { get; set; }
public bool KycVerified { get; set; }
public string KycStatus { get; set; }
public string KycStatusMsg { get; set; }
} }
public class AppUpdate public class AppUpdate

40
JsonRx/Api/SendMoneyController.cs

@ -140,43 +140,7 @@ namespace JsonRx.Api
{ {
//model.senderId = Util.GetCustomerId(Request); //model.senderId = Util.GetCustomerId(Request);
var res = _bussiness.Calculate(model); var res = _bussiness.Calculate(model);
if (res.ErrorCode.Equals("1"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_1.ToString();
}
else if (res.ErrorCode.Equals("2"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_2.ToString();
}
else if (res.ErrorCode.Equals("3"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_3.ToString();
}
else if (res.ErrorCode.Equals("4"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_4.ToString();
}
else if (res.ErrorCode.Equals("5"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_5.ToString();
}
else if (res.ErrorCode.Equals("6"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_6.ToString();
}
else if (res.ErrorCode.Equals("7"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_7.ToString();
}
else if (res.ErrorCode.Equals("8"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_8.ToString();
}
else if (res.ErrorCode.Equals("9"))
{
enumString = RESPONSE_MSG.CALCULATE_AMOUNT_FAIL_9.ToString();
}
var map = Utilities.GetLanguageMapping(enumString, lang);
res.FootNoteMessage = res.ErrorCode.Equals("0") ? Utilities.GetLanguageMapping(ConfigurationManager.AppSettings["footNote_calculateSendMoney"].ToString(), lang).Message : ""; res.FootNoteMessage = res.ErrorCode.Equals("0") ? Utilities.GetLanguageMapping(ConfigurationManager.AppSettings["footNote_calculateSendMoney"].ToString(), lang).Message : "";
@ -188,7 +152,7 @@ namespace JsonRx.Api
res.FootNoteMessage = $"{ res.FootNoteMessage}. {d["schemeAppliedMsg"].ToString()}"; res.FootNoteMessage = $"{ res.FootNoteMessage}. {d["schemeAppliedMsg"].ToString()}";
} }
} }
return Ok(new JsonRxResponse { ErrorCode = res.ErrorCode.Equals("0") ? "0" : "1", Msg = map.Message, Data = res.Data, FootNoteMessage = res.FootNoteMessage });
return Ok(new JsonRxResponse { ErrorCode = res.ErrorCode.Equals("0") ? "0" : "1", Msg = res.Msg, Data = res.Data, FootNoteMessage = res.FootNoteMessage });
//return Ok(res); //return Ok(res);
} }

4
JsonRx/AuthFilter/TokenAuthenticationAttribute.cs

@ -54,7 +54,7 @@ namespace JsonRx.AuthFilter
catch catch
{ {
} }
var actionName = actionContext.ActionDescriptor.ActionName;
CallContext.SetData("language", lang); CallContext.SetData("language", lang);
HttpResponseMessage httpResponse; HttpResponseMessage httpResponse;
@ -166,7 +166,7 @@ namespace JsonRx.AuthFilter
} }
catch (Exception ex) catch (Exception ex)
{ {
Log.Error("TokenAuthenticationAttribute Exception", ex);
Log.Error("TokenAuthenticationAttribute Exception: " + actionName+ "|" + token, ex);
httpResponse = actionContext.Request.CreateResponse(HttpStatusCode.InternalServerError, new JsonRxResponse httpResponse = actionContext.Request.CreateResponse(HttpStatusCode.InternalServerError, new JsonRxResponse
{ {
ErrorCode = "1", ErrorCode = "1",

8
JsonRx/Config/ResponseMsg.json

@ -1841,7 +1841,7 @@
}, },
{ {
"Key": "FOOTNOTE_CALCULATE_SENDMONEY", "Key": "FOOTNOTE_CALCULATE_SENDMONEY",
"Message": "Please include additional JPY 300 if you are depositing with JME Remittance Card.",
"Message": "XXXXXXXXXXXXXXXXXXXXX",
"Lang": "en" "Lang": "en"
}, },
{ {
@ -1871,7 +1871,7 @@
}, },
{ {
"Key": "INVITE_MESSAGE_TITLE", "Key": "INVITE_MESSAGE_TITLE",
"Message": "Earn up to JPY 500 worth of Referral Points.",
"Message": "Receive a FREE 5£ bonus credit as Reward amount",
"Lang": "en" "Lang": "en"
}, },
{ {
@ -1901,7 +1901,7 @@
}, },
{ {
"Key": "INVITE_MESSAGE_BODY", "Key": "INVITE_MESSAGE_BODY",
"Message": "Get 100 points immediately after successful registration and 400 points after his/her first transaction.",
"Message": "You and your friend will each be given £5.00 in bonus credit. Get £1 after they successfully register, and £4 after their first transaction. There may be minimum send requirements. Terms and Conditions.",
"Lang": "en" "Lang": "en"
}, },
{ {
@ -1931,7 +1931,7 @@
}, },
{ {
"Key": "REWARD_POINTS_MESSAGE", "Key": "REWARD_POINTS_MESSAGE",
"Message": "You have @point reward point available",
"Message": "You have @point reward amount available",
"Lang": "en" "Lang": "en"
}, },
{ {

1
JsonRx/Helper/Util.cs

@ -2,6 +2,7 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Configuration; using System.Configuration;
using System.Globalization;
using System.IdentityModel.Tokens.Jwt; using System.IdentityModel.Tokens.Jwt;
using System.IO; using System.IO;
using System.Linq; using System.Linq;

3
Repository/Mobile/MobileServicesRepo.cs

@ -1591,6 +1591,9 @@ namespace Repository.Mobile
ResidenceType = Convert.ToString(dataTable.Rows[0]["ResidenceType"]), ResidenceType = Convert.ToString(dataTable.Rows[0]["ResidenceType"]),
UseNFC = Convert.ToString(dataTable.Rows[0]["UseNFC"]), UseNFC = Convert.ToString(dataTable.Rows[0]["UseNFC"]),
SelfieDocPath = Convert.ToString(dataTable.Rows[0]["SelfieDoc"]).Replace("////", "/"), SelfieDocPath = Convert.ToString(dataTable.Rows[0]["SelfieDoc"]).Replace("////", "/"),
KycVerified=false,
KycStatus= "Processing",
KycStatusMsg= "ID Document Submission is in Processing",
// IsForcedPwdchange = Convert.ToString(dataTable.Rows[0]["IsForcedPwdChange"]), // IsForcedPwdchange = Convert.ToString(dataTable.Rows[0]["IsForcedPwdChange"]),
appUpdate = app appUpdate = app
}; };

Loading…
Cancel
Save