Skip to content

Text area and edit field defaults#38617

Merged
fancyFranci merged 1 commit intojoomla:4.2-devfrom
brianteeman:field_sql
Sep 6, 2022
Merged

Text area and edit field defaults#38617
fancyFranci merged 1 commit intojoomla:4.2-devfrom
brianteeman:field_sql

Conversation

@brianteeman
Copy link
Copy Markdown
Contributor

The default values for these two fields was not being set during installation. This PR will fix that for new installs. We can't do updates as it would be changing user data

code review should be fine

The default values for these two fields was not being set during installation. This PR will fix that for new installs. We can't do updates as it would be changing user data
@richard67
Copy link
Copy Markdown
Member

@brianteeman Checking elsewhere in the SQL, the integer values are quoted with double quotes, too, e.g. here:

https://github.com/joomla/joomla-cms/pull/38617/files#diff-3a9a51c74db65d66b70dbd56c86e63882cfaa26701ef6ff3f88bd0ea2682bb9fR286

https://github.com/joomla/joomla-cms/pull/38617/files#diff-d6e22b9d36df769fc1e7f3e847faf6374793792fe81b73166837406587ab3348R292

On the other hand, when saving the parameters of that field or of the fields modified by your PR, the integer values are not quoted. I've tested with MySQL and MariaDB and PostgreSQL.

So your PR is right.

But it seems we could clean up the quotes elsewhere, too (of course not with this PR).

@richard67
Copy link
Copy Markdown
Member

I have tested this item ✅ successfully on 7f03618

Tested with MySQL and MariaDB and PostgreSQL (recent versions) that the "params" values saved in database when saving the plugins options without having made changes after a new install are equal to what this PR adds to the SQL.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/38617.

@viocassel
Copy link
Copy Markdown
Contributor

I have tested this item ✅ successfully on 7f03618


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/38617.

@richard67
Copy link
Copy Markdown
Member

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/38617.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label Aug 29, 2022
@fancyFranci fancyFranci merged commit 06b7815 into joomla:4.2-dev Sep 6, 2022
@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label Sep 6, 2022
@fancyFranci
Copy link
Copy Markdown
Contributor

Good that you fixed that. Thank you!

@fancyFranci fancyFranci added this to the Joomla! 4.2.3 milestone Sep 6, 2022
@brianteeman
Copy link
Copy Markdown
Contributor Author

thx

@brianteeman brianteeman deleted the field_sql branch September 6, 2022 19:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants