Merge pull request #3552 from alchemy-fr/PHRAS-3148_thesaurus_Guy

PHRAS-3148 Merge fix populate from Thesaurus GUI
This commit is contained in:
Nicolas Maillat
2020-07-02 14:42:21 +02:00
committed by GitHub
2 changed files with 56 additions and 74 deletions

View File

@@ -33,23 +33,17 @@
<a href="javascript:void(0)" id="delete_sy">{{ 'thesaurus:properties:: Mettre dans le stock' | trans }}</a>
</div>
<div id="desktop" class="dialog">
<div class="menu" id="flagsMenu" style="z-index:999">
{% for code, language in languages %}
<a id='flagMenu_{{ code }}' href='javascript:void(0)' class=''>
<img src='/assets/common/images/lng/{{ code }}_flag_18.gif' />{{ language }}</a>
{% endfor %}
</div>
<div style='text-align:right'>
<H4>{{ fullpath | raw }}</H4>
<div style='float:right'>
<b>id:</b>&nbsp;{{ id }}
</div>
<H4>{{ fullpath | raw }}</H4><br/>
{% if typ == "CT" %}
<br/>
{% elseif typ == "TH" %}
{#{% elseif typ == "TH" %}
{% trans with {'%hits%' : hits} %}thesaurus:: %hits% reponses retournees{% endtrans %}
<br/>
<br/>
<br/>#}
{% endif %}
<div id="TSY" class="tableContainer" style="margin:10px; position:relative; top:0px; left:0px">
<div>
@@ -295,8 +289,8 @@
// td.setAttribute("colSpan", "3"); // attention au 'S' majuscule !!!
td.innerHTML = n.getAttribute("t");
td = tr.appendChild(document.createElement("td"));
td.innerHTML = n.getAttribute("hits");
/*td = tr.appendChild(document.createElement("td"));
td.innerHTML = n.getAttribute("hits");*/
td = tr.appendChild(document.createElement("td"));
td.innerHTML = n.getAttribute("id");
@@ -322,17 +316,6 @@
;
if(tr)
myGUI.select(tr);
/* switch(o.id.substr(0, 4))
{
case "FLG_": // le drapeau
document.getElementById("flagsMenu").runAsMenu( evt, tr );
break;
case "SYN_": // le synonyme
document.getElementById("syMenu").runAsMenu( evt, tr );
$('.delete_term').html('');
$('.delete_term', tr).append($('#syMenu').html());
break;
}*/
}
break;
case "MOUSEDOWN":

View File

@@ -169,10 +169,6 @@
<p><img id='flagMenu_{{ code }}' src='/assets/common/images/lng/{{ code }}_flag_18.gif' /> {{ language }}</p>
{% endfor %}
{# {% for code, language in flags %}
<a id='flagMenu_{{ code }}' href='javascript:void(0)' class=''>
<img src='/assets/common/images/lng/{{ code }}_flag_18.gif' />{{ language }}</a>
{% endfor %}#}
</div>
<div class="menu" id="kctermMenu" style="z-index:999; width:240px;">
<a href="javascript:void(0)" class="" id="kcterm_properties" style="font-weight:700">{{ 'thesaurus::menu: proprietes' | trans }}</a>
@@ -1525,8 +1521,9 @@
*/
$(document).ready(function () {
/**Populate btn action**/
$('#populate_btn').click(function (e) {
$('#populate_btn').bind('click', function (e) {
e.preventDefault();
$("#confirm_populate").dialog({
modal: true,
@@ -1547,7 +1544,8 @@
}
});
$("#confirm_populate").dialog('open');
$('#confirm_populate_button').click(function () {
$('#confirm_populate_button').unbind('click').bind('click', function (e) {
e.preventDefault();
$.ajax({
type: 'GET',
url: '/admin/worker-manager/populate-status',
@@ -1574,6 +1572,7 @@
});
})
});
})
</script>
</body>