localgovdrupal / localgov_microsites

A repository for the LocalGov Drupal Microsites project.
GNU General Public License v2.0
3 stars 2 forks source link

Controller cannot save microsite site-stettings #486

Open finnlewis opened 2 weeks ago

finnlewis commented 2 weeks ago

As a controller logged into the control site I want to save the site-settings form for a microsite So that I can configure the microsite from the control site

But we can't!

Steps to replicate

  1. install microsites 4.0.0
  2. create a user with the 'controller' role
  3. log into the control site as the controller user
  4. create a microsite
  5. edit the microsite
  6. Edit the site settings https://localgov-microsites.ddev.site/group/1/domain-settings
  7. Save
  8. See "Error message 1 error has been found: Site front page

image

This seems to happen because the controller user does not have access to the microsite content on the control site, so Drupal is not happy setting the front page.

Maybe we should just hide the domain-settings from the control site?

Or remove the 'site front page' and 403 and 404 page fields from the form on the control site.

@ekes @stephen-cox any thoughts on the best logic here?

stephen-cox commented 1 day ago

This seems to be fairly critical to me. It prevents controllers from saving any domain settings.

I suggest hiding the fields controllers don't have access to. PR on it's way.