mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 09:53:15 +00:00
Merge branch 'master' of https://github.com/alchemy-fr/Phraseanet into PHRAS-2504-ginga-subtitle
This commit is contained in:
@@ -22,25 +22,24 @@
|
||||
<script type="text/javascript" src="/assets/thesaurus/js/thesaurus{% if not app.debug %}.min{% endif %}.js"></script>
|
||||
{#<script type="text/javascript" src="{{ path('minifier', { 'f' : 'skins/thesaurus/xmlhttp.js' }) }}"></script>#}
|
||||
<script type="text/javascript">
|
||||
function loaded()
|
||||
{
|
||||
window.name="ACCEPT";
|
||||
self.focus();
|
||||
}
|
||||
//$('.close-dialog').trigger('click');
|
||||
function ok()
|
||||
{
|
||||
as = "";
|
||||
if((n=document.forms[0].as.length) > 0)
|
||||
if($(".as_1").length > 0)
|
||||
{
|
||||
for(i=0; i<n && as==""; i++)
|
||||
{
|
||||
if(document.forms[0].as[i].checked)
|
||||
as = document.forms[0].as[i].value;
|
||||
}
|
||||
if($(".as_1")[0].checked) {
|
||||
as = $(".as_1").val();
|
||||
}
|
||||
if($(".as_2").length > 0 && $(".as_2")[0].checked) {
|
||||
as = $(".as_2").val();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
as = document.forms[0].as.value;
|
||||
if($(".as_3").length > 0) {
|
||||
as = $(".as_3").val();
|
||||
}
|
||||
}
|
||||
if(as == "TS")
|
||||
{
|
||||
@@ -59,14 +58,13 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
self.close();
|
||||
}
|
||||
else if(as == "SY")
|
||||
{
|
||||
@@ -85,19 +83,23 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
self.close();
|
||||
}
|
||||
$('.close-dialog').trigger('click');
|
||||
}
|
||||
|
||||
function closeModal() {
|
||||
$('.close-dialog').trigger('click');
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body id="desktop" onload="loaded();" class="dialog">
|
||||
<body id="desktop" class="dialog">
|
||||
|
||||
{% if not cterm_found %}
|
||||
<center>
|
||||
@@ -109,11 +111,9 @@
|
||||
<br/>
|
||||
{{ 'thesaurus:: refresh' | trans }}
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<input style="position:relative; z-index:2; width:100px" type="button" id="cancel_button" value="{{ 'boutton::fermer' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" class="cancel_btn" id="cancel_button" value="{{ 'boutton::fermer' | trans }}" onclick="closeModal();">
|
||||
</div>
|
||||
{% else %}
|
||||
{% if not term_found %}
|
||||
<center>
|
||||
@@ -125,11 +125,9 @@
|
||||
<br/>
|
||||
{{ 'thesaurus:: refresh' | trans }}
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<input style="position:relative; z-index:2; width:100px" type="button" id="cancel_button" value="{{ 'boutton::fermer' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" class="cancel_btn" id="cancel_button" value="{{ 'boutton::fermer' | trans }}" onclick="closeModal();">
|
||||
</div>
|
||||
{% else %}
|
||||
{% if acceptable %}
|
||||
<center>
|
||||
@@ -144,9 +142,9 @@
|
||||
{{ 'thesaurus:: Accepter le terme comme' | trans }}
|
||||
<br/><br/><h4>{{ fullpath_src | raw }}</h4><br/><br/>
|
||||
<br/>
|
||||
<input type='radio' name='as' value='TS' checked>{{ 'thesaurus:: comme terme specifique' | trans }}
|
||||
<input type='radio' name='as' class="as_1" value='TS' checked>{{ 'thesaurus:: comme terme specifique' | trans }}
|
||||
<br/><br/>
|
||||
<input type='radio' name='as' value='SY'>
|
||||
<input type='radio' name='as' class="as_2" value='SY'>
|
||||
{% set fullpath_tgt_raw = fullpath_tgt | raw %}
|
||||
{% trans with {'%fullpath_tgt_raw%' : fullpath_tgt_raw} %}thesaurus:: comme synonyme de %fullpath_tgt_raw%{% endtrans %}
|
||||
<br/>
|
||||
@@ -155,13 +153,12 @@
|
||||
{{ 'thesaurus:: Accepter la branche comme' | trans }}
|
||||
{{ 'thesaurus:: comme terme specifique' | trans }}
|
||||
<br/><br/><h4>{{ fullpath_tgt | raw }}</h4><br/><br/>
|
||||
<input type='hidden' name='as' value='TS'>
|
||||
<input type='hidden' name='as' class="as_3" value='TS'>
|
||||
{% endif %}
|
||||
<br/>
|
||||
<br/>
|
||||
<input style="position:relative; z-index:2; width:100px" type="button" id="ok_button" value="{{ 'boutton::valider' | trans }}" onclick="ok();">
|
||||
|
||||
<input style="position:relative; z-index:2; width:100px" type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input class="cancel_btn" type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="closeModal();">
|
||||
<input class="validate_btn" type="button" id="ok_button" value="{{ 'boutton::valider' | trans }}" onclick="ok();">
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
{% else %}
|
||||
@@ -171,13 +168,9 @@
|
||||
<br/>
|
||||
{% trans with {'%cfield%' : cfield} %}thesaurus:: A cet emplacement du thesaurus , un candidat du champ %cfield% ne peut etre accepte{% endtrans %}
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<input style="position:relative; z-index:2; width:100px" type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input class="cancel_btn" type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="closeModal();">
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
@@ -13,12 +13,13 @@
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
document.forms[0].action = "export_" + format + ".php";
|
||||
document.forms[0].submit();
|
||||
$('.export-form').attr('action',"export_" + format + ".php");
|
||||
$('.export-form').submit();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
case "cancel":
|
||||
self.returnValue = null;
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -49,19 +50,22 @@
|
||||
{
|
||||
var i, f;
|
||||
url = "./export_"+format+".php?bid={{ bid }}&piv={{ piv }}&id={{ id }}&typ={{ typ }}&dlg=0&smp=1";
|
||||
url += "&osl=" + (document.forms[0].osl[0].checked ? "1" : "0");
|
||||
url += "&iln=" + (document.forms[0].iln.checked ? "1" : "0");
|
||||
url += "&hit=" + (document.forms[0].hit.checked ? "1" : "0");
|
||||
url += "&ilg=" + (document.forms[0].ilg.checked ? "1" : "0");
|
||||
url += "&osl=" + ($('.osl_1')[0].checked ? "1" : $('.osl_0')[0].checked ? "0" : "0");
|
||||
url += "&iln=" + ($('.iln')[0].checked ? "1" : "0");
|
||||
url += "&hit=" + ($('.hit')[0].checked ? "1" : "0");
|
||||
url += "&ilg=" + ($('.ilg')[0].checked ? "1" : "0");
|
||||
document.getElementById("ifrsample").src = url;
|
||||
}
|
||||
$( document ).ready(function() {
|
||||
loaded();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog">
|
||||
<body class="dialog">
|
||||
<center>
|
||||
<br/>
|
||||
<form onsubmit="clkBut('submit');return(false);" action="export_topics.php" target="EXPORT2">
|
||||
<input type="hidden" name="bid" value="{{ bid }}" >
|
||||
<form class="export-form" action="export_topics.php" target="EXPORT2">
|
||||
<input type="hidden" name="bid" value="{{ bid }}">
|
||||
<input type="hidden" name="piv" value="{{ piv }}" >
|
||||
<input type="hidden" name="id" value="{{ id }}" >
|
||||
<input type="hidden" name="typ" value="{{ typ }}" >
|
||||
@@ -82,23 +86,23 @@
|
||||
</div>
|
||||
<div id='subform_text' style="margin-left:10px;">
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='osl' checked value='1' onclick="chgFormat();">
|
||||
<input type='radio' name='osl' class="osl_1" checked value='1' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: exporter avec les synonymes sur la meme ligne' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='osl' value='0' onclick="chgFormat();">
|
||||
<input type='radio' name='osl' class="osl_0" value='0' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: exporter avec une ligne par synonyme' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='checkbox' name='iln' value='1' onclick="chgFormat();">
|
||||
<input type='checkbox' name='iln' class="iln" value='1' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: export : numeroter les lignes' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='checkbox' name='ilg' value='1' onclick="chgFormat();">
|
||||
<input type='checkbox' name='ilg' class="ilg" value='1' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: export : inclure la langue' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='checkbox' name='hit' value='1' onclick="chgFormat();">
|
||||
<input type='checkbox' name='hit' class="hit" value='1' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: export : inclure les hits' | trans }}
|
||||
</div>
|
||||
</div>
|
||||
@@ -110,10 +114,11 @@
|
||||
</tbody>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" style="width:100px;">
|
||||
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
</body>
|
||||
|
@@ -11,12 +11,12 @@
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
document.forms[0].target = (format == 'tofiles' ? "_self" : "EXPORT2");
|
||||
document.forms[0].submit();
|
||||
$('.export-topics-form').submit();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
case "cancel":
|
||||
self.returnValue = null;
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -45,21 +45,25 @@
|
||||
}
|
||||
function chgFormat()
|
||||
{
|
||||
var i, f;
|
||||
for(i=0; i<document.forms[0].ofm.length; i++)
|
||||
var i;
|
||||
for(i=0; i<$('.ofm').length; i++)
|
||||
{
|
||||
f = document.forms[0].ofm[i].value;
|
||||
if(document.forms[0].ofm[i].checked)
|
||||
{
|
||||
format = f;
|
||||
if($(".ofm_1")[0].checked) {
|
||||
format = $(".ofm_1").val();
|
||||
}
|
||||
if($(".ofm_2")[0].checked) {
|
||||
format = $(".ofm_2").val();
|
||||
}
|
||||
}
|
||||
}
|
||||
$( document ).ready(function() {
|
||||
loaded();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog">
|
||||
<body class="dialog">
|
||||
<center>
|
||||
<form onsubmit="clkBut('submit');return(false);" action="export_topics.php">
|
||||
<form action="export_topics.php" class="export-topics-form" target="EXPORT2">
|
||||
<input type="hidden" name="bid" value="{{ bid }}" >
|
||||
<input type="hidden" name="piv" value="{{ piv }}" >
|
||||
<input type="hidden" name="id" value="{{ id }}" >
|
||||
@@ -67,15 +71,15 @@
|
||||
<input type="hidden" name="dlg" value="{{ dlg }}" >
|
||||
<input type="hidden" name="obr" value="{{ obr }}" >
|
||||
|
||||
<div style="padding:10px;">
|
||||
<div style="padding: 5px 15px">
|
||||
<div class="x3Dbox">
|
||||
<span class="title">{{ 'thesaurus:: exporter' | trans }}</span>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='ofm' checked value='tofiles' onclick="chgFormat();">
|
||||
<input type='radio' name='ofm' class="ofm ofm_1" checked value='tofiles' onclick="chgFormat();">
|
||||
{{ 'thesaurus:: exporter vers topics pour toutes les langues' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='ofm' value='toscreen' onclick="chgFormat();">
|
||||
<input type='radio' name='ofm' value='toscreen' class="ofm ofm_2" onclick="chgFormat();">
|
||||
{% trans with {'%piv%' : piv} %}thesaurus:: exporter a l'ecran pour la langue %piv%{% endtrans %}
|
||||
</div>
|
||||
</div>
|
||||
@@ -85,7 +89,7 @@
|
||||
<div class="x3Dbox">
|
||||
<span class="title">{{ 'phraseanet:: tri' | trans }}</span>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='checkbox' name='srt' checked onclick="chgFormat();">
|
||||
<input type='checkbox' name='srt' checked >
|
||||
{{ 'phraseanet:: tri par date' | trans }}
|
||||
</div>
|
||||
</div>
|
||||
@@ -95,15 +99,15 @@
|
||||
<div class="x3Dbox">
|
||||
<span class="title">{{ 'thesaurus:: recherche' | trans }}</span>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='sth' value="1" checked onclick="chgFormat();">
|
||||
<input type='radio' name='sth' value="1" checked >
|
||||
{{ 'thesaurus:: recherche thesaurus *:"query"' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='sth' value="0" onclick="chgFormat();">
|
||||
<input type='radio' name='sth' value="0" >
|
||||
{{ 'thesaurus:: recherche fulltext' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='checkbox' name='sand' onclick="chgFormat();">
|
||||
<input type='checkbox' name='sand' >
|
||||
{{ 'thesaurus:: question complete (avec operateurs)' | trans }}
|
||||
</div>
|
||||
</div>
|
||||
@@ -113,30 +117,31 @@
|
||||
<div class="x3Dbox">
|
||||
<span class="title">{{ 'thesaurus:: presentation' | trans }}</span>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='obrf' value="from_itf_closable" checked onclick="chgFormat();">
|
||||
<input type='radio' name='obrf' value="from_itf_closable" checked >
|
||||
{{ 'thesaurus:: presentation : branches refermables' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='obrf' value="from_itf_static" onclick="chgFormat();">
|
||||
<input type='radio' name='obrf' value="from_itf_static" >
|
||||
{{ 'thesaurus:: presentation : branche ouvertes' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='obrf' value="all_opened_closable" onclick="chgFormat();">
|
||||
<input type='radio' name='obrf' value="all_opened_closable" >
|
||||
{{ 'thesaurus:: tout deployer - refermable' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='obrf' value="all_opened_static" onclick="chgFormat();">
|
||||
<input type='radio' name='obrf' value="all_opened_static" >
|
||||
{{ 'thesaurus:: tout deployer - statique' | trans }}
|
||||
</div>
|
||||
<div style="white-space:nowrap">
|
||||
<input type='radio' name='obrf' value="all_closed" onclick="chgFormat();">
|
||||
<input type='radio' name='obrf' value="all_closed" >
|
||||
{{ 'thesaurus:: tout fermer' | trans }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" style="width:100px;">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
</body>
|
||||
|
@@ -32,12 +32,9 @@
|
||||
{% endfor %}
|
||||
|
||||
{% if ofm == 'tofiles' %}
|
||||
<center>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<input type="button" value="{{ 'boutton::fermer' | trans }}" onclick="self.close();" style="width:100px;">
|
||||
</center>
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" class="cancel_btn" value="{{ 'boutton::fermer' | trans }}" onclick=" self.close();" style="width:120px;">
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</body>
|
||||
|
@@ -15,13 +15,12 @@
|
||||
{
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
document.forms[0].target='IFRIM';
|
||||
document.forms[0].submit();
|
||||
case "submit":=
|
||||
$('.import-form').submit();
|
||||
break;
|
||||
case "cancel":
|
||||
self.returnValue = null;
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -32,8 +31,7 @@
|
||||
{
|
||||
if(!err)
|
||||
{
|
||||
{{ opener }}.reload();
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -44,7 +42,7 @@
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog">
|
||||
<br/>
|
||||
<form onsubmit="clkBut('submit');return(false);" action="import.php" enctype="multipart/form-data" method="post">
|
||||
<form onsubmit="clkBut('submit');return(false);" action="import.php" enctype="multipart/form-data" method="post" class="import-form" target="IFRIM">
|
||||
<input type="hidden" name="bid" value="{{ bid }}" >
|
||||
<input type="hidden" name="piv" value="{{ piv }}" >
|
||||
<input type="hidden" name="id" value="{{ id }}" >
|
||||
@@ -57,7 +55,7 @@
|
||||
<input type="file" name="fil" /> (max 16Mo)
|
||||
<br/>
|
||||
|
||||
<div style="text-align:center">
|
||||
<div class="text-center">
|
||||
<table>
|
||||
<tr>
|
||||
<td style="text-align:left"><input type="checkbox" disabled="disabled" name="dlk" checked="checked">{{ 'thesaurus:: supprimer les liens des champs tbranch' | trans }}</td>
|
||||
@@ -67,10 +65,11 @@
|
||||
</tr>
|
||||
</table>
|
||||
<br/>
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');" style="width:100px;">
|
||||
</div>
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" >
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</div>
|
||||
</divclass>
|
||||
</form>
|
||||
<iframe style="display:block; height:50px;" name="IFRIM"></iframe>
|
||||
</body>
|
||||
|
@@ -25,41 +25,55 @@
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
// document.forms[0].target="LINKFIELD";
|
||||
document.forms[0].submit();
|
||||
$('.link-field-1').submit(
|
||||
$.ajax({
|
||||
url : 'linkfield2.php',
|
||||
type : 'POST',
|
||||
data : $('.link-field-1').serialize(),
|
||||
success : function( data ) {
|
||||
$("#DLG_LINK_FIELD_1").html('');
|
||||
$("#DLG_LINK_FIELD_1").append(data);
|
||||
},
|
||||
error : function( xhr, err ) {
|
||||
alert('Error');
|
||||
}
|
||||
})
|
||||
);
|
||||
break;
|
||||
case "cancel":
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
}
|
||||
}
|
||||
function loaded()
|
||||
{
|
||||
window.name="LINKFIELD";
|
||||
ckField();
|
||||
}
|
||||
$( document ).ready(function() {
|
||||
loaded();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog">
|
||||
<center>
|
||||
<form action="linkfield2.php" method="post" target="LINKFIELD">
|
||||
<input type="hidden" name="piv" value="{{ piv }}">
|
||||
<input type="hidden" name="bid" value="{{ bid }}">
|
||||
<input type="hidden" name="tid" value="{{ tid }}">
|
||||
<body class="dialog">
|
||||
|
||||
{% set branch = "<br/><b>" ~ fullBranch ~ "</b><br/>" %}
|
||||
{% trans with {'%branch%' : branch} %}thesaurus:: Lier la branche de thesaurus au champ %branch%{% endtrans %}
|
||||
<form class="link-field-1" action="linkfield2.php" method="post" target="LINKFIELD" style="padding: 5px 15px">
|
||||
<input type="hidden" name="piv" value="{{ piv }}">
|
||||
<input type="hidden" name="bid" value="{{ bid }}">
|
||||
<input type="hidden" name="tid" value="{{ tid }}">
|
||||
|
||||
<div style="width:70%; height:200px; overflow:scroll;" class="x3Dbox">
|
||||
{% for fieldname, checked in fieldnames %}
|
||||
<input type="checkbox" name="field[]" value="{{ fieldname }}" {% if checked %}checked{% endif %} ck0="{% if checked %}1{% else %}0{% endif %}" onclick="return(ckField());">{{ fieldname }}<br/>
|
||||
{% endfor %}
|
||||
{% set branch = "<br/><b>" ~ fullBranch ~ "</b><br/>" %}
|
||||
{% trans with {'%branch%' : branch} %}thesaurus:: Lier la branche de thesaurus au champ %branch%{% endtrans %}
|
||||
|
||||
<div style="width:100%; height:270px; overflow:scroll;" class="x3Dbox">
|
||||
{% for fieldname, checked in fieldnames %}
|
||||
<input type="checkbox" name="field[]" value="{{ fieldname }}" {% if checked %}checked{% endif %} ck0="{% if checked %}1{% else %}0{% endif %}" onclick="return(ckField());">{{ fieldname }}<br/>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</div>
|
||||
<br/>
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
</form>
|
||||
</center>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
@@ -12,10 +12,23 @@
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
document.forms[0].submit();
|
||||
$('.link-field-2').submit(
|
||||
$.ajax({
|
||||
url : 'linkfield3.php',
|
||||
type : 'POST',
|
||||
data : $('.link-field-2').serialize(),
|
||||
success : function( data ) {
|
||||
$("#DLG_LINK_FIELD_1").html('');
|
||||
$("#DLG_LINK_FIELD_1").append(data);
|
||||
},
|
||||
error : function( xhr, err ) {
|
||||
alert('Error');
|
||||
}
|
||||
})
|
||||
);
|
||||
break;
|
||||
case "cancel":
|
||||
self.close();
|
||||
$('.close-dialog').trigger('click');
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -23,11 +36,15 @@
|
||||
{
|
||||
window.name="LINKFIELD";
|
||||
}
|
||||
$( document ).ready(function() {
|
||||
loaded();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog">
|
||||
<body class="dialog">
|
||||
<center>
|
||||
<form action="linkfield3.php" method="post" target="LINKFIELD">
|
||||
<form class="link-field-2" action="linkfield3.php" method="post" target="LINKFIELD">
|
||||
<div class="text-center">
|
||||
<input type="hidden" name="piv" value="{{ piv }}">
|
||||
<input type="hidden" name="bid" value="{{ bid }}">
|
||||
<input type="hidden" name="tid" value="{{ tid }}">
|
||||
@@ -68,10 +85,11 @@
|
||||
{% else %}
|
||||
<div style='position:absolute; top:5px; left:0px; width:100%; text-align:center; color:green'>{{ 'thesaurus:: pas de reindexation' | trans }}</div>
|
||||
{% endif %}
|
||||
<br/>
|
||||
<input type="button" id="submit_button" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
</div>
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="cancel_button" class="cancel_btn" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');">
|
||||
<input type="button" id="submit_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" onclick="clkBut('submit');">
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
</body>
|
||||
|
@@ -41,8 +41,9 @@
|
||||
<br/>
|
||||
{% endif %}
|
||||
</div>
|
||||
<br/>
|
||||
<input type="button" value="{{ 'boutton::fermer' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" value="{{ 'boutton::fermer' | trans }}" class="cancel_btn" onclick="$('.close-dialog').trigger('click');">
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
</body>
|
||||
|
@@ -8,6 +8,7 @@
|
||||
{#<script type="text/javascript" src="{{ path('minifier', { 'f' : 'skins/thesaurus/xmlhttp.js' }) }}"></script>#}
|
||||
</head>
|
||||
<body onload="loaded();" class="dialog" style="text-align:center">
|
||||
<div class="text-center">
|
||||
{% if dlg is not none %}
|
||||
{% set opener = 'window.dialogArguments.win' %}
|
||||
{% else %}
|
||||
@@ -37,8 +38,9 @@
|
||||
<br/>
|
||||
{{ prop_label }}
|
||||
<br/>
|
||||
<center>
|
||||
<form onsubmit="return(false);">
|
||||
</div>
|
||||
<div class="text-center">
|
||||
<form onsubmit="return(false);" class="thesaurus_confirm_bottom_block">
|
||||
<input type="hidden" name="bid" value="{{ bid }} ">
|
||||
<input type="hidden" name="pid" value="{{ pid }}">
|
||||
<div class='x3Dbox' style='margin:15px; height:100px; overflow:auto;'>
|
||||
@@ -50,34 +52,27 @@
|
||||
{{ '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>
|
||||
</center>
|
||||
</div>
|
||||
{% else %}
|
||||
{% if nb_candidates_bad > 0 %}
|
||||
{% set prop_label = 'thesaurus:: est candidat en provenance des champs mais ne peut etre accepte a cet emplacement du thesaurus' | trans %}
|
||||
{% else %}
|
||||
{% set prop_label = 'thesaurus:: n\'est pas present dans les candidats' | trans %}
|
||||
{% endif %}
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<br/>
|
||||
{{ zterm }}
|
||||
<br/>
|
||||
<br/>
|
||||
{{ prop_label }}
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<br/>
|
||||
<form>
|
||||
<input type="button" id="cancel_button" value="{{ 'boutton::annuler' | trans }}" onclick="clkBut('cancel');" style="width:100px;">
|
||||
<form class="thesaurus_confirm_bottom_block">
|
||||
<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>
|
||||
@@ -119,17 +114,19 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
self.close();
|
||||
$("#NEWSY_DLG_CONFIRM").dialog('close');
|
||||
$("#NEWSY_DLG_CONFIRM").html('');
|
||||
break;
|
||||
case "cancel":
|
||||
self.close();
|
||||
$("#NEWSY_DLG_CONFIRM").dialog('close');
|
||||
$("#NEWSY_DLG_CONFIRM").html('');
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -141,18 +138,18 @@
|
||||
switch(button)
|
||||
{
|
||||
case "submit":
|
||||
{% if typ == "TS" %}
|
||||
url = "xmlhttp/newts.x.php";
|
||||
{% else %}
|
||||
url = "xmlhttp/newsy.x.php";
|
||||
{% endif %}
|
||||
{% if typ == "TS" %}
|
||||
url = "xmlhttp/newts.x.php";
|
||||
{% else %}
|
||||
url = "xmlhttp/newsy.x.php";
|
||||
{% endif %}
|
||||
parms = "bid={{ bid }}";
|
||||
parms += "&piv={{ piv }}";
|
||||
parms += "&pid={{ pid }}";
|
||||
parms += "&t={{ term | url_encode }}";
|
||||
{% if context is not none %}
|
||||
parms += "&k={{ context | url_encode }}";
|
||||
{% endif %}
|
||||
{% if context is not none %}
|
||||
parms += "&k={{ context | url_encode }}";
|
||||
{% endif %}
|
||||
parms += "&sylng={{ sylng }}";
|
||||
parms += "&reindex=0";
|
||||
|
||||
@@ -163,17 +160,20 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
$("#NEWSY_DLG_CONFIRM").dialog('close');
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
$("#NEWSY_DLG_CONFIRM").dialog('close');
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
self.close();
|
||||
break;
|
||||
case "cancel":
|
||||
self.close();
|
||||
$("#NEWSY_DLG_CONFIRM").dialog('close');
|
||||
$("#NEWSY_DLG_CONFIRM").html('');
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@@ -3,11 +3,6 @@
|
||||
{% else %}
|
||||
{% set opener = "opener" %}
|
||||
{% endif %}
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
|
||||
<html lang="{{ app['locale'] }}">
|
||||
<head>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
||||
<title>{{ 'thesaurus:: Proprietes' | trans }}</title>
|
||||
<link type="text/css" rel="stylesheet" href="/assets/thesaurus/css/thesaurus{% if not app.debug %}.min{% endif %}.css" />
|
||||
<style type="text/css">
|
||||
a
|
||||
@@ -24,38 +19,31 @@
|
||||
font-weight:900;
|
||||
}
|
||||
</style>
|
||||
<script type="text/javascript" src="/assets/vendors/jquery/jquery{% if not app.debug %}.min{% endif %}.js"></script>
|
||||
<script type="text/javascript" src="/assets/thesaurus/js/thesaurus{% if not app.debug %}.min{% endif %}.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
function loaded()
|
||||
{
|
||||
window.name="PROPERTIES";
|
||||
self.focus();
|
||||
}
|
||||
$( document ).ready(function() {
|
||||
loaded();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body id="desktop" onload="loaded();" class="dialog">
|
||||
<div class="menu" id="flagsMenu" style="z-index:50">
|
||||
{% 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 class="menu" id="syMenu" style="z-index:50">
|
||||
<a href="javascript:void(0)" id="delete_sy">{{ 'thesaurus::menu: supprimer' | trans }}</a>
|
||||
</div>
|
||||
<div class="menu" id="syMenu" style="z-index:999">
|
||||
<a href="javascript:void(0)" id="delete_sy">{{ 'thesaurus:properties:: Mettre dans le stock' | trans }}</a>
|
||||
</div>
|
||||
<div id="desktop" class="dialog">
|
||||
|
||||
<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>
|
||||
@@ -71,9 +59,7 @@
|
||||
<th> </th>
|
||||
<th> </th>
|
||||
<th>{{ 'thesaurus:: synonymes' | trans }}</th>
|
||||
<th>{{ 'thesaurus:: hits' | trans }}</th>
|
||||
<th>{{ 'thesaurus:: ids' | trans }}</th>
|
||||
<th></th>
|
||||
<th colspan="3">{{ 'thesaurus:termePorperties:termeId' | trans }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
@@ -99,13 +85,13 @@
|
||||
{% endif %}
|
||||
</td>
|
||||
{% if data['lng'] %}
|
||||
<td id='FLG_{{ data['id'] }}'><img src='/assets/common/images/lng/{{ data['lng'] }}_flag_18.gif' /></td>
|
||||
<td id='FLG_{{ data['id'] }}'>{{ data['lng'] }}</td>
|
||||
{% else %}
|
||||
<td id='FLG_{{ data['id'] }}'><img src='/assets/thesaurus/images/noflag.gif' /></td>
|
||||
<td id='FLG_{{ data['id'] }}'></td>
|
||||
{% endif %}
|
||||
<td>{{ data['t'] }}</td>
|
||||
<td>{{ data['hits'] }}</td>
|
||||
<td>{{ data['id'] }}</td>
|
||||
<td><span class="delete_term"></span></td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
@@ -115,13 +101,17 @@
|
||||
</div>
|
||||
<center>
|
||||
<form onsubmit="return(false);">
|
||||
<input style="position:relative; z-index:2" type="button" id="close_button" value="{{ 'boutton::fermer' | trans }}" onclick="self.close();">
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" id="close_button" class="close_button cancel_btn" value="{{ 'boutton::fermer' | trans }}" >
|
||||
</div>
|
||||
</form>
|
||||
</center>
|
||||
<script type="text/javascript">
|
||||
$(".close_button").on("click", function(){
|
||||
$('.close-dialog').trigger('click');
|
||||
});
|
||||
// gui callback du menu des drapeaux
|
||||
var nsy = {{ synonyms | length }};
|
||||
|
||||
function cbME_flags(action, cbParm, menuelem_id)
|
||||
{
|
||||
if(action != "SELECT" || !menuelem_id) {
|
||||
@@ -148,17 +138,23 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$('.delete_term').click(function (e) {
|
||||
e.preventDefault();
|
||||
$('#delete_sy').trigger('click');
|
||||
});
|
||||
|
||||
// gui callback du menu des synonymes
|
||||
function cbME_synonym(action, cbParm, menuelem_id)
|
||||
{
|
||||
@@ -169,6 +165,7 @@
|
||||
// pas d'action possible s'il ne reste qu'un seul synonyme
|
||||
// alert(nsy);
|
||||
document.getElementById("delete_sy").className = "disabled";
|
||||
$('.delete_term').addClass('disabled');
|
||||
// document.getElementById("reject_sy").className = "disabled";
|
||||
}
|
||||
else
|
||||
@@ -178,12 +175,14 @@
|
||||
// y'a des hits, on peut pas supprimer
|
||||
// document.getElementById("reject_sy").className = "";
|
||||
document.getElementById("delete_sy").className = "";
|
||||
$('.delete_term').removeClass('disabled');
|
||||
}
|
||||
else
|
||||
{
|
||||
// pas de hits : on peut supprimer
|
||||
// document.getElementById("reject_sy").className = "";
|
||||
document.getElementById("delete_sy").className = "";
|
||||
$('.delete_term').removeClass('disabled');
|
||||
}
|
||||
}
|
||||
return;
|
||||
@@ -216,7 +215,7 @@
|
||||
ret = loadXMLDoc(url, parms, true);
|
||||
|
||||
sy_list = ret.getElementsByTagName("sy_list").item(0);
|
||||
refresh_sy(sy_list);
|
||||
//refresh_sy(sy_list);
|
||||
|
||||
refresh = ret.getElementsByTagName("refresh");
|
||||
for(i=0; i<refresh.length; i++)
|
||||
@@ -224,15 +223,24 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
var new_url = $('#url_properties').val();
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: `${new_url}`,
|
||||
success: function(data){
|
||||
$('#DLG_PROPERTIES').html('');
|
||||
$('#DLG_PROPERTIES').append(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -273,16 +281,16 @@
|
||||
td = tr.appendChild(document.createElement("td"));
|
||||
td.id = "FLG_"+(nsy+1);
|
||||
// td.innerText = n.getAttribute("lng");
|
||||
img = td.appendChild(document.createElement("img"));
|
||||
img.setAttribute("src", "/assets/common/images/lng/"+n.getAttribute("lng")+"_flag_18.gif");
|
||||
span = td.appendChild(document.createElement("span"));
|
||||
span.innerHTML = n.getAttribute("lng");
|
||||
|
||||
td = tr.appendChild(document.createElement("td"));
|
||||
// td.colSpan = "2";
|
||||
// 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");
|
||||
@@ -308,15 +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 );
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "MOUSEDOWN":
|
||||
@@ -335,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":
|
||||
@@ -368,12 +382,12 @@
|
||||
switch(refresh.item(i).getAttribute("type"))
|
||||
{
|
||||
case "CT":
|
||||
{{ opener }}.reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadCtermsBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
case "TH":
|
||||
{{ opener }}.reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
{{ opener }}.myGUI.select({{ opener }}.document.getElementById("THE_{{ id }}"));
|
||||
reloadThesaurusBranch(refresh.item(i).getAttribute("id"));
|
||||
myGUI.select(document.getElementById("THE_{{ id }}"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -383,7 +397,5 @@
|
||||
myGUI.setClickable("TSY", cbDD_TSY);
|
||||
myGUI.setAsMenu("flagsMenu", cbME_flags);
|
||||
myGUI.setAsMenu("syMenu", cbME_synonym);
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
</div>
|
||||
|
@@ -53,10 +53,11 @@
|
||||
t = t.replace(/&/g, "&");
|
||||
t = t.replace(/</g, "<");
|
||||
t = t.replace(/>/g, ">");
|
||||
// t = escape(t);
|
||||
// t = escape(t);
|
||||
w = window.open("about:blank", div+"wSRC", "left=2, top=2, directories=yes, width=1000, height=800, location=yes, menubar=yes, toolbar=yes, help=yes, status=yes, resizable=yes, scrollbars=yes", true);
|
||||
w.document.write("<pre>"+t+"</pre>");
|
||||
w.document.close();
|
||||
|
||||
}
|
||||
|
||||
var o_thbox_bck = null;
|
||||
@@ -82,7 +83,12 @@
|
||||
$("#SEARCH_DLG").dialog({
|
||||
modal: true,
|
||||
title: "{{ 'Chercher' | trans }}",
|
||||
autoOpen:false
|
||||
autoOpen:false,
|
||||
open:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
}
|
||||
});
|
||||
$("#NEWSY_DLG").dialog({
|
||||
modal: true,
|
||||
@@ -156,14 +162,15 @@
|
||||
|
||||
</head>
|
||||
|
||||
<body id="desktop" style="background-color:#808080; overflow:hidden" onload="loaded();" onscroll="evtScrollBody();" >
|
||||
<body id="desktop" class="thesaurus-page" style="background-color:#808080; overflow:hidden" onload="loaded();" onscroll="evtScrollBody();" >
|
||||
|
||||
<div class="menu" id="flagsMenu" style="z-index:50">
|
||||
<div class="menu" id="flagsMenu" style="z-index:999">
|
||||
{% for code, language in flags %}
|
||||
<img id='flagMenu_{{ code }}' src='/assets/common/images/lng/{{ code }}_flag_18.gif' />
|
||||
<p><img id='flagMenu_{{ code }}' src='/assets/common/images/lng/{{ code }}_flag_18.gif' /> {{ language }}</p>
|
||||
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="menu" id="kctermMenu" style="z-index:50; width:240px;">
|
||||
<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>
|
||||
<a href="javascript:void(0)" class="" id="kcterm_reject">{{ 'thesaurus::menu: refuser' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="disabled" id="kcterm_accept">{{ 'thesaurus::menu: accepter' | trans }}</a>
|
||||
@@ -174,15 +181,15 @@
|
||||
<a href="javascript:void(0)" class="" id="kcterm_export">{{ 'thesaurus::menu: exporter' | trans }}</a>
|
||||
</div>
|
||||
|
||||
<div class="menu" id="kThMenu" style="z-index:50; width:200px;">
|
||||
<div class="menu" id="kThMenu" style="z-index:999; width:200px;">
|
||||
<a href="javascript:void(0)" class="" id="kth_import">{{ 'thesaurus::menu: importer' | trans }}</a>
|
||||
</div>
|
||||
|
||||
<div class="menu" id="ktermMenu" style="z-index:50; width:200px;">
|
||||
<div class="menu" id="ktermMenu" style="z-index:999; width:200px;">
|
||||
<a href="javascript:void(0)" class="" id="kterm_properties" style="font-weight:700">{{ 'thesaurus::menu: proprietes' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="" id="kterm_newts">{{ 'thesaurus::menu: Nouveau terme' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="" id="kterm_newsy">{{ 'thesaurus::menu: Nouveau synonyme' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="" id="kterm_delete">{{ 'thesaurus::menu: supprimer' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="" id="kterm_delete">{{ 'thesaurus::menu: Mettre dans le stock' | trans }}</a>
|
||||
<div class="line"></div>
|
||||
<a href="javascript:void(0)" class="" id="kterm_search">{{ 'thesaurus::menu: chercher' | trans }}</a>
|
||||
<a href="javascript:void(0)" class="" id="kterm_export">{{ 'thesaurus::menu: exporter' | trans }}</a>
|
||||
@@ -211,6 +218,18 @@
|
||||
<br/>
|
||||
<br/>
|
||||
<div id="id_thbox_bck" class="thbox" style="position:absolute; top:28px; left:8px; right:8px; bottom:8px; background-color:#f4f4f4; xoverflow:hidden">
|
||||
<div class="populate_btn_wrapper">
|
||||
<a class="populate_btn btn btn-primary" id="populate_btn">{{ 'thesaurus:: populate button' | trans }}</a>
|
||||
</div>
|
||||
<div style="display: none">
|
||||
<div id="confirm_populate">
|
||||
<p><span class="alert alert-message"> {{ 'thesaurus:: confirm populate' | trans }}</span></p>
|
||||
<div class="thesaurus_confirm_bottom_block">
|
||||
<input type="button" class="cancel_button cancel_btn" value="{{ 'boutton::annuler' | trans }}" >
|
||||
<input type="button" id="confirm_populate_button" class="validate_btn" value="{{ 'boutton::valider' | trans }}" >
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="onglet" style="background-color:#f0f0f0; border-bottom:1px solid #f4f4f4">
|
||||
<span id="baseName">{{ 'phraseanet:: thesaurus' | trans }}</span>
|
||||
@@ -278,11 +297,13 @@
|
||||
<td><input type="text" style="width:250px;" name="term"
|
||||
onkeyup="inputChanged();return(false);"></td>
|
||||
</tr>
|
||||
<tr><td colspan="3" style="height: 10px"></td></tr>
|
||||
<tr>
|
||||
<td style="text-align:right">{{ 'thesaurus:: contexte' | trans }} : </td>
|
||||
<td><b>(</b> </td>
|
||||
<td><input type="text" style="width:250px;" name="context"> <b>)</b></td>
|
||||
</tr>
|
||||
<tr><td colspan="3" style="height: 10px"></td></tr>
|
||||
<tr>
|
||||
<td valign="bottom" style="text-align:right">{{ 'phraseanet:: language' | trans }} : </td>
|
||||
<td></td>
|
||||
@@ -300,12 +321,25 @@
|
||||
</div>
|
||||
<!-- ------------------------- end "new term/synonym" dialog ---------------------- -->
|
||||
|
||||
<div id="NEWSY_DLG_CONFIRM">
|
||||
</div>
|
||||
<div id="DLG_EXPORT">
|
||||
</div>
|
||||
<div id="DLG_EXPORT_TOPICS">
|
||||
</div>
|
||||
<div id="DLG_PROPERTIES">
|
||||
</div>
|
||||
<div id="ACCEPT_DLG_CONFIRM">
|
||||
</div>
|
||||
<div id="DLG_LINK_FIELD_1">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<br/>
|
||||
|
||||
</form>
|
||||
|
||||
<input type="hidden" id="url_properties">
|
||||
<div id="clipboard" style="position:absolute; top:0px; left:0px; z-index:99"> </div>
|
||||
|
||||
|
||||
@@ -315,6 +349,32 @@
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
//Ajax function to get data
|
||||
var title = '';
|
||||
var stock = false;
|
||||
function loadDataAjax(urls, width, height, bloc, title) {
|
||||
$(bloc).dialog({
|
||||
title: title,
|
||||
width: width,
|
||||
height: height,
|
||||
modal: true,
|
||||
create:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
}
|
||||
});
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: `${urls}`,
|
||||
success: function(data){
|
||||
$(bloc).html('');
|
||||
$(bloc).append(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
document.body.oncontextmenu = function(){
|
||||
return false;
|
||||
@@ -580,8 +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 }}');
|
||||
|
||||
w = window.open(url, "PROPERTIES", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
break;
|
||||
case "kcterm_search":
|
||||
$("#SEARCH_DLG").dialog("option", "buttons",
|
||||
@@ -628,7 +691,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=CT";
|
||||
w = window.open(url, "EXPORT", "directories=no, height=300, width=700, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
// w = window.open(url, "EXPORT", "directories=no, height=300, width=700, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 700 , 340,'#DLG_EXPORT', '{{ 'thesaurus:dialog:: export' | trans }}');
|
||||
break;
|
||||
break;
|
||||
}
|
||||
@@ -689,8 +753,10 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=CT";
|
||||
|
||||
w = window.open(url, "PROPERTIES", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
$('#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 }}');
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -926,7 +992,6 @@
|
||||
{
|
||||
if(tid=='')
|
||||
tid='T';
|
||||
|
||||
return(reloadbranch(document.getElementById("THB_"+tid), tid, "TH"))
|
||||
}
|
||||
|
||||
@@ -1009,7 +1074,6 @@
|
||||
var lng = zdialog.find("[name=lng]:checked").val();
|
||||
|
||||
zdialog.dialog("close");
|
||||
|
||||
url = "newterm.php";
|
||||
url += "?bid={{ bid }}";
|
||||
url += "&piv={{ piv }}";
|
||||
@@ -1018,11 +1082,21 @@
|
||||
url += "&typ=" + typ;
|
||||
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 = 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, 350,"#NEWSY_DLG_CONFIRM",'{% if typ == "TS" %}{{ 'thesaurus:: Nouveau terme specifique' | trans }}{% else %}{{ 'thesaurus:: Nouveau synonyme' | trans }}{% endif %}');
|
||||
}
|
||||
}
|
||||
]
|
||||
],
|
||||
|
||||
);
|
||||
|
||||
$("#NEWSY_DLG").dialog({
|
||||
open:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
}
|
||||
});
|
||||
$("#NEWSY_DLG").dialog("open");
|
||||
break;
|
||||
|
||||
@@ -1074,7 +1148,8 @@
|
||||
url += "?bid={{ bid }}";
|
||||
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 = 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, 430, "#DLG_LINK_FIELD_1", '{{ 'thesaurus:: Lier la branche de thesaurus au champ' | trans }}');
|
||||
break;
|
||||
case "kterm_properties":
|
||||
var myObj = { "win":window };
|
||||
@@ -1083,8 +1158,11 @@
|
||||
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 }}');
|
||||
|
||||
w = window.open(url, "PROPERTIES", "directories=no, height=300, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
break;
|
||||
case "kterm_search":
|
||||
$("#SEARCH_DLG").dialog("option", "buttons",
|
||||
@@ -1122,6 +1200,13 @@
|
||||
}
|
||||
]
|
||||
);
|
||||
$("#SEARCH_DLG").dialog({
|
||||
open:function () {
|
||||
$(this).closest(".ui-dialog")
|
||||
.find(".ui-button:first") // the first button
|
||||
.addClass("close-dialog").hide();
|
||||
}
|
||||
});
|
||||
$("#SEARCH_DLG").dialog("open");
|
||||
break;
|
||||
case "kterm_export":
|
||||
@@ -1131,7 +1216,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=TH";
|
||||
w = window.open(url, "EXPORT", "directories=no, height=300, width=700, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
//w = window.open(url, "EXPORT", "directories=no, height=300, width=700, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 700, 400, "#DLG_EXPORT", '{{ 'thesaurus:: export au format texte' | trans }}');
|
||||
break;
|
||||
case "kterm_topics":
|
||||
var myObj = { "win":window };
|
||||
@@ -1141,7 +1227,8 @@
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=TH";
|
||||
url += "&obr=" + list_opened_branches(o.parentNode);
|
||||
w = window.open(url, "EXPORT", "directories=no, height=400, width=550, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
//w = window.open(url, "EXPORT", "directories=no, height=400, width=550, location=no, menubar=no, resizable=yes, scrollbars=yes, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 700, 450, "#DLG_EXPORT_TOPICS", '{{ 'thesaurus:: export en topics' | trans }}');
|
||||
break;
|
||||
}
|
||||
break;
|
||||
@@ -1245,7 +1332,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&id=" + o.id.substr(4);
|
||||
url += "&typ=TH";
|
||||
w = window.open(url, "PROPERTIES", "directories=no, height=340, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
// 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, "#NEWSY_DLG_CONFIRM", '{{ 'thesaurus:: Proprietes' | trans }}');
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1318,7 +1406,8 @@
|
||||
url += "&piv={{ piv }}";
|
||||
url += "&src=" + eventObj.Src0.id.substr(4);
|
||||
url += "&tgt=" + tgt0.id.substr(4);
|
||||
w = window.open(url, "ACCEPT", "directories=no, height=300, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
//w = window.open(url, "ACCEPT", "directories=no, height=300, width=500, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 500 , 340, "#ACCEPT_DLG_CONFIRM", '{{ 'thesaurus:: accepter...' | trans }}');
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1372,7 +1461,8 @@
|
||||
url += "?piv={{ piv }}";
|
||||
url += "&bid={{ bid }}";
|
||||
url += "&id=";
|
||||
w = window.open(url, "IMPORT", "directories=no, height=400, width=600, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
// w = window.open(url, "IMPORT", "directories=no, height=400, width=600, location=no, menubar=no, resizable=yes, scrollbars=no, status=no, toolbar=no");
|
||||
w = loadDataAjax(url, 600 , 400, "#NEWSY_DLG_CONFIRM", '{{ 'thesaurus:: Importer' | trans }}');
|
||||
break;
|
||||
}
|
||||
break;
|
||||
@@ -1430,8 +1520,61 @@
|
||||
/*
|
||||
*/
|
||||
|
||||
</script>
|
||||
|
||||
$(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').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>
|
||||
|
||||
</html>
|
||||
|
Reference in New Issue
Block a user