When a user visits their personal "scheduled content" page (user/UID/scheduled), it changes the theme to the administration theme, even if the permission "view administration theme" is disabled for the role. Is there a way to prevent the theme from switching?

Issue fork scheduler-3266795

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

arlingtonvoicellc created an issue. See original summary.

jonathan1055’s picture

Version: 8.x-1.4 » 2.x-dev

Thanks arlingtonvoicellc for reporting this.
1. Just so I understand you correctly, you are allowing users access to admin/content/scheduled but you are not allowing them to view the admin theme?
2. It will need investigation (and fixing) at Scheduler 2.x first. Have you tried that yet?

arlingtonvoicellc’s picture

Version: 2.x-dev » 8.x-1.4

Sorry, I had the wrong version selected. I'm using 1.4.

The affected URL is user/UID/scheduled.

Steps to reproduce:
1. Enable scheduler and dependencies
2. Assign 'schedule content publication' permission to authenticated role
3. Set scheduler field settings for node type and add/schedule a piece of content as authenticated user
4. After content is scheduled, visit /user/UID/scheduled (admin theme shown here)

You probably don't have to assign any content. You can probably just visit user/UID/scheduled as an authenticated user after assigning the permission to see the admin theme displayed.

arlingtonvoicellc’s picture

Issue summary: View changes
jonathan1055’s picture

Title: Scheduled Content page defaults to admin theme even if permission is restricted » Users' scheduled view uses admin theme even if permission is restricted
Version: 8.x-1.4 » 2.x-dev

Thanks @arlingtonvoicellc that makes sence now, I thought you were saying the problem was on admin/content/scheduled. I have confirmed this is a bug, at both 8.x-1.x and 2.x (I switched the version on this issue, it was not your mistake). The problem was introduced in #3128187: Content List View for a user - change theme to admin not front-end default theme and should be simple to fix.

jonathan1055’s picture

The MR is on the 2.x branch, but the identical fix applies to 8.x-1.x, here's a patch for you to try.

jonathan1055’s picture

Status: Active » Needs review

All seems OK, needs review. @arlingtonvoicellc let me know how you get on with the patch. You will have to clear the cache to get the updated SchedulerThemeNegotiator to become active.

arlingtonvoicellc’s picture

The patch works great! Thank you for this.

  • jonathan1055 committed e7eedb7 on 2.x
    Issue #3266795 by jonathan1055: Users' scheduled view uses admin theme...

  • jonathan1055 committed 5e47d78 on 8.x-1.x
    Issue #3266795 by jonathan1055: Users' scheduled view uses admin theme...
jonathan1055’s picture

Status: Needs review » Fixed

Thanks for testing.
Committed to 2.x and 1.x

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.