aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/webui/static
Commit message (Collapse)AuthorAgeFilesLines
* webui: Replace jQuery.when() with jQuery.Deferred's .then()Aaron LI2016-11-241-5/+5
| | | | | | | | | | Note that jQuery.when() can NOT promise the ordering of the passed Deferred's. Therefore, chain multiple AJAX requests using ".then()" and ".done()" to keep them ordered. This fixes the configurations loading problem on IE (v11), which calls the "when()" arguments in different orders as Firefox and Chromium, thus leads to the wrong results.
* webui: Use new ".getJSONUncached()" instead of ".getJSON()"Aaron LI2016-11-243-7/+7
|
* webui: Extend jQuery with "getJSONUncached()"Aaron LI2016-11-241-6/+27
| | | | | | | | | | This jQuery extension sent the AJAX GET request but force the requested page NOT to be cached by the browser! NOTE: IE will by default cache the GET request even the contents has changed. Credit: https://stackoverflow.com/a/35130770/4856091
* webui: Update modal box stylesAaron LI2016-11-242-28/+43
|
* webui: configs.js: Trigger "Enter keypress" event after field updatedAaron LI2016-11-241-6/+9
| | | | | | | | When the value of a configuration field is updated by jQuery ".val()", trigger the "Enter keypress" event to update its related contents, e.g., the resolution note for "common/nside". Remove the wrong "Enter keypress" event triggering on page loading.
* webui: products.js: Support download healpix/hpx productsAaron LI2016-11-241-6/+25
|
* webui: main.js: Prevent form submitting on "Enter" pressAaron LI2016-11-241-0/+9
|
* webui: configs.html: Improve the form layout and stylesAaron LI2016-11-231-1/+7
|
* webui: main.css: Hide the spinner in "number" inputAaron LI2016-11-231-0/+13
| | | | | | Tested on both Firefox (v45.4) and Chromium (v53.0). Credit: https://stackoverflow.com/a/23374725/4856091
* webui: products: Add the client-side support for opening HPX imagesAaron LI2016-11-231-11/+68
|
* webui: configs.js: Trigger "Enter" after page load on "common/nside"Aaron LI2016-11-231-14/+15
| | | | | Refactor the "click" event handler on "common/nside" to avoid the duplicated code on resolution calculation.
* webui: products: Implement GET action "which"Aaron LI2016-11-231-1/+20
| | | | | | | | The "which" GET action try to locate the given executable name/path, in order to check whether the executable callable. This function will be used to check the validity of the specified FITS viewer, which opens the HPX FITS images.
* webui: products: Implement HPX conversion functionAaron LI2016-11-222-16/+45
|
* webui: products.js: Convert file size from bytes to MBAaron LI2016-11-221-4/+5
|
* webui: main.js: Add new styles for "products.html"Aaron LI2016-11-221-1/+19
| | | | Also update the ".btn" rule and add the ".btn.btn-small" rule
* webui: products: Implement client-side AJAX interactionsAaron LI2016-11-221-0/+289
|
* webui: Update against the improved "showModal()"Aaron LI2016-11-222-16/+16
|
* webui: main.js: Extend "showModal()" with "title" and "contents"Aaron LI2016-11-221-4/+15
| | | | | * Change original "message" attribute to "title" * Add new attribute "contents" which allow multiple paragraphs
* webui: Move several generic functions from "configs.js" to "main.js"Aaron LI2016-11-222-47/+47
|
* webui: configs: Some minor fixesAaron LI2016-11-221-6/+11
| | | | | | | | * configs.py/_set_configs(): Also return the original data if the input values failed the validation; * setServerConfigs(): Success callback also reset value if the input value failed pass the server-side validation; * getServerConfigs(): Return "undefined" if key does not exists.
* webui: websocket.py: Also push current task status when connectedAaron LI2016-11-211-0/+2
|
* webui: configs: Add pixel resolution note for "common/nside"Aaron LI2016-11-191-0/+24
| | | | | | * Calculate pixel resolution note on pressing "Enter" in "common/nside" * Update the pixel resolution note as well as "common/lmax" when "common/nside" changed.
* webui: Rename "Results" to "Products"Aaron LI2016-11-191-1/+1
|
* webui: Remove jQuery version from its filenameAaron LI2016-11-181-0/+0
|
* webui: configs.js: Fix two bugsAaron LI2016-11-181-2/+2
| | | | | * Fix the wrong "action=reset" in "setServerConfigs()" * Add the missing "return" in the jQuery AJAX chain
* webui: Rename jQuery ".fail()" callback argument "error" to "jqxhr"Aaron LI2016-11-182-21/+21
|
* webui: console.js: Disable the "Start" button when task startedAaron LI2016-11-181-0/+7
|
* webui: main.js: Extend jQuery with ".disable()"Aaron LI2016-11-181-1/+16
|
* webui: Redirect to login page if not authenticated on POST requestAaron LI2016-11-181-5/+13
| | | | | | * Remove the authentication requirement on GET operation * "main.js": Redirect to the login page if POST response 403 forbidden * "main.js": Use global AJAX events handling instead of `$.ajaxSetup()`
* webui: Fix a bug for "showModal()"; Cleanup ".onmessage()"Aaron LI2016-11-172-16/+6
|
* configs: Update logging message formatAaron LI2016-11-171-2/+8
| | | | | * Also update the logging messages styles for the Web UI * Show a modal notification when the task finished.
* webui: console.js: Change to use AJAX instead of WebSocket messagesAaron LI2016-11-172-42/+65
| | | | Also support modal dialog for confirmation and operation results.
* webui: Support IE11; Fix a missing quotation.Aaron LI2016-11-171-2/+7
| | | | | | | * 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"
* webui: login: Submit login form on "Enter" keyAaron LI2016-11-171-0/+23
|
* webui: console.html: Remove extra modal "#console-invalid-configs"Aaron LI2016-11-172-40/+58
| | | | | * Implement "showModalConsole()" based on "showModal()" * Move binding function from "websocket.js" to "console.js"
* webui: configs.js: Rename "showConfigsModal" to "showModalConfigs()"Aaron LI2016-11-171-11/+11
|
* webui: Implement "showModal()" in "main.js" allowing use in othersAaron LI2016-11-172-43/+57
|
* webui: main.js: Refactor out the function "toggleBlock()"Aaron LI2016-11-171-22/+20
|
* webui: Support toggle the body/contents of sectionsAaron LI2016-11-172-3/+38
| | | | | | The section header has class "heading" and a toggle control with class "toggle", which will toggle the display of the next block with the "body" class.
* webui: Add panel toggle and allow expand/collapse its bodyAaron LI2016-11-172-1/+30
|
* webui: configs.js: Confirm before reset the configurationsAaron LI2016-11-171-2/+20
|
* webui: configs.js: Confirm before overwrite the configuration fileAaron LI2016-11-171-18/+74
| | | | Also improve the "showConfigsModal()" to support buttons.
* webui: configs.js: Re-implement using AJAX instead of WebSocketAaron LI2016-11-162-92/+221
| | | | | | | | | | * Interact with server-side configurations using AJAX GET and POST, instead of sending and receiving messages through the WebSocket. * Add callbacks on both AJAX success and error, to show a modal box displaying the operation results/errors, achieving better user experiences. * Use jQuery deferred and promises to achieve sequential operations. * Also move the binding function from "websocket.js" to "configs.js"
* webui: main.js: Add "getCookie()" and "jQuery.postJSON()" functionsAaron LI2016-11-161-0/+56
| | | | | | | | * Add function "getCookie()": get the value of the specified key from the cookies; * Add jQuery extension ".postJSON()": wrapper for easier AJAX post, with the XSRF header and correct content type; * Also set the default "error" handle function for AJAX request.
* webui: Rename "scroll_target()" to "scrollTarget()" and export itAaron LI2016-11-161-17/+16
|
* webui: Some minor changesAaron LI2016-11-152-3/+3
| | | | | | | * Change configuration status text from "Valid :)" to "OK" * Reduce maximum WS connection trials from 100 to 21 * Fix the wrong global name of "g_ws_reconnect" * Comment the Console "Stop" button, which is currently not implemented
* webui: Change log toggle icons opacity according to toggle statusAaron LI2016-11-152-4/+10
|
* webui: Fix the wrong value "galactic/freefree" to "galactic/snr"Aaron LI2016-11-151-1/+2
| | | | configs.js: Update "workdir" and "configfile" to be sync with server.
* webui: Show a modal box indicating there are invalid configsAaron LI2016-11-132-6/+4
|
* webui: Import "jQuery Modal" v0.8.0Aaron LI2016-11-132-0/+317
| | | | | | Thanks: http://jquerymodal.com/ https://github.com/kylefox/jquery-modal