@@ -28,6 +28,7 @@
|
||||
package net.locusworks.discord.eighttrack.database.repos;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.data.repository.CrudRepository;
|
||||
@@ -53,4 +54,9 @@ public interface GuildSongRepository extends CrudRepository<GuildSong, Long> {
|
||||
@Query("SELECT gs FROM GuildSong gs WHERE gs.guild.guildId = ?1 ORDER BY RAND()")
|
||||
List<GuildSong> findRandomSong(Long guildId);
|
||||
|
||||
List<GuildSong> findByGuildAndUuidIn(DiscordGuild guild, Set<String> uuid);
|
||||
|
||||
@Query("SELECT gs FROM GuildSong gs WHERE gs.guild.guildId = ?1 AND gs.uuid = ?2")
|
||||
List<GuildSong> findByGuildAndUuidIn(Long guildId, Set<String> uuid);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user