The start and end dates of the maintenance are now stored in UTC, which allows it to be converted between time zones

This commit is contained in:
Karel Krýda
2022-01-24 22:33:15 +01:00
parent 5fda1f0f59
commit e7b2832967
6 changed files with 33 additions and 34 deletions

View File

@@ -152,7 +152,7 @@
<!-- Incident Date -->
<div class="date mt-3">
{{ $t("End") }}: {{ $root.datetimeMaintenance(maintenanceItem.end_date) }} ({{ dateFromNowMaintenance(maintenanceItem.start_date) }})<br />
{{ $t("End") }}: {{ $root.datetimeMaintenance(maintenanceItem.end_date) }} ({{ dateFromNow(maintenanceItem.start_date) }})<br />
</div>
</div>
@@ -620,10 +620,6 @@ export default {
return dayjs.utc(date).fromNow();
},
dateFromNowMaintenance(date) {
return dayjs(date).fromNow();
},
}
};
</script>