cms/app-client/app/templates/components/notice-component.hbs
author ymh <ymh.work@gmail.com>
Sun, 27 Nov 2016 15:12:30 +0100
changeset 447 38d5789e30d0
parent 445 b1e5ad6b2a29
child 488 0161e028afb7
permissions -rw-r--r--
Improce notice data display, correct m3.23

<h2>{{ item.title }}</h2>
<h5><a href={{abs-url-for "document" item.id}} class="notice-permalink" target="_blank">permalien</a></h5>
<table>
  <tr>
    <td class="title">Editeur{{#if (if-operator item.publishers.length '>' 1)}}s{{/if}}</td>
    <td>
      <ul>
        {{#each item.publishers as |publisher|}}
        <li>{{ publisher }}</li>
        {{/each}}
      </ul>
    </td>
  </tr>
  <tr>
    <td class="title">Langue</td>
    <td>{{#each item.languages as |lang index|}}{{if index ", "}}{{ component (getLinkType lang) url=lang class="language" onClick=(action 'addLanguageFilter' lang)}}{{/each}}</td>
  </tr>
  <tr>
    <td class="title">Sujet{{#if (if-operator item.computedSubjects.length '>' 1)}}s{{/if}}</td>
    <td>
      <ul>
        {{#each item.subjects as |subject|}}
        <li>
          {{component (getLinkType subject) url=subject onClick=(action "addThemeFilter" subject)}}
        </li>
        {{/each}}
      </ul>
    </td>
  </tr>
  <tr>
    <td class="title">Enregistré en</td>
    <td>{{ doc-created value=item.created }}</td>
  </tr>
  <tr>
    <td class="title">Participant{{#if (if-operator participants.length '>' 1)}}s{{/if}}</td>
    <td>
      <ul>
        {{#each participants as |participant|}}
        <li>{{component (getLinkType participant.identifier) url=participant.identifier }} ({{#each participant.role as |r index| }}{{if index ", "}}{{r}}{{/each}})</li>
        {{/each}}
      </ul>
    </td>
  </tr>
  <tr>
    <td class="title">Lieu</td>
    <td>{{ notice-location-component geoInfo=item.geoInfo }}</td>
  </tr>
  <tr>
    <td class="title">Durée</td>
    <td>{{to-minutes item.duration}}</td>
  </tr>
</table>