<div class='dashboard-block-header'>
  {{t 'general.myCourses'}}
</div>

<div class='dashboard-block-body'>
  {{#if listOfCourses.isFulfilled}}
    {{#if sortedListOfCourses.length}}
      <table>
        <tbody>
          {{#each sortedListOfCourses as |course|}}
            {{#link-to 'course' course}}
              <tr class='clickable'>
                <td>{{fa-icon 'external-link-square'}}</td>
                <td>{{course.academicYear}}</td>
                <td>{{course.title}}</td>
              </tr>
            {{/link-to}}
          {{/each}}
        </tbody>
      </table>
    {{else}}
      {{t 'general.none'}}
    {{/if}}
  {{else}}
    <h1>{{fa-icon 'spinner' spin=true}}</h1>
  {{/if}}
</div>

<div class='dashboard-block-header'>
  {{t 'general.myCourses'}}
</div>

<div class='dashboard-block-body'>
  {{#if listOfCourses.isFulfilled}}
    {{#if sortedListOfCourses.length}}
      <table>
        <tbody>
          {{#each sortedListOfCourses as |course|}}
            {{#if (can 'edit courses')}}
              {{#link-to 'course' course}}
                <tr class='clickable'>
                  <td>{{fa-icon 'external-link-square'}}</td>
                  <td>{{course.academicYear}}</td>
                  <td colspan=2>{{course.title}}</td>
                </tr>
              {{/link-to}}
            {{else}}
              <tr>                
                <td colspan=1>{{course.academicYear}}</td>
                <td colspan=3>{{course.title}}</td>
              </tr>
            {{/if}}
          {{/each}}
        </tbody>
      </table>
    {{else}}
      {{t 'general.none'}}
    {{/if}}
  {{else}}
    <h1>{{fa-icon 'spinner' spin=true}}</h1>
  {{/if}}
</div>

Make links to dashboard courses permissions based
Make links to dashboard courses permissions based
