{{! 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 . }} {{! @template tool_lp/user_competency_summary_in_course Moodle template for the the summary of a user competency Classes required for JS: * none Data attributes required for JS: * none Context variables required for this template: * usercompetencysummary - object containing: * showrelatedcompetencies - boolean * cangrade - boolean * competency - competency summary record * user - user record * usercompetency - user competency record * evidence - array of evidence * course - course summary record This template does not have an example context because it includes ajax functionality. }} {{#usercompetencysummary}}
{{#competency}} {{> tool_lp/competency_summary }} {{/competency}}
{{#str}}activities, tool_lp{{/str}}

    {{#coursemodules}}
  • {{name}}
  • {{/coursemodules}} {{^coursemodules}}
  • {{#str}}noactivities, tool_lp{{/str}}
  • {{/coursemodules}}

{{#displayuser}} {{#user}}
{{#str}}user{{/str}}
{{>tool_lp/user_summary}}
{{/user}} {{/displayuser}}
{{#str}}userplans, competency{{/str}}

    {{#plans}}
  • {{{name}}}
  • {{/plans}} {{^plans}}
  • {{#str}}nouserplanswithcompetency, competency{{/str}}
  • {{/plans}}

{{#usercompetencycourse}}
{{#str}}proficient, tool_lp{{/str}}
{{proficiencyname}}
{{#str}}rating, tool_lp{{/str}}
{{gradename}} {{#cangrade}} {{/cangrade}}
{{/usercompetencycourse}} {{#js}} require(['jquery', 'tool_lp/grade_user_competency_inline', 'tool_lp/user_competency_info'], function($, mod, info) { var inlineGrader = new mod('#rate_{{uniqid}}', '{{competency.scaleid}}', '{{competency.competency.id}}', '{{user.id}}', '', '{{course.id}}', '{{#str}}chooserating, tool_lp{{/str}}'); var competencyElement = $('[data-region-id="{{uniqid}}"]'); var displayuser = ('{{displayuser}}' == 'true') ? true : false; var infoReloader = new info(competencyElement, '{{competency.competency.id}}', '{{user.id}}', '', '{{course.id}}', displayuser); inlineGrader.on('competencyupdated', infoReloader.reload.bind(infoReloader)); }); {{/js}}
{{#commentarea}} {{#canpostorhascomments}} {{>tool_lp/comment_area}} {{/canpostorhascomments}} {{/commentarea}}
{{#str}}evidence, tool_lp{{/str}}
{{#evidence}} {{> tool_lp/evidence_summary }} {{/evidence}} {{^evidence}}

{{#str}}noevidence, tool_lp{{/str}}

{{/evidence}}
{{/usercompetencysummary}}