mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 09:53:15 +00:00
Merge branch 'master' into PHRAS-3157_prod_video_tools
This commit is contained in:
@@ -52,9 +52,9 @@
|
||||
{{ 'thesaurus:: selectionner la provenance a accepter' | trans }}
|
||||
{% endif %}
|
||||
<br/>
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" >
|
||||
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" style="width:100px;">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</form>
|
||||
</div>
|
||||
{% else %}
|
||||
@@ -70,9 +70,9 @@
|
||||
{{ prop_label }}
|
||||
<br/>
|
||||
<form class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" >
|
||||
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" style="width:100px;">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" >
|
||||
</form>
|
||||
{% endif %}
|
||||
</body>
|
||||
|
@@ -30,26 +30,20 @@
|
||||
});
|
||||
</script>
|
||||
<div class="menu" id="syMenu" style="z-index:999">
|
||||
<a href="javascript:void(0)" id="delete_sy">{{ 'thesaurus::menu: supprimer' | trans }}</a>
|
||||
<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> {{ 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>
|
||||
@@ -238,6 +232,15 @@
|
||||
break;
|
||||
}
|
||||
}
|
||||
var new_url = $('#url_properties').val();
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: `${new_url}`,
|
||||
success: function(data){
|
||||
$('#DLG_PROPERTIES').html('');
|
||||
$('#DLG_PROPERTIES').append(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -286,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");
|
||||
@@ -313,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":
|
||||
@@ -342,6 +334,21 @@
|
||||
syChgPos(-1);
|
||||
break;
|
||||
}
|
||||
|
||||
switch(o.id.substr(0, 4))
|
||||
{
|
||||
case "FLG_": // le drapeau
|
||||
document.getElementById("flagsMenu").runAsMenu( evt, tr );
|
||||
break;
|
||||
case "SYN_": // le synonyme
|
||||
if (stock == false)
|
||||
{
|
||||
document.getElementById("syMenu").runAsMenu(evt, tr);
|
||||
$('.delete_term').html('');
|
||||
$('.delete_term', tr).append($('#syMenu').html());
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "DBLCLICK":
|
||||
|
@@ -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>
|
||||
@@ -343,7 +339,7 @@
|
||||
<br/>
|
||||
|
||||
</form>
|
||||
|
||||
<input type="hidden" id="url_properties">
|
||||
<div id="clipboard" style="position:absolute; top:0px; left:0px; z-index:99"> </div>
|
||||
|
||||
|
||||
@@ -355,6 +351,7 @@
|
||||
|
||||
//Ajax function to get data
|
||||
var title = '';
|
||||
var stock = false;
|
||||
function loadDataAjax(urls, width, height, bloc, title) {
|
||||
$(bloc).dialog({
|
||||
title: title,
|
||||
@@ -643,9 +640,11 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=CT";
|
||||
|
||||
$('#url_properties').val(url);
|
||||
stock = true;
|
||||
// w = window.open(url, "PROPERTIES", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 500 , 340, '#DLG_PROPERTIES','{{ 'thesaurus:dialog:: properties' | trans }}');
|
||||
|
||||
break;
|
||||
case "kcterm_search":
|
||||
$("#SEARCH_DLG").dialog("option", "buttons",
|
||||
@@ -754,7 +753,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=CT";
|
||||
|
||||
$('#url_properties').val(url);
|
||||
stock = false;
|
||||
//w = window.open(url, "PROPERTIES", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 500 , 340,'#DLG_PROPERTIES', '{{ 'thesaurus:: Proprietes' | trans }}');
|
||||
}
|
||||
@@ -1083,7 +1083,7 @@
|
||||
url += "&sylng=" + encodeURIComponent(lng);
|
||||
|
||||
// w = window.open(url, "NEWTERM", "directories=no, height=290, width=490, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
w = loadDataAjax(url,490, 290,"#NEWSY_DLG_CONFIRM",'{% if typ == "TS" %}{{ 'thesaurus:: Nouveau terme specifique' | trans }}{% else %}{{ 'thesaurus:: Nouveau synonyme' | trans }}{% endif %}');
|
||||
w = loadDataAjax(url,490, 350,"#NEWSY_DLG_CONFIRM",'{% if typ == "TS" %}{{ 'thesaurus:: Nouveau terme specifique' | trans }}{% else %}{{ 'thesaurus:: Nouveau synonyme' | trans }}{% endif %}');
|
||||
}
|
||||
}
|
||||
],
|
||||
@@ -1149,7 +1149,7 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&tid=" + o.id.substr(4);
|
||||
// w = window.open(url, "LINK", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url,700, 400, "#DLG_LINK_FIELD_1", '{{ 'thesaurus:: Lier la branche de thesaurus au champ' | trans }}');
|
||||
w = loadDataAjax(url,700, 430, "#DLG_LINK_FIELD_1", '{{ 'thesaurus:: Lier la branche de thesaurus au champ' | trans }}');
|
||||
break;
|
||||
case "kterm_properties":
|
||||
var myObj = { "win":window };
|
||||
@@ -1158,7 +1158,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=TH";
|
||||
|
||||
$('#url_properties').val(url);
|
||||
stock = false;
|
||||
// w = window.open(url, "PROPERTIES", "directories=no, height=300, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url,700, 400, "#DLG_PROPERTIES", '{{ 'thesaurus:: Proprietes' | trans }}');
|
||||
|
||||
@@ -1520,55 +1521,58 @@
|
||||
*/
|
||||
|
||||
|
||||
/**Populate btn action**/
|
||||
$('#populate_btn').click(function (e) {
|
||||
e.preventDefault();
|
||||
$("#confirm_populate").dialog({
|
||||
modal: true,
|
||||
title: "{{ 'thesaurus: Populate title' | trans }}",
|
||||
autoOpen:false,
|
||||
width: 400,
|
||||
open:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
$('.cancel_button').click(function () {
|
||||
$('.close-dialog').trigger('click');
|
||||
});
|
||||
$('#CTERMS').find('.OB').addClass('ob').removeClass('OB');
|
||||
$('#THP_C').html('+');
|
||||
$(document).ready(function () {
|
||||
/**Populate btn action**/
|
||||
$('#populate_btn').bind('click', function (e) {
|
||||
e.preventDefault();
|
||||
$("#confirm_populate").dialog({
|
||||
modal: true,
|
||||
title: "{{ 'thesaurus: Populate title' | trans }}",
|
||||
autoOpen:false,
|
||||
width: 400,
|
||||
open:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
$('.cancel_button').click(function () {
|
||||
$('.close-dialog').trigger('click');
|
||||
});
|
||||
$('#CTERMS').find('.OB').addClass('ob').removeClass('OB');
|
||||
$('#THP_C').html('+');
|
||||
|
||||
|
||||
}
|
||||
});
|
||||
$("#confirm_populate").dialog('open');
|
||||
$('#confirm_populate_button').click(function () {
|
||||
$.ajax({
|
||||
type: 'GET',
|
||||
url: '/admin/worker-manager/populate-status',
|
||||
data: {
|
||||
sbasIds: [{{ bid }}]
|
||||
},
|
||||
success: function (data) {
|
||||
if (data == 0) {
|
||||
$.ajax({
|
||||
url: '/thesaurus/populate',
|
||||
type: 'POST',
|
||||
data: {
|
||||
databox_id: {{ bid }}
|
||||
},
|
||||
success: function (data) {
|
||||
//humane.info('{{ "thesaurus::populate: success message" |trans }}');
|
||||
$('.close-dialog').trigger('click');
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('{{ "thesaurus::populate: Warning populate is in process to indexing databox" |trans }}');
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
});
|
||||
}
|
||||
});
|
||||
$("#confirm_populate").dialog('open');
|
||||
$('#confirm_populate_button').unbind('click').bind('click', function (e) {
|
||||
e.preventDefault();
|
||||
$.ajax({
|
||||
type: 'GET',
|
||||
url: '/admin/worker-manager/populate-status',
|
||||
data: {
|
||||
sbasIds: [{{ bid }}]
|
||||
},
|
||||
success: function (data) {
|
||||
if (data == 0) {
|
||||
$.ajax({
|
||||
url: '/thesaurus/populate',
|
||||
type: 'POST',
|
||||
data: {
|
||||
databox_id: {{ bid }}
|
||||
},
|
||||
success: function (data) {
|
||||
//humane.info('{{ "thesaurus::populate: success message" |trans }}');
|
||||
$('.close-dialog').trigger('click');
|
||||
}
|
||||
});
|
||||
} else {
|
||||
alert('{{ "thesaurus::populate: Warning populate is in process to indexing databox" |trans }}');
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
});
|
||||
})
|
||||
|
||||
</script>
|
||||
</body>
|
||||
|
Reference in New Issue
Block a user