mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-27 09:36:19 -05:00
50 lines
1.5 KiB
Handlebars
50 lines
1.5 KiB
Handlebars
<h3>{{model.title}}</h3>
|
|
|
|
<div class="admin-reports-filter">
|
|
{{i18n 'admin.dashboard.reports.start_date'}} {{date-picker-past value=startDate}}
|
|
{{i18n 'admin.dashboard.reports.end_date'}} {{date-picker-past value=endDate}}
|
|
{{#if showCategoryOptions}}
|
|
{{combo-box valueAttribute="value" content=categoryOptions value=categoryId}}
|
|
{{/if}}
|
|
{{#if showGroupOptions}}
|
|
{{combo-box valueAttribute="value" content=groupOptions value=groupId}}
|
|
{{/if}}
|
|
{{d-button action="refreshReport" class="btn-primary" label="admin.dashboard.reports.refresh_report" icon="refresh"}}
|
|
{{d-button action="exportCsv" label="admin.export_csv.button_text" icon="download"}}
|
|
</div>
|
|
|
|
<div class='view-options'>
|
|
{{#if viewingTable}}
|
|
{{i18n 'admin.dashboard.reports.view_table'}}
|
|
{{else}}
|
|
<a href {{action "viewAsTable"}}>{{i18n 'admin.dashboard.reports.view_table'}}</a>
|
|
{{/if}}
|
|
|
|
|
{{#if viewingGraph}}
|
|
{{i18n 'admin.dashboard.reports.view_graph'}}
|
|
{{else}}
|
|
<a href {{action "viewAsGraph"}}>{{i18n 'admin.dashboard.reports.view_graph'}}</a>
|
|
{{/if}}
|
|
</div>
|
|
|
|
{{#conditional-loading-spinner condition=refreshing}}
|
|
{{#if viewingGraph}}
|
|
{{admin-graph model=model}}
|
|
{{else}}
|
|
<table class='table report'>
|
|
<tr>
|
|
<th>{{model.xaxis}}</th>
|
|
<th>{{model.yaxis}}</th>
|
|
</tr>
|
|
|
|
{{#each model.dataReversed as |row|}}
|
|
<tr>
|
|
<td>{{row.x}}</td>
|
|
<td>
|
|
{{row.y}}
|
|
</td>
|
|
</tr>
|
|
{{/each}}
|
|
</table>
|
|
{{/if}}
|
|
{{/conditional-loading-spinner}}
|