[ASTPPCOM-1400] Invoice payment not applying to one invoice Created: 02/Nov/23  Updated: 02/Nov/23

Status: Open
Project: ASTPP Community
Component/s: None
Affects Version/s: v6.0
Fix Version/s: None

Type: Bug Priority: High
Reporter: Ryan Becker Assignee: Samir Doshi
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

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.


Generated at Sat Feb 10 07:25:47 CET 2024 using Jira 8.13.3#813003-sha1:22ebedbb75c99b147c66f14e031dd8a2d214753a.