[WIP] first draft implementing mucus

This commit is contained in:
emelko
2018-07-04 13:03:23 +02:00
parent 7dee497431
commit 2b5e6351f7
5 changed files with 159 additions and 9 deletions
+15 -1
View File
@@ -18,6 +18,15 @@ const BleedingSchema = {
}
}
const MucusSchema = {
name: 'Mucus',
properties: {
feeling: 'int',
texture: 'int',
exclude: 'bool'
}
}
const CycleDaySchema = {
name: 'CycleDay',
primaryKey: 'date',
@@ -30,6 +39,10 @@ const CycleDaySchema = {
bleeding: {
type: 'Bleeding',
optional: true
},
mucus: {
type: 'Mucus',
optional: true
}
}
}
@@ -38,7 +51,8 @@ const db = new Realm({
schema: [
CycleDaySchema,
TemperatureSchema,
BleedingSchema
BleedingSchema,
MucusSchema
],
// we only want this in dev mode
deleteRealmIfMigrationNeeded: true