[Web] Fix sieve example insert
parent
e1897b0631
commit
2b1ff6c9a3
|
@ -3,7 +3,7 @@ function presets($_action, $_kind) {
|
|||
global $lang;
|
||||
switch ($_action) {
|
||||
case 'get':
|
||||
if ($_SESSION['mailcow_cc_role'] != "admin") {
|
||||
if ($_SESSION['mailcow_cc_role'] != "admin" && $_SESSION['mailcow_cc_role'] != "domainadmin") {
|
||||
return false;
|
||||
}
|
||||
$presets = array();
|
||||
|
|
|
@ -22,7 +22,7 @@ if (sieve_presetsElem) {
|
|||
document.getElementById(elemID).addEventListener('click', function (e) {
|
||||
e.preventDefault();
|
||||
document.querySelector('form[data-id=add_filter] #script_desc').value = item.headline;
|
||||
document.querySelector('form[data-id=add_filter] #script_data').value = item.content;
|
||||
document.querySelector('form[data-id=add_filter] .script_data').value = item.content;
|
||||
return true;
|
||||
});
|
||||
}, 0);
|
||||
|
|
|
@ -351,7 +351,7 @@ $_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
|
|||
<a class="btn btn-sm btn-success" href="#" data-toggle="modal" data-target="#addFilterModalAdmin"><span class="glyphicon glyphicon-plus"></span> <?=$lang['mailbox']['add_filter'];?></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="panel-body <?=($_SESSION['mailcow_cc_role'] == "admin") ?: 'hidden';?>">
|
||||
<?php
|
||||
$global_filters = mailbox('get', 'global_filter_details');
|
||||
?>
|
||||
|
|
Loading…
Reference in New Issue