From e1bc50d8b3d25314b590764501a2c66b577130b5 Mon Sep 17 00:00:00 2001 From: Piero Toffanin Date: Thu, 3 Oct 2019 21:56:01 -0400 Subject: [PATCH] UI simplification, support for true default bools --- public/index.html | 24 ++++++++++++++---------- public/js/main.js | 13 +++++++++++-- 2 files changed, 25 insertions(+), 12 deletions(-) diff --git a/public/index.html b/public/index.html index e92e202..0eb3f44 100644 --- a/public/index.html +++ b/public/index.html @@ -4,7 +4,7 @@ - NodeODM + NodeODM - Web UI @@ -39,7 +39,7 @@ @@ -49,9 +49,6 @@
-
-
Images and GCP File (optional):
Selected files:
@@ -89,9 +86,17 @@
+
- -
-
-

This software is released under the terms of the GPLv3 License. See NodeODM on Github for more information.

+
+ This window can be closed after uploading a task. The process will continue running on the server.
@@ -204,7 +208,7 @@ - + diff --git a/public/js/main.js b/public/js/main.js index cd228d3..9801987 100644 --- a/public/js/main.js +++ b/public/js/main.js @@ -480,14 +480,23 @@ $(function() { $('#resetDoPostProcessing').on('click', function(){ $("#doPostProcessing").prop('checked', false); }); + $('#resetTaskName').on('click', function(){ + $("#taskName").val(''); + }); // Load options function Option(properties) { this.properties = properties; - this.value = ko.observable(); + + this.defaultValue = undefined; + if (properties.type === 'bool' && properties.value === 'true'){ + this.defaultValue = true; + } + + this.value = ko.observable(this.defaultValue); } Option.prototype.resetToDefault = function() { - this.value(undefined); + this.value(this.defaultValue); }; function OptionsModel() {