Skip to content
Snippets Groups Projects

Resolve "Overview: Replace the course link with a button on the overview"

2 files
+ 5
4
Compare changes
  • Side-by-side
  • Inline

Files

+ 4
4
@@ -53,10 +53,7 @@
@@ -53,10 +53,7 @@
<tbody>
<tbody>
<tr th:each="course : ${courses}">
<tr th:each="course : ${courses}">
<td>
<td>
<th:block th:if="${@permissionService.canViewCourse(#authentication.principal, course.id)}">
<th:block th:text="${course}">
<a href="#" th:href="@{/course/{id}(id=${course.id})}" th:text="${course}">Algorithms &amp; Datastructures (TI1316)</a>
</th:block>
<th:block th:unless="${@permissionService.canViewCourse(#authentication.principal, course.id)}" th:text="${course}">
Algorithms &amp; Datastructures (TI1316)
Algorithms &amp; Datastructures (TI1316)
</th:block>
</th:block>
</td>
</td>
@@ -65,6 +62,9 @@
@@ -65,6 +62,9 @@
<th:block th:unless="${#authenticated.teaches(course) || #authenticated.assists(course) || #authenticated.manages(course) || #authenticated.participates(course) || course.getIsArchived() }">
<th:block th:unless="${#authenticated.teaches(course) || #authenticated.assists(course) || #authenticated.manages(course) || #authenticated.participates(course) || course.getIsArchived() }">
<a href="#" class="btn btn-success" th:href="@{/course/{id}/enroll(id=${course.id})}">enrol</a>
<a href="#" class="btn btn-success" th:href="@{/course/{id}/enroll(id=${course.id})}">enrol</a>
</th:block>
</th:block>
 
<th:block th:if="${#authenticated.teaches(course) || #authenticated.assists(course) || #authenticated.manages(course) || #authenticated.participates(course)}">
 
<a href="#" class="btn btn-primary" th:href="@{/course/{id}(id=${course.id})}">view</a>
 
</th:block>
</td>
</td>
</tr>
</tr>
</tbody>
</tbody>
Loading