Create a custom field list
Add some texts and values. For example:
Text | Value
Spain | spain
England | emgland
France | france
Assign values to several articles (hundreds in my case)
After that we notice that value "emgland" is bad written. So, I edit the Custom Field and change the value "emgland" to "england".
I expected that every Article with the custom field value "emgland" assigned, was updated to the corrected value "england" in the table "fields_values"
Every row with the "emgland" value is deleted from the table "fields_values".
Joomla 3.8.7
Labels |
Added:
?
|
Title |
|
Title |
|
Category | ⇒ | com_fields |
thanks for answering.
Please, let me reply to your message:
We have lost hours of work (hundred of articles with a custom field value assigned) , and here nobody thought that changing a value will make losing all the work. Maybe it is not a bug... but it seems an issue.
I am not programmer, but i think "Remapping" or "User Interface" is not necessary. Just an "SQL search and replace" the old value for the new in the fields_values table, isn`t it?
Or at least a pop-up message like: "Modifying a value will make you lose all the articles associated with this value, are you sure?"
Once again, thanks for your time.
Or at least a pop-up message like: "Modifying a value will make you lose all the articles associated with this value, are you sure?"
I had same thought,
there is no warning that you will have data loss !
and without possibility to just re-edit the field's configuration and set the old value (it will be useless because values were deleted), it makes real damage (you will need to restore a website backup)
if there was a warning someone would prefer not to change (the anyway hidden value "emgland") and thus avoid data loss
To try to fix your problem (not the bug/feature), take a look at Regular Labs dbReplacer. This should make changing all those incorrect values much easier - it's a simple (but powerful!) search and replace.
Status | New | ⇒ | Discussion |
Labels |
Added:
J3 Issue
|
I agree and I will try to come up with a suitable message/alert
This is very good idea to minimize user errors,
but i think it is complementary to the message which is still needed,
because there is still no warning that re-adding a deleted record will not make things work again ...
Maybe to avoid message completely,
Do the read-only thing suggested above
and
put a message when one clicks to delete the value record ?
"After you click save, value assignments of this value will be lost" or some other more good text
If you delete something then you expect it to be gone. Adding a message to
tell you that is superfluous
If you delete something then you expect it to be gone.
you are right,
but everybody makes mistakes,
because being a little tired, little sleepless or or whatever other reason
also how someone perceives this differs
e.g. example deleting a Joomla user does not cause a cascading deletion of user's content
in this case we do have deletion or related assignments (i mean someone may expect same pattern here)
also permanent deletions usually have a warning,
but i understand that deleting many values will be annoying unless the message is only shown once
also i understand that showing the message like i suggested above on delete button is currently not implemented
I guess readonly can work here.
ok i failed at working out how to do it - lack of skills by me - sure someone else can do it though
Title |
|
Title |
|
Having a short check, I don't think so there is a way to make list items read only. Only the whole field or nothing.
Thank you for raising this issue.
Joomla 3 is now in security only mode with no further bug fixes or new features.
As this issue doesn't relate to Joomla 4 it will now been closed.
If we are mistaken and this does apply to Joomla 4 please open a new issue (and reference this one if you wish) with updated details for testing in Joomla 4.
cc @zero-24
Status | Discussion | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2022-08-23 13:46:42 |
Closed_By | ⇒ | zero-24 | |
Labels |
Added:
No Code Attached Yet
Removed: ? |
About the automatic "cleanup" (deleting of value) when options change
(Special handling by the field model for fields of type "FieldsListPlugin")
checkboxes, list, radio, (
imagelist, sql)yes it is there
about remapping an old value to a new value,
there is no bug as there is no magic guessing of what you want to do
no bug, this would be a new feature