Closed error08 closed 1 month ago
Unfortunately, I get an error message when trying this locally:
An exception occurred while executing a query: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(ORDER BY m.dateAdded) as all_members,
DATE_FORMAT(FROM_UNIXTIME' at line 3
Since I'm running MySQL 5.7 (MAMP on macOS), it could be that ORDER BY
inside the SELECT is not supported on older databases?
Yes you are right! The window functions (sum in that case) are new in Version 8. But 5.7 has reached EOL. Should we support that version futhermore? How do you handle the base requirements for Isotope? Can they only be updated with a new major version of Isotope?
Well we cannot require a minimum version of MySQL (technically, on a Composer level). And Contao perfectly supports MySQL 5.7. So it would be a PITA to have a different dependency. Appart from the fact that my default hoster still has 5.7 (will be changed early next year) 😅
Ok, I see! I will try an alternative query.
I removed the window function and solved it via code. I think it is a good alternative. Now the code compatible to MySQL 5.x.
I tried this PR locally. But (probably) because I did not have any registration/member data, I got an empty page and an error in apexchart
Unhandled Promise Rejection: TypeError: null is not an object (evaluating 't.toString')
I guess there's a problem somewhere if the data/row is empty?
Hi, I tried it without members / member data, but I cannot reproduce the error. I need more information about this.
Could you add a screenshot what this report is supposed to look like? Here's what I see. I guess the chart error is because some of the months do not have a new registration?
Hi, here a screenshot
I have update the PR, please try it again. I see no such error.
@aschempp I think now is fine and ready to merge?
I'm sorry, I don't know what I'm doing wrong. I tried it again, but nothing changed. As you can see in the previous screenshot, I don't even have the same columns in the HTML table. Are you sure you pushed all changes?
I have found the problem. The language keys in the English file was wrong.
Thank you @error08! I fixed a minor issue with language collision.
Add new report member registrations using new apexcharts library.