Browse Source

dashobard made dynamic

feature/Redmine-18711-Receiver_Module_for_Web
arjundhami123 1 year ago
parent
commit
539a4aeaf1
  1. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/DesignTimeBuild/.dtbcache.v2
  2. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/8cc015c1-aea9-4d15-84d0-91327ad1934f.vsidx
  3. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/dd47eca8-e44a-40ca-b0c7-8b11e911b0e9.vsidx
  4. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/dd6572ed-0f7d-4953-bb34-95fd8cf2d9f4.vsidx
  5. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/e201466f-7afd-4ac3-ab72-025f5b13ea31.vsidx
  6. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/v17/.futdcache.v2
  7. BIN
      CustomerOnlineRemit/.vs/CustomerOnlineRemit/v17/.suo
  8. BIN
      CustomerOnlineRemit/.vs/ProjectEvaluation/customeronlineremit.metadata.v7.bin
  9. BIN
      CustomerOnlineRemit/.vs/ProjectEvaluation/customeronlineremit.projects.v7.bin
  10. 16
      CustomerOnlineRemit/CustomerOnlineRemit.Business/Business/Account/AccountBusiness.cs
  11. 4
      CustomerOnlineRemit/CustomerOnlineRemit.Business/Business/Account/IAccountBusiness.cs
  12. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Business.dll
  13. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Business.pdb
  14. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll
  15. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb
  16. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll
  17. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb
  18. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.csproj.AssemblyReference.cache
  19. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.dll
  20. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.pdb
  21. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/ref/CustomerOnlineRemit.Business.dll
  22. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/refint/CustomerOnlineRemit.Business.dll
  23. 37
      CustomerOnlineRemit/CustomerOnlineRemit.Common/Helper/Utilities.cs
  24. 5
      CustomerOnlineRemit/CustomerOnlineRemit.Common/Model/CommonResponse.cs
  25. 41
      CustomerOnlineRemit/CustomerOnlineRemit.Common/Model/Customer/CustomerModel.cs
  26. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll
  27. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb
  28. 2
      CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.csproj.CoreCompileInputs.cache
  29. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.dll
  30. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.pdb
  31. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/ref/CustomerOnlineRemit.Common.dll
  32. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/refint/CustomerOnlineRemit.Common.dll
  33. 143
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/Repository/Account/AccountRepository.cs
  34. 7
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/Repository/Account/IAccountRepository.cs
  35. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll
  36. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb
  37. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll
  38. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb
  39. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.csproj.AssemblyReference.cache
  40. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.dll
  41. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.pdb
  42. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/ref/CustomerOnlineRemit.Repository.dll
  43. BIN
      CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/refint/CustomerOnlineRemit.Repository.dll
  44. 0
      CustomerOnlineRemit/CustomerOnlineRemit/Components/CustomButtonComponent.razor
  45. 83
      CustomerOnlineRemit/CustomerOnlineRemit/Components/ReceiverListComponent.razor
  46. 134
      CustomerOnlineRemit/CustomerOnlineRemit/Components/TableComponent.razor
  47. 0
      CustomerOnlineRemit/CustomerOnlineRemit/Components/ToastAlertComponent.razor
  48. 82
      CustomerOnlineRemit/CustomerOnlineRemit/Components/TransactionListComponent.razor
  49. 5
      CustomerOnlineRemit/CustomerOnlineRemit/Components/UserLeftView.razor
  50. 24
      CustomerOnlineRemit/CustomerOnlineRemit/Data/Account/AccountServices.cs
  51. 4
      CustomerOnlineRemit/CustomerOnlineRemit/Data/Account/IAccountServices.cs
  52. 253
      CustomerOnlineRemit/CustomerOnlineRemit/Pages/Dashboard.razor
  53. 10
      CustomerOnlineRemit/CustomerOnlineRemit/Pages/Login.razor
  54. 2
      CustomerOnlineRemit/CustomerOnlineRemit/Program.cs
  55. 68
      CustomerOnlineRemit/CustomerOnlineRemit/Shared/MainLayout.razor
  56. 7
      CustomerOnlineRemit/CustomerOnlineRemit/_Imports.razor
  57. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Business.dll
  58. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Business.pdb
  59. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll
  60. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb
  61. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll
  62. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb
  63. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.dll
  64. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.pdb
  65. 20
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.GeneratedMSBuildEditorConfig.editorconfig
  66. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.csproj.AssemblyReference.cache
  67. 16
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.csproj.FileListAbsolute.txt
  68. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.dll
  69. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.pdb
  70. 2
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/project.razor.vs.json
  71. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/ref/CustomerOnlineRemit.dll
  72. BIN
      CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/refint/CustomerOnlineRemit.dll
  73. 44
      DB/PROC_DYNAMIC_TABLE.sql

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/DesignTimeBuild/.dtbcache.v2

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/8cc015c1-aea9-4d15-84d0-91327ad1934f.vsidx

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/dd47eca8-e44a-40ca-b0c7-8b11e911b0e9.vsidx

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/dd6572ed-0f7d-4953-bb34-95fd8cf2d9f4.vsidx

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/FileContentIndex/e201466f-7afd-4ac3-ab72-025f5b13ea31.vsidx

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/v17/.futdcache.v2

BIN
CustomerOnlineRemit/.vs/CustomerOnlineRemit/v17/.suo

BIN
CustomerOnlineRemit/.vs/ProjectEvaluation/customeronlineremit.metadata.v7.bin

BIN
CustomerOnlineRemit/.vs/ProjectEvaluation/customeronlineremit.projects.v7.bin

16
CustomerOnlineRemit/CustomerOnlineRemit.Business/Business/Account/AccountBusiness.cs

@ -1,6 +1,7 @@
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Repository.Repository.Account;
using CustomerOnlineRemit.Common.Model.Customer;
namespace CustomerOnlineRemit.Business.Business.Account
{
@ -16,5 +17,20 @@ namespace CustomerOnlineRemit.Business.Business.Account
{
return _accountRepo.DoLoginAsync(loginModel);
}
public Task<CommonResponse> GetDynamicTable(string flag)
{
return _accountRepo.GetDynamicTable(flag);
}
public Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll)
{
return _accountRepo.GetCustomerReceiverList(ShowAll);
}
public Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll)
{
return _accountRepo.GetCustomerTransactionList(ShowAll);
}
}
}

4
CustomerOnlineRemit/CustomerOnlineRemit.Business/Business/Account/IAccountBusiness.cs

@ -1,10 +1,14 @@
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Common.Model.Customer;
namespace CustomerOnlineRemit.Business.Business.Account
{
public interface IAccountBusiness
{
Task<LoginResponse> DoLoginAsync(LoginModel loginModel);
Task<CommonResponse> GetDynamicTable(string flag);
Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll);
Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll);
}
}

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Business.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Business.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.csproj.AssemblyReference.cache

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/CustomerOnlineRemit.Business.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/ref/CustomerOnlineRemit.Business.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Business/obj/Debug/net7.0/refint/CustomerOnlineRemit.Business.dll

37
CustomerOnlineRemit/CustomerOnlineRemit.Common/Helper/Utilities.cs

@ -1,5 +1,7 @@
using CustomerOnlineRemit.Common.Configuration;
using CustomerOnlineRemit.Common.Model.Customer;
using Newtonsoft.Json;
using System.Data;
using System.Text.Json.Serialization;
namespace CustomerOnlineRemit.Common.Helper
@ -21,6 +23,41 @@ namespace CustomerOnlineRemit.Common.Helper
}
}
public static dynamic ParseTableData(string flag, DataTable dt)
{
dynamic list = null;
if (flag.ToLower().Equals("customertxn"))
{
List<CustomerTransaction> obj = new List<CustomerTransaction>();
foreach (DataRow item in dt.Rows)
{
obj.Add(new CustomerTransaction
{
Id = Convert.ToString(item["Id"]),
Amount = Convert.ToString(item["Amount"]),
Status = Convert.ToString(item["Status"])
});
}
list = obj;
}
else if (flag.ToLower().Equals("customerreceiver"))
{
List<CustomerModel> obj = new List<CustomerModel>();
foreach (DataRow item in dt.Rows)
{
obj.Add(new CustomerModel
{
Id = Convert.ToString(item["Id"]),
Name = Convert.ToString(item["Name"]),
Country = Convert.ToString(item["Country"]),
TransactionType = Convert.ToString(item["TransactionType"])
});
}
list = obj;
}
return list;
}
public static string ReadFromAppSettings(string key, string defValue = "")
{
return ConfigurationManager.AppSettings[key] ?? defValue;

5
CustomerOnlineRemit/CustomerOnlineRemit.Common/Model/CommonResponse.cs

@ -29,11 +29,12 @@
}
public string Id { get; set; }
public object Data { get; set; }
public dynamic Data { get; set; }
public List<dynamic> ListData { get; set; }
public string Extra { get; set; }
public string Extra2 { get; set; }
public CommonResponse SetResponse(int ResponseCode, string ResponseMessage, object Data = null)
public CommonResponse SetResponse(int ResponseCode, string ResponseMessage, dynamic Data = null)
{
return new CommonResponse(ResponseCode, ResponseMessage, Data);
}

41
CustomerOnlineRemit/CustomerOnlineRemit.Common/Model/Customer/CustomerModel.cs

@ -0,0 +1,41 @@
namespace CustomerOnlineRemit.Common.Model.Customer
{
public class CustomerModel
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Country { get; set; }
public string? TransactionType { get; set; }
}
public class ReceiverModel
{
public string? Id { get; set; }
public string? Name { get; set; }
public string? Country { get; set; }
public string? Mobile { get; set; }
public string? TransactionType { get; set; }
}
public class CustomerReceiverModel : CommonResponse
{
public List<ReceiverModel> ReceiverModel { get; set; }
}
public class CustomerTransactionList : CommonResponse
{
public List<CustomerTransaction> CustomerTransaction { get; set; }
}
public class CustomerTransaction
{
public string? Id { get; set; }
public string? TransactionMonth { get; set; }
public string? TransactionDay { get; set; }
public string? PaymentMethod { get; set; }
public string? PBankName { get; set; }
public string? Amount { get; set; }
public string? Status { get; set; }
public string? PCurrency { get; set; }
}
}

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb

2
CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.csproj.CoreCompileInputs.cache

@ -1 +1 @@
920738b58fa01e910179d0d32059cfc1af0f04e5
4c32cd9b794c31d1353d906504e2aa2fefe95958

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/CustomerOnlineRemit.Common.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/ref/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Common/obj/Debug/net7.0/refint/CustomerOnlineRemit.Common.dll

143
CustomerOnlineRemit/CustomerOnlineRemit.Repository/Repository/Account/AccountRepository.cs

@ -2,6 +2,9 @@
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Repository.ConnectionServices;
using Newtonsoft.Json;
using CustomerOnlineRemit.Common.Helper;
using CustomerOnlineRemit.Common.Model.Customer;
using System.Data;
namespace CustomerOnlineRemit.Repository.Repository.Account
{
@ -66,5 +69,145 @@ namespace CustomerOnlineRemit.Repository.Repository.Account
}
return Task.FromResult(_response);
}
public Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll)
{
CustomerReceiverModel _response = new CustomerReceiverModel();
try
{
var sql = "EXEC PROC_DYNAMIC_TABLE";
sql += " @Flag = " + _dbHelper.FilterString("CustomerReceiver");
sql += " @ShowAll = " + _dbHelper.FilterString(ShowAll.ToString());
Log.Debug("ACCOUNTREPOSITORY | GETCUSTOMERRECEIVERLIST | SQL | " + sql);
var dt = _dbHelper.ExecuteDataTable(sql);
if (dt == null || dt.Rows.Count <= 0)
{
_response.ResponseCode = ResponseHelper.FAILED;
_response.ResponseMessage = "DB Null Error!";
Log.Error("ACCOUNTREPOSITORY | GETCUSTOMERRECEIVERLIST | DB RESPONSE | " + JsonConvert.SerializeObject(_response));
}
else
{
_response.ResponseCode = Convert.ToInt16(dt.Rows[0]["errorCode"]);
_response.ResponseMessage = Convert.ToString(dt.Rows[0]["msg"]);
List<ReceiverModel> obj = new List<ReceiverModel>();
foreach (DataRow item in dt.Rows)
{
obj.Add(new ReceiverModel
{
Id = Convert.ToString(item["Id"]),
Name = Convert.ToString(item["Name"]),
Mobile = Convert.ToString(item["Mobile"]),
Country = Convert.ToString(item["Country"]),
TransactionType = Convert.ToString(item["TransactionType"])
});
}
_response.ReceiverModel = obj;
}
}
catch (Exception ex)
{
_response.ResponseCode = ResponseHelper.EXCEPTION;
_response.ResponseMessage = "Exception occured: " + ex.Message;
Log.Error("ACCOUNTREPOSITORY | GETCUSTOMERRECEIVERLIST | EXCEPTION | " + JsonConvert.SerializeObject(_response));
}
return Task.FromResult(_response);
}
public Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll)
{
CustomerTransactionList _response = new CustomerTransactionList();
try
{
var sql = "EXEC PROC_DYNAMIC_TABLE";
sql += " @Flag = " + _dbHelper.FilterString("CustomerTxn");
sql += " @ShowAll = " + _dbHelper.FilterString(ShowAll.ToString());
Log.Debug("ACCOUNTREPOSITORY | GETCUSTOMERTRANSACTIONLIST | SQL | " + sql);
var dt = _dbHelper.ExecuteDataTable(sql);
if (dt == null || dt.Rows.Count <= 0)
{
_response.ResponseCode = ResponseHelper.FAILED;
_response.ResponseMessage = "DB Null Error!";
Log.Error("ACCOUNTREPOSITORY | GETCUSTOMERTRANSACTIONLIST | DB RESPONSE | " + JsonConvert.SerializeObject(_response));
}
else
{
_response.ResponseCode = Convert.ToInt16(dt.Rows[0]["errorCode"]);
_response.ResponseMessage = Convert.ToString(dt.Rows[0]["msg"]);
List<CustomerTransaction> obj = new List<CustomerTransaction>();
foreach (DataRow item in dt.Rows)
{
obj.Add(new CustomerTransaction
{
Id = Convert.ToString(item["Id"]),
Amount = Convert.ToString(item["Amount"]),
PaymentMethod = Convert.ToString(item["PaymentMethod"]),
PBankName = Convert.ToString(item["PBankName"]),
PCurrency = Convert.ToString(item["PCurrency"]),
TransactionDay = Convert.ToString(item["TransactionDay"]),
TransactionMonth = Convert.ToString(item["TransactionMonth"]),
Status = Convert.ToString(item["Status"])
});
}
_response.CustomerTransaction = obj;
}
}
catch (Exception ex)
{
_response.ResponseCode = ResponseHelper.EXCEPTION;
_response.ResponseMessage = "Exception occured: " + ex.Message;
Log.Error("ACCOUNTREPOSITORY | GETCUSTOMERTRANSACTIONLIST | EXCEPTION | " + JsonConvert.SerializeObject(_response));
}
return Task.FromResult(_response);
}
public Task<CommonResponse> GetDynamicTable(string flag)
{
CommonResponse _response = new CommonResponse();
try
{
var sql = "EXEC PROC_DYNAMIC_TABLE";
sql += " @Flag = " + _dbHelper.FilterString(flag);
Log.Debug("ACCOUNTREPOSITORY | GETDYNAMICTABLE | SQL | " + sql);
var dt = _dbHelper.ExecuteDataTable(sql);
if (dt == null || dt.Rows.Count <= 0)
{
_response.ResponseCode = ResponseHelper.FAILED;
_response.ResponseMessage = "DB Null Error!";
Log.Error("ACCOUNTREPOSITORY | GETDYNAMICTABLE | DB RESPONSE | " + JsonConvert.SerializeObject(_response));
}
else
{
_response.ResponseCode = Convert.ToInt16(dt.Rows[0]["errorCode"]);
_response.ResponseMessage = Convert.ToString(dt.Rows[0]["msg"]);
if (_response.ResponseCode == ResponseHelper.SUCCESS)
{
_response.Data = Utilities.ParseTableData(flag, dt);
}
}
}
catch (Exception ex)
{
_response.ResponseCode = ResponseHelper.EXCEPTION;
_response.ResponseMessage = "Exception occured: " + ex.Message;
Log.Error("ACCOUNTREPOSITORY | GETDYNAMICTABLE | EXCEPTION | " + JsonConvert.SerializeObject(_response));
}
return Task.FromResult(_response);
}
}
}

7
CustomerOnlineRemit/CustomerOnlineRemit.Repository/Repository/Account/IAccountRepository.cs

@ -1,9 +1,14 @@
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model.Customer;
namespace CustomerOnlineRemit.Repository.Repository.Account
{
public interface IAccountRepository
{
Task<LoginResponse> DoLoginAsync(LoginModel loginModel);
Task<CommonResponse> GetDynamicTable(string flag);
Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll);
Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll);
}
}

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.csproj.AssemblyReference.cache

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/CustomerOnlineRemit.Repository.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/ref/CustomerOnlineRemit.Repository.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit.Repository/obj/Debug/net7.0/refint/CustomerOnlineRemit.Repository.dll

0
CustomerOnlineRemit/CustomerOnlineRemit/Components/CustomButton.razor → CustomerOnlineRemit/CustomerOnlineRemit/Components/CustomButtonComponent.razor

83
CustomerOnlineRemit/CustomerOnlineRemit/Components/ReceiverListComponent.razor

@ -0,0 +1,83 @@
<div class="bg-white rounded py-4 mb-4">
<div class="text-left">
<h3 class="text-5 fw-400 d-flex align-items-center px-4 mb-4">My Receivers</h3>
</div>
<div class="text-right">
<h5 class="text-3 fw-400 d-flex align-items-right px-4 mb-4"> <a href="add-receiver.html"> Add Receivers</a></h5>
</div>
<!-- Title
=============================== -->
<div class="transaction-title py-2 px-4">
<div class="row fw-00">
<div class="col-1 col-sm-4">Name</div>
<div class="col-2 col-sm-2">Send Transaction</div>
<div class="col-3 col-sm-3 d-none d-sm-block text-center">Country</div>
<div class="col-4 col-sm-3 text-end">Transaction Type</div>
</div>
</div>
<!-- Title End -->
<!-- My Receiver List
=============================== -->
<div class="transaction-list">
@if (IsLoading)
{
<div class="px-4 py-3">
<div class="row align-items-center flex-row text-center">
<div class="col-12 col-sm-12 text-center">
<div class="spinner-border text-success loading" role="status"></div>
</div>
</div>
</div>
}
else
{
@if (customerReceiver == null || customerReceiver.ReceiverModel == null || customerReceiver.ReceiverModel.Count <= 0)
{
<div class="px-4 py-3">
<div class="row align-items-center flex-row">
<div class="col-1 col-sm-12 text-center"><span class="d-block text-1">No Data To Display!</span> </div>
</div>
</div>
}
else
{
<div class="px-4 py-3">
<div class="row align-items-center flex-row">
@foreach (var receiver in customerReceiver.ReceiverModel)
{
<div class="col-1 col-sm-4"> <span class="d-block text-1">@receiver.Name</span> <span class="text-muted">@receiver.Mobile</span> </div>
<div class="col-2 col-sm-2"> <span class="d-block text-1"><a href="send-money.html?receiverid=123123123">Send Transaction</a></span></div>
<div class="col-3 col-sm-3 d-none d-sm-block text-center text-1">@receiver.Country</div>
<div class="col-4 col-sm-3 text-end text-1"> <span class="text-nowrap">@receiver.TransactionType</span></div>
}
</div>
</div>
}
}
</div>
<!-- My Receiver List End -->
<!-- View all Link
=============================== -->
<div class="text-center mt-4">
<a href="#" class="btn-link text-3">View all Receivers<i class="fas fa-chevron-right text-2 ms-2 text-link"></i></a>
</div>
<!-- View all Link End -->
</div>
@code {
[Parameter] public bool IsLoading { get; set; }
[Parameter] public bool ShowAll { get; set; }
private CustomerReceiverModel customerReceiver;
protected override async Task OnInitializedAsync()
{
IsLoading = true;
await Task.Delay(2000);
customerReceiver = await service.GetCustomerReceiverList(ShowAll);
if (customerReceiver.ResponseCode != ResponseHelper.SUCCESS)
{
toastAlert.ShowMessage(customerReceiver, ToastService);
}
IsLoading = false;
}
}

134
CustomerOnlineRemit/CustomerOnlineRemit/Components/TableComponent.razor

@ -0,0 +1,134 @@
@typeparam TItem
@using System.Reflection
<div class="bg-white rounded py-4 mb-4">
<div class="text-left">
<h3 class="text-5 fw-400 d-flex align-items-center px-4 mb-4">@ReportTitle</h3>
</div>
@if (!string.IsNullOrEmpty(CustomLink))
{
<div class="text-right">
<h5 class="text-3 fw-400 d-flex align-items-right px-4 mb-4"> <a href="@CustomLink">@CustomLinkTitle</a></h5>
</div>
}
<div class="transaction-title py-2 px-4">
<div class="row fw-00">
@if (columnDefinitions != null && columnDefinitions.Count > 0)
{
count = 1;
@foreach (var column in columnDefinitions)
{
<div class="col-@count.ToString() col-sm-4">@column.Header</div>
count++;
}
}
</div>
</div>
<!-- Title End -->
<div class="transaction-list">
@if (IsLoading)
{
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row text-center">
<div class="col-12 col-sm-12">
<div class="spinner-border text-success loading" role="status"></div>
</div>
</div>
</div>
}
else if (dataApi != null && dataApi.Count > 0)
{
count = 1;
@foreach (var item in dataApi)
{
<div class="transaction-item px-4 py-3">
<div class="row align-items-center flex-row">
@foreach (var column in columnDefinitions)
{
if (ShowModal)
{
<div class="col-@count.ToString() col-sm-4">@column.GetValue(item)</div>
}
else
{
<div class="col-@count.ToString() col-sm-4">@column.GetValue(item)</div>
}
}
</div>
</div>
count++;
}
}
</div>
@if (!string.IsNullOrEmpty(ViewAllLink))
{
<div class="text-center mt-4">
<a href="@ViewAllLink" class="btn-link text-3">@ViewAllTitle<i class="fas fa-chevron-right text-2 ms-2 text-link"></i></a>
</div>
}
</div>
<ToastAlertComponent></ToastAlertComponent>
<!-- View all Link End -->
@code {
[Parameter] public string? CustomLink { get; set; }
[Parameter] public string? IdField { get; set; }
[Parameter] public string? SkipColumns { get; set; }
[Parameter] public string? CustomLinkTitle { get; set; }
[Parameter] public string? ReportTitle { get; set; }
[Parameter] public string? TableFlag { get; set; }
[Parameter] public bool IsLoading { get; set; }
[Parameter] public bool ShowModal { get; set; }
[Parameter] public string? ModalId { get; set; }
[Parameter] public string? ViewAllTitle { get; set; }
[Parameter] public string? ViewAllLink { get; set; }
[Parameter] public int count { get; set; }
[Parameter]
public List<TItem> data { get; set; }
private List<dynamic> dataApi;
private List<TableComponent<dynamic>.ColumnDefinition<dynamic>> columnDefinitions;
public class ColumnDefinition<T>
{
public string Header { get; set; }
public Func<T, object> GetValue { get; set; }
}
protected override async Task OnInitializedAsync()
{
IsLoading = true;
await Task.Delay(2000);
var response = await service.GetDynamicTable(TableFlag);
if (response.ResponseCode != ResponseHelper.SUCCESS)
{
toastAlert.ShowMessage(response, ToastService);
}
dataApi = new List<dynamic>(response.Data);
columnDefinitions = GenerateColumnDefinitions(response.Data[0]);
IsLoading = false;
}
private List<TableComponent<dynamic>.ColumnDefinition<dynamic>> GenerateColumnDefinitions(dynamic item)
{
List<TableComponent<dynamic>.ColumnDefinition<dynamic>> columns = new List<TableComponent<dynamic>.ColumnDefinition<dynamic>>();
var skipColumns = SkipColumns.Split(",").ToList();
PropertyInfo[] properties = item.GetType().GetProperties();
foreach (PropertyInfo property in properties)
{
if (!skipColumns.Contains(property.Name)) // Check if the column should be skipped
{
columns.Add(new TableComponent<dynamic>.ColumnDefinition<dynamic>
{
Header = property.Name,
GetValue = i => property.GetValue(i)
});
}
}
return columns;
}
}

0
CustomerOnlineRemit/CustomerOnlineRemit/Components/ToastAlert.razor → CustomerOnlineRemit/CustomerOnlineRemit/Components/ToastAlertComponent.razor

82
CustomerOnlineRemit/CustomerOnlineRemit/Components/TransactionListComponent.razor

@ -0,0 +1,82 @@
<div class="bg-white rounded py-4 mb-4">
<div class="text-left">
<h3 class="text-5 fw-400 d-flex align-items-center px-4 mb-4">My Transactions</h3>
</div>
<div class="transaction-title py-2 px-4">
<div class="row fw-00">
<div class="col-2 col-sm-2 text-center"><span class="">Date</span></div>
<div class="col-3 col-sm-4">Description</div>
<div class="col-4 col-sm-2">Quick Send </div>
<div class="col-5 col-sm-2 d-none d-sm-block text-center">Status</div>
<div class="col-6 col-sm-2 text-end">Amount</div>
</div>
</div>
<!-- Title End -->
<!-- My Receiver List
=============================== -->
<div class="transaction-list">
@if (IsLoading)
{
<div class="px-4 py-3">
<div class="row align-items-center flex-row text-center">
<div class="col-12 col-sm-12 text-center">
<div class="spinner-border text-success loading" role="status"></div>
</div>
</div>
</div>
}
else
{
@if (customerTransaction == null || customerTransaction.CustomerTransaction == null || customerTransaction.CustomerTransaction.Count <= 0)
{
<div class="px-4 py-3">
<div class="row align-items-center flex-row">
<div class="col-1 col-sm-12 text-center"> <span class="d-block text-1">No Data To Display!</span> </div>
</div>
</div>
}
else
{
<div class="transaction-list">
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row">
@foreach (var transaction in customerTransaction.CustomerTransaction)
{
<div class="col-2 col-sm-2 text-center"> <span class="d-block text-1 fw-300">@transaction.TransactionDay</span> <span class="d-block text-1 fw-300 text-uppercase">@transaction.TransactionMonth</span> </div>
<div class="col-3 col-sm-4"> <span class="d-block text-1">HDFC Bank</span> <span class="text-muted">@transaction.PaymentMethod</span> </div>
<div class="col-4 col-sm-2"> <span class="d-block text-2"><a href="send-money.html?transactionId=23423423">Repeat Transaction</a></span></div>
<div class="col-5 col-sm-2 d-none d-sm-block text-center text-1"> <span class="text-warning" data-bs-toggle="tooltip" title="In Progress"><i class="fas fa-ellipsis-h"></i>@transaction.Status</span></div>
<div class="col-6 col-sm-2 text-end text-1"> <span class="text-nowrap">-@transaction.Amount</span> <span class="text-2 text-uppercase">(@transaction.PCurrency)</span> </div>
}
</div>
</div>
</div>
}
}
</div>
<!-- My Receiver List End -->
<!-- View all Link
=============================== -->
<div class="text-center mt-4">
<a href="#" class="btn-link text-3">View all Receivers<i class="fas fa-chevron-right text-2 ms-2 text-link"></i></a>
</div>
<!-- View all Link End -->
</div>
@code {
[Parameter] public bool IsLoading { get; set; }
[Parameter] public bool ShowAll { get; set; }
private CustomerTransactionList customerTransaction;
protected override async Task OnInitializedAsync()
{
IsLoading = true;
await Task.Delay(2000);
customerTransaction = await service.GetCustomerTransactionList(ShowAll);
if (customerTransaction.ResponseCode != ResponseHelper.SUCCESS)
{
toastAlert.ShowMessage(customerTransaction, ToastService);
}
IsLoading = false;
}
}

5
CustomerOnlineRemit/CustomerOnlineRemit/Components/UserLeftView.razor

@ -1,5 +0,0 @@
<h3>UserLeftView</h3>
@code {
}

24
CustomerOnlineRemit/CustomerOnlineRemit/Data/Account/AccountServices.cs

@ -2,6 +2,7 @@
using CustomerOnlineRemit.Business.Business.Account;
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model.Customer;
using Microsoft.AspNetCore.Components.Authorization;
namespace CustomerOnlineRemit.Data.Account
@ -21,14 +22,6 @@ namespace CustomerOnlineRemit.Data.Account
public async Task<CommonResponse> DoLoginAsync(LoginModel loginModel)
{
//var myContent = JsonConvert.SerializeObject(loginModel);
//var buffer = System.Text.Encoding.UTF8.GetBytes(myContent);
//var byteContent = new ByteArrayContent(buffer);
//HttpResponseMessage response = await _httpClient.PostAsJsonAsync("api/auth/login", loginModel);
//response.EnsureSuccessStatusCode();
//string data = await response.Content.ReadAsStringAsync();
var response = await _accountBusiness.DoLoginAsync(loginModel);
if (response.ResponseCode == ResponseHelper.SUCCESS)
{
@ -40,5 +33,20 @@ namespace CustomerOnlineRemit.Data.Account
}
return response;
}
public async Task<CommonResponse> GetDynamicTable(string Flag)
{
return await _accountBusiness.GetDynamicTable(Flag);
}
public async Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll)
{
return await _accountBusiness.GetCustomerReceiverList(ShowAll);
}
public async Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll)
{
return await _accountBusiness.GetCustomerTransactionList(ShowAll);
}
}
}

4
CustomerOnlineRemit/CustomerOnlineRemit/Data/Account/IAccountServices.cs

@ -1,10 +1,14 @@
using CustomerOnlineRemit.Common.Model;
using CustomerOnlineRemit.Common.Model.Account;
using CustomerOnlineRemit.Common.Model.Customer;
namespace CustomerOnlineRemit.Data.Account
{
public interface IAccountServices
{
Task<CommonResponse> DoLoginAsync(LoginModel loginModel);
Task<CommonResponse> GetDynamicTable(string Flag);
Task<CustomerReceiverModel> GetCustomerReceiverList(bool ShowAll);
Task<CustomerTransactionList> GetCustomerTransactionList(bool ShowAll);
}
}

253
CustomerOnlineRemit/CustomerOnlineRemit/Pages/Dashboard.razor

@ -1,6 +1,9 @@
@layout MainLayout
@page "/dashboard"
@attribute [Authorize]
@inject IJSRuntime JSRuntime
@inherits LayoutComponentBase
<!-- Profile Completeness -->
<div class="bg-white rounded p-4 mb-4">
@ -77,191 +80,101 @@
</div>
</div>
<!-- Profile Completeness End -->
<!-- Recent Activity
=============================== -->
<div class="bg-white rounded py-4 mb-4">
<h3 class="text-5 fw-400 d-flex align-items-center px-4 mb-4">My Transactions</h3>
<!-- Title
=============================== -->
<div class="transaction-title py-2 px-4">
<div class="row fw-00">
<div class="col-2 col-sm-1 text-center"><span class="">Date</span></div>
<div class="col-3 col-sm-4">Description</div>
<div class="col-4 col-sm-2">Quick Send </div>
<div class="col-5 col-sm-2 d-none d-sm-block text-center">Status</div>
<div class="col-6 col-sm-2 text-end">Amount</div>
</div>
</div>
<!-- Title End -->
<!-- Transaction List
=============================== -->
<div class="transaction-list">
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row">
<div class="col-2 col-sm-1 text-center"> <span class="d-block text-1 fw-300">16</span> <span class="d-block text-1 fw-300 text-uppercase">APR</span> </div>
<div class="col-3 col-sm-4"> <span class="d-block text-1">HDFC Bank</span> <span class="text-muted">Cash collection</span> </div>
<div class="col-4 col-sm-2"> <span class="d-block text-2"><a href="send-money.html?transactionId=23423423">Repeat Transaction </a></span></div>
<div class="col-5 col-sm-2 d-none d-sm-block text-center text-1"> <span class="text-warning" data-bs-toggle="tooltip" title="In Progress"><i class="fas fa-ellipsis-h"></i>Processing</span> </div>
<div class="col-6 col-sm-2 text-end text-1"> <span class="text-nowrap">- $562</span> <span class="text-2 text-uppercase">(USD)</span> </div>
</div>
</div>
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row">
<div class="col-2 col-sm-1 text-center"> <span class="d-block text-1 fw-300">16</span> <span class="d-block text-1 fw-300 text-uppercase">APR</span> </div>
<div class="col-3 col-sm-4"> <span class="d-block text-1">Global IME Bank</span> <span class="text-muted">Bank Deposit</span> </div>
<div class="col-4 col-sm-2"> <span class="d-block text-2"><a href="send-money.html?transactionId=23423423">Repeat Transaction </a></span></div>
<div class="col-5 col-sm-2 d-none d-sm-block text-center text-1"> <span class="text-success" data-bs-toggle="tooltip" title="Completed"><i class="fas fa-check-circle"></i>Paid</span> </div>
<div class="col-6 col-sm-2 text-end text-1"> <span class="text-nowrap">- $562</span> <span class="text-2 text-uppercase">(USD)</span> </div>
</div>
</div>
</div>
<!-- Transaction List End -->
<!-- Transaction Item Details Modal
=========================================== -->
<div id="transaction-detail" class="modal fade" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered transaction-details" role="document">
<div class="modal-content">
<div class="modal-body">
<div class="row g-0">
<div class="col-sm-5 d-flex justify-content-center bg-primary rounded-start py-4">
<div class="my-auto text-center">
<div class="text-17 text-white my-3"><i class="fas fa-building"></i></div>
<h3 class="text-4 text-white fw-400 my-3">Global IME Bank Ltd</h3>
<div class="text-8 fw-500 text-white my-4">$557.20</div>
<p class="text-white">15 March 2021</p>
</div>
<TransactionListComponent ShowAll="false"></TransactionListComponent>
<ReceiverListComponent ShowAll="false"></ReceiverListComponent>
<div id="transaction-detail" class="modal fade" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered transaction-details" role="document">
<div class="modal-content">
<div class="modal-body">
<div class="row g-0">
<div class="col-sm-5 d-flex justify-content-center bg-primary rounded-start py-4">
<div class="my-auto text-center">
<div class="text-17 text-white my-3"><i class="fas fa-building"></i></div>
<h3 class="text-4 text-white fw-400 my-3">Global IME Bank Ltd</h3>
<div class="text-8 fw-500 text-white my-4">$557.20</div>
<p class="text-white">15 March 2021</p>
</div>
<div class="col-sm-7">
<h5 class="text-5 fw-400 m-3">
Transaction Details
<button type="button" class="btn-close text-2 float-end" data-bs-dismiss="modal" aria-label="Close"></button>
</h5>
<hr>
<div class="px-3">
<ul class="list-unstyled">
<li class="mb-2">Payment Amount <span class="float-end text-3">$562.00</span></li>
<li class="mb-2">Fee <span class="float-end text-3">-$4.80</span></li>
</ul>
<hr class="mb-2">
<p class="d-flex align-items-center fw-500 mb-0">Total Amount <span class="text-3 ms-auto">$557.20</span></p>
<hr class="mb-2">
<p class="d-flex align-items-center fw-500 mb-0">Total Amount NPR <span class="text-3 ms-auto">Rs. 70000</span></p>
<hr class="mb-4 mt-2">
<ul class="list-unstyled">
<li class="fw-500">Paid By:</li>
<li class="text-muted">Global IME Bank Ltd</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Country:</li>
<li class="text-muted">Nepal</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Transaction ID:</li>
<li class="text-muted">26566689645685976589</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Description:</li>
<li class="text-muted">GBIME March 2021 Member Payment</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Status:</li>
<li class="text-muted">Completed<span class="text-success text-3 ms-1"><i class="fas fa-check-circle"></i></span></li>
</ul>
</div>
</div>
<div class="col-sm-7">
<h5 class="text-5 fw-400 m-3">
Transaction Details
<button type="button" class="btn-close text-2 float-end" data-bs-dismiss="modal" aria-label="Close"></button>
</h5>
<hr>
<div class="px-3">
<ul class="list-unstyled">
<li class="mb-2">Payment Amount <span class="float-end text-3">$562.00</span></li>
<li class="mb-2">Fee <span class="float-end text-3">-$4.80</span></li>
</ul>
<hr class="mb-2">
<p class="d-flex align-items-center fw-500 mb-0">Total Amount <span class="text-3 ms-auto">$557.20</span></p>
<hr class="mb-2">
<p class="d-flex align-items-center fw-500 mb-0">Total Amount NPR <span class="text-3 ms-auto">Rs. 70000</span></p>
<hr class="mb-4 mt-2">
<ul class="list-unstyled">
<li class="fw-500">Paid By:</li>
<li class="text-muted">Global IME Bank Ltd</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Country:</li>
<li class="text-muted">Nepal</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Transaction ID:</li>
<li class="text-muted">26566689645685976589</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Description:</li>
<li class="text-muted">GBIME March 2021 Member Payment</li>
</ul>
<ul class="list-unstyled">
<li class="fw-500">Status:</li>
<li class="text-muted">Completed<span class="text-success text-3 ms-1"><i class="fas fa-check-circle"></i></span></li>
</ul>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Transaction Item Details Modal End -->
<!-- View all Link
=============================== -->
<div class="text-center mt-4">
<a href="transaction-history.html" class="btn-link text-3">View all Transactions<i class="fas fa-chevron-right text-2 ms-2 text-link"></i></a>
</div>
<!-- View all Link End -->
</div>
<!-- Recent Activity End -->
<!-- My Receiver Activity
=============================== -->
<div class="bg-white rounded py-4 mb-4">
<div class="text-left">
<h3 class="text-5 fw-400 d-flex align-items-center px-4 mb-4">My Receivers</h3>
</div>
<div class="text-right">
<h5 class="text-3 fw-400 d-flex align-items-right px-4 mb-4"> <a href="add-receiver.html"> Add Receivers</a></h5>
</div>
<!-- Title
=============================== -->
<div class="transaction-title py-2 px-4">
<div class="row fw-00">
<div class="col-1 col-sm-4">Name</div>
<div class="col-2 col-sm-2">Send Transaction</div>
<div class="col-3 col-sm-2 d-none d-sm-block text-center">Country</div>
<div class="col-4 col-sm-2 text-end">Transaction Type</div>
</div>
</div>
<!-- Title End -->
<!-- My Receiver List
=============================== -->
<div class="transaction-list">
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row">
<div class="col-1 col-sm-4"> <span class="d-block text-1">Ram Bahadur</span> <span class="text-muted">980403234234</span> </div>
<div class="col-2 col-sm-2"> <span class="d-block text-1"><a href="send-money.html?receiverid=123123123">Send Transaction</a></span></div>
<div class="col-3 col-sm-2 d-none d-sm-block text-center text-1"> Nepal</div>
<div class="col-4 col-sm-2 text-end text-1"> <span class="text-nowrap">Cash collection</span></div>
</div>
</div>
<div class="transaction-item px-4 py-3" data-bs-toggle="modal" data-bs-target="#transaction-detail">
<div class="row align-items-center flex-row">
<div class="col-1 col-sm-4"> <span class="d-block text-1">Ram Bahadur</span> <span class="text-muted">980403234234</span> </div>
<div class="col-2 col-sm-2"> <span class="d-block text-1"><a href="send-money.html?receiverid=123123123">Send Transaction</a></span></div>
<div class="col-3 col-sm-2 d-none d-sm-block text-center text-1"> Nepal</div>
<div class="col-4 col-sm-2 text-end text-1"> <span class="text-nowrap">Cash collection</span></div>
</div>
</div>
@code {
private string currentLocation = string.Empty;
private Dictionary<string, string> QueryParameters { get; set; }
protected override void OnInitialized()
{
currentLocation = NavigationManager.Uri;
</div>
<!-- My Receiver List End -->
<!-- View all Link
=============================== -->
<div class="text-center mt-4">
<a href="receivers.html" class="btn-link text-3">View all Receivers<i class="fas fa-chevron-right text-2 ms-2 text-link"></i></a>
</div>
<!-- View all Link End -->
</div>
<!-- MY Receiver Activity End -->
@*<AuthorizeView>
<Authorized>
</Authorized>
<NotAuthorized>
<h1>You are not authorized to view this page</h1>
</NotAuthorized>
</AuthorizeView>*@
NavigationManager.LocationChanged += OnLocationChanged;
}
@code {
string userAuthenticated;
protected override async Task OnInitializedAsync()
private async void OnLocationChanged(object sender, LocationChangedEventArgs e)
{
var authState = await AuthenticationStateProvider.GetAuthenticationStateAsync();
var user = authState.User;
if (user.Identity.IsAuthenticated)
if (e.Location != currentLocation)
{
userAuthenticated = $"{user.Identity.Name} is authenticated.";
currentLocation = e.Location;
if (HasReloadQueryParam(e.Location))
{
await JSRuntime.InvokeVoidAsync("location.reload");
}
}
else
}
private bool HasReloadQueryParam(string url)
{
var uri = new Uri(url);
var queryParams = System.Web.HttpUtility.ParseQueryString(uri.Query);
if (queryParams.Count <= 0)
return false;
QueryParameters = queryParams.AllKeys.ToDictionary(key => key, key => queryParams[key]);
if (QueryParameters["login"].ToLower() == "success")
{
userAuthenticated = "The user is NOT authenticated.";
return true;
}
return false;
}
}

10
CustomerOnlineRemit/CustomerOnlineRemit/Pages/Login.razor

@ -1,7 +1,6 @@
@layout LoginLayout
@page "/"
@using CustomerOnlineRemit.Data.Account
@inject AccountServices service
@using Microsoft.AspNetCore.Components
@attribute [AllowAnonymous]
@ -78,7 +77,7 @@
</div>
<div class="col-lg-3 mt-4">
<div class="d-grid mb-5">
<CustomButton ButtonText="Login" ButtonClass="btn btn-lg btn-primary" ButtonIcon="fa fa-window-maximize px-2" IsLoading="@_isLoading" />
<CustomButtonComponent ButtonText="Login" ButtonClass="btn btn-lg btn-primary" ButtonIcon="fa fa-window-maximize px-2" IsLoading="@_isLoading" />
@*<button class="btn btn-lg btn-primary" type="submit" disabled="@isSubmitting">Login <i class="fa fa-window-maximize px-2" aria-hidden="true"></i></button>*@
</div>
</div>
@ -116,7 +115,7 @@
<!-- Content end -->
<!-- Footer -->
<FooterComponent></FooterComponent>
<ToastAlert></ToastAlert>
<ToastAlertComponent></ToastAlertComponent>
<!-- Footer end -->
</div>
<!-- Document Wrapper end -->
@ -147,7 +146,7 @@
_isLoading = true;
StateHasChanged();
await Task.Delay(3000);
await Task.Delay(1000);
var response = await service.DoLoginAsync(_loginModel);
_isLoading = false;
@ -157,7 +156,8 @@
if (response.ResponseCode == ResponseHelper.SUCCESS)
{
NavigationManager.NavigateTo("/dashboard");
await Task.Delay(2000);
NavigationManager.NavigateTo("/dashboard?login=success");
}
}
}

2
CustomerOnlineRemit/CustomerOnlineRemit/Program.cs

@ -41,7 +41,7 @@ builder.Host.UseSerilog(((ctx, lc) => lc
builder.Services.AddControllers();
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
builder.Services.AddScoped<ToastAlert>();
builder.Services.AddScoped<ToastAlertComponent>();
builder.Services.AddScoped<AccountServices>();
builder.Services.AddScoped<ProtectedSessionStorage>();
builder.Services.AddScoped<AuthenticationStateProvider, CustomAuthenticationStateProvider>();

68
CustomerOnlineRemit/CustomerOnlineRemit/Shared/MainLayout.razor

@ -1,4 +1,5 @@
@inherits LayoutComponentBase
@inject IJSRuntime JSRuntime
<PageTitle>CustomerOnlineRemit</PageTitle>
@ -13,7 +14,7 @@
<!-- Logo
============================= -->
<div class="logo me-3">
<a class="d-flex" href="dashboard-new.html" title="IME Londan">
<a class="d-flex" href="dashboard" title="IME Londan">
<img src="images/imelondon.svg" height="30" alt="IME London - Logo" />
</a>
</div>
@ -150,31 +151,46 @@
</div>
<!-- Content end -->
<!-- Footer -->
<footer id="footer" class="footer-web">
<div class="container">
<div class="text-center">
<div class="row">
<div class="mx-auto">
<div class="text-center text-white">
<p class="text-center mb-3 text-1">
IME London is a product of Subhida UK Limited, Pentax House,South Hill Avenue, South Harrow, London, H2A 0D
Company Registration No. 06432399 Subhida UK Ltd is authorized and regulated by the Financial Conduct
Authority (FCA) <br> under the Payment Service Regulations 2017. FCA Registration No. 576127 HMRC Registration No. XYML000000119350
</p>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6 mx-auto">
<div class="text-center text-white">
<p>© IME London, 2023</p>
</div>
</div>
</div>
</div>
</div>
</footer>
<FooterComponent></FooterComponent>
<ToastAlertComponent></ToastAlertComponent>
<!-- Footer end -->
</div>
<!-- Document Wrapper end -->
@code {
private string currentLocation = string.Empty;
private Dictionary<string, string> QueryParameters { get; set; }
protected override void OnInitialized()
{
currentLocation = NavigationManager.Uri;
NavigationManager.LocationChanged += OnLocationChanged;
}
private async void OnLocationChanged(object sender, LocationChangedEventArgs e)
{
if (e.Location != currentLocation)
{
currentLocation = e.Location;
if (HasReloadQueryParam(e.Location))
{
await JSRuntime.InvokeVoidAsync("location.reload");
}
}
}
private bool HasReloadQueryParam(string url)
{
var uri = new Uri(url);
var queryParams = System.Web.HttpUtility.ParseQueryString(uri.Query);
if (queryParams.Count <= 0)
return false;
QueryParameters = queryParams.AllKeys.ToDictionary(key => key, key => queryParams[key]);
if (QueryParameters["login"].ToLower() == "success")
{
toastAlert.ShowMessage("Login Successful!", 0, ToastService);
return true;
}
return false;
}
}

7
CustomerOnlineRemit/CustomerOnlineRemit/_Imports.razor

@ -1,4 +1,5 @@
@using System.Net.Http
@using CustomerOnlineRemit.Data.Account;
@using Microsoft.AspNetCore.Authorization
@using Microsoft.AspNetCore.Components.Authorization
@using Microsoft.AspNetCore.Components.Forms
@ -15,8 +16,10 @@
@using Blazored.Toast
@using Blazored.Toast.Services
@using Blazored.Toast.Configuration
@using CustomerOnlineRemit.Common.Model.Customer
@inject NavigationManager NavigationManager
@inject IToastService ToastService
@inject ToastAlert toastAlert
@inject AuthenticationStateProvider AuthenticationStateProvider
@inject ToastAlertComponent toastAlert
@inject AuthenticationStateProvider AuthenticationStateProvider
@inject AccountServices service

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Business.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Business.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Common.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Common.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Repository.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.Repository.pdb

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/bin/Debug/net7.0/CustomerOnlineRemit.pdb

20
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.GeneratedMSBuildEditorConfig.editorconfig

@ -20,20 +20,28 @@ build_property._RazorSourceGeneratorDebug =
build_metadata.AdditionalFiles.TargetPath = QXBwLnJhem9y
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/CustomButton.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xDdXN0b21CdXR0b24ucmF6b3I=
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/CustomButtonComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xDdXN0b21CdXR0b25Db21wb25lbnQucmF6b3I=
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/FooterComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xGb290ZXJDb21wb25lbnQucmF6b3I=
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/ToastAlert.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xUb2FzdEFsZXJ0LnJhem9y
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/ReceiverListComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xSZWNlaXZlckxpc3RDb21wb25lbnQucmF6b3I=
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/UserLeftView.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xVc2VyTGVmdFZpZXcucmF6b3I=
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/TableComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xUYWJsZUNvbXBvbmVudC5yYXpvcg==
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/ToastAlertComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xUb2FzdEFsZXJ0Q29tcG9uZW50LnJhem9y
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Components/TransactionListComponent.razor]
build_metadata.AdditionalFiles.TargetPath = Q29tcG9uZW50c1xUcmFuc2FjdGlvbkxpc3RDb21wb25lbnQucmF6b3I=
build_metadata.AdditionalFiles.CssScope =
[D:/C\# Projects/Personal/IME_Remit_London/CustomerPortal/CustomerOnlineRemit/CustomerOnlineRemit/Pages/Account/Index.razor]

BIN
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.csproj.AssemblyReference.cache

16
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.csproj.FileListAbsolute.txt

@ -71,6 +71,14 @@ D:\C# Projects\Personal\IME_Remit_London\CustomerOnlineRemit\CustomerOnlineRemit
D:\C# Projects\Personal\IME_Remit_London\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.pdb
D:\C# Projects\Personal\IME_Remit_London\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.genruntimeconfig.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\ref\CustomerOnlineRemit.dll
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.csproj.AssemblyReference.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.GeneratedMSBuildEditorConfig.editorconfig
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.AssemblyInfoInputs.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.AssemblyInfo.cs
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.csproj.CoreCompileInputs.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.MvcApplicationPartsAssemblyInfo.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.RazorAssemblyInfo.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.RazorAssemblyInfo.cs
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\appsettings.Development.json
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\appsettings.json
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\package-lock.json
@ -113,14 +121,6 @@ D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\Cust
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\CustomerOnlineRemit.Business.pdb
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\CustomerOnlineRemit.Common.pdb
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\bin\Debug\net7.0\CustomerOnlineRemit.Repository.pdb
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.csproj.AssemblyReference.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.GeneratedMSBuildEditorConfig.editorconfig
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.AssemblyInfoInputs.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.AssemblyInfo.cs
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.csproj.CoreCompileInputs.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.MvcApplicationPartsAssemblyInfo.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.RazorAssemblyInfo.cache
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\CustomerOnlineRemit.RazorAssemblyInfo.cs
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\staticwebassets\msbuild.CustomerOnlineRemit.Microsoft.AspNetCore.StaticWebAssets.props
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\staticwebassets\msbuild.build.CustomerOnlineRemit.props
D:\C# Projects\Personal\IME_Remit_London\CustomerPortal\CustomerOnlineRemit\CustomerOnlineRemit\obj\Debug\net7.0\staticwebassets\msbuild.buildMultiTargeting.CustomerOnlineRemit.props

BIN
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/CustomerOnlineRemit.pdb

2
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/project.razor.vs.json
File diff suppressed because it is too large
View File

BIN
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/ref/CustomerOnlineRemit.dll

BIN
CustomerOnlineRemit/CustomerOnlineRemit/obj/Debug/net7.0/refint/CustomerOnlineRemit.dll

44
DB/PROC_DYNAMIC_TABLE.sql

@ -0,0 +1,44 @@
ALTER PROC PROC_DYNAMIC_TABLE
(
@Flag VARCHAR(20)
,@UserEmail VARCHAR(150) = NULL
,@ShowAll VARCHAR(5) = NULL
)
AS;
SET NOCOUNT ON;
SET XACT_ABORT ON;
BEGIN TRY
DECLARE @ErrorMsg VARCHAR(MAX)
IF @Flag = 'CustomerTxn'
BEGIN
SELECT Id
, Amount = pAmt
, Status = payStatus
, TransactionDay = DATEPART(DAY, createdDate)
, TransactionMonth = DATENAME(MONTH, createdDate)
, PaymentMethod
, PBankName
, PCurrency = payoutCurr
, errorCode = 0
, msg = 'Success'
FROM remitTranTemp (NOLOCK)
END
ELSE IF @Flag = 'CustomerReceiver'
BEGIN
SELECT Id = receiverId
, Name = FULLNAME
, Country = country
, Mobile
, TransactionType = SM.typeTitle
, errorCode = 0
, msg = 'Success'
FROM receiverInformation RI(NOLOCK)
INNER JOIN serviceTypeMaster SM(NOLOCK) ON SM.serviceTypeId = RI.paymentMode
END
END TRY
BEGIN CATCH
SET @ErrorMsg = 'Internal Server Error: ' + ERROR_MESSAGE()
SELECT errorCode = 1, msg = @ErrorMsg, id = NULL
END CATCH
Loading…
Cancel
Save