Change createAppeal method in AppealMapper to return UUID, adjust AppealController to construct Appeal with generated UUID.

This commit is contained in:
2025-08-14 01:37:57 +02:00
parent 24d7cfe913
commit eaee31ab2b
2 changed files with 9 additions and 5 deletions
@@ -1,12 +1,12 @@
package com.alttd.altitudeweb.database.web_db.forms;
import com.alttd.altitudeweb.model.MinecraftAppealDto;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Options;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import java.util.List;
import java.util.UUID;
public interface AppealMapper {
@@ -15,7 +15,7 @@ public interface AppealMapper {
VALUES (#{uuid}, #{username}, #{reason}, #{createdAt}, #{sendAt}, #{email}, #{assignedTo})
""")
@Options(useGeneratedKeys = true, keyProperty = "id")
Appeal createAppeal(Appeal appeal);
UUID createAppeal(Appeal appeal);
@Update("""
UPDATE appeals