show whether user has been notified yet (#3058)
* show wether user has been notified yet * add translationsmaster
parent
eadf051d70
commit
51a8d58e3d
|
@ -624,7 +624,7 @@ function quarantine($_action, $_data = null) {
|
|||
break;
|
||||
case 'get':
|
||||
if ($_SESSION['mailcow_cc_role'] == "user") {
|
||||
$stmt = $pdo->prepare('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created` FROM `quarantine` WHERE `rcpt` = :mbox');
|
||||
$stmt = $pdo->prepare('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created`, `notified` FROM `quarantine` WHERE `rcpt` = :mbox');
|
||||
$stmt->execute(array(':mbox' => $_SESSION['mailcow_cc_username']));
|
||||
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
|
||||
while($row = array_shift($rows)) {
|
||||
|
@ -632,7 +632,7 @@ function quarantine($_action, $_data = null) {
|
|||
}
|
||||
}
|
||||
elseif ($_SESSION['mailcow_cc_role'] == "admin") {
|
||||
$stmt = $pdo->query('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created` FROM `quarantine`');
|
||||
$stmt = $pdo->query('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created`, `notified` FROM `quarantine`');
|
||||
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
|
||||
while($row = array_shift($rows)) {
|
||||
$q_meta[] = $row;
|
||||
|
@ -641,7 +641,7 @@ function quarantine($_action, $_data = null) {
|
|||
else {
|
||||
$domains = array_merge(mailbox('get', 'domains'), mailbox('get', 'alias_domains'));
|
||||
foreach ($domains as $domain) {
|
||||
$stmt = $pdo->prepare('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created` FROM `quarantine` WHERE `rcpt` REGEXP :domain');
|
||||
$stmt = $pdo->prepare('SELECT `id`, `qid`, `subject`, LOCATE("VIRUS_FOUND", `symbols`) AS `virus_flag`, `score`, `rcpt`, `sender`, UNIX_TIMESTAMP(`created`) AS `created`, `notified` FROM `quarantine` WHERE `rcpt` REGEXP :domain');
|
||||
$stmt->execute(array(':domain' => '@' . $domain . '$'));
|
||||
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
|
||||
while($row = array_shift($rows)) {
|
||||
|
|
|
@ -15,10 +15,11 @@ jQuery(function($){
|
|||
{"name":"id","type":"ID","filterable": false,"sorted": true,"direction":"DESC","title":"ID","style":{"width":"50px"}},
|
||||
{"name":"qid","breakpoints":"all","type":"text","title":lang.qid,"style":{"width":"125px"}},
|
||||
{"name":"sender","title":lang.sender},
|
||||
{"name":"subject","title":lang.subj, "type": "text"},
|
||||
{"name":"rcpt","title":lang.rcpt, "breakpoints":"xs sm md", "type": "text"},
|
||||
{"name":"virus","title":lang.danger, "type": "text"},
|
||||
{"name":"score","title": lang.spam_score, "type": "text"},
|
||||
{"name":"subject","title":lang.subj, "type": "text"},
|
||||
{"name":"notified","title":lang.notified, "type": "text"},
|
||||
{"name":"created","formatter":function unix_time_format(tm) { var date = new Date(tm ? tm * 1000 : 0); return date.toLocaleString();},"title":lang.received,"style":{"width":"170px"}},
|
||||
{"name":"action","filterable": false,"sortable": false,"style":{"text-align":"right"},"style":{"width":"220px"},"type":"html","title":lang.action,"breakpoints":"xs sm md"}
|
||||
],
|
||||
|
@ -44,6 +45,11 @@ jQuery(function($){
|
|||
} else {
|
||||
item.virus = '<span class="dot-neutral"></span>';
|
||||
}
|
||||
if(item.notified > 0) {
|
||||
item.notified = '✔';
|
||||
} else {
|
||||
item.notified = '✖';
|
||||
}
|
||||
if (acl_data.login_as === 1) {
|
||||
item.action = '<div class="btn-group">' +
|
||||
'<a href="#" data-item="' + encodeURI(item.id) + '" class="btn btn-xs btn-info show_qid_info"><span class="glyphicon glyphicon-modal-window"></span> ' + lang.show_item + '</a>' +
|
||||
|
|
|
@ -534,7 +534,8 @@
|
|||
"qhandler_success": "Aktion wurde an das System übergeben. Sie dürfen dieses Fenster nun schließen.",
|
||||
"release_body": "Die ursprüngliche Nachricht wurde als EML-Datei im Anhang hinterlegt.",
|
||||
"release_subject": "Potentiell schädliche Nachricht aus Quarantäne: %s",
|
||||
"confirm_delete": "Bestätigen Sie die Löschung dieses Elements."
|
||||
"confirm_delete": "Bestätigen Sie die Löschung dieses Elements.",
|
||||
"notified": "Benachrichtigt"
|
||||
},
|
||||
"mailbox": {
|
||||
"tls_policy_maps": "TLS-Richtlinien",
|
||||
|
|
|
@ -533,7 +533,8 @@
|
|||
"confirm_delete": "Confirm the deletion of this element.",
|
||||
"qhandler_success": "Request successfully sent to the system. You can now close the window.",
|
||||
"release_body": "We have attached your message as eml file to this message.",
|
||||
"release_subject": "Potentially damaging quarantine item %s"
|
||||
"release_subject": "Potentially damaging quarantine item %s",
|
||||
"notified": "Notified"
|
||||
},
|
||||
"mailbox": {
|
||||
"tls_policy_maps": "TLS policy maps",
|
||||
|
|
Loading…
Reference in New Issue