mirror of
https://github.com/anyproto/anytype-kotlin.git
synced 2025-06-08 05:47:05 +09:00
DROID-2649 Protocol | Enhancement | 0.35.0-rc5 (#1372)
This commit is contained in:
parent
b2dd0265b6
commit
26ae59d803
21 changed files with 143 additions and 146 deletions
|
@ -5,16 +5,15 @@ import com.anytypeio.anytype.persistence.model.AccountTable
|
|||
|
||||
fun AccountTable.toEntity(): AccountEntity {
|
||||
return AccountEntity(
|
||||
id = id,
|
||||
name = name,
|
||||
color = color
|
||||
id = id
|
||||
)
|
||||
}
|
||||
|
||||
fun AccountEntity.toTable(): AccountTable {
|
||||
return AccountTable(
|
||||
id = id,
|
||||
name = name,
|
||||
timestamp = System.currentTimeMillis()
|
||||
timestamp = System.currentTimeMillis(),
|
||||
name = "",
|
||||
color = null
|
||||
)
|
||||
}
|
|
@ -7,7 +7,9 @@ import com.anytypeio.anytype.persistence.common.Config
|
|||
@Entity(tableName = Config.ACCOUNT_TABLE_NAME)
|
||||
data class AccountTable(
|
||||
@PrimaryKey val id: String,
|
||||
val name: String,
|
||||
val timestamp: Long,
|
||||
val color: String? = null
|
||||
@Deprecated("Should not be used")
|
||||
val color: String? = null,
|
||||
@Deprecated("Should not be used")
|
||||
val name: String,
|
||||
)
|
Loading…
Add table
Add a link
Reference in a new issue