package com.ga.common.system; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import java.util.List; import java.util.Map; /** * 시스템 로그 DB 매퍼 (MyBatis) — 로그인/API접근/데이터변경 3종. * insert*는 로그 적재용(주로 비동기 서비스가 호출), select*는 관리 화면 조회용이다. */ @Mapper public interface SystemLogMapper { int insertLoginLog(@Param("userId") Long userId, @Param("loginId") String loginId, @Param("loginType") String loginType, @Param("failReason") String failReason, @Param("ipAddress") String ipAddress, @Param("userAgent") String userAgent); int insertApiAccessLog(@Param("userId") Long userId, @Param("method") String method, @Param("url") String url, @Param("requestParam") String requestParam, @Param("responseCode") String responseCode, @Param("responseTime") Integer responseTime, @Param("ipAddress") String ipAddress, @Param("errorMessage") String errorMessage); int insertDataChangeLog(@Param("userId") Long userId, @Param("menuCode") String menuCode, @Param("tableName") String tableName, @Param("recordId") String recordId, @Param("actionType") String actionType, @Param("beforeJson") String beforeJson, @Param("afterJson") String afterJson, @Param("changedKeys") String changedKeys); List> selectLoginLogs(@Param("param") Map param); List> selectApiAccessLogs(@Param("param") Map param); List> selectDataChangeLogs(@Param("param") Map param); }