Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tweak to allow sub navigation (activity_navigation) #1

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 13 additions & 1 deletion lib.php
Expand Up @@ -39,7 +39,19 @@ public function uses_sections() {
}

public function uses_course_index() {
return true;

// Dirty tweak to allow both index and submenu.
// First run will be -> course_index_drawer().
// Next run will be -> activity_navigation().

static $i = 0;
$i++;

if ($i === 1) {
return true;
}

return false;
}

public function uses_indentation(): bool {
Expand Down
2 changes: 1 addition & 1 deletion version.php
Expand Up @@ -27,7 +27,7 @@

defined('MOODLE_INTERNAL') || die();

$plugin->version = 2021120700;
$plugin->version = 2022101202;
$plugin->maturity = MATURITY_ALPHA;
$plugin->requires = 2022032900.00; // 4.0beta+ (Build: 20220329).
$plugin->supported = array(400, 400);
Expand Down