better urls for api stuff & fixed chart AR box position on mobile

This commit is contained in:
2016-04-01 15:01:18 +02:00
parent f4a702ed0d
commit 42f869de61
18 changed files with 42 additions and 49 deletions
+3 -3
View File
@@ -8,14 +8,14 @@ var page_status = (function() {
st.trigReset = function() {
var modal_sel = '#reset-modal';
$().get(_root + '/reset.cgi', function(resp, status) {
$().get(_root + '/system/reset', function(resp, status) {
if (status == 200) {
modal.show(modal_sel);
updateInhibited = true;
var ping_i = setInterval(function() {
$().get(_root+'/ping.cgi', function(resp, code){
$().get(_root+'/system/ping', function(resp, code){
if (code == 200) {
// device is ready
modal.hide(modal_sel);
@@ -77,7 +77,7 @@ var page_status = (function() {
}
function requestUpdate() {
$().get(_root+'/api/status.json', onUpdate);
$().get(_root+'/system/status', onUpdate);
}
st.init = function() {
+1 -1
View File
@@ -168,7 +168,7 @@ var page_waveform = (function () {
var n = $('#count').val();
var fs = $('#freq').val();
var url = _root+'/api/{fmt}.json?n={n}&fs={fs}'.format({
var url = _root+'/measure/{fmt}?n={n}&fs={fs}'.format({
fmt: dataFormat, // fft or raw
n: n,
fs: fs
+1 -1
View File
@@ -76,7 +76,7 @@ var page_wifi = (function () {
/** Ask the CGI what APs are visible (async) */
function scanAPs() {
$().get(_root+'/wifi/scan.cgi', onScan); // no cache, no jsonp
$().get(_root+'/wifi/scan', onScan); // no cache, no jsonp
}
function rescan(time) {