Skip to content
Snippets Groups Projects
Commit cdd27586 authored by Lucio Zambon's avatar Lucio Zambon
Browse files

Update bpm2d.js

parent f9c8d709
No related branches found
No related tags found
No related merge requests found
......@@ -63,6 +63,7 @@
}
}
function bpmSwitch(bpmData, params) {
console.log('bpmSwitch()',bpmData, params, params.bpm);
if (bpmData.reader !== false) clearInterval(bpmData.reader);
bpmData.reader = false;
if (params.bpm=='') {
......@@ -70,7 +71,10 @@
$('#applicationFrame').removeAttr("src");
}
else {
const bpms = 'sr,bts,preinjector'.split(','); // <<<<<<<<<<<<<<<<<<<<<<<<--------------------------------------------------
const bpms = [];
for (let i in bpmData) if (i!="reader") bpms.push(i);
console.log('bpms', bpms);
// const bpms = 'sr,bts,preinjector'.split(','); // <<<<<<<<<<<<<<<<<<<<<<<<--------------------------------------------------
for (let facility in bpmData) {
if (typeof bpmData[facility].map == 'undefined') continue;
bpmData.oldIndex = facility;
......@@ -114,7 +118,7 @@
fetch(conf.bpmUrl)
.then((response) => {return response.json();})
.then((eventData) => {
// console.log('bpmRead()', eventData);
console.log('bpmRead()', conf.bpmUrl, eventData);
for (let i in eventData) {
// console.log(i, eventData[i]);
bpmRender(i, eventData[i]);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment