feat: added beneficiary creation date and time in the api response to manage cooldown at frontend

This commit is contained in:
2025-11-08 02:04:48 +05:30
parent caef3bd690
commit 95fc26ef6b

View File

@@ -36,7 +36,7 @@ async function validateOutsideBank(accountNo, ifscCode, name) {
async function getSingleBeneficiary(customerNo, accountNo) {
const queryStr =
'SELECT b.account_no, b.name, b.account_type, b.ifsc_code, i.bank_name, i.branch_name FROM beneficiaries b JOIN ifsc_details i ON b.ifsc_code = i.ifsc_code WHERE customer_no = $1 AND account_no = $2';
'SELECT b.account_no, b.name, b.account_type, b.ifsc_code, b.created_at, i.bank_name, i.branch_name FROM beneficiaries b JOIN ifsc_details i ON b.ifsc_code = i.ifsc_code WHERE customer_no = $1 AND account_no = $2';
const result = await db.query(queryStr, [customerNo, accountNo]);
return result.rows[0];
}