Active
Project:
Drupal core
Version:
main
Component:
views.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
22 Mar 2014 at 20:48 UTC
Updated:
15 Feb 2021 at 15:57 UTC
Jump to comment: Most recent
Comments
Comment #9
lendude$form_state['controller']->getEntity() instanceof ConfigEntityInterface;If I read that line right, it gets the entity from the form and checks if this is a config entity. The Preview displays how a View is rendered, and since a View is a config entity, I'm not sure what is bugged here.
But if this is still an issue, please feel free to reopen this.
Comment #10
longwaveI think the point is that while a View is a config entity, submitting the preview form doesn't make any changes to config. config_readonly uses this mechanism to detect and show a message on forms that might change config - it incorrectly shows a message here because it thinks the form is used to manage a config entity, but that's not actually true.
The way to rearchitect this would be to change the parent class of ViewPreviewForm so it doesn't extend from ViewFormBase (which then inherits from EntityForm), and perhaps move some parts of ViewFormBase into a trait so they can be reused as required.
However I'm not sure this is strictly a bug so reclassifying this as a task for now.