FIX: Relative links in translations should work with subfolder

This commit is contained in:
Gerhard Schlager
2018-11-07 17:59:42 +01:00
parent 5c845c5877
commit 24e5be3f0c
32 changed files with 217 additions and 116 deletions
@@ -41,7 +41,7 @@ export default Ember.Component.extend({
classNameBindings: ["isEnabled", "isLoading", "dasherizedDataSourceName"],
classNames: ["admin-report"],
isEnabled: true,
disabledLabel: "admin.dashboard.disabled",
disabledLabel: I18n.t("admin.dashboard.disabled"),
isLoading: false,
rateLimitationString: null,
dataSourceName: null,
@@ -22,6 +22,7 @@ export default Ember.Controller.extend(PeriodComputationMixin, {
"model.attributes.last_backup_taken_at"
),
shouldDisplayDurability: Ember.computed.and("diskSpace"),
basePath: Discourse.BaseUri,
@computed
activityMetrics() {
@@ -77,6 +78,13 @@ export default Ember.Controller.extend(PeriodComputationMixin, {
};
},
@computed
trendingSearchDisabledLabel() {
return I18n.t("admin.dashboard.reports.trending_search.disabled", {
basePath: Discourse.BaseUri
});
},
usersByTypeReport: staticReport("users_by_type"),
usersByTrustLevelReport: staticReport("users_by_trust_level"),
@@ -192,6 +192,6 @@
{{/conditional-loading-section}}
{{else}}
<div class="alert alert-info">
{{{i18n disabledLabel}}}
{{{disabledLabel}}}
</div>
{{/if}}
@@ -161,8 +161,8 @@
reportOptions=trendingSearchOptions
filters=trendingSearchFilters
isEnabled=logSearchQueriesEnabled
disabledLabel="admin.dashboard.reports.trending_search.disabled"}}
{{{i18n "admin.dashboard.reports.trending_search.more"}}}
disabledLabel=trendingSearchDisabledLabel}}
{{{i18n "admin.dashboard.reports.trending_search.more" basePath=basePath}}}
</div>
</div>