Skip to content

Commit

Permalink
MDL-69874 workshop: Title mentions received assessments in close phase.
Browse files Browse the repository at this point in the history
  • Loading branch information
lucaboesch committed Apr 13, 2021
1 parent 511a87f commit 37a1f24
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
1 change: 1 addition & 0 deletions mod/workshop/lang/en/workshop.php
Expand Up @@ -445,3 +445,4 @@
$string['yourassessmentfor'] = 'Your assessment for {$a}';
$string['yourgrades'] = 'Your grades';
$string['yoursubmission'] = 'Your submission';
$string['yoursubmissionwithassessments'] = 'Your submission with assessments';
8 changes: 8 additions & 0 deletions mod/workshop/tests/behat/workshop_assessment.feature
Expand Up @@ -148,6 +148,14 @@ Feature: Workshop submission and assessment
And I press "Re-calculate grades"
And I should see "32" in the "//table/tbody/tr[td[contains(concat(' ', normalize-space(@class), ' '), ' participant ') and contains(.,'Sam1')]]/td[contains(concat(' ', normalize-space(@class), ' '), ' submissiongrade ')]" "xpath_element"
And I should see "16" in the "//table/tbody/tr[td[contains(concat(' ', normalize-space(@class), ' '), ' participant ') and contains(.,'Sam1')]]/td[contains(concat(' ', normalize-space(@class), ' '), ' gradinggrade ')]" "xpath_element"
And I change phase in workshop "TestWorkshop" to "Closed"
And I log out

# student1 looks at the activity
And I log in as "student1"
And I am on "Course1" course homepage
And I follow "TestWorkshop"
Then I should see "Your submission with assessments"
And I log out

@javascript
Expand Down
4 changes: 2 additions & 2 deletions mod/workshop/view.php
Expand Up @@ -615,8 +615,8 @@
}
}
if (has_capability('mod/workshop:submit', $PAGE->context)) {
print_collapsible_region_start('', 'workshop-viewlet-ownsubmission', get_string('yoursubmission', 'workshop'),
'workshop-viewlet-ownsubmission-collapsed');
print_collapsible_region_start('', 'workshop-viewlet-ownsubmission',
get_string('yoursubmissionwithassessments', 'workshop'), 'workshop-viewlet-ownsubmission-collapsed');
echo $output->box_start('generalbox ownsubmission');
if ($submission = $workshop->get_submission_by_author($USER->id)) {
echo $output->render($workshop->prepare_submission_summary($submission, true));
Expand Down

0 comments on commit 37a1f24

Please sign in to comment.