Skip to content

Commit

Permalink
Show no location dialog on missing sync location ids
Browse files Browse the repository at this point in the history
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
  • Loading branch information
ellykits committed Oct 23, 2024
1 parent 6f77fe5 commit 0752ea2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import androidx.lifecycle.viewModelScope
import com.google.android.fhir.datacapture.extensions.logicalId
import dagger.hilt.android.lifecycle.HiltViewModel
import dagger.hilt.android.qualifiers.ApplicationContext
import javax.inject.Inject
import kotlinx.coroutines.flow.MutableSharedFlow
import kotlinx.coroutines.flow.asSharedFlow
import kotlinx.coroutines.launch
Expand Down Expand Up @@ -62,6 +61,7 @@ import org.smartregister.fhircore.quest.R
import org.smartregister.fhircore.quest.ui.shared.QuestionnaireHandler
import org.smartregister.fhircore.quest.util.extensions.referenceToBitmap
import timber.log.Timber
import javax.inject.Inject

@HiltViewModel
class GeoWidgetLauncherViewModel
Expand Down Expand Up @@ -271,7 +271,7 @@ constructor(
suspend fun showNoLocationDialog(geoWidgetConfiguration: GeoWidgetConfiguration) {
geoWidgetConfiguration.noResults?.let {
_noLocationFoundDialog.postValue(

Check warning on line 273 in android/quest/src/main/java/org/smartregister/fhircore/quest/ui/geowidget/GeoWidgetLauncherViewModel.kt

View check run for this annotation

Codecov / codecov/patch

android/quest/src/main/java/org/smartregister/fhircore/quest/ui/geowidget/GeoWidgetLauncherViewModel.kt#L273

Added line #L273 was not covered by tests
context.retrieveRelatedEntitySyncLocationState(MultiSelectViewAction.FILTER_DATA).isEmpty(),
context.retrieveRelatedEntitySyncLocationState(MultiSelectViewAction.SYNC_DATA).isEmpty(),
)
}
}
Expand Down

0 comments on commit 0752ea2

Please sign in to comment.