Skip to content
This repository was archived by the owner on Feb 22, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ const AccountClosure = (() => {
};
if (response.error.details.open_positions) {
Object.keys(response.error.details.open_positions).forEach((account) => {
const txt_positions = `${response.error.details.open_positions[account]} position(s)`;
const txt_positions = `${response.error.details.open_positions[account]} ${localize('position(s)')}`;
if (/^MT/.test(account)) {
section_id = 'account_closure_open_mt';
display_name = getMTDisplay(account);
Expand All @@ -245,6 +245,13 @@ const AccountClosure = (() => {
addSection(account, txt_balance);
});
}
if (response.error.details.pending_withdrawals) {
Object.keys(response.error.details.pending_withdrawals).forEach((account) => {
const txt_pending_withdrawals = `${response.error.details.pending_withdrawals[account]} ${localize('withdrawal(s)')}`;
section_id = 'account_closure_pending_withdrawals';
addSection(account, txt_pending_withdrawals);
});
}
};

const showFormMessage = (localized_msg) => {
Expand Down
3 changes: 3 additions & 0 deletions src/templates/app/user/security/account_closure.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ const AccountClosureError = () => (
<div className='gr-padding-20 gr-parent invisible' id='account_closure_balance_mt'>
{it.L('You have funds in these MT5 accounts:')}
</div>
<div className='gr-padding-20 gr-parent invisible' id='account_closure_pending_withdrawals'>
{it.L('You have pending withdrawal(s) in these Binary accounts:')}
</div>
</div>
<div id='account_closure_error_buttons' className='gr-padding-10 gr-child'>
<button className='modal-back back button no-margin'>{it.L('OK')}</button>
Expand Down