Skip to content

Commit ddab8ad

Browse files
authored
documentation added properly. (openMF#2979)
1 parent 7702fcb commit ddab8ad

File tree

25 files changed

+689
-17
lines changed

25 files changed

+689
-17
lines changed

.run/cmp-web-wasm.run.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</option>
1111
<option name="taskNames">
1212
<list>
13-
<option value=":cmp-web:wasmJsBrowserRun" />
13+
<option value=":cmp-web:wasmJsBrowserDevelopmentRun" />
1414
</list>
1515
</option>
1616
<option name="vmOptions" />

ci-prepush.sh

100644100755
File mode changed.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* Copyright 2025 Mifos Initiative
3+
*
4+
* This Source Code Form is subject to the terms of the Mozilla Public
5+
* License, v. 2.0. If a copy of the MPL was not distributed with this
6+
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7+
*
8+
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md
9+
*/
10+
package cmp.navigation.authenticated
11+
12+
import org.mifos.mobile.feature.beneficiary.beneficiaryApplicationConfirmation.BeneficiaryApplicationConfirmationNavRoute
13+
import org.mifos.mobile.feature.loan.application.confirmDetails.ConfirmDetailsRoute
14+
import org.mifos.mobile.feature.transfer.process.transferProcess.TransferProcessRoute
15+
16+
actual fun getPopRules(): Map<String, Int> = mapOf(
17+
ConfirmDetailsRoute::class.qualifiedName.orEmpty() to 2,
18+
TransferProcessRoute::class.qualifiedName.orEmpty() to 2,
19+
BeneficiaryApplicationConfirmationNavRoute::class.qualifiedName.orEmpty() to 2,
20+
)
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* Copyright 2025 Mifos Initiative
3+
*
4+
* This Source Code Form is subject to the terms of the Mozilla Public
5+
* License, v. 2.0. If a copy of the MPL was not distributed with this
6+
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7+
*
8+
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md
9+
*/
10+
package cmp.navigation.authenticated
11+
12+
import org.mifos.mobile.feature.beneficiary.beneficiaryApplicationConfirmation.BeneficiaryApplicationConfirmationNavRoute
13+
import org.mifos.mobile.feature.loan.application.confirmDetails.ConfirmDetailsRoute
14+
import org.mifos.mobile.feature.transfer.process.transferProcess.TransferProcessRoute
15+
16+
actual fun getPopRules(): Map<String, Int> = mapOf(
17+
ConfirmDetailsRoute::class.qualifiedName.orEmpty() to 2,
18+
TransferProcessRoute::class.qualifiedName.orEmpty() to 2,
19+
BeneficiaryApplicationConfirmationNavRoute::class.qualifiedName.orEmpty() to 2,
20+
)

cmp-navigation/src/commonMain/kotlin/cmp/navigation/authenticated/AuthenticatedNavigation.kt

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,13 @@ import org.mifos.mobile.feature.accounts.accounts.navigateToAccountsScreen
3333
import org.mifos.mobile.feature.auth.login.navigateToLoginScreen
3434
import org.mifos.mobile.feature.auth.navigation.AuthGraphRoute
3535
import org.mifos.mobile.feature.beneficiary.beneficiaryApplication.navigateToManualBeneficiaryAddScreen
36-
import org.mifos.mobile.feature.beneficiary.beneficiaryApplicationConfirmation.BeneficiaryApplicationConfirmationNavRoute
3736
import org.mifos.mobile.feature.beneficiary.navigation.BeneficiaryNavRoute
3837
import org.mifos.mobile.feature.beneficiary.navigation.beneficiaryNavGraph
3938
import org.mifos.mobile.feature.beneficiary.navigation.navigateToBeneficiaryNavGraph
4039
import org.mifos.mobile.feature.charge.charges.navigateToClientChargeScreen
4140
import org.mifos.mobile.feature.charge.navigation.clientChargeNavGraph
4241
import org.mifos.mobile.feature.charge.navigation.navigateToChargeGraph
4342
import org.mifos.mobile.feature.home.navigation.HomeNavigationDestination
44-
import org.mifos.mobile.feature.loan.application.confirmDetails.ConfirmDetailsRoute
4543
import org.mifos.mobile.feature.loan.application.navigation.loanApplicationNavGraph
4644
import org.mifos.mobile.feature.loan.application.navigation.navigateToLoanApplicationGraph
4745
import org.mifos.mobile.feature.loanaccount.loanAccountDetails.navigateToLoanAccountDetailsScreen
@@ -69,13 +67,14 @@ import org.mifos.mobile.feature.status.navigation.statusDestination
6967
import org.mifos.mobile.feature.third.party.transfer.navigation.TptNavigationDestination
7068
import org.mifos.mobile.feature.transfer.process.makeTransfer.makeTransferDestination
7169
import org.mifos.mobile.feature.transfer.process.makeTransfer.navigateToMakeTransferScreen
72-
import org.mifos.mobile.feature.transfer.process.transferProcess.TransferProcessRoute
7370
import org.mifos.mobile.feature.transfer.process.transferProcess.navigateToTransferProcessScreen
7471
import org.mifos.mobile.feature.transfer.process.transferProcess.transferProcessDestination
7572

7673
@Serializable
7774
internal data object AuthenticatedGraphRoute
7875

76+
expect fun getPopRules(): Map<String, Int>
77+
7978
internal fun NavController.navigateToAuthenticatedGraph(navOptions: NavOptions? = null) {
8079
navigate(route = AuthenticatedGraphRoute, navOptions = navOptions)
8180
}
@@ -471,11 +470,7 @@ fun NavController.navigateToBeneficiaryFromStatus() {
471470
}
472471

473472
fun NavController.popScreens(
474-
popRules: Map<String, Int> = mapOf(
475-
ConfirmDetailsRoute::class.qualifiedName.orEmpty() to 2,
476-
TransferProcessRoute::class.qualifiedName.orEmpty() to 2,
477-
BeneficiaryApplicationConfirmationNavRoute::class.qualifiedName.orEmpty() to 2,
478-
),
473+
popRules: Map<String, Int> = getPopRules(),
479474
) {
480475
val lastEntry = previousBackStackEntry?.destination?.route
481476

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/*
2+
* Copyright 2025 Mifos Initiative
3+
*
4+
* This Source Code Form is subject to the terms of the Mozilla Public
5+
* License, v. 2.0. If a copy of the MPL was not distributed with this
6+
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7+
*
8+
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md
9+
*/
10+
package cmp.navigation.authenticated
11+
12+
import org.mifos.mobile.feature.beneficiary.beneficiaryApplicationConfirmation.BeneficiaryApplicationConfirmationNavRoute
13+
import org.mifos.mobile.feature.loan.application.confirmDetails.ConfirmDetailsRoute
14+
import org.mifos.mobile.feature.transfer.process.transferProcess.TransferProcessRoute
15+
16+
actual fun getPopRules(): Map<String, Int> = mapOf(
17+
ConfirmDetailsRoute::class.qualifiedName.orEmpty() to 2,
18+
TransferProcessRoute::class.qualifiedName.orEmpty() to 2,
19+
BeneficiaryApplicationConfirmationNavRoute::class.qualifiedName.orEmpty() to 2,
20+
)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/*
2+
* Copyright 2025 Mifos Initiative
3+
*
4+
* This Source Code Form is subject to the terms of the Mozilla Public
5+
* License, v. 2.0. If a copy of the MPL was not distributed with this
6+
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7+
*
8+
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md
9+
*/
10+
package cmp.navigation.authenticated
11+
12+
actual fun getPopRules(): Map<String, Int> = mapOf(
13+
"cmp.navigation.authenticated.ConfirmDetailsRoute" to 2,
14+
"cmp.navigation.authenticated.TransferProcessRoute" to 2,
15+
"cmp.navigation.authenticated.BeneficiaryApplicationConfirmationNavRoute" to 2,
16+
)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/*
2+
* Copyright 2025 Mifos Initiative
3+
*
4+
* This Source Code Form is subject to the terms of the Mozilla Public
5+
* License, v. 2.0. If a copy of the MPL was not distributed with this
6+
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7+
*
8+
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md
9+
*/
10+
package cmp.navigation.authenticated
11+
12+
actual fun getPopRules(): Map<String, Int> = mapOf(
13+
"cmp.navigation.authenticated.ConfirmDetailsRoute" to 2,
14+
"cmp.navigation.authenticated.TransferProcessRoute" to 2,
15+
"cmp.navigation.authenticated.BeneficiaryApplicationConfirmationNavRoute" to 2,
16+
)

cmp-web/build.gradle.kts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ kotlin {
5959
}
6060
}
6161

62+
tasks.register("jsBrowserRun") {
63+
dependsOn("jsBrowserDevelopmentRun")
64+
}
65+
6266
compose.resources {
6367
publicResClass = true
6468
generateResClass = always

feature/beneficiary/src/commonMain/kotlin/org/mifos/mobile/feature/beneficiary/beneficiaryApplication/BeneficiaryApplicationContent.kt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,13 @@ import org.mifos.mobile.core.designsystem.theme.MifosTypography
5050
import org.mifos.mobile.core.model.enums.BeneficiaryState
5151
import org.mifos.mobile.core.ui.component.MifosDropDownTextField
5252

53+
/**
54+
* Composable function to display a beneficiary application form.
55+
*
56+
* @param state The current state of the beneficiary application form.
57+
* @param onAction A callback to handle actions from the form.
58+
* @param modifier The modifier to apply to the composable.
59+
*/
5360
@Composable
5461
@Suppress("CyclomaticComplexMethod", "ComplexCondition")
5562
internal fun BeneficiaryApplicationContent(

0 commit comments

Comments
 (0)