[Web] Fix ACL for spam score and minor style fix

master
andryyy 2021-07-09 08:23:23 +02:00
parent f73ac284e5
commit dfc8c95a54
No known key found for this signature in database
GPG Key ID: 8EC34FF2794E25EF
1 changed files with 29 additions and 25 deletions

View File

@ -569,32 +569,36 @@ elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == '
</div> </div>
<div role="tabpanel" class="tab-pane" id="Spamfilter"> <div role="tabpanel" class="tab-pane" id="Spamfilter">
<h4><?=$lang['user']['spamfilter_behavior'];?></h4> <h4><?=$lang['user']['spamfilter_behavior'];?></h4>
<form class="form-horizontal" role="form" data-id="spam_score" method="post"> <div class="row">
<div class="form-group"> <div class="col-sm-12">
<div class="col-lg-8 col-sm-12"> <form class="form-horizontal" role="form" data-id="spam_score" method="post">
<div id="spam_score" data-provide="slider" data-acl="<?=$_SESSION['acl']['spam_score'];?>"></div> <div class="form-group">
<input id="spam_score_value" name="spam_score" type="hidden" value="<?=mailbox('get', 'spam_score', $username);?>"> <div class="col-lg-8 col-sm-12">
<ul class="list-group list-group-flush"> <div id="spam_score" data-provide="slider" data-acl="<?=$_SESSION['acl']['spam_score'];?>"></div>
<li class="list-group-item"><span class="label label-ham spam-ham-score"></span> <?=$lang['user']['spamfilter_green'];?></li> <input id="spam_score_value" name="spam_score" type="hidden" value="<?=mailbox('get', 'spam_score', $username);?>">
<li class="list-group-item"><span class="label label-spam spam-spam-score"></span> <?=$lang['user']['spamfilter_yellow'];?></li> <ul class="list-group list-group-flush">
<li class="list-group-item"><span class="label label-reject spam-reject-score"></span> <?=$lang['user']['spamfilter_red'];?></li> <li class="list-group-item"><span class="label label-ham spam-ham-score"></span> <?=$lang['user']['spamfilter_green'];?></li>
</ul> <li class="list-group-item"><span class="label label-spam spam-spam-score"></span> <?=$lang['user']['spamfilter_yellow'];?></li>
</div> <li class="list-group-item"><span class="label label-reject spam-reject-score"></span> <?=$lang['user']['spamfilter_red'];?></li>
</div> </ul>
<div class="btn-group" data-acl="<?=$_SESSION['acl']['spam_policy'];?>"> </div>
<a type="button" class="btn btn-sm visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline btn-success" data-action="edit_selected" </div>
data-item="<?= htmlentities($username); ?>" <div class="btn-group" data-acl="<?=$_SESSION['acl']['spam_score'];?>">
data-id="spam_score" <a type="button" class="btn btn-sm btn-xs-half visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline btn-success" data-action="edit_selected"
data-api-url='edit/spam-score' data-item="<?= htmlentities($username); ?>"
data-api-attr='{}'><i class="bi bi-save"></i> <?=$lang['user']['save_changes'];?></a> data-id="spam_score"
<a type="button" class="btn btn-sm visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline btn-default" data-action="edit_selected" data-api-url='edit/spam-score'
data-item="<?= htmlentities($username); ?>" data-api-attr='{}'><i class="bi bi-save"></i> <?=$lang['user']['save_changes'];?></a>
data-id="spam_score_reset" <a type="button" class="btn btn-sm btn-xs-half visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline btn-default" data-action="edit_selected"
data-api-url='edit/spam-score' data-item="<?= htmlentities($username); ?>"
data-api-attr='{"spam_score":"default"}'><?=$lang['user']['spam_score_reset'];?></a> data-id="spam_score_reset"
data-api-url='edit/spam-score'
data-api-attr='{"spam_score":"default"}'><?=$lang['user']['spam_score_reset'];?></a>
</div>
</form>
</div> </div>
</form> </div>
<hr> <hr>
<div class="row"> <div class="row">
<div class="col-sm-6"> <div class="col-sm-6">