fix
This commit is contained in:
@@ -29,6 +29,22 @@ android {
|
||||
}
|
||||
|
||||
buildConfigField("String", "API_BASE_URL", "\"${project.findProperty("API_BASE_URL")}\"")
|
||||
|
||||
// Add backend/port buildConfig fields derived from gradle.properties (with safe defaults)
|
||||
buildConfigField("String", "BACKEND_HOST", "\"${project.findProperty("BASE_URL") ?: "10.0.2.2"}\"")
|
||||
buildConfigField("String", "API_PORT", "\"${project.findProperty("API_PORT") ?: "8002"}\"")
|
||||
buildConfigField("String", "WS_PORT", "\"${project.findProperty("WS_PORT") ?: "8003"}\"")
|
||||
|
||||
buildConfigField(
|
||||
"String",
|
||||
"EMERGENCY_API_BASE",
|
||||
"\"http://${project.findProperty("BASE_URL") ?: "10.0.2.2"}:${project.findProperty("API_PORT") ?: "8002"}/\""
|
||||
)
|
||||
buildConfigField(
|
||||
"String",
|
||||
"EMERGENCY_WS_BASE",
|
||||
"\"ws://${project.findProperty("BASE_URL") ?: "10.0.2.2"}:${project.findProperty("WS_PORT") ?: "8002"}/api/v1/\""
|
||||
)
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
@@ -99,12 +115,15 @@ dependencies {
|
||||
implementation("androidx.navigation:navigation-fragment-ktx:2.7.7")
|
||||
implementation("androidx.navigation:navigation-ui-ktx:2.7.7")
|
||||
|
||||
// ViewBinding
|
||||
implementation("androidx.databinding:databinding-runtime:8.2.2")
|
||||
implementation("androidx.appcompat:appcompat:1.6.1")
|
||||
// Emergency Module dependencies
|
||||
implementation("com.google.android.gms:play-services-location:21.0.1")
|
||||
implementation("com.google.accompanist:accompanist-permissions:0.32.0")
|
||||
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.7.0")
|
||||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.7.3")
|
||||
implementation("com.google.android.gms:play-services-maps:18.2.0")
|
||||
|
||||
// Testing dependencies
|
||||
testImplementation(libs.junit)
|
||||
testImplementation("io.mockk:mockk:1.13.8")
|
||||
androidTestImplementation(libs.androidx.junit)
|
||||
androidTestImplementation(libs.androidx.espresso.core)
|
||||
androidTestImplementation(platform(libs.androidx.compose.bom))
|
||||
|
||||
Reference in New Issue
Block a user