Link party IDs to users in chat: added getPartyId query, updated EventUser with partyId field, and adjusted message filtering logic in ChatService.
This commit is contained in:
@@ -4,6 +4,7 @@ import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
public interface ChatLogMapper {
|
||||
|
||||
@@ -15,4 +16,10 @@ public interface ChatLogMapper {
|
||||
""")
|
||||
List<ChatLogDao> getChatLogs(@Param("since") long since);
|
||||
|
||||
@Select("""
|
||||
SELECT party_id FROM chat_users
|
||||
WHERE uuid = #{uuid}
|
||||
""")
|
||||
Optional<Integer> getPartyId(@Param("uuid") String uuid);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user