Skip to content

Commit 72c9b5b

Browse files
committed
Add a few types
1 parent 0ab69a8 commit 72c9b5b

File tree

1 file changed

+20
-7
lines changed

1 file changed

+20
-7
lines changed

interface/web/monitor/dataloghistory_view.php

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,26 @@
5656
$out['table'] = $record['dbtable'];
5757
list($key, $value) = explode(':', $record['dbidx']);
5858
if (!empty($value)) {
59-
if ($record['action'] == 'd') {
60-
// No link for deleted content.
61-
$out['table_id'] = $record['dbidx'];
62-
} else {
63-
// TODO link per content type
64-
$out['table_id'] = '<a href="#" data-load-content="mail/mail_user_edit.php?id=' . $value .'" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="link">'.$record['dbidx'].'</a>';
65-
}
59+
if ($record['action'] == 'd') {
60+
// No link for deleted content.
61+
$out['table_id'] = $record['dbidx'];
62+
} else {
63+
switch ($out['table']) {
64+
case 'mail_forwarding':
65+
$file = 'mail/mail_forward_edit.php';
66+
break;
67+
case 'mail_user':
68+
$file = 'mail/mail_user_edit.php';
69+
break;
70+
case 'mail_domain':
71+
$file = 'mail/mail_domain_edit.php';
72+
break;
73+
default:
74+
$file = '';
75+
}
76+
// TODO link per content type
77+
$out['table_id'] = '<a href="#" data-load-content="' . $file . '?id=' . $value .'" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="link">'.$record['dbidx'] . $file .'</a>';
78+
}
6679
}
6780

6881
$out['action_char'] = $record['action'];

0 commit comments

Comments
 (0)