pull/46/head
parent
3e7f38e584
commit
aa4f7512d0
@ -1,12 +0,0 @@ |
|||||||
package io.legado.app.data.dao |
|
||||||
|
|
||||||
import androidx.room.Dao |
|
||||||
import androidx.room.Query |
|
||||||
|
|
||||||
@Dao |
|
||||||
interface SourceCookieDao { |
|
||||||
|
|
||||||
@Query("SELECT cookie FROM cookies Where url = :url") |
|
||||||
fun getCookieByUrl(url: String): String? |
|
||||||
|
|
||||||
} |
|
@ -1,11 +1,12 @@ |
|||||||
package io.legado.app.data.entities |
package io.legado.app.data.entities |
||||||
|
|
||||||
import androidx.room.Entity |
import androidx.room.Entity |
||||||
|
import androidx.room.Index |
||||||
import androidx.room.PrimaryKey |
import androidx.room.PrimaryKey |
||||||
|
|
||||||
@Entity(tableName = "cookies") |
@Entity(tableName = "cookies", indices = [(Index(value = ["url"], unique = true))]) |
||||||
data class Cookie( |
data class Cookie( |
||||||
@PrimaryKey |
@PrimaryKey |
||||||
var url: String = "", |
var url: String = "", |
||||||
var cookie: String? = null |
var cookie: String = "" |
||||||
) |
) |
@ -1,12 +0,0 @@ |
|||||||
package io.legado.app.data.entities |
|
||||||
|
|
||||||
import androidx.room.Entity |
|
||||||
import androidx.room.Index |
|
||||||
import androidx.room.PrimaryKey |
|
||||||
|
|
||||||
@Entity(tableName = "cookies", indices = [(Index(value = ["url"], unique = true))]) |
|
||||||
data class SourceCookie( |
|
||||||
@PrimaryKey |
|
||||||
var url: String = "", |
|
||||||
var cookie: String = "" |
|
||||||
) |
|
Loading…
Reference in new issue