From 6e177fd859b347e6af1d4cbaf035e437e0e97737 Mon Sep 17 00:00:00 2001 From: Aleem92 <129393448+Aleem92@users.noreply.github.com> Date: Sun, 1 Dec 2024 16:49:33 +0500 Subject: [PATCH 1/2] Fixed the sticky bottom padding in the profile screen (#3590) Co-authored-by: Allan Onchuru <16164649+allan-on@users.noreply.github.com> --- .../quest/ui/profile/ProfileScreen.kt | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/android/quest/src/main/java/org/smartregister/fhircore/quest/ui/profile/ProfileScreen.kt b/android/quest/src/main/java/org/smartregister/fhircore/quest/ui/profile/ProfileScreen.kt index 1bcc672edd..45f37213b8 100644 --- a/android/quest/src/main/java/org/smartregister/fhircore/quest/ui/profile/ProfileScreen.kt +++ b/android/quest/src/main/java/org/smartregister/fhircore/quest/ui/profile/ProfileScreen.kt @@ -26,6 +26,7 @@ import androidx.compose.foundation.layout.Row import androidx.compose.foundation.layout.Spacer import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size import androidx.compose.foundation.layout.width @@ -161,15 +162,6 @@ fun ProfileScreen( } LazyColumn( state = lazyListState, - modifier = - Modifier.padding( - bottom = - if (!fabActions.isNullOrEmpty() && fabActions.first().visible) { - PADDING_BOTTOM_WITH_FAB.dp - } else { - PADDING_BOTTOM_WITHOUT_FAB.dp - }, - ), ) { item(key = profileUiState.resourceData?.baseResourceId) { ViewRenderer( @@ -180,6 +172,18 @@ fun ProfileScreen( decodeImage = decodeImage, ) } + item { + Spacer( + modifier = + Modifier.height( + if (!fabActions.isNullOrEmpty() && fabActions.first().visible) { + PADDING_BOTTOM_WITH_FAB.dp + } else { + PADDING_BOTTOM_WITHOUT_FAB.dp + }, + ), + ) + } } } } From 6197f7d41e1c593d35e7c86d2494ea420681aae4 Mon Sep 17 00:00:00 2001 From: Martin Ndegwa Date: Sun, 1 Dec 2024 15:44:02 +0300 Subject: [PATCH 2/2] Migrate FHIR SDK Artifacts to the latest version changes (#3640) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Migrate FHIR SDK Artifacts to the latest version changes * Reduce the verbosity of logs on CI 🧱 * Refactor FhirCarePlanGeneratorTest unit test for Future Proofing 💚 --------- Co-authored-by: Benjamin Mwalimu --- .../engine/task/FhirCarePlanGeneratorTest.kt | 30 ++++++++++++++----- .../plans/anc-visit/plandefinition.json | 1 + android/gradle.properties | 5 +--- android/gradle/libs.versions.toml | 4 +-- 4 files changed, 27 insertions(+), 13 deletions(-) diff --git a/android/engine/src/test/java/org/smartregister/fhircore/engine/task/FhirCarePlanGeneratorTest.kt b/android/engine/src/test/java/org/smartregister/fhircore/engine/task/FhirCarePlanGeneratorTest.kt index e0ff0dd89e..fefc5033f4 100644 --- a/android/engine/src/test/java/org/smartregister/fhircore/engine/task/FhirCarePlanGeneratorTest.kt +++ b/android/engine/src/test/java/org/smartregister/fhircore/engine/task/FhirCarePlanGeneratorTest.kt @@ -1246,15 +1246,31 @@ class FhirCarePlanGeneratorTest : RobolectricTest() { "\$this + 3 'month'", )!! .value + + val expectedAssertionDates: MutableList = + mutableListOf( + fhirCarePlanGenerator + .evaluateToDate( + DateTimeType(ancStart), + "\$this + 1 'month'", + )!! + .value, + ) + + for (index in 1 until this.size) { + expectedAssertionDates.add( + fhirCarePlanGenerator + .evaluateToDate( + DateTimeType(expectedAssertionDates.last()), + "\$this + 1 'month'", + )!! + .value, + ) + } + this.forEachIndexed { index, task -> assertEquals( - (fhirCarePlanGenerator - .evaluateToDate( - DateTimeType(ancStart), - "\$this + ${index + 1} 'month'", - )!! - .value) - .asYyyyMmDd(), + expectedAssertionDates[index].asYyyyMmDd(), task.executionPeriod.start.asYyyyMmDd(), ) } diff --git a/android/engine/src/test/resources/plans/anc-visit/plandefinition.json b/android/engine/src/test/resources/plans/anc-visit/plandefinition.json index 34485d3112..f03a0887be 100644 --- a/android/engine/src/test/resources/plans/anc-visit/plandefinition.json +++ b/android/engine/src/test/resources/plans/anc-visit/plandefinition.json @@ -1,6 +1,7 @@ { "resourceType": "PlanDefinition", "id": "132157", + "url": "https://my-opensrp-server.org/my/globally/unique/url/132157", "meta": { "versionId": "1", "lastUpdated": "2022-06-20T22:30:39.217+00:00" diff --git a/android/gradle.properties b/android/gradle.properties index 262a8849e7..4163bed138 100644 --- a/android/gradle.properties +++ b/android/gradle.properties @@ -21,13 +21,10 @@ android.enableJetifier=true android.defaults.buildfeatures.buildconfig=true android.suppressUnsupportedCompileSdk=34 android.jetifier.ignorelist=jackson-core -org.gradle.warning.mode=all - -org.gradle.logging.level=INFO +org.gradle.warning.mode=all org.gradle.caching=false org.gradle.parallel=true org.gradle.configureondemand=true android.enableR8.fullMode=true -android.enableR8.verbose=true diff --git a/android/gradle/libs.versions.toml b/android/gradle/libs.versions.toml index b4e18b95e4..bf1326ee09 100644 --- a/android/gradle/libs.versions.toml +++ b/android/gradle/libs.versions.toml @@ -27,8 +27,8 @@ espresso-core = "3.6.1" fhir-sdk-common = "0.1.0-alpha05-preview3-SNAPSHOT" fhir-sdk-contrib-barcode = "0.1.0-beta3-preview7-rc1-SNAPSHOT" fhir-sdk-contrib-locationwidget = "0.1.0-alpha01-preview2-rc1-SNAPSHOT" -fhir-sdk-data-capture = "1.2.0-preview4-SNAPSHOT" -fhir-sdk-engine = "1.0.0-preview16-SNAPSHOT" +fhir-sdk-data-capture = "1.2.0-preview5-SNAPSHOT" +fhir-sdk-engine = "1.0.0-preview17-SNAPSHOT" fhir-sdk-knowledge = "0.1.0-alpha03-preview5-rc1-SNAPSHOT" fhir-sdk-workflow = "0.1.0-alpha04-preview10-rc1-SNAPSHOT" fragment-ktx = "1.8.3"