fixing errors related to version
This commit is contained in:
@@ -42,9 +42,9 @@ android {
|
||||
|
||||
dependencies {
|
||||
|
||||
implementation 'androidx.core:core-ktx:1.10.1'
|
||||
implementation 'androidx.core:core-ktx:1.12.0'
|
||||
implementation 'androidx.appcompat:appcompat:1.6.1'
|
||||
implementation 'com.google.android.material:material:1.9.0'
|
||||
implementation 'com.google.android.material:material:1.10.0'
|
||||
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
|
||||
testImplementation 'junit:junit:4.13.2'
|
||||
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
|
||||
@@ -58,26 +58,26 @@ dependencies {
|
||||
implementation 'com.google.firebase:firebase-auth-ktx'
|
||||
implementation 'com.google.firebase:firebase-storage-ktx'
|
||||
implementation 'com.firebaseui:firebase-ui-firestore:8.0.2'
|
||||
implementation 'com.google.android.gms:play-services-auth:20.6.0'
|
||||
implementation 'com.google.firebase:firebase-appdistribution:16.0.0-beta10'
|
||||
implementation("com.google.firebase:firebase-appdistribution-api-ktx:16.0.0-beta10")
|
||||
implementation 'com.google.android.gms:play-services-auth:20.7.0'
|
||||
implementation 'com.google.firebase:firebase-appdistribution:16.0.0-beta11'
|
||||
implementation("com.google.firebase:firebase-appdistribution-api-ktx:16.0.0-beta11")
|
||||
|
||||
// Coroutines
|
||||
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.7.1'
|
||||
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.1'
|
||||
|
||||
// Coroutine Lifecycle Scopes
|
||||
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.1"
|
||||
implementation "androidx.lifecycle:lifecycle-runtime-ktx:2.6.1"
|
||||
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.2"
|
||||
implementation "androidx.lifecycle:lifecycle-runtime-ktx:2.6.2"
|
||||
|
||||
//Dagger - Hilt
|
||||
implementation "com.google.dagger:hilt-android:2.46"
|
||||
kapt "com.google.dagger:hilt-android-compiler:2.46"
|
||||
kapt "androidx.hilt:hilt-compiler:1.0.0"
|
||||
kapt "androidx.hilt:hilt-compiler:1.1.0"
|
||||
|
||||
// Navigation Component
|
||||
implementation "androidx.navigation:navigation-fragment-ktx:2.7.0"
|
||||
implementation "androidx.navigation:navigation-ui-ktx:2.7.0"
|
||||
implementation "androidx.navigation:navigation-fragment-ktx:2.7.5"
|
||||
implementation "androidx.navigation:navigation-ui-ktx:2.7.5"
|
||||
|
||||
// Retrofit + GSON
|
||||
implementation "com.squareup.retrofit2:retrofit:2.9.0"
|
||||
@@ -87,16 +87,16 @@ dependencies {
|
||||
implementation 'com.jakewharton.timber:timber:4.7.1'
|
||||
|
||||
// Activity KTX for viewModels()
|
||||
implementation "androidx.activity:activity-ktx:1.7.2"
|
||||
implementation "androidx.activity:activity-ktx:1.8.1"
|
||||
|
||||
//image
|
||||
implementation 'com.github.bumptech.glide:glide:4.13.2'
|
||||
annotationProcessor 'com.github.bumptech.glide:compiler:4.13.2'
|
||||
|
||||
//Room
|
||||
implementation "androidx.room:room-ktx:2.6.0-alpha03"
|
||||
implementation "androidx.room:room-runtime:2.6.0-alpha03"
|
||||
kapt ("androidx.room:room-compiler:2.6.0-alpha03")
|
||||
implementation "androidx.room:room-ktx:2.6.1"
|
||||
implementation "androidx.room:room-runtime:2.6.1"
|
||||
kapt ("androidx.room:room-compiler:2.6.1")
|
||||
|
||||
// Barcode scanner
|
||||
implementation 'com.journeyapps:zxing-android-embedded:4.3.0'
|
||||
|
||||
@@ -1,11 +1,36 @@
|
||||
package com.example.hposregistration.dao
|
||||
|
||||
import android.content.Context
|
||||
import androidx.room.Database
|
||||
import androidx.room.Room
|
||||
import androidx.room.RoomDatabase
|
||||
import androidx.room.TypeConverters
|
||||
import androidx.room.migration.Migration
|
||||
import androidx.sqlite.db.SupportSQLiteDatabase
|
||||
import com.example.hposregistration.data.user.UserData
|
||||
|
||||
@Database(entities = [UserData::class], version = 1, exportSchema = false)
|
||||
@Database(entities = [UserData::class], version = 3, exportSchema = false)
|
||||
abstract class MyDatabase : RoomDatabase() {
|
||||
|
||||
abstract fun userDao(): UserDao
|
||||
}
|
||||
|
||||
companion object {
|
||||
val MIGRATION_2_3: Migration = object : Migration(2, 3) {
|
||||
override fun migrate(database: SupportSQLiteDatabase) {
|
||||
// Define the necessary SQL statements for migration from version 2 to 3
|
||||
// For example, you can alter tables or create new ones
|
||||
database.execSQL("ALTER TABLE user_table ADD COLUMN aadharIdSearch TEXT")
|
||||
}
|
||||
}
|
||||
|
||||
fun getInstance(context: Context): MyDatabase {
|
||||
return Room.databaseBuilder(
|
||||
context.applicationContext,
|
||||
MyDatabase::class.java,
|
||||
"my_database"
|
||||
)
|
||||
.addMigrations(MIGRATION_2_3)
|
||||
.build()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,4 +27,7 @@ class UserDao {
|
||||
// suspend fun getPatientList(): List<UserData> {
|
||||
// return patientCollection.get().await().toObjects(UserData::class.java)
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user