Loan And TD funds transfer disabled
This commit is contained in:
@@ -268,6 +268,8 @@ class _DashboardScreenState extends State<DashboardScreen>
|
||||
if (state is Authenticated) {
|
||||
final users = state.users;
|
||||
final currAccount = users[selectedAccountIndex];
|
||||
final accountType = currAccount.accountType?.toLowerCase();
|
||||
final isPaymentDisabled = accountType != 'sa' && accountType != 'sb' && accountType != 'ca';
|
||||
// first‐time load
|
||||
if (!_txInitialized) {
|
||||
_txInitialized = true;
|
||||
@@ -482,35 +484,36 @@ class _DashboardScreenState extends State<DashboardScreen>
|
||||
);
|
||||
},
|
||||
),
|
||||
_buildQuickLink(
|
||||
Symbols.currency_rupee,
|
||||
AppLocalizations.of(context).quickPay,
|
||||
() {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => QuickPayScreen(
|
||||
debitAccount: currAccount.accountNo!,
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
_buildQuickLink(
|
||||
Symbols.currency_rupee,
|
||||
AppLocalizations.of(context).quickPay,
|
||||
() {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => QuickPayScreen(
|
||||
debitAccount: currAccount.accountNo!,
|
||||
),
|
||||
),
|
||||
);
|
||||
},
|
||||
disable: isPaymentDisabled,
|
||||
),
|
||||
_buildQuickLink(Symbols.send_money,
|
||||
AppLocalizations.of(context).fundTransfer, () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => FundTransferScreen(
|
||||
creditAccountNo:
|
||||
users[selectedAccountIndex]
|
||||
.accountNo!,
|
||||
remitterName:
|
||||
users[selectedAccountIndex]
|
||||
.name!,
|
||||
// Pass the full list of accounts
|
||||
accounts: users)));
|
||||
}, disable: false),
|
||||
AppLocalizations.of(context).fundTransfer, () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => FundTransferScreen(
|
||||
creditAccountNo:
|
||||
users[selectedAccountIndex]
|
||||
.accountNo!,
|
||||
remitterName:
|
||||
users[selectedAccountIndex]
|
||||
.name!,
|
||||
// Pass the full list of accounts
|
||||
accounts: users)));
|
||||
}, disable: isPaymentDisabled),
|
||||
_buildQuickLink(
|
||||
Symbols.server_person,
|
||||
AppLocalizations.of(context).accountInfo,
|
||||
|
||||
Reference in New Issue
Block a user