diff options
author | Aaron LI <aaronly.me@outlook.com> | 2016-11-17 18:58:27 +0800 |
---|---|---|
committer | Aaron LI <aaronly.me@outlook.com> | 2016-11-17 18:58:27 +0800 |
commit | 4967e163f4ae6b1d679e14821096f2617c954c8e (patch) | |
tree | 19e9639af638d18a175c0046286ffdd51d4bb0ef /fg21sim/webui | |
parent | 627f3164d8826609e9e6819e02d0b450db1239cd (diff) | |
download | fg21sim-4967e163f4ae6b1d679e14821096f2617c954c8e.tar.bz2 |
webui: Support IE11; Fix a missing quotation.
* IE11 does NOT support most of the ECMAScript 6 features, such as the
"computed property names" which used in "configs.js".
* Do not use the "computed property names" feature to support IE11
* Fix a missing quotation in "index.html"
Diffstat (limited to 'fg21sim/webui')
-rw-r--r-- | fg21sim/webui/static/js/configs.js | 9 | ||||
-rw-r--r-- | fg21sim/webui/templates/index.html | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/fg21sim/webui/static/js/configs.js b/fg21sim/webui/static/js/configs.js index 87919e2..ed1e177 100644 --- a/fg21sim/webui/static/js/configs.js +++ b/fg21sim/webui/static/js/configs.js @@ -587,8 +587,13 @@ $(document).ready(function () { var name = $(e.target).attr("name"); var value = getFormConfigSingle(name); // Synchronize the changed form configuration to the server - // NOTE: Use the "computed property names" available in ECMAScript 6 - setServerConfigs(ajax_url, {[name]: value}) + // NOTE: + // Use the "computed property names" available in ECMAScript 6 + // (IE 11 not support this!) + // var data = {[name]: value}; + var data = {}; + data[name] = value; + setServerConfigs(ajax_url, data) .then(function () { validateServerConfigs(ajax_url); }) .done(function () { updateFormConfigStatus(); }); }); diff --git a/fg21sim/webui/templates/index.html b/fg21sim/webui/templates/index.html index 9e47472..27fac3d 100644 --- a/fg21sim/webui/templates/index.html +++ b/fg21sim/webui/templates/index.html @@ -17,7 +17,7 @@ <ul class="navigation-list float-right"> <li class="navigation-item"><a class="navigation-link button button-outline" href="#configs" title="Configurations"><span class="fa fa-wrench" aria-hidden="true"></span> Configurations</a></li> <li class="navigation-item"><a class="navigation-link button button-outline" href="#console" title="Console"><span class="fa fa-gamepad" aria-hidden="true"></span> Console</a></li> - <li class="navigation-item"><a class="navigation-link button button-outline" href="#results" title="Results"><span class="fa fa-files-o aria-hidden="true"></span> Results</a></li> + <li class="navigation-item"><a class="navigation-link button button-outline" href="#results" title="Results"><span class="fa fa-files-o" aria-hidden="true"></span> Results</a></li> </ul> {% end %} {# block header_contents #} |