添加阅读记录

pull/326/head
gedoor 4 years ago
parent bcb4a0cb8d
commit c19057c52f
  1. 4
      app/src/main/java/io/legado/app/data/AppDatabase.kt
  2. 11
      app/src/main/java/io/legado/app/data/entities/ReadRecord.kt

@ -18,8 +18,8 @@ import kotlinx.coroutines.launch
entities = [Book::class, BookGroup::class, BookSource::class, BookChapter::class,
ReplaceRule::class, SearchBook::class, SearchKeyword::class, Cookie::class,
RssSource::class, Bookmark::class, RssArticle::class, RssReadRecord::class,
RssStar::class, TxtTocRule::class],
version = 15,
RssStar::class, TxtTocRule::class, ReadRecord::class],
version = 16,
exportSchema = true
)
abstract class AppDatabase : RoomDatabase() {

@ -1,4 +1,11 @@
package io.legado.app.data.entities
class ReadRecord {
}
import androidx.room.Entity
import androidx.room.PrimaryKey
@Entity
data class ReadRecord(
@PrimaryKey
val bookName: String = "",
val readTime: Long = 0L
)
Loading…
Cancel
Save