webERP Forum
Missing ChequeNo in Payments.php? - Printable Version

+- webERP Forum (http://www.weberp.org/forum)
+-- Forum: webERP Discussion (http://www.weberp.org/forum/forumdisplay.php?fid=1)
+--- Forum: Problems / Bugs? (http://www.weberp.org/forum/forumdisplay.php?fid=8)
+--- Thread: Missing ChequeNo in Payments.php? (/showthread.php?tid=8287)



Missing ChequeNo in Payments.php? - VortecCPI - 12-11-2018

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?