Improved data handling for LanguagesPageFieldValue at module installa…#11
Improved data handling for LanguagesPageFieldValue at module installa…#11happy-kaseem wants to merge 11 commits intoteppokoivula:masterfrom
Conversation
Your Selector is not compatible with: sql_mode=only_full_group_by Errors: SQLSTATE[42000]: Syntax error or access violation: 1055 Expression teppokoivula#7 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'objektdatenbank.d.property' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by (in /site/modules/VersionControl/ProcessVersionControl.module line 249) SQLSTATE[42000]: Syntax error or access violation: 1055 Expression teppokoivula#8 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'objektdatenbank.d.data' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by (in /site/modules/VersionControl/ProcessVersionControl.module line 248) SQLSTATE[42000]: Syntax error or access violation: 1055 Expression #2 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'objektdatenbank.d.id' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by (in /site/modules/VersionControl/ProcessVersionControl.module line 249)
…tion time and at page/field save time
|
Hi there, @happy-kaseem! After going through some of the changes here, I must admit that I don't really know what to do with this PR :) There are definitely some good things here that I might be able to merge as-is, but some parts will need to be fixed or tweaked a bit before merging, and some parts I might prefer to solve in a different way altogether. The main problem here is that this single PR contains multiple unrelated fixes/changes. I hope you don't mind, but I may have to split them up myself and commit them manually. If I do that, GitHub can't connect them directly to you (i.e. give you credit for the commits), but I'll definitely mention you in the commit messages. Either way, thanks for your input here. It's very much appreciated :) |
|
Hi @teppokoivula. Thanks for all your work and your comments. Please do as best as you can using this PR. And don't worry about the credit. I am more than happy to know that the module can be improved. |
|
Closing this PR for now. Some of the things here, I believe, were already implemented, and others will have to wait for the 2.0 version of the module. This will likely be a pretty big change, so I'd rather move all remaining "non-critical" features (including better multilanguage and Repeater support) there. |
The current version does not seem to include fields of class "LanguagesPageFieldValue"(like TextAreaLanguage or TextLanguage") at the initial creation of the database table "version_control_data". The revisions are stored in "version_control_revision" but the entries for the unchanged, original data field is not included in the table "version_control_data".
The changes in the file "VersionControl.module" try to address this issue. By replacing the function LanguagesPageFieldValue::getChanges for the case of the original database initialisation. LanguagesPageFieldValue::getChanges works perfectly fine for changes of fields submitted in later revisions of the pages.