Details
-
Type:
Bug
-
Status: Open
-
Priority:
High
-
Resolution: Unresolved
-
Affects Version/s: v6.0
-
Fix Version/s: None
-
Labels:None
-
Reproducibility:always
-
Category:UI
-
Edition:Community
Description
There is one invoice in our system that we are trying to apply a payment to, and whenever we do so, we receive an error. All other invoices had payments applied the same way and worked fine. We receive this error:
A Database Error Occurred
Error Number: 1064
You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'Group By invoiceid' at line 1
select sum(credit) as credit from invoice_details where invoiceid = Group By invoiceid
Filename: /opt/ASTPP/web_interface/astpp/modules/invoices/controllers/invoices.php
Line Number: 1257
I have tried manually editing this file (which isn't actually at the path the page states) to set the invoice ID just to see if the payment was applied, but then this appears:
An Error Was Encountered
Cannot use object of type CI_DB_mysqli_result as array
Not sure what issue would cause just this single invoice to not accept payment but all other generated invoices have taken payment properly. I am also fine with manually crediting the invoice payment amount in the database but there doesn't seem to be a single table that holds invoice payment details and it's instead split between multiple tables that build all of the invoice line items together.