관리자 페이지 및 일부 데이터 업데이트 시 Event hook 추가

This commit is contained in:
kkigomi
2023-06-22 15:37:06 +09:00
parent 4eba618a82
commit bbbc568db8
15 changed files with 44 additions and 1 deletions

View File

@ -21,6 +21,10 @@ if ($w == '') {
ma_time = '" . G5_TIME_YMDHIS . "',
ma_ip = '{$_SERVER['REMOTE_ADDR']}' ";
sql_query($sql);
$ma_id = sql_insert_id();
run_event('admin_mail_created', $ma_id);
} elseif ($w == 'u') {
$sql = " update {$g5['mail_table']}
set ma_subject = '{$ma_subject}',
@ -29,9 +33,12 @@ if ($w == '') {
ma_ip = '{$_SERVER['REMOTE_ADDR']}'
where ma_id = '{$ma_id}' ";
sql_query($sql);
run_event('admin_mail_updated', $ma_id);
} elseif ($w == 'd') {
$sql = " delete from {$g5['mail_table']} where ma_id = '{$ma_id}' ";
sql_query($sql);
run_event('admin_mail_deleted', $ma_id);
}
goto_url('./mail_list.php');