feat: update database schema and configuration for Flyway integration and refactor table names

This commit is contained in:
siujamo
2026-03-19 10:54:50 +08:00
parent 7c9f9c35f9
commit 484a9f4a71
10 changed files with 145 additions and 142 deletions
@@ -4,9 +4,9 @@
<mapper namespace="com.onixbyte.helix.mapper.AuthorityMapper">
<select id="selectByUserId" parameterType="long">
SELECT DISTINCT a.id, a.code, a.name, a.description, a.status, a.created_at, a.updated_at
FROM authorities a
JOIN role_authorities ra ON a.id = ra.authority_id
JOIN user_roles ur ON ra.role_id = ur.role_id
FROM authority a
JOIN role_authority ra ON a.id = ra.authority_id
JOIN user_role ur ON ra.role_id = ur.role_id
WHERE ur.user_id = #{userId}
</select>
</mapper>