Skip to content
Snippets Groups Projects
Commit 1ec42c66 authored by Julian Tolstich's avatar Julian Tolstich
Browse files

Merge branch 'SaveAndReturn' into 'master'

CHANGE save and return return to link after approving a course

See merge request !1
parents 0d607747 bc9297b6
No related branches found
No related tags found
1 merge request!1CHANGE save and return return to link after approving a course
...@@ -64,7 +64,18 @@ if (!empty($approve) and confirm_sesskey()) { ...@@ -64,7 +64,18 @@ if (!empty($approve) and confirm_sesskey()) {
if ($courseid !== false) { if ($courseid !== false) {
if (has_capability('moodle/course:update', context_course::instance($courseid))) { if (has_capability('moodle/course:update', context_course::instance($courseid))) {
redirect(new moodle_url('/course/edit.php', ['id' => $courseid, 'returnto' => 'pending'])); // > Hsh julian wendling - changed "save and return" link to go back to hsh pending page
$returnurl = new moodle_url($baseurl);
$saveandbackurl = new moodle_url($CFG->wwwroot . '/course/edit.php', array(
'id' => $courseid,
'sesskey' => sesskey(),
'returnto' => 'url',
'returnurl' => $returnurl->out(false))
);
redirect(new moodle_url($saveandbackurl->out()));
// < Hsh julian wendling
} else { } else {
redirect(new moodle_url('/course/view.php', ['id' => $courseid])); redirect(new moodle_url('/course/view.php', ['id' => $courseid]));
} }
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
defined('MOODLE_INTERNAL') || die(); defined('MOODLE_INTERNAL') || die();
$plugin->component = 'local_hsh'; $plugin->component = 'local_hsh';
$plugin->version = 2021022300; $plugin->version = 2021022301;
$plugin->release = '3.3 (Build: 2015042300)'; $plugin->release = '3.3 (Build: 2015042300)';
$plugin->requires = 2014051200; $plugin->requires = 2014051200;
$plugin->maturity = MATURITY_STABLE; $plugin->maturity = MATURITY_STABLE;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment