퍼스트가든에서 사용하는 사용자 함수 및 관련파일 추가

This commit is contained in:
2025-07-02 14:14:02 +09:00
parent 68797db562
commit ec949b682d
265 changed files with 27086 additions and 0 deletions

View File

@ -0,0 +1,23 @@
<?php
include_once '_common.php';
if(!$_SESSION['user_id']) exit;
if ( isset($_POST['tname'])) {
$tname = trim($_POST['tname']);
// 데이터 입력
$query = "INSERT INTO {$fg['member_group_table']} (tname, tused) VALUES('{$tname}', '1') "; // 기본값은 활성
$result = sql_query($query);
if ($result) {
// log 기록
$work_detail = "부서명 : ".$tname.", 처리자 : ".$_SESSION['user_name'];
$time = date("Y-m-d H:i:s");
$logquery = "INSERT INTO {$fg['log_table']} (work, work_detail, id, date) VALUES ('부서추가', '{$work_detail}', '{$_SESSION['user_id']}', '{$time}')";
$result = sql_query($logquery);
//log 기록 완료
$data = array("isSuccess" => $result);
header("Content-Type: application/json");
echo json_encode($data);
}
}