Hide feature that need re-engeneering
This commit is contained in:
parent
6a363fd1ab
commit
2bbf9a3429
@ -363,45 +363,48 @@ class ActionsDatapolicies
|
|||||||
global $conf, $user, $langs;
|
global $conf, $user, $langs;
|
||||||
$langs->load('datapolicies@datapolicies');
|
$langs->load('datapolicies@datapolicies');
|
||||||
|
|
||||||
$dialog = '<div id="dialogdatapolicies" style="display:none;" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">';
|
if (! empty($conf->global->DATAPOLICIES_ENABLE_EMAILS))
|
||||||
$dialog .= '<div class="confirmmessage">' . img_help('', '') . ' ' . $langs->trans('DATAPOLICIES_PORTABILITE_CONFIRMATION') . '</div>';
|
{
|
||||||
$dialog .= "</div>";
|
$dialog = '<div id="dialogdatapolicies" style="display:none;" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">';
|
||||||
$dialog .= '<script>
|
$dialog .= '<div class="confirmmessage">' . img_help('', '') . ' ' . $langs->trans('DATAPOLICIES_PORTABILITE_CONFIRMATION') . '</div>';
|
||||||
$( function() {
|
$dialog .= "</div>";
|
||||||
$("#rpgpdbtn").on("click", function(){
|
$dialog .= '<script>
|
||||||
var href = $(this).attr("href");
|
$( function() {
|
||||||
$( "#dialogdatapolicies" ).dialog({
|
$("#rpgpdbtn").on("click", function(){
|
||||||
modal: true,
|
var href = $(this).attr("href");
|
||||||
buttons: {
|
$( "#dialogdatapolicies" ).dialog({
|
||||||
"OK": function() {
|
modal: true,
|
||||||
window.open(href);
|
buttons: {
|
||||||
$( this ).dialog( "close" );
|
"OK": function() {
|
||||||
},
|
window.open(href);
|
||||||
"' . $langs->trans('Cancel') . '": function() {
|
$( this ).dialog( "close" );
|
||||||
$( this ).dialog( "close" );
|
},
|
||||||
}
|
"' . $langs->trans('Cancel') . '": function() {
|
||||||
}
|
$( this ).dialog( "close" );
|
||||||
});
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
} );
|
} );
|
||||||
</script>';
|
</script>';
|
||||||
echo $dialog;
|
echo $dialog;
|
||||||
if ($parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) {
|
if ($parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) {
|
||||||
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?socid=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?socid=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
||||||
} elseif ($parameters['currentcontext'] == 'membercard') {
|
} elseif ($parameters['currentcontext'] == 'membercard') {
|
||||||
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?rowid=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?rowid=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
||||||
} elseif ($parameters['currentcontext'] == 'contactcard') {
|
} elseif ($parameters['currentcontext'] == 'contactcard') {
|
||||||
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?id=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a target="_blank" id="rpgpdbtn" class="butAction" href="' . $_SERVER["PHP_SELF"] . "?id=" . $object->id . '&action=datapolicies_portabilite" title="' . $langs->trans('DATAPOLICIES_PORTABILITE_TITLE') . '">' . $langs->trans("DATAPOLICIES_PORTABILITE") . '</a></div>';
|
||||||
}
|
}
|
||||||
if (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) {
|
if (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) {
|
||||||
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?socid=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?socid=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
||||||
} elseif (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'membercard') {
|
} elseif (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'membercard') {
|
||||||
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?rowid=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?rowid=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
||||||
} elseif (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'contactcard') {
|
} elseif (!empty($object->mail) && empty($object->array_options['options_datapolicies_send']) && $parameters['currentcontext'] == 'contactcard') {
|
||||||
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?id=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
echo '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . "?id=" . $object->id . '&action=send_datapolicies" title="' . $langs->trans('DATAPOLICIES_SEND') . '">' . $langs->trans("DATAPOLICIES_SEND") . '</a></div>';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -40,10 +40,13 @@ function datapoliciesAdminPrepareHead()
|
|||||||
$head[$h][2] = 'settings';
|
$head[$h][2] = 'settings';
|
||||||
$h++;
|
$h++;
|
||||||
|
|
||||||
$head[$h][0] = dol_buildpath("/datapolicies/admin/setupmail.php", 1);
|
if (! empty($conf->global->DATAPOLICIES_ENABLE_EMAILS))
|
||||||
$head[$h][1] = $langs->trans("DATAPOLICIESMail");
|
{
|
||||||
$head[$h][2] = 'settings';
|
$head[$h][0] = dol_buildpath("/datapolicies/admin/setupmail.php", 1);
|
||||||
$h++;
|
$head[$h][1] = $langs->trans("DATAPOLICIESMail");
|
||||||
|
$head[$h][2] = 'settings';
|
||||||
|
$h++;
|
||||||
|
}
|
||||||
|
|
||||||
complete_head_from_modules($conf, $langs, $object, $head, $h, 'datapolicies');
|
complete_head_from_modules($conf, $langs, $object, $head, $h, 'datapolicies');
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user