Merge branch 'master' of
https://gitea-s2i2s.isti.cnr.it/concordia/LiDa_Search.git
This commit is contained in:
parent
b095d6a1d3
commit
b575051308
|
@ -10,6 +10,7 @@ var latestPhraseId = "";
|
||||||
var numeroPagine = 0;
|
var numeroPagine = 0;
|
||||||
var latestOffset = 0;
|
var latestOffset = 0;
|
||||||
var numberOfQueries = 0;
|
var numberOfQueries = 0;
|
||||||
|
var topClause = 1;
|
||||||
|
|
||||||
const cssCantoHeight = 0.65;
|
const cssCantoHeight = 0.65;
|
||||||
const cssTableMainHeight = 0.95; //.tableMain {height: 95%;}
|
const cssTableMainHeight = 0.95; //.tableMain {height: 95%;}
|
||||||
|
@ -341,20 +342,33 @@ $(document).ready(function() {
|
||||||
$('#cla-TabContent').on('click', '.removeCla', function() {
|
$('#cla-TabContent').on('click', '.removeCla', function() {
|
||||||
var claListItemId = $(this).closest('li').attr('id');
|
var claListItemId = $(this).closest('li').attr('id');
|
||||||
var claIdNum = claListItemId.substr(6);
|
var claIdNum = claListItemId.substr(6);
|
||||||
|
var condizioni;
|
||||||
|
var idCondizione;
|
||||||
|
if (claListLen == 1) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
claListLen--;
|
claListLen--;
|
||||||
numberOfQueries--;
|
numberOfQueries--;
|
||||||
var thisIs = $("#" + claListItemId);
|
var thisIs = $("#" + claListItemId);
|
||||||
if (claIdNum > 1) {
|
|
||||||
$("#" + claListItemId).fadeOut(300, function() {
|
$("#" + claListItemId).fadeOut(300, function() {
|
||||||
thisIs.remove();
|
thisIs.remove();
|
||||||
|
if (claIdNum == topClause){
|
||||||
|
condizioni = $(".condizioneAndOr")
|
||||||
|
idCondizione = condizioni[1].id;
|
||||||
|
topClause = idCondizione.substr(4);
|
||||||
|
$("#" + idCondizione).remove();
|
||||||
|
}else{
|
||||||
$("#cond" + claIdNum).remove();
|
$("#cond" + claIdNum).remove();
|
||||||
|
}
|
||||||
delete queryJson["Clausola" + claIdNum];
|
delete queryJson["Clausola" + claIdNum];
|
||||||
delete window["context" + claIdNum];
|
delete window["context" + claIdNum];
|
||||||
refreshClaList(claIdNum);
|
refreshClaList(claIdNum);
|
||||||
refreshSortables();
|
refreshSortables();
|
||||||
});
|
if (claIdNum == 1) {
|
||||||
|
$("#unitaRicerca").prop('disabled', false);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
});
|
||||||
|
|
||||||
// Evento: click sull'icona rimuovi condizione
|
// Evento: click sull'icona rimuovi condizione
|
||||||
$('#sortable0').on('click', '.removeCond', function() {
|
$('#sortable0').on('click', '.removeCond', function() {
|
||||||
|
@ -989,6 +1003,7 @@ $(document).ready(function() {
|
||||||
};
|
};
|
||||||
var boolCond = $('<span />')
|
var boolCond = $('<span />')
|
||||||
boolCond.attr('id','cond'+tabID);
|
boolCond.attr('id','cond'+tabID);
|
||||||
|
boolCond.addClass("condizioneAndOr")
|
||||||
switch (cond){
|
switch (cond){
|
||||||
case 1: boolCond.append("AND");
|
case 1: boolCond.append("AND");
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue