UX: remove ? from new dashboard

Link to actual report
This commit is contained in:
Sam 2018-05-14 11:33:36 +10:00
parent 9d97e1244e
commit 5f54b005a1
3 changed files with 12 additions and 7 deletions

View File

@ -1,13 +1,17 @@
import { ajax } from 'discourse/lib/ajax';
import round from "discourse/lib/round";
import { fmt } from 'discourse/lib/computed';
import { fillMissingDates } from 'discourse/lib/utilities';
import computed from 'ember-addons/ember-computed-decorators';
const Report = Discourse.Model.extend({
average: false,
reportUrl: fmt("type", "/admin/reports/%@"),
@computed("type", "start_date", "end_date")
reportUrl(type, start_date, end_date) {
start_date = moment(start_date).format("YYYY-MM-DD");
end_date = moment(end_date).format("YYYY-MM-DD");
return Discourse.getURL(`/admin/reports/${type}?start_date=${start_date}&end_date=${end_date}`);
},
valueAt(numDaysAgo) {
if (this.data) {

View File

@ -1,11 +1,9 @@
{{#conditional-loading-section isLoading=isLoading title=report.title}}
<div class="chart-title">
<h3 title={{report.description}}>
<a href="{{report.reportUrl}}">
{{report.title}}
{{#if report.description}}
{{d-icon "question-circle"}}
{{/if}}
</a>
</h3>
<div class="chart-trend {{trend}}">

View File

@ -182,6 +182,9 @@
h3 {
margin: 1em 0;
a, a:visited {
color: $primary;
}
}
}