Set time and time zone

This commit is contained in:
David Carley
2022-07-21 20:53:57 -07:00
parent 46d26deb8e
commit 3f3b609de6
16 changed files with 1303 additions and 141 deletions

View File

@@ -9,6 +9,7 @@ module.exports = {
data: function () {
return {
current_time: "",
mach_units: this.$root.state.metric ? "METRIC" : "IMPERIAL",
mdi: '',
last_file: undefined,
@@ -253,6 +254,10 @@ module.exports = {
ready: function () {
this.load();
setInterval(() => {
this.current_time = new Date().toLocaleTimeString();
}, 1000);
SvelteComponents.registerControllerMethods({
stop: (...args) => this.stop(...args),
send: (...args) => this.send(...args),
@@ -527,6 +532,10 @@ module.exports = {
showProbeDialog: function (probeType) {
SvelteComponents.showDialog("Probe", { probeType });
},
showSetTimeDialog: function () {
SvelteComponents.showDialog("SetTime");
}
},