MDL-57445 block_myoverview: Add course view to timeline
authorCameron Ball <cameron@moodle.com>
Sun, 1 Jan 2017 17:19:09 +0000 (01:19 +0800)
committerDamyon Wiese <damyon@moodle.com>
Mon, 3 Apr 2017 03:35:37 +0000 (11:35 +0800)
Part of MDL-55611 epic.

blocks/myoverview/templates/timeline-view-courses.mustache [new file with mode: 0644]
blocks/myoverview/templates/timeline-view.mustache

diff --git a/blocks/myoverview/templates/timeline-view-courses.mustache b/blocks/myoverview/templates/timeline-view-courses.mustache
new file mode 100644 (file)
index 0000000..89539a2
--- /dev/null
@@ -0,0 +1,35 @@
+{{!
+    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 <http://www.gnu.org/licenses/>.
+}}
+{{!
+    @template block_myoverview/timeline-view-courses
+
+    This template renders the timeline view by courses for the myoverview block.
+}}
+<div id="timeline-view-courses-{{uniqid}}" data-region="timeline-view-courses">
+    {{#courses}}
+        <div class="container-fluid" data-region="view-course">
+            <div class="row">
+                <div class="col-md-3">
+                    {{> block_myoverview/course-summary }}
+                </div>
+                <div class="col-md-9">
+                    {{> block_myoverview/view-dates }}
+                </div>
+            </div>
+        </div>
+    {{/courses}}
+</div>
index 3fb6633..0f68ba3 100644 (file)
@@ -36,6 +36,7 @@
             {{> block_myoverview/timeline-view-dates }}
         </div>
         <div class="tab-pane fade" id="myoverview_timeline_courses">
+            {{> block_myoverview/timeline-view-courses }}
         </div>
     </div>
 </div>