rework of the server side
main change: the same server may be used for several instruments - client classes are 'Interactors' dealing with the parameters etc. - methods from history are added to the clients + improvements on the js client side
This commit is contained in:
@ -490,7 +490,7 @@ let graphs = (function (){
|
||||
if(idx != -1){ //if the clicked block is displayed somewhere, we create a selection window
|
||||
createSelection(idx); // We will create a selection at the gindex
|
||||
}
|
||||
}
|
||||
}
|
||||
createGraph(gindex, block); // we create at the current shown selector (gindex), the graph corresponding to the one clicked (block)
|
||||
})
|
||||
selection.appendChild(bel);
|
||||
@ -547,7 +547,7 @@ let graphs = (function (){
|
||||
+ "&variables=" + varlist
|
||||
+ "&interval=" + resolution
|
||||
+ "&id=" + clientID).getJSON().then(function(data){
|
||||
//console.log('Graph', block, data)
|
||||
// console.log('Graph', block, data);
|
||||
let graph = new Graph(gindex, graph_elm, "Time", block.unit, block.tag, type);
|
||||
graph_array[gindex] = graph;
|
||||
|
||||
@ -559,7 +559,6 @@ let graphs = (function (){
|
||||
for(let e of data.graph[key]){
|
||||
pdata.push({x: e[0]*1000, y: e[1]});
|
||||
}
|
||||
|
||||
addDataset(gindex, key, pdata, dict[key])
|
||||
// if(pdata.length > 0){
|
||||
// addDataset(gindex, key, pdata, dict[key])
|
||||
@ -919,7 +918,6 @@ let graphs = (function (){
|
||||
|
||||
AJAX("http://" + hostPort + "/getvars").postForm(
|
||||
"time=" + msRightTimestampGetVars/1000
|
||||
+ window['clientTags']
|
||||
+ "&userconfiguration=" + JSON.stringify(getFormattedUserConfigurationFromLocalStorage())
|
||||
+ "&id="+ clientID).then(function(data){
|
||||
blocks = data.blocks;
|
||||
@ -998,7 +996,6 @@ let graphs = (function (){
|
||||
AJAX("http://" + hostPort + "/getvars").postForm(
|
||||
"time=" + msRightTimestamp/1000 + "&userconfiguration="
|
||||
+ JSON.stringify(getFormattedUserConfigurationFromLocalStorage())
|
||||
+ window['clientTags']
|
||||
+ "&id="+ clientID).then(function(data){
|
||||
currentMaxTime = msRightTimestamp + 60000;
|
||||
currentMinTime = msLeftTimestamp;
|
||||
@ -1304,7 +1301,6 @@ let graphs = (function (){
|
||||
AJAX("http://" + hostPort + "/getvars").postForm(
|
||||
"time=" + currentMaxTime/1000
|
||||
+ "&userconfiguration=" + JSON.stringify(userConfiguration)
|
||||
+ window['clientTags']
|
||||
+ "&id="+ clientID).then(function(data){
|
||||
blocks = data.blocks;
|
||||
document.getElementById("device").innerHTML = data.device
|
||||
|
Reference in New Issue
Block a user