Browse Source

Merge branch 'feature/Redmine-17825-Email_Template' of http://202.166.220.79:3000/IME-LONDON/ThirdPartyAPI into feature/Redmine-17825-Email_Template

# Conflicts:
#	ThirdPartyAPIs/App_Data/Templates/BASIC_REGISTRATION_EMAIL.html
feature/Redmine-17825-Email_Template
Leeza Baidar 8 months ago
parent
commit
a5ff4fcf4c
  1. 1
      Business/BusinessLogic/SMSApiService/SMSService.cs
  2. 4
      Common/Models/Enums/GeneralEnum.cs
  3. 1
      Common/Models/RequestResponse/TPResponse.cs
  4. 7
      Common/Utility/GetStatic.cs
  5. 6
      GMENepal/GMENepalAPIService/GMENepalAPI.cs
  6. 4
      Repository/DAO/Application/ApplicationDAO.cs
  7. 13
      Repository/DAO/ThirdParty/ThirdPartyRepo.cs
  8. 63
      ThirdPartyAPIs/App_Data/Templates/BANK_TRANSFER_TXN_CLEARED.html
  9. 10
      ThirdPartyAPIs/App_Data/Templates/BANK_TRANSFER_TXN_PENDING.html
  10. 4
      ThirdPartyAPIs/App_Data/Templates/BANK_TXN_POST.html
  11. 7
      ThirdPartyAPIs/App_Data/Templates/BASIC_REGISTRATION_EMAIL.html
  12. 4
      ThirdPartyAPIs/App_Data/Templates/CASH_TXN_POST.html
  13. 8
      ThirdPartyAPIs/App_Data/Templates/KYC_VERIFICATION_EMAIL.html
  14. 4
      ThirdPartyAPIs/App_Data/Templates/NEW_CUSTOMER_EMAIL.html
  15. 2
      ThirdPartyAPIs/App_Data/Templates/OTP_EMAIL.html
  16. 2
      ThirdPartyAPIs/Config/Mapping.json

1
Business/BusinessLogic/SMSApiService/SMSService.cs

@ -44,6 +44,7 @@ namespace Business.BusinessLogic.SMSApiService
"?username=" + _userName + "&password=" + _password +
"&number=" + model.MobileNumber + "&message=" + HttpUtility.UrlEncode(model.SMSBody) +
"&orig=" + HttpUtility.UrlEncode(_senderId);
_log.Debug(url);
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Stream resStream = response.GetResponseStream();

4
Common/Models/Enums/GeneralEnum.cs

@ -73,9 +73,7 @@ namespace Common.Models.Enums
TF_NO_BALANCE = 16,
CUSTOMER_MOBILE_NOT_REGISTER = 17,
CUSTOMER_LAWSON_REGISTER = 18,
CUSTOMER_REFERRAL_500 = 19
NEW_REGISTER_WELCOME = 17,
}
public enum JWTType

1
Common/Models/RequestResponse/TPResponse.cs

@ -12,6 +12,7 @@ namespace Common.Models.RequestResponse
public string Extra2 { get; set; }
public string Extra3 { get; set; }
public string Extra4 { get; set; }
public void SetResponse(string responseCode, string msg, string id)
{
ResponseCode = responseCode;

7
Common/Utility/GetStatic.cs

@ -86,6 +86,13 @@ namespace Common.Utility
return strVal;
}
public static String ShowTwoDecimal(String strVal)
{
if (strVal != "")
return double.Parse(strVal).ToString("0.00");
else
return strVal;
}
public static string Truncate(this string value, int maxLength)
{
var returnValue = "";

6
GMENepal/GMENepalAPIService/GMENepalAPI.cs

@ -298,12 +298,12 @@ namespace GMENepal.GMENepalAPIService
, gS.BankName, gS.BankAccountNumber, dateTxn, gS.CalculateBy, gS.FreeCharge, gS.ControlNo, gS.PayoutCurrency, gS.ReceiverCostRate
, gS.SenderCostRate, gS.Signature, "");
_response.Extra = exRateBank.ExRate;
_response.Extra = exRateBank.UsdVsNpr;
}
else
{
ThirdPartyRepo thirdPartyRepo = new ThirdPartyRepo();
var resp = thirdPartyRepo.SyncTxnAsComment(sendTransaction.ProviderId, sendTransaction.TranId.ToString(), gS.ControlNo, "", response.Msg);
thirdPartyRepo.SyncTxnAsComment(sendTransaction.ProviderId, sendTransaction.TranId.ToString(), gS.ControlNo, "", response.Msg);
_response.ResponseCode = response.ResponseCode;
_response.Msg = response.Msg;
@ -506,7 +506,7 @@ namespace GMENepal.GMENepalAPIService
CollectionAmount = sT.Transaction.CAmt,
ExRate = sT.Transaction.ExRate,
PayoutCommCurr = "NPR",
CalculateBy = "C",/*sT.Transaction.CalBy*/
CalculateBy = "P",/*sT.Transaction.CalBy*/
FreeCharge = Convert.ToString(sT.Transaction.ServiceCharge) /*sT.Transaction.IsManualSc*/
};
}

4
Repository/DAO/Application/ApplicationDAO.cs

@ -206,6 +206,10 @@ namespace Repository.DAO.Application
{
res.Extra3 = dt.Rows[0][5].ToString();
}
if (dt.Columns.Count > 6)
{
res.Extra4 = dt.Rows[0][6].ToString();
}
}
return res;
}

13
Repository/DAO/ThirdParty/ThirdPartyRepo.cs

@ -71,6 +71,7 @@ namespace Repository.DAO.ThirdParty
sql.AppendLine(", @goodsType = " + FilterString(txn.CDDI.GoodsType));
sql.AppendLine(", @portOfShipment = " + FilterString(txn.CDDI.PortOfShipment));
sql.AppendLine(", @discountedFee = " + FilterString(txn.DiscountedFee));
sql.AppendLine(", @requestedBy = " + FilterString(txn.RequestedBy));
_log.Debug("OnlineOrMobileSendTransaction | SQL: " + sql.ToString());
TPResponse res = ParseDbResult(sql);
_log.Debug("OnlineOrMobileSendTransaction | DB Response: " + JsonConvert.SerializeObject(res));
@ -640,7 +641,7 @@ namespace Repository.DAO.ThirdParty
exRateResponse.amountLimitPerTran = Convert.ToString(dt.Rows[0]["amountLimitPerTran"]);
exRateResponse.collAmt = Convert.ToString(dt.Rows[0]["collAmt"]);
exRateResponse.currDecimal = Convert.ToString(dt.Rows[0]["currDecimal"]);
exRateResponse.pAmt = Convert.ToString(dt.Rows[0]["pAmt"]);
exRateResponse.pAmt = GetStatic.ShowDecimal( Convert.ToString(dt.Rows[0]["pAmt"]));
exRateResponse.sAmt = Convert.ToString(dt.Rows[0]["sAmt"]);
exRateResponse.collCurr = Convert.ToString(dt.Rows[0]["collCurr"]);
exRateResponse.disc = Convert.ToString(dt.Rows[0]["disc"]);
@ -676,9 +677,11 @@ namespace Repository.DAO.ThirdParty
}
}
if (exRateResponse.isSCExcluded && model.RequestedBy.ToLower().Equals("online"))
if (!string.IsNullOrEmpty( model.CouponCode) && model.CouponCode.ToLower().Equals("android"))
{
exRateResponse.collAmt = Convert.ToString(Convert.ToDouble(exRateResponse.collAmt) - Convert.ToDouble(exRateResponse.scCharge));
exRateResponse.collAmt = GetStatic.ShowDecimal(exRateResponse.collAmt);
exRateResponse.sAmt = GetStatic.ShowDecimal(exRateResponse.sAmt);
exRateResponse.scCharge = GetStatic.ShowTwoDecimal(exRateResponse.scCharge);
}
tPResponse.Data = exRateResponse;
@ -1011,7 +1014,7 @@ namespace Repository.DAO.ThirdParty
return ParseDbResult(sb);
}
public TPResponse SyncTxnAsComment(string provider, string tranId, string ControlNo, string status, string msg)
public void SyncTxnAsComment(string provider, string tranId, string ControlNo, string status, string msg)
{
string sql = "EXEC PROC_TP_TXN_PUSH @flag='add-job-txn-comment'";
sql += ",@PROVIDER = " + FilterString(provider);
@ -1020,7 +1023,7 @@ namespace Repository.DAO.ThirdParty
sql += ",@status = " + FilterString(status);
sql += ",@user = " + FilterString("TxnPushJob");
StringBuilder sb = new StringBuilder(sql);
return ParseDbResult(sb);
ExecuteDataset(sb);
}
}
}

63
ThirdPartyAPIs/App_Data/Templates/BANK_TRANSFER_TXN_CLEARED.html

@ -2,14 +2,15 @@
<body>
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 20px">
<div style="text-align: right;">
<img src="https://japanremit.com/assets/img/jmelogo.jpg" alt="IME London" class="CToWUd" height="90">
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 10px">
<div style="text-align: left;">
<img src="https://imelondon.co.uk/assets/images/logo.png" alt="imelondon" class="CToWUd" height="50" width="150" style="height: 50px;width:150;border:0;" >
<img src="https://imelondon.co.uk/assets/dist/images/imelondan.svg" alt="imelondon" class="CToWUd" height="50" width="155" style="height: 50px;width:155px;border:0;">
</div>
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />
<div class="body">
Dear <strong>{CustomerName}</strong>,
@ -28,54 +29,54 @@
<td>
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td>Payout Country:</td>
<td>{PayoutCountry}</td>
<td>Payout Country</td>
<td> : {PayoutCountry}</td>
</tr>
<tr>
<td>Beneficiary Name:</td>
<td>{BeneName}</td>
<td>Receiver Name </td>
<td> : {BeneName}</td>
</tr>
<tr>
<td>Transfer Type:</td>
<td>{TransferType}</td>
<td>Transfer Type</td>
<td> : {TransferType}</td>
</tr>
<tr>
<td>Bank Name:</td>
<td>{BankName}</td>
<td>Bank Name</td>
<td> : {BankName}</td>
</tr>
<tr>
<td>Bank Branch:</td>
<td>{BankBranch}</td>
<td>Bank Branch</td>
<td> : {BankBranch}</td>
</tr>
<tr>
<td>Bank Account No:</td>
<td>{AccNum}</td>
<td>Bank Account No</td>
<td> : {AccNum}</td>
</tr>
<tr>
<td>Payout Amount:</td>
<td>{PayoutAmt}</td>
<td>Payout Amount</td>
<td> : {PayoutAmt}</td>
</tr>
<tr>
<td>Transfer Amount:</td>
<td>{TransferAmt}</td>
<td>Transfer Amount</td>
<td> : {TransferAmt}</td>
<tr>
<td>Exchange Rate:</td>
<td>{ExRate}</td>
<td>Exchange Rate</td>
<td> : {ExRate}</td>
<tr>
<td>Fee:</td>
<td>{Fee}</td>
<td>Fee</td>
<td> : {Fee}</td>
</tr>
<tr>
<td>Discount:</td>
<td>{Discount}</td>
<td>Discount</td>
<td> : {Discount}</td>
</tr>
<tr>
<td>Total Amount:</td>
<td>{TotalAmt}</td>
<td>Total Amount</td>
<td> : {TotalAmt}</td>
</tr>
<tr>
<td>Transaction Date:</td>
<td>{TxnDate}</td>
<td>Transaction Date</td>
<td> : {TxnDate}</td>
</tr>
</table>
</td>
@ -86,7 +87,7 @@
<p style="margin-top: 20px">
If there is any mistake in the details and needs correction, Please contact us. <br /> <br />
Once the transaction is approved by us, you will receive an email with the Pin number which should be forwarded to your receiver. <br />
Once the transaction is approved by us, you will receive an email with the Reference number which should be forwarded to your receiver. <br />
</p>

10
ThirdPartyAPIs/App_Data/Templates/BANK_TRANSFER_TXN_PENDING.html

@ -3,9 +3,9 @@
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 20px">
<div style="text-align: right;">
<!--<div style="text-align: right;">
<img src="https://japanremit.com/assets/img/jmelogo.jpg" alt="IME London" class="CToWUd" height="90">
</div>
</div>-->
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />
@ -14,7 +14,7 @@
Dear <strong>{CustomerName}</strong>,
<p style="margin-top: 20px">
Thank you for your transaction. Please kindly deposit the total amount of £XXX.00 in the following bank account. Your transaction
Thank you for your transaction. Please kindly deposit the total amount of £{CollectAmt} in the following bank account. Your transaction
will be released once the amount is credited in our account with the reference number given below. If we do not get the deposit in two working days,
your transaction will be cancelled. Please note that the transfer amount should exactly match with your transaction amount.<br />
<b>You can now start sending money to your loved ones. </b>
@ -25,8 +25,8 @@
<ol style=" list-style-type: none; /* Remove bullets */ padding: 0; /* Remove padding */ margin-left: 30px; /* Remove margins */">
<li>Bank Name: CLEAR BANK </li>
<li>Account Name: IME LONDON </li>
<li>Sort Code: 04-06-93 </li>
<li>Accoutn Number: 00000151 </li>
<li>Sort Code: 04-08-42 </li>
<li>Accoutn Number: 00000042 </li>
<li>Reference: {CustomerName} </li>
<li><b>Subhida UK Ltd is the registered name of IME London.</b></li>
</ol>

4
ThirdPartyAPIs/App_Data/Templates/BANK_TXN_POST.html

@ -3,9 +3,9 @@
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 20px">
<div style="text-align: right;">
<!--<div style="text-align: right;">
<img src="https://japanremit.com/assets/img/jmelogo.jpg" alt="IME London" class="CToWUd" height="90">
</div>
</div>-->
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />

7
ThirdPartyAPIs/App_Data/Templates/BASIC_REGISTRATION_EMAIL.html

@ -2,13 +2,10 @@
<body>
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 10px">
<div style="text-align: left;">
<img src="https://imelondon.co.uk/assets/images/logo.png" alt="imelondon" class="CToWUd" height="50" width="150" style="height: 50px;width:150;border:0;" >
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 1px">
<img src="https://imelondon.co.uk/assets/dist/images/imelondan.svg" alt="imelondon" class="CToWUd" height="50" width="155" style="height: 50px;width:155px;border:0;">
</div>
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />
<div class="body">

4
ThirdPartyAPIs/App_Data/Templates/CASH_TXN_POST.html

@ -3,9 +3,9 @@
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 20px">
<div style="text-align: right;">
<!--<div style="text-align: right;">
<img src="https://japanremit.com/assets/img/jmelogo.jpg" alt="IME London" class="CToWUd" height="90">
</div>
</div>-->
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />

8
ThirdPartyAPIs/App_Data/Templates/KYC_VERIFICATION_EMAIL.html

@ -19,7 +19,11 @@
</p>
<p style="margin-top: 20px">
<b>Please use the Referral CODE {RefCode} to Invite your friends and get 10 £ as our signing gift. </b><br />
Please use the referal code <b>
{RefCode}
</b> to invite your friends and get 1£ after your friend sucessfully registers and 4 £ after sending the transaction.
<br />
** Terms and Condition applied
</p>
@ -44,7 +48,7 @@
</div>
<p style="margin-top: 20px;">
Thank you! <br />
IME London Team <br/>
IME London Team <br />
</p>

4
ThirdPartyAPIs/App_Data/Templates/NEW_CUSTOMER_EMAIL.html

@ -3,9 +3,9 @@
<div style="color:#434444; padding: 15px; font-family: Roboto; font-size: 15px; margin-top: 20px">
<div style="text-align: right;">
<!--<div style="text-align: right;">
<img src="https://japanremit.com/assets/img/jmelogo.jpg" alt="Japan Money Express" class="CToWUd" height="90">
</div>
</div>-->
<br />
<hr style="background-color: #fff; border-top: 1.5px solid #2B3C90; border-bottom: none;" />

2
ThirdPartyAPIs/App_Data/Templates/OTP_EMAIL.html

@ -14,7 +14,7 @@
</p>
<p style="margin-top: 20px">
Please contact Customer Care at <strong>02088660307 </strong>at 9:30 AM- 6:30 PM or email to info@imelondon.co.uk if you need further assistance. <br />
Please contact Customer Care at <strong>02088660307 </strong>at 6.00 AM- 6:00 PM or email to info@imelondon.co.uk if you need further assistance. <br />
</p>

2
ThirdPartyAPIs/Config/Mapping.json

@ -74,7 +74,7 @@
"Mappings": [
{
"SValue": "NEW_REGISTER_WELCOME",
"SText": "You have successfully register to JME \n Remmittance System.",
"SText": "You have successfully register to IME London. Now you are able to send transaction",
"DText": "Welcome",
"DValue": "en"
},

Loading…
Cancel
Save