Synchronize units on control and settings pages.
This commit is contained in:
@@ -417,6 +417,7 @@ module.exports = new Vue({
|
|||||||
delete settings.tool["tool-type"];
|
delete settings.tool["tool-type"];
|
||||||
|
|
||||||
this.config["selected-tool-settings"][selected_tool] = settings;
|
this.config["selected-tool-settings"][selected_tool] = settings;
|
||||||
|
this.display_units = this.config.settings["units"];
|
||||||
|
|
||||||
try {
|
try {
|
||||||
await api.put("config/save", this.config);
|
await api.put("config/save", this.config);
|
||||||
|
|||||||
@@ -91,7 +91,9 @@ module.exports = {
|
|||||||
return this.$root.display_units;
|
return this.$root.display_units;
|
||||||
},
|
},
|
||||||
set: function(value) {
|
set: function(value) {
|
||||||
|
this.config.settings.units = value;
|
||||||
this.$root.display_units = value;
|
this.$root.display_units = value;
|
||||||
|
this.$dispatch("config-changed");
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user