{{! This file is part of Moodle - http://moodle.org/ Moodle is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. Moodle is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with Moodle. If not, see . }} {{! Manage learning plan templates template. Classes required for JS: * drag-parentnode * drag-samenode * templateactions Data attibutes required for JS: * data-region = managetemplates * data-templateid = id * data-action = deletetemplate Context variables required for this template: * templates - array of objects containing id, shortname, visible, canmanage, contextname * navigation - array of strings containing buttons for navigation }}
{{#navigation}} {{{.}}} {{/navigation}}
{{#canmanage}} {{/canmanage}} {{#templates}} {{/templates}}
{{#str}}listtemplatescaption, tool_lp{{/str}}
{{#str}}templatename, tool_lp{{/str}} {{#str}}category, tool_lp{{/str}} {{#str}}cohorts, core_cohort{{/str}} {{#str}}userplans, core_competency{{/str}}{{#str}}actions, tool_lp{{/str}}
{{{shortname}}} {{^visible}}{{#str}}hiddenhint, tool_lp{{/str}}{{/visible}} {{contextnamenoprefix}} {{cohortscount}} {{planscount}} {{#canmanage}} {{/canmanage}}
{{^templates}}

{{#str}}notemplates, tool_lp{{/str}}

{{/templates}} {{#js}} // Initialise the JS. require(['tool_lp/templateactions', 'tool_lp/menubar'], function(actionsMod, menubar) { actionsMod.init({{pagecontextid}}); menubar.enhance('.templateactions', { '[data-action="deletetemplate"]': actionsMod.deleteHandler, '[data-action="duplicatetemplate"]': actionsMod.duplicateHandler }); }); {{/js}}