Report by client gives uncorrect values

Hi,

When i make a report by “client” with group “Client” i get wrong values on some of my clients.
I have one payment of 2701.00 € and one credit of -57.60 €
The report gives me on Allready payed 5286.80€

I have no idea where it come from.
Do you have any idea?



Kind regards and happy holidays.

Koen

Hi,

Not sure I follow, if you remove the grouping what values do you see?

Also, what paid to date value do you see for the client on the client overview?

Hi Hillel,

Just the same…



Greetz…
Koen

It may help to run this command:

php artisan ninja:check-data --fix=true --client_balance=true

Hi Hillel,

I’m on a self hosted platform…
Is there a command for the browser also?

@david can you please advise?

We don’t have this implemented via the browser yet.

Ok thank you David… maybe in the future…

Happy holidays…

Koen

Hi David,

I ran the command “php81 artisan ninja:check-data --fix=true --client_balance=true”

This is the result.
I removed the client names with xx

2022-12-28 08:51:22 2022-12-28 08:51:22 Running CheckData… on Connected to Default DB Fix Status = Fixing Issues
2022-12-28 08:51:22 0 clients with incorrect balances
2022-12-28 08:51:22 xx id = # 3 - Client Paid To Date = 324.820000 != Invoice Payments = 522.41 - 522.410000 +
2022-12-28 08:51:22 xx id = # 6 - Client Paid To Date = 8392.680000 != Invoice Payments = 3662.84 - 3662.840000 +
2022-12-28 08:51:22 xx id = # 8 - Client Paid To Date = 1510.000000 != Invoice Payments = 755 - 755.000000 +
2022-12-28 08:51:22 xx id = # 11 - Client Paid To Date = 1741.000000 != Invoice Payments = 870.5 - 870.500000 +
2022-12-28 08:51:22 xx id = # 12 - Client Paid To Date = 10372.000000 != Invoice Payments = 5186 - 5186.000000 +
2022-12-28 08:51:22 xx id = # 13 - Client Paid To Date = 2372.400000 != Invoice Payments = 1186.2 - 1186.200000 +
2022-12-28 08:51:22 xx id = # 16 - Client Paid To Date = 3158.600000 != Invoice Payments = 1579.3 - 1579.300000 +
2022-12-28 08:51:22 xx id = # 18 - Client Paid To Date = 1692.200000 != Invoice Payments = 846.1 - 846.100000 +
2022-12-28 08:51:22 xx id = # 20 - Client Paid To Date = 5219.300000 != Invoice Payments = 2609.65 - 2609.650000 +
2022-12-28 08:51:22 xx id = # 21 - Client Paid To Date = 2558.000000 != Invoice Payments = 1279 - 1279.000000 +
2022-12-28 08:51:22 xx id = # 25 - Client Paid To Date = 11837.500000 != Invoice Payments = 6937.75 - 6937.750000 +
2022-12-28 08:51:22 xx id = # 27 - Client Paid To Date = 1252.780000 != Invoice Payments = 626.39 - 626.390000 +
2022-12-28 08:51:22 xx id = # 34 - Client Paid To Date = 2874.300000 != Invoice Payments = 1437.15 - 1437.150000 +
2022-12-28 08:51:22 xx id = # 36 - Client Paid To Date = 2407.200000 != Invoice Payments = 1203.6 - 1203.600000 +
2022-12-28 08:51:22 xx id = # 37 - Client Paid To Date = 2736.800000 != Invoice Payments = 1368.4 - 1368.400000 +
2022-12-28 08:51:22 xx id = # 38 - Client Paid To Date = 1376.900000 != Invoice Payments = 2317.7 - 2317.700000 +
2022-12-28 08:51:22 xx id = # 39 - Client Paid To Date = 5286.800000 != Invoice Payments = 2643.4 - 2643.400000 +
2022-12-28 08:51:22 xx id = # 46 - Client Paid To Date = 3464.700000 != Invoice Payments = 1707.35 - 1707.350000 +
2022-12-28 08:51:22 xx id = # 48 - Client Paid To Date = 5913.700000 != Invoice Payments = 2956.85 - 2956.850000 +
2022-12-28 08:51:22 xx id = # 51 - Client Paid To Date = 5994.200000 != Invoice Payments = 2997.1 - 2997.100000 +
2022-12-28 08:51:22 xx id = # 52 - Client Paid To Date = 1304.000000 != Invoice Payments = 652 - 652.000000 +
2022-12-28 08:51:22 xx id = # 54 - Client Paid To Date = 5475.200000 != Invoice Payments = 2737.6 - 2737.600000 +

2022-12-28 08:51:22 xx id = # 55 - Client Paid To Date = 1898.500000 != Invoice Payments = 949.25 - 949.250000 +
2022-12-28 08:51:22 xx id = # 58 - Client Paid To Date = 2552.200000 != Invoice Payments = 857.2 - 857.200000 +
2022-12-28 08:51:22 xx id = # 60 - Client Paid To Date = 7784.500000 != Invoice Payments = 3892.25 - 3892.250000 +
2022-12-28 08:51:22 xx id = # 61 - Client Paid To Date = 6658.200000 != Invoice Payments = 3826.6 - 3826.600000 +
2022-12-28 08:51:22 xx id = # 62 - Client Paid To Date = 5395.200000 != Invoice Payments = 2697.6 - 2697.600000 +
2022-12-28 08:51:22 xx id = # 63 - Client Paid To Date = 785.000000 != Invoice Payments = 392.5 - 392.500000 +
2022-12-28 08:51:22 xx id = # 65 - Client Paid To Date = 5365.780000 != Invoice Payments = 2682.89 - 2682.890000 +
2022-12-28 08:51:22 xx id = # 67 - Client Paid To Date = 2946.080000 != Invoice Payments = 1473.04 - 1473.040000 +
2022-12-28 08:51:22 xx id = # 68 - Client Paid To Date = 1162.000000 != Invoice Payments = 556 - 556.000000 +
2022-12-28 08:51:22 xx id = # 69 - Client Paid To Date = 951.000000 != Invoice Payments = 475.5 - 475.500000 +
2022-12-28 08:51:22 32 clients with incorrect paid to dates
2022-12-28 08:51:22 0 contacts without a contact_key
2022-12-28 08:51:22 0 clients without any contacts
2022-12-28 08:51:22 0 contacts without a contact_key
2022-12-28 08:51:22 0 vendors without any contacts
2022-12-28 08:51:22 0 invoices without any invitations
2022-12-28 08:51:22 0 quotes without any invitations
2022-12-28 08:51:22 0 credits without any invitations
2022-12-28 08:51:22 0 recurring_invoices without any invitations
2022-12-28 08:51:22 0 wrong invoices with bad balance state
2022-12-28 08:51:22 0 users with duplicate oauth ids
2022-12-28 08:51:22 Done: FAILURE
2022-12-28 08:51:22 Total execution time in seconds: 0.3485369682312

Report is still not correct.

@david
Have you any idea left?

Koen

Try this extended version

php81 artisan ninja:check-data --fix=true --client_balance=true --paid_to_date=true

Hi David, it seems to be OK now…

Thanks and wish you and the team a wonderful 2023.

Koen