Merge branch 'dev' of https://github.com/nightscout/AndroidAPS into dev
This commit is contained in:
commit
83a8d90cf3
2 changed files with 5 additions and 5 deletions
|
@ -6,14 +6,13 @@ import androidx.room.TypeConverters
|
||||||
import info.nightscout.androidaps.database.daos.*
|
import info.nightscout.androidaps.database.daos.*
|
||||||
import info.nightscout.androidaps.database.entities.*
|
import info.nightscout.androidaps.database.entities.*
|
||||||
|
|
||||||
const val DATABASE_VERSION = 2
|
const val DATABASE_VERSION = 3
|
||||||
|
|
||||||
@Database(version = DATABASE_VERSION,
|
@Database(version = DATABASE_VERSION,
|
||||||
entities = arrayOf(APSResult::class, Bolus::class, BolusCalculatorResult::class, Carbs::class,
|
entities = [APSResult::class, Bolus::class, BolusCalculatorResult::class, Carbs::class,
|
||||||
EffectiveProfileSwitch::class, ExtendedBolus::class, GlucoseValue::class, ProfileSwitch::class,
|
EffectiveProfileSwitch::class, ExtendedBolus::class, GlucoseValue::class, ProfileSwitch::class,
|
||||||
TemporaryBasal::class, TemporaryTarget::class, TherapyEvent::class, TotalDailyDose::class,
|
TemporaryBasal::class, TemporaryTarget::class, TherapyEvent::class, TotalDailyDose::class, APSResultLink::class,
|
||||||
APSResultLink::class, MealLink::class, MultiwaveBolusLink::class, PreferenceChange::class,
|
MealLink::class, MultiwaveBolusLink::class, PreferenceChange::class, VersionChange::class, UserEntry::class],
|
||||||
VersionChange::class, UserEntry::class),
|
|
||||||
exportSchema = true)
|
exportSchema = true)
|
||||||
@TypeConverters(Converters::class)
|
@TypeConverters(Converters::class)
|
||||||
internal abstract class AppDatabase : RoomDatabase() {
|
internal abstract class AppDatabase : RoomDatabase() {
|
||||||
|
|
|
@ -22,6 +22,7 @@ open class DatabaseModule {
|
||||||
Room
|
Room
|
||||||
.databaseBuilder(context, AppDatabase::class.java, fileName)
|
.databaseBuilder(context, AppDatabase::class.java, fileName)
|
||||||
.addMigrations(migration1to2)
|
.addMigrations(migration1to2)
|
||||||
|
.fallbackToDestructiveMigration()
|
||||||
.build()
|
.build()
|
||||||
|
|
||||||
@Qualifier
|
@Qualifier
|
||||||
|
|
Loading…
Reference in a new issue