Skip to content

Commit

Permalink
MDL-78267 core_courseformat: Language changes
Browse files Browse the repository at this point in the history
Change from "Bulk edit" to "Bulk actions"
  • Loading branch information
HuongNV13 committed Sep 14, 2023
1 parent f6b7447 commit 705a721
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 29 deletions.
6 changes: 3 additions & 3 deletions course/format/tests/behat/bulk_activity_actions.feature
Expand Up @@ -26,7 +26,7 @@ Feature: Bulk course activity actions.
| allowstealth | 1 |
And I am on the "C1" "Course" page logged in as "teacher1"
And I turn editing mode on
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"

Scenario: Bulk hiding activities
Expand All @@ -52,7 +52,7 @@ Feature: Bulk course activity actions.
| assign | Activity sample 5 | Test assignment description | C1 | sample5 | 1 | 0 |
| assign | Activity sample 6 | Test assignment description | C1 | sample6 | 2 | 0 |
And I reload the page
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should not see "Hidden from students" in the "Activity sample 4" "activity"
And I should see "Hidden from students" in the "Activity sample 5" "activity"
And I should see "Hidden from students" in the "Activity sample 6" "activity"
Expand All @@ -76,7 +76,7 @@ Feature: Bulk course activity actions.
When the following config values are set as admin:
| allowstealth | 0 |
And I reload the page
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
Then I click on "Select activity Activity sample 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
And I click on "Activity availability" "button" in the "sticky-footer" "region"
Expand Down
2 changes: 1 addition & 1 deletion course/format/tests/behat/bulk_section_actions.feature
Expand Up @@ -26,7 +26,7 @@ Feature: Bulk course section actions.
| allowstealth | 1 |
And I am on the "C1" "Course" page logged in as "teacher1"
And I turn editing mode on
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"

Scenario: Bulk hide sections
Expand Down
40 changes: 20 additions & 20 deletions course/format/tests/behat/bulk_select.feature
Expand Up @@ -26,60 +26,60 @@ Feature: Bulk activity and section selection.
And I turn editing mode on

Scenario: Enable and disable bulk editing
When I click on "Bulk edit" "button"
When I click on "Bulk actions" "button"
Then I should see "0 selected" in the "sticky-footer" "region"
And the focused element is "Select topic Topic 1" "checkbox"
And I click on "Close bulk edit" "button" in the "sticky-footer" "region"
And I click on "Close bulk actions" "button" in the "sticky-footer" "region"
And "sticky-footer" "region" should not be visible
And the focused element is "Bulk edit" "button"
And the focused element is "Bulk actions" "button"

Scenario: Selecting activities disable section selection
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Select activity Activity sample 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
Then the "Select topic Topic 1" "checkbox" should be disabled

Scenario: Selecting sections disable activity selection
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Select topic Topic 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
Then the "Select activity Activity sample 1" "checkbox" should be disabled

Scenario: Disable bulk resets the selection
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I click on "Select activity Activity sample 1" "checkbox"
And I click on "Select activity Activity sample 2" "checkbox"
And I should see "2 selected" in the "sticky-footer" "region"
And the field "Activity sample 1" matches value "1"
And the field "Activity sample 2" matches value "1"
And the field "Activity sample 3" matches value ""
And the field "Activity sample 4" matches value ""
When I click on "Close bulk edit" "button" in the "sticky-footer" "region"
And I click on "Bulk edit" "button"
When I click on "Close bulk actions" "button" in the "sticky-footer" "region"
And I click on "Bulk actions" "button"
Then I should see "0 selected" in the "sticky-footer" "region"
And the field "Activity sample 1" matches value ""
And the field "Activity sample 2" matches value ""
And the field "Activity sample 3" matches value ""
And the field "Activity sample 4" matches value ""

Scenario: Select all is disabled until an activity is selected
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And the "Select all" "checkbox" should be disabled
When I click on "Select activity Activity sample 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
Then the "Select all" "checkbox" should be enabled

Scenario: Select all is disabled until a section is selected
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And the "Select all" "checkbox" should be disabled
When I click on "Select topic Topic 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
Then the "Select all" "checkbox" should be enabled

Scenario: Select all when an activity is selected will select all activities
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I click on "Select activity Activity sample 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
And the field "Activity sample 1" matches value "1"
Expand All @@ -95,7 +95,7 @@ Feature: Bulk activity and section selection.
And the field "Activity sample 4" matches value "1"

Scenario: Select all when a section is selected will select all sections
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I click on "Select topic Topic 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
And the field "Select topic Topic 1" matches value "1"
Expand All @@ -111,7 +111,7 @@ Feature: Bulk activity and section selection.
And the field "Select topic Topic 4" matches value "1"

Scenario: Click on a select all with all sections selected unselects all sections
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I click on "Select topic Topic 1" "checkbox"
And I click on "Select topic Topic 2" "checkbox"
And I click on "Select topic Topic 3" "checkbox"
Expand All @@ -127,7 +127,7 @@ Feature: Bulk activity and section selection.
And the field "Select topic Topic 4" matches value ""

Scenario: Click on a select all with all activity selected unselects all activities
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I click on "Select activity Activity sample 1" "checkbox"
And I click on "Select activity Activity sample 2" "checkbox"
And I click on "Select activity Activity sample 3" "checkbox"
Expand All @@ -143,7 +143,7 @@ Feature: Bulk activity and section selection.
And the field "Activity sample 4" matches value ""

Scenario: Click an activity name in bulk mode select and unselects the activity
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Activity sample 1" "link" in the "Topic 1" "section"
And the field "Activity sample 1" matches value "1"
Expand All @@ -164,7 +164,7 @@ Feature: Bulk activity and section selection.
And the field "Activity sample 4" matches value ""

Scenario: Select a range of activities using shift
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Activity sample 1" "link" in the "Topic 1" "section"
And the field "Activity sample 1" matches value "1"
Expand All @@ -179,7 +179,7 @@ Feature: Bulk activity and section selection.
And the field "Activity sample 4" matches value ""

Scenario: Select all activities in a section using alt
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I alt click on "Activity sample 3" "link" in the "Topic 2" "section"
Then I should see "2 selected" in the "sticky-footer" "region"
Expand All @@ -189,7 +189,7 @@ Feature: Bulk activity and section selection.
And the field "Activity sample 4" matches value "1"

Scenario: Select a range of sections using shift
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Select topic Topic 1" "checkbox"
And the field "Select topic Topic 1" matches value "1"
Expand All @@ -204,7 +204,7 @@ Feature: Bulk activity and section selection.
And the field "Select topic Topic 4" matches value ""

Scenario: Select all section with alt click
Given I click on "Bulk edit" "button"
Given I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
And the field "Select topic Topic 1" matches value ""
And the field "Select topic Topic 2" matches value ""
Expand All @@ -222,7 +222,7 @@ Feature: Bulk activity and section selection.
And I expand all fieldsets
And I set the field "Course layout" to "Show one section per page"
And I click on "Save and display" "button"
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"
When I click on "Select topic Topic 1" "checkbox"
And I click on "Select topic Topic 2" "checkbox"
Expand Down
Expand Up @@ -27,15 +27,15 @@ Feature: Bulk course section actions one section per page.
| allowstealth | 1 |
And I am on the "C1" "Course" page logged in as "teacher1"
And I turn editing mode on
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"

Scenario: Bulk section edit is only available when multiple sections are displayed
Given I click on "Select topic Topic 1" "checkbox"
And I should see "1 selected" in the "sticky-footer" "region"
# Move to single topic page.
When I click on "Topic 1" "link" in the "region-main" "region"
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
Then "Select topic Topic 1" "checkbox" should not exist

Scenario: Bulk availability sections in one section per page
Expand Down
2 changes: 1 addition & 1 deletion course/format/weeks/tests/behat/bulk_actions.feature
Expand Up @@ -26,7 +26,7 @@ Feature: Weeks format bulk activity actions.
| teacher1 | C1 | editingteacher |
And I am on the "C1" "Course" page logged in as "teacher1"
And I turn editing mode on
And I click on "Bulk edit" "button"
And I click on "Bulk actions" "button"
And I should see "0 selected" in the "sticky-footer" "region"

Scenario: Bulk hide weeks
Expand Down
4 changes: 2 additions & 2 deletions lang/en/courseformat.php
Expand Up @@ -28,9 +28,9 @@
$string['availability_hide_help'] = 'Not available to students.';
$string['availability_stealth'] = 'Make available but don\'t show on course page';
$string['availability_stealth_help'] = 'Available to students if you provide a link. Activities will still appear in the gradebook and other reports.';
$string['bulkedit'] = 'Bulk edit';
$string['bulkedit'] = 'Bulk actions';
$string['bulkeditingcourse'] = 'Bulk edit course: {$a}';
$string['bulkcancel'] = 'Close bulk edit';
$string['bulkcancel'] = 'Close bulk actions';
$string['bulkselection'] = '{$a} selected';
$string['bulkselection_plural'] = '{$a} selected';
$string['cmavailability'] = 'Activity availability';
Expand Down

0 comments on commit 705a721

Please sign in to comment.