2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-12 21:10:47 +08:00
discourse/app/assets/javascripts/discourse/templates/review-topics.hbs
Robin Ward b58867b6e9 FEATURE: New 'Reviewable' model to make reviewable items generic
Includes support for flags, reviewable users and queued posts, with REST API
backwards compatibility.

Co-Authored-By: romanrizzi <romanalejandro@gmail.com>
Co-Authored-By: jjaffeux <j.jaffeux@gmail.com>
2019-03-28 12:45:10 -04:00

45 lines
1.5 KiB
Handlebars

<div class="reviewable">
<ul class="nav nav-pills reviewable-title">
{{nav-item route='review.index' routeParam=(query-params topic_id=null) label='review.view_all'}}
{{nav-item route='review.topics' label='review.grouped_by_topic'}}
</ul>
{{#if reviewableTopics}}
<table class='reviewable-topics'>
<thead>
<th>{{i18n "review.topics.topic"}} </th>
<th>{{i18n "review.topics.reviewable_count"}}</th>
<th>{{i18n "review.topics.reported_by"}}</th>
<th></th>
</thead>
<tbody>
{{#each reviewableTopics as |rt|}}
<tr class='reviewable-topic'>
<td class="topic-title">
<div class='combined-title'>
{{topic-status topic=rt}}
<a href={{rt.relative_url}} target="_blank">{{replace-emoji rt.fancy_title}}</a>
</div>
</td>
<td class="reviewable-count">
{{rt.stats.count}}
</td>
<td class="reported-by">
{{i18n "review.topics.unique_users" count=rt.stats.unique_users}}
</td>
<td class="reviewable-details">
{{#link-to "review.index" (query-params topic_id=rt.id) class="btn btn-primary btn-small"}}
{{d-icon "list"}}
<span>{{i18n "review.topics.details"}}</span>
{{/link-to}}
</td>
</tr>
{{/each}}
</tbody>
</table>
{{else}}
<div class="no-review">
{{i18n "review.none"}}
</div>
{{/if}}
</div>