Problem/Motivation

What does this error mean? I can certainly changes these settings on this screen.

Proposed resolution

Change: "The field settings can no longer be changed."
To: "Some field settings can no longer be changed."

Remaining tasks

Usability discussion. Can we be more specific?

User interface changes

Nothing except text.

API changes

None.

Data model changes

None.

Comments

chx created an issue. See original summary.

cilefen’s picture

Version: 8.2.x-dev » 8.3.x-dev
Status: Active » Needs review
StatusFileSize
new2.78 KB
chx’s picture

That's a great simple patch definitely making it better, thanks! Although translators might disagree. I am not sure what is the policy on strings changing when they are conveying the wrong information?

But I wonder, could we display the labels perhaps of those no longer changeable? Some of them at least? Or is that overkill?

chi’s picture

This message is always confusing me. Why is it red? Did something really wrong happen on a site? A user just wanted to check field settings and got scared with this error message.

Can we turn it into warning?

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.0-alpha1 will be released the week of January 30, 2017, which means new developments and disruptive changes should now be targeted against the 8.4.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

chrisrockwell’s picture

This patch makes the error message more accurate and is a welcome improvement. I agree with @chx that it would be nice to know which ones can not be changed.

In my instance (available values for select list / checkboxes) I went ahead and changed values, clicked Save, *just to see* what would happen. Surprisingly, I received a confirmation message and the values were changed.

EDIT: I did more testing. In my case, there were *no* settings that I couldn't change, though I still got this error message.

EDIT 2: After saving some content that uses this field I tried again. I was able to change labels just fine, I couldn't change the keys (which makes sense). I did get a proper warning when I tried to change the keys.

chrisrockwell’s picture

Issue tags: +UX

Adding ux tag

yoroy’s picture

Issue tags: -UX +Usability

Thanks for noticing this :) We settled on "usability" as the catch-all tag for ux & design related issues, so tagging with that.

wturrell’s picture

Issue summary: View changes
Issue tags: +String change in 8.4.0

- Updated issue summary.
- Tagged as translatable string change.

alexrayu’s picture

I often end up explaining to my clients, that there is a reason for this - there is data there already, and Drupal can not change some of the settings, or it would break it.

"This field has data in the database. Some respective settings can no longer be changed." Or something like that.

And, possibly, a warning, rather than an error?

yoroy’s picture

It's not an error to go to this page so this should probably be a warning indeed.

Although more correct I don't like to use the word "some" in these situations, it shifts the work of finding out *which* to the user. If there’s a way to visually disable those elements that can't be changed that'd be good.

tkoleary’s picture

Issue summary: View changes
StatusFileSize
new32.17 KB

Discussion in the Usability Meeting brought up the following points:

1. Why do we allow users to make an action they should not make? ie. why not disable the select.
2. This issue points to a larger problem with the mental model of field UI not being clear, ie. there is no clear separation of affordances between what is a setting on a base field or a field instance.

On the first question, since the problem here is that it is possible to change the setting but only in one direction—more, not fewer values—then we should disable only options that are not allowed. So if the user had limited the number of values to 3 then another user wanted to decrease it to 2 they would see something like thisomething like this:

The second point about the field UI mental model is something that really requires deeper consideration but perhaps not in this issue.

chrisrockwell’s picture

@tkoleary to complicate things further...in the instance of a List that allows for <select>, <checkbox>, <radio> we enter values as value|label. If there is data already saved, the value cannot be changed, but the label can, so we can't disable the entire textarea

chrisrockwell’s picture

Issue summary: View changes
StatusFileSize
new23.05 KB

Probably outside of the scope of this issue, but I'm attaching a screenshot of how Webform (YamlForm) handles select list. Not only would this, IMO, be easier for a site builder to comprehend but it would allow for disabling the parts that can't be changed.

tkoleary’s picture

@chrisrcokwell

I don't think it's out of scope. It works quite well for that case but could also work in the case of limited/unlimited where, for example, if 'limited' was selected and the limit was 3 you could potentially see a table with:

Entry 1 — Data exists — Remove (x) [disabled]
Entry 2 — No data exists yet — Remove (x) [enabled]
Entry 3 — No data exists yet — Remove (x) [enabled], Add row (+) [Enabled]

In the webform example I don't really see the value of providing a plus button on every row. One 'Add row' button at the end should be enough.

Version: 8.4.x-dev » 8.5.x-dev

Drupal 8.4.0-alpha1 will be released the week of July 31, 2017, which means new developments and disruptive changes should now be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

coffeymachine’s picture

IMO, Drupal could handle this whole use case better.

If a site builder wants to remove values from a field, let them. Have Drupal go ahead and destroy the content (after a stern warning of course). Then maybe you have some entities dangling with empty fields. The next time a user goes to update the entity, they'll have to fix the field before they can save.

In addition to this, could we notify the user of which entities are preventing the field from being modified? For instance, currently if you try to reduce the allowed number of values from 4 to 3, Drupal will give an error message along the lines of:

There is 1 entity with 4 or more values in this field.

Instead of this vague error message, could we list the entity(ies) that the error message is referring to? Then the site builder would have the opportunity to review the content in question and decide if they can discard it or not.

Does this make sense?

+1 vote for the Webform style select list by the way. That's an awesome idea.

Version: 8.5.x-dev » 8.6.x-dev

Drupal 8.5.0-alpha1 will be released the week of January 17, 2018, which means new developments and disruptive changes should now be targeted against the 8.6.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.6.x-dev » 8.7.x-dev

Drupal 8.6.0-alpha1 will be released the week of July 16, 2018, which means new developments and disruptive changes should now be targeted against the 8.7.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.7.x-dev » 8.8.x-dev

Drupal 8.7.0-alpha1 will be released the week of March 11, 2019, which means new developments and disruptive changes should now be targeted against the 8.8.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

bramdriesen’s picture

Issue tags: -

I agree with #17. Doesn't really make sense to me to block changes to a field, for example if you would have a list field with colours, you won't be able to add/remove anything after you added 1 piece of content with it;

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

CptCasual’s picture

Came across this same issue in 8.8.4. Wish the fix would get into core, please?

Version: 8.9.x-dev » 9.1.x-dev

Drupal 8.9.0-beta1 was released on March 20, 2020. 8.9.x is the final, long-term support (LTS) minor release of Drupal 8, which means new developments and disruptive changes should now be targeted against the 9.1.x-dev branch. For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

Version: 9.2.x-dev » 9.3.x-dev

Drupal 9.2.0-alpha1 will be released the week of May 3, 2021, which means new developments and disruptive changes should now be targeted for the 9.3.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

bernardm28’s picture

I agree with #12. A user should not be able to change the field original value if there's data stored.
If they did not care about the data they could create a new field and delete the current one.
I'm not sure a site builder will know the implications their actions until is too late to save any data from backups or otherwise.
I can see #17 #18 perspective but thats more of a developer time saving concern.
if you would have a list field with colours, that could come from taxonomy if is unpredictable how often they will change their options or just add a new field and migrate their current selection to their new list options.

Version: 9.3.x-dev » 9.4.x-dev

Drupal 9.3.0-rc1 was released on November 26, 2021, which means new developments and disruptive changes should now be targeted for the 9.4.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.4.x-dev » 9.5.x-dev

Drupal 9.4.0-alpha1 was released on May 6, 2022, which means new developments and disruptive changes should now be targeted for the 9.5.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

Version: 9.5.x-dev » 10.1.x-dev

Drupal 9.5.0-beta2 and Drupal 10.0.0-beta2 were released on September 29, 2022, which means new developments and disruptive changes should now be targeted for the 10.1.x-dev branch. For more information see the Drupal core minor version schedule and the Allowed changes during the Drupal core release cycle.

lauriii’s picture