pkp / classic

An official theme for OJS 3.1.1+
GNU General Public License v2.0
11 stars 27 forks source link

Themes shown when installed, even if they are not enabled #66

Closed marcbria closed 4 years ago

marcbria commented 4 years ago

Describe the bug Themes are available in Appearance to be activated just when they are installed. This is wrong because themes should be enabled first at journal level.

To Reproduce Steps to reproduce the behavior:

  1. Setup a clean OJS 3.2 installation.
  2. Go to Settings > Website > Plugins > Plugin Gallery
  3. Click on any theme (ie: Classic) to install it.
  4. You will be redirected to Appearance
  5. Classic will be shown in the dropdown.

Expected behavior As said, installing is not enough to show to allow you activate the theme. Themes should be enabled first at journal level to be shown in this list... otherwise we will show and let journal managers use a theme that we still don't want them to use.

Desktop (please complete the following information):

Vitaliy-1 commented 4 years ago

Thanks,

I would say that it should be handled from an upper level. It looks to me that passing a contextId here as an additional parameter should work, but it doesn't, for some reason: https://github.com/pkp/pkp-lib/blob/66b986b734e3296d33cb2ea1f5d23dfe51ea1b89/classes/components/forms/context/PKPThemeForm.inc.php#L59

Can you open it as a general OJS issue?

marcbria commented 4 years ago

Ups, my fault.

Closing and posted here: https://github.com/pkp/pkp-lib/issues/5617

Thanks Vitaliy.