config updation

This commit is contained in:
2026-03-15 16:24:12 +05:30
parent 642c523570
commit eccd596dc0

View File

@@ -10,7 +10,7 @@ from decimal import Decimal
from typing import Dict, Any, List from typing import Dict, Any, List
from logging_config import get_logger from logging_config import get_logger
from db.models import RTGSInwardRecord from db.models import RTGSInwardRecord # Note: You use NEFTInwardRecord below
logger = get_logger(__name__) logger = get_logger(__name__)
@@ -41,12 +41,11 @@ class RTGSDataMapper:
logger.error(f"Error converting date '{date_str}': {e}") logger.error(f"Error converting date '{date_str}': {e}")
return datetime.now().strftime("%d%m%Y") return datetime.now().strftime("%d%m%Y")
@staticmethod @staticmethod
def process_status(status: str) -> str: def process_status(status: str) -> str:
"""
try: Normalize status codes.
"""
if not status: if not status:
return '' return ''
s = status.strip() s = status.strip()
@@ -95,7 +94,7 @@ class RTGSDataMapper:
amount_in = parsed_txn.get('amount', '0') amount_in = parsed_txn.get('amount', '0')
txn_amt = cls.convert_amount(amount_in) txn_amt = cls.convert_amount(amount_in)
txnind = "CR" txnind = "CR"
creditor_amt=parsed_txn.get('amount', '0') creditor_amt = parsed_txn.get('amount', '0')
# Date handling # Date handling
txn_date_raw = parsed_txn.get('tran_date', '') or '' txn_date_raw = parsed_txn.get('tran_date', '') or ''
@@ -112,7 +111,6 @@ class RTGSDataMapper:
recvr_acct_name = (parsed_txn.get('beneficiary_details') or '').strip() recvr_acct_name = (parsed_txn.get('beneficiary_details') or '').strip()
record = NEFTInwardRecord( record = NEFTInwardRecord(
bank_code=bankcode, bank_code=bankcode,
txnind=txnind, txnind=txnind,
jrnl_id=(parsed_txn.get('journal_no') or '').strip(), jrnl_id=(parsed_txn.get('journal_no') or '').strip(),