Skip to content

Commit

Permalink
Improvement: Make all block regions available for the incourse and co…
Browse files Browse the repository at this point in the history
…ursecategory page layouts, resolves #543. (#545)
  • Loading branch information
abias authored Jan 26, 2024
1 parent 1acf7c0 commit 30900ab
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 15 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Changes

### Unreleased

* 2024-01-20 - Improvement: Make all block regions available for the incourse and coursecategory page layouts, resolves #543.
* 2024-01-19 - Bugfix: Get rid of 'Undefined stdClass property' notices for static page settings, resolves #431.

### v4.3-r4
Expand Down
4 changes: 2 additions & 2 deletions settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -1345,8 +1345,8 @@
$pagelayouts = [
'standard' => $partialregions,
'admin' => $partialregions,
'coursecategory' => $partialregions,
'incourse' => $partialregions,
'coursecategory' => $allavailableregions,
'incourse' => $allavailableregions,
'mypublic' => $partialregions,
'report' => $partialregions,
'course' => $allavailableregions,
Expand Down
21 changes: 9 additions & 12 deletions tests/behat/theme_boost_union_feelsettings_blocks.feature
Original file line number Diff line number Diff line change
Expand Up @@ -87,15 +87,14 @@ Feature: Configuring the theme_boost_union plugin for the "Blocks" tab on the "F
| outside-top | footer-left,footer-right | should not |

@javascript
Scenario Outline: Setting: Enable additional block regions (on a category overview page where not all regions are offered)
Scenario Outline: Setting: Enable additional block regions (on the admin overview page where not all regions are offered)
When I log in as "admin"
And I am on course index
And I follow "Category A"
And I follow "Site administration"
And I turn editing mode on
Then "#theme-block-region-<region>" "css_element" should not exist
And the following config values are set as admin:
| config | value | plugin |
| blockregionsforcoursecategory | <settingvalue> | theme_boost_union |
| config | value | plugin |
| blockregionsforadmin | <settingvalue> | theme_boost_union |
And I reload the page
Then "#theme-block-region-<region>" "css_element" <should> exist

Expand Down Expand Up @@ -183,20 +182,18 @@ Feature: Configuring the theme_boost_union plugin for the "Blocks" tab on the "F
| header | header |

@javascript
Scenario Outline: Setting: Use additional block regions (on a category overview page where not all regions are offered)
Scenario Outline: Setting: Use additional block regions (on the admin overview page where not all regions are offered)
Given the following config values are set as admin:
| config | value | plugin |
| blockregionsforcoursecategory | <settingvalue> | theme_boost_union |
| config | value | plugin |
| blockregionsforadmin | <settingvalue> | theme_boost_union |
When I log in as "admin"
And I am on course index
And I follow "Category A"
And I follow "Site administration"
And I turn editing mode on
And I should see "Add a block" in the "#theme-block-region-<region>" "css_element"
And I click on "Add a block" "link" in the "#theme-block-region-<region>" "css_element"
And I should see "Online users" in the ".modal-body" "css_element"
And I click on "Online users" "link" in the ".modal-body" "css_element"
And I am on course index
And I follow "Category A"
And I follow "Site administration"
And I turn editing mode off
Then I should see "Online users" in the "#theme-block-region-<region>" "css_element"

Expand Down
2 changes: 1 addition & 1 deletion version.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
defined('MOODLE_INTERNAL') || die();

$plugin->component = 'theme_boost_union';
$plugin->version = 2023102018;
$plugin->version = 2023102019;
$plugin->release = 'v4.3-r4';
$plugin->requires = 2023100900;
$plugin->supported = [403, 403];
Expand Down

0 comments on commit 30900ab

Please sign in to comment.