-
Notifications
You must be signed in to change notification settings - Fork 714
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2731 from openMF/development
Updating the latest changes on kmp branch
- Loading branch information
Showing
83 changed files
with
2,403 additions
and
1,977 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2,194 changes: 1,121 additions & 1,073 deletions
2,194
androidApp/dependencies/releaseRuntimeClasspath.tree.txt
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 17 additions & 11 deletions
28
build-logic/convention/src/main/kotlin/AndroidHiltConventionPlugin.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
core/data/kotlin/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
mock-maker-inline |
95 changes: 95 additions & 0 deletions
95
core/data/src/main/java/org/mifos/mobile/core/data/model/Charge.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
/* | ||
* Copyright 2025 Mifos Initiative | ||
* | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. | ||
* | ||
* See https://github.com/openMF/mobile-mobile/blob/master/LICENSE.md | ||
*/ | ||
package org.mifos.mobile.core.data.model | ||
|
||
import org.mifos.mobile.core.database.entity.ChargeCalculationTypeEntity | ||
import org.mifos.mobile.core.database.entity.ChargeEntity | ||
import org.mifos.mobile.core.database.entity.ChargeTimeTypeEntity | ||
import org.mifos.mobile.core.database.entity.CurrencyEntity | ||
import org.mifos.mobile.core.model.entity.Charge | ||
import org.mifos.mobile.core.model.entity.ChargeCalculationType | ||
import org.mifos.mobile.core.model.entity.ChargeTimeType | ||
import org.mifos.mobile.core.model.entity.Currency | ||
|
||
fun ChargeEntity.toCharge(): Charge { | ||
return Charge( | ||
clientId = clientId, | ||
chargeId = chargeId, | ||
name = name, | ||
dueDate = dueDate, | ||
chargeTimeType = ChargeTimeType( | ||
id = chargeTimeType?.id ?: 0, | ||
code = chargeTimeType?.code, | ||
value = chargeTimeType?.value, | ||
), | ||
chargeCalculationType = ChargeCalculationType( | ||
id = chargeCalculationType?.id ?: 0, | ||
code = chargeCalculationType?.code, | ||
value = chargeCalculationType?.value, | ||
), | ||
currency = Currency( | ||
code = currency?.code, | ||
name = currency?.name, | ||
decimalPlaces = currency?.decimalPlaces ?: 0, | ||
displaySymbol = currency?.displaySymbol, | ||
nameCode = currency?.nameCode, | ||
displayLabel = currency?.displayLabel, | ||
), | ||
amount = amount, | ||
amountPaid = amountPaid, | ||
amountWaived = amountWaived, | ||
amountWrittenOff = amountWrittenOff, | ||
amountOutstanding = amountOutstanding, | ||
penalty = penalty, | ||
isActive = isActive, | ||
isChargePaid = isChargePaid, | ||
isChargeWaived = isChargeWaived, | ||
paid = paid, | ||
waived = waived, | ||
) | ||
} | ||
|
||
fun Charge.toChargeEntity(): ChargeEntity { | ||
return ChargeEntity( | ||
clientId = clientId, | ||
chargeId = chargeId, | ||
name = name, | ||
dueDate = dueDate, | ||
chargeTimeType = ChargeTimeTypeEntity( | ||
id = chargeTimeType?.id ?: 0, | ||
code = chargeTimeType?.code, | ||
value = chargeTimeType?.value, | ||
), | ||
chargeCalculationType = ChargeCalculationTypeEntity( | ||
id = chargeCalculationType?.id ?: 0, | ||
code = chargeCalculationType?.code, | ||
value = chargeCalculationType?.value, | ||
), | ||
currency = CurrencyEntity( | ||
code = currency?.code, | ||
name = currency?.name, | ||
decimalPlaces = currency?.decimalPlaces ?: 0, | ||
displaySymbol = currency?.displaySymbol, | ||
nameCode = currency?.nameCode, | ||
displayLabel = currency?.displayLabel, | ||
), | ||
amount = amount, | ||
amountPaid = amountPaid, | ||
amountWaived = amountWaived, | ||
amountWrittenOff = amountWrittenOff, | ||
amountOutstanding = amountOutstanding, | ||
penalty = penalty, | ||
isActive = isActive, | ||
isChargePaid = isChargePaid, | ||
isChargeWaived = isChargeWaived, | ||
paid = paid, | ||
waived = waived, | ||
) | ||
} |
Oops, something went wrong.