package com.pandoli365.bibimbap.mapper;

import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface RbacAuditMapper {

    @Insert("""
            INSERT INTO rbac_audit_log (actor_id, target_id, action, permission_key)
            VALUES (#{actorId}, #{targetId}, #{action}, #{permissionKey})
            """)
    int insert(@Param("actorId") long actorId,
               @Param("targetId") long targetId,
               @Param("action") String action,
               @Param("permissionKey") String permissionKey);
}
