Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fixed build failure #2264

Merged
merged 1 commit into from
Dec 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,12 @@ object FileUtils {
when {
isExternalStorageDocument(uri) -> {
val docId = DocumentsContract.getDocumentId(uri)
val split = docId.split(":")
val split = docId.split(":".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()
val type = split[0]
if ("primary".equals(type, ignoreCase = true)) {
resultPath = "${Environment.getExternalStorageDirectory()}/${split[1]}"
}
// Handle non-primary volumes if necessary
// TODO() Handle non-primary volumes
}
isDownloadsDocument(uri) -> {
val id = DocumentsContract.getDocumentId(uri)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
package com.mifos.feature.passcode

import org.junit.Assert.assertEquals
import org.junit.Test

import org.junit.Assert.*

/**
* Example local unit test, which will execute on the development machine (host).
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ private fun PathTrackingItem(
modifier: Modifier = Modifier,
onPathTrackingClick: (List<UserLatLng>) -> Unit,
) {
val latLngList = getLatLngList(pathTracking.latlng)
val latLngList = getLatLngList(pathTracking.latLng)
val latLng = latLngList[0]
val cameraPositionState = rememberCameraPositionState {
position = CameraPosition.fromLatLngZoom(LatLng(latLng.lat, latLng.lng), 15f)
Expand All @@ -286,7 +286,7 @@ private fun PathTrackingItem(
)
Text(
modifier = Modifier.padding(8.dp),
text = "${pathTracking.date} from ${pathTracking.start_time} to ${pathTracking.stop_time}",
text = "${pathTracking.date} from ${pathTracking.startTime} to ${pathTracking.stopTime}",
style = TextStyle(
fontSize = 16.sp,
fontWeight = FontWeight.Normal,
Expand Down Expand Up @@ -335,10 +335,10 @@ private fun PathTrackingScreenPreview(

val samplePathTrackingList = List(10) {
UserLocation(
user_id = it,
latlng = "123,456",
userId = it,
latLng = "123,456",
date = "date $it",
start_time = "start time $it",
stop_time = "stop time $it",
startTime = "start time $it",
stopTime = "stop time $it",
)
}
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ internal fun ReportDetailScreen(
}

LaunchedEffect(Unit) {
val reportName = "'" + reportItem.report_name + "'"
val reportName = "'" + reportItem.reportName + "'"
viewModel.fetchFullParameterList(reportName, true)
}

Expand All @@ -180,7 +180,7 @@ internal fun ReportDetailScreen(
reportProducts = reportProducts,
runReport = { mapQuery ->
runReportEnable = true
reportItem.report_name?.let {
reportItem.reportName?.let {
viewModel.fetchRunReportWithQuery(it, mapQuery)
}
},
Expand Down Expand Up @@ -380,7 +380,7 @@ private fun RunReportContent(
.weight(1f)
.padding(start = 16.dp),
) {
reportItem.report_name?.let {
reportItem.reportName?.let {
Text(
text = it,
style = TextStyle(
Expand All @@ -398,7 +398,7 @@ private fun RunReportContent(
horizontalArrangement = Arrangement.SpaceBetween,
) {
Text(
text = reportItem.report_type.toString(),
text = reportItem.reportType.toString(),
style = TextStyle(
fontSize = 14.sp,
fontWeight = FontWeight.Normal,
Expand All @@ -407,7 +407,7 @@ private fun RunReportContent(
),
)
Text(
text = reportItem.report_category.toString(),
text = reportItem.reportCategory.toString(),
style = TextStyle(
fontSize = 14.sp,
fontWeight = FontWeight.Normal,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ private fun RunReportCardItem(
.weight(1f)
.padding(start = 16.dp),
) {
report.report_name?.let {
report.reportName?.let {
Text(
text = it,
style = TextStyle(
Expand All @@ -294,7 +294,7 @@ private fun RunReportCardItem(
horizontalArrangement = Arrangement.SpaceBetween,
) {
Text(
text = report.report_type.toString(),
text = report.reportType.toString(),
style = TextStyle(
fontSize = 14.sp,
fontWeight = FontWeight.Normal,
Expand All @@ -303,7 +303,7 @@ private fun RunReportCardItem(
),
)
Text(
text = report.report_category.toString(),
text = report.reportCategory.toString(),
style = TextStyle(
fontSize = 14.sp,
fontWeight = FontWeight.Normal,
Expand Down Expand Up @@ -353,8 +353,8 @@ private fun RunReportPreview(

val sampleRunReports = List(10) {
ClientReportTypeItem(
report_name = "Report $it",
report_type = "Type $it",
report_category = "Category $it",
reportName = "Report $it",
reportType = "Type $it",
reportCategory = "Category $it",
)
}
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ androidDesugarJdkLibs = "2.0.4"
androidIconifyMaterial = "2.2.2"
androidJob = "1.2.6"
androidMapsUtils = "0.4.2"
androidGradlePlugin = "8.5.0"
androidGradlePlugin = "8.7.3"
androidTools = "31.6.0"
androidxActivity = "1.8.2"
androidxAppCompat = "1.6.1"
Expand Down
Loading