mirror of
https://github.com/atsunatsu/Look4Sat.git
synced 2026-10-04 03:37:21 +00:00
Fixed too many sql error on selection update
This commit is contained in:
1 parent
c6aae706f9
commit
753a3c823f
1 file changed
+3
-3
@@ -47,12 +47,12 @@ interface EntriesDao {
|
|||||||
@Transaction
|
@Transaction
|
||||||
suspend fun updateEntriesSelection(satIds: List<Int>) {
|
suspend fun updateEntriesSelection(satIds: List<Int>) {
|
||||||
clearSelection()
|
clearSelection()
|
||||||
updateSelection(satIds)
|
satIds.forEach { updateSelection(it) }
|
||||||
}
|
}
|
||||||
|
|
||||||
@Query("UPDATE entries SET isSelected = 0")
|
@Query("UPDATE entries SET isSelected = 0")
|
||||||
suspend fun clearSelection()
|
suspend fun clearSelection()
|
||||||
|
|
||||||
@Query("UPDATE entries SET isSelected = 1 WHERE catNum IN (:satIds)")
|
@Query("UPDATE entries SET isSelected = 1 WHERE catNum = :satId")
|
||||||
suspend fun updateSelection(satIds: List<Int>)
|
suspend fun updateSelection(satId: Int)
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user