Skip to content

Commit

Permalink
Add link to recit apis
Browse files Browse the repository at this point in the history
  • Loading branch information
gustavobazzo committed Jan 29, 2025
1 parent 61e322e commit 1bb85a1
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/classes/local/CtrlLayout.php
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,10 @@ public static function get_user_menu($page, $user) {
self::add_nav_item($result, "mycourses", "fa-graduation-cap", "mycourses", $CFG->wwwroot . "/my/courses.php");
self::add_nav_item($result, "mymoodle", "fa-tachometer", "dashboard", $CFG->wwwroot . "/my/", get_string('mymoodle', 'my'));

if(is_dir($CFG->dirroot . "/admin/tool/recitapis")){
self::add_nav_item($result, "recitapis", "fa-connectdevelop", null, $CFG->wwwroot . "/admin/tool/recitapis/view.php", get_string("tool_recitapis", "theme_recit2"));
}

if($COURSE->id > 1){

$roles = ThemeUtils::getUserRoles($COURSE->id, $USER->id);
Expand Down
3 changes: 2 additions & 1 deletion src/lang/en/theme_recit2.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,4 +160,5 @@
$string['hide_restricted_section'] = "Do not display sections that have access restrictions";
$string['hide_restricted_section_help'] = "When checked, unavailable sections are not displayed in the menu.";
$string['prev_section'] = 'Previous section';
$string['next_section'] = 'Next section';
$string['next_section'] = 'Next section';
$string['tool_recitapis'] = 'RÉCIT APIs';
3 changes: 2 additions & 1 deletion src/lang/fr/theme_recit2.php
Original file line number Diff line number Diff line change
Expand Up @@ -161,4 +161,5 @@
$string['hide_restricted_section'] = "Ne pas afficher les sections qui possèdent des restrictions d'accès";
$string['hide_restricted_section_help'] = "Lorsque coché, les sections non disponibles ne sont pas affichées dans le menu.";
$string['prev_section'] = 'Section précédente';
$string['next_section'] = 'Section suivante';
$string['next_section'] = 'Section suivante';
$string['tool_recitapis'] = 'RÉCIT APIs';
3 changes: 3 additions & 0 deletions src/templates/recit/navbar_top.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,9 @@
{{#usermenu.mymoodle.url}}
<a class="dropdown-item" href="{{usermenu.mymoodle.url}}"><i class="fa {{usermenu.mymoodle.pix}}"></i> {{usermenu.mymoodle.title}}</a>
{{/usermenu.mymoodle.url}}
{{#usermenu.recitapis.url}}
<a class="dropdown-item" href="{{usermenu.recitapis.url}}"><i class="fa {{usermenu.recitapis.pix}}"></i> {{usermenu.recitapis.title}}</a>
{{/usermenu.recitapis.url}}

{{#usermenu.participants.url}}
<a class="dropdown-item" href="{{usermenu.participants.url}}"><i class="fa {{usermenu.participants.pix}}"></i> {{usermenu.participants.title}}</a>
Expand Down
2 changes: 1 addition & 1 deletion src/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
$plugin->component = 'theme_recit2';

// This is the named version.
$plugin->release = 'v3.2.5-stable';
$plugin->release = 'v3.2.6-stable';
$plugin->supported = [400, 403]; // Moodle 4.0.x, are supported.
// This is a stable release.
$plugin->maturity = MATURITY_STABLE;
1 change: 1 addition & 0 deletions sync.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
$from = "moodle-theme_recit/src/*"
$to = "shared/recitfad/theme/recit2/"
$source = "./src";

try {
. ("..\sync\watcher.ps1")
Expand Down

0 comments on commit 1bb85a1

Please sign in to comment.