overwrite

This commit is contained in:
cesare 2022-10-10 13:12:29 +02:00
parent 3a4bcb3575
commit b931517565
1 changed files with 16 additions and 1 deletions

View File

@ -856,6 +856,7 @@ $(document).ready(function() {
$("#sparqlquery").val(logicExprString); $("#sparqlquery").val(logicExprString);
queryJson.EsprLogica = logicExprString.split(' '); queryJson.EsprLogica = logicExprString.split(' ');
queryJson.LogicaGui = guiLogicString.split(' '); queryJson.LogicaGui = guiLogicString.split(' ');
console.log(queryJson.LogicaGui);
}; };
// Funzione di refresh dei collegamenti tra elementi sortable // Funzione di refresh dei collegamenti tra elementi sortable
@ -996,7 +997,7 @@ $(document).ready(function() {
$("#cla" + tabID + " .catgram").val(selectedValue); $("#cla" + tabID + " .catgram").val(selectedValue);
addCatgramSubcla("cla" + tabID,selectedValue); addCatgramSubcla("cla" + tabID,selectedValue);
var ks = Object.keys(queryJson["Clausola" + i]); var ks = Object.keys(queryJson["Clausola" + i]);
for (var j = 5; j < ks.length; j++) { /* for (var j = 5; j < ks.length; j++) {
switch ($("#cla" + i + ks[j])[0].type) { switch ($("#cla" + i + ks[j])[0].type) {
case "fieldset": case "fieldset":
var sval = queryJson["Clausola" + i][ks[j]] var sval = queryJson["Clausola" + i][ks[j]]
@ -1008,6 +1009,20 @@ $(document).ready(function() {
break; break;
default: default:
}; };
}; */
for (var j = 5; j < ks.length; j++) {
var test="cla" + i + ks[j];
var melement = document.getElementById(test);
switch (melement.type) {
case "fieldset":
var sval = queryJson["Clausola" + i][ks[j]]
$("#cla" + tabID + sval.replace(/\s/g, '')).attr("checked",true);
break;
case "select-one":
melement.value=([queryJson["Clausola" + i][ks[j]]])
break;
default:
};
}; };
}; };
break; break;