mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
fixes https://github.com/grafana/grafana/issues/8840 by setting a default locale. Also uses fromNow(true) to work arround the replace.
This commit is contained in:
parent
a045f175b6
commit
c5f6cf0809
@ -125,7 +125,7 @@ class AlertListPanel extends PanelCtrl {
|
|||||||
.then(res => {
|
.then(res => {
|
||||||
this.currentAlerts = this.sortResult(_.map(res, al => {
|
this.currentAlerts = this.sortResult(_.map(res, al => {
|
||||||
al.stateModel = alertDef.getStateDisplayModel(al.state);
|
al.stateModel = alertDef.getStateDisplayModel(al.state);
|
||||||
al.newStateDateAgo = moment(al.newStateDate).fromNow().replace(" ago", "");
|
al.newStateDateAgo = moment(al.newStateDate).locale('en').fromNow(true);
|
||||||
return al;
|
return al;
|
||||||
}));
|
}));
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user