I ran into two issues when using Brick + SQLite:
Serialization of nested objects with custom generators
@Sqlite(
columnType: Column.text,
fromGenerator: "PhoneMeta.fromJson(jsonDecode(%DATA_PROPERTY%))",
toGenerator: "%INSTANCE_PROPERTY% == null ? null : jsonEncode(%INSTANCE_PROPERTY%?.toJson())"
)
final PhoneMeta? phone;
When select I got an error
WherePhrase([
Where.exact("creatorId", currUser.localId),
WherePhrase([
Or("email").isExactly(email),
Or("phone").isExactly(phone) // <<<====
])
])
Invalid argument(s): Field phone on Person is not serialized by SQLite
Isn't I already define it as text type column. Why is it still throw error?
I ran into two issues when using Brick + SQLite:
Serialization of nested objects with custom generators
When select I got an error
Isn't I already define it as text type column. Why is it still throw error?