webERP Forum

Full Version: Missing ChequeNo in Payments.php?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
On or about line 530 we are not inserting ChequeNo into the BankTrans table:

PHP Code:
                    $SQL "INSERT INTO banktrans (
                                transno,
                                type,
                                bankact,
                                ref,
                                exrate,
                                functionalexrate,
                                transdate,
                                banktranstype,
                                amount,
                                currcode
                            ) VALUES ('" 
.
                                
$ReceiptTransNo "',
                                2,'" 
.
                                
$PaymentItem->GLCode "','" .
                                
'@' $TransNo ' ' _('Act Transfer From') .' '$_SESSION['PaymentDetail'.$identifier]->Account ' - ' $PaymentItem->Narrative "','" .
                                
$ExRate "','" .
                                
$TrfToBankExRate "','" .
                                
FormatDateForSQL($_SESSION['PaymentDetail'.$identifier]->DatePaid) . "','" .
                                
$_SESSION['PaymentDetail'.$identifier]->Paymenttype "','" .
                                
$PaymentItem->Amount "','" .
                                
$_SESSION['PaymentDetail'.$identifier]->Currency .
                            
"')"

Should this not be:

PHP Code:
                    $SQL "INSERT INTO banktrans (
                                transno,
                                type,
                                bankact,
                                ref,
                                exrate,
                                functionalexrate,
                                transdate,
                                banktranstype,
                                amount,
                                currcode,
                                chequeno
                            ) VALUES ('" 
.
                                
$ReceiptTransNo "',
                                2,'" 
.
                                
$PaymentItem->GLCode "','" .
                                
'@' $TransNo ' ' _('Act Transfer From') .' '$_SESSION['PaymentDetail'.$identifier]->Account ' - ' $PaymentItem->Narrative "','" .
                                
$ExRate "','" .
                                
$TrfToBankExRate "','" .
                                
FormatDateForSQL($_SESSION['PaymentDetail'.$identifier]->DatePaid) . "','" .
                                
$_SESSION['PaymentDetail'.$identifier]->Paymenttype "','" .
                                
$PaymentItem->Amount "','" .
                                
$_SESSION['PaymentDetail'.$identifier]->Currency "','" .
                                
$PaymentItem->Cheque .
                            
"')"

Also... How are we reconciling the parent Cheque Number with those in the individual child GL entries? The parent Cheque Number can not be blank so is it assumed it must match one of those in the child GL entries?
Reference URL's