From a31fe529ad1f727679df01a1e2d3acb6859f83b9 Mon Sep 17 00:00:00 2001 From: Pronay sarker Date: Tue, 14 Jan 2025 23:02:29 +0600 Subject: [PATCH 1/2] migrate [core.model] to KMP applied spotless and detekt rename --- core/common/build.gradle.kts | 7 +- .../com/mifos/core/common/utils/Parcelize.kt | 41 +++++++ .../mifos/core/common/utils}/ServerConfig.kt | 9 +- .../core/common/utils/Parcelize.desktop.kt | 46 ++++++++ .../mifos/core/common/utils/Parcelize.js.kt | 46 ++++++++ .../mifos/core/common/utils/JsonExtension.kt | 6 +- .../core/common/utils/Parcelize.android.kt | 29 +++++ .../core/common/utils/Parcelize.native.kt | 46 ++++++++ .../core/common/utils/Parcelize.wasmJs.kt | 46 ++++++++ .../repository/CheckerInboxTasksRepository.kt | 3 +- .../repository/DataTableListRepository.kt | 2 +- .../repository/GroupLoanAccountRepository.kt | 2 +- .../LoanAccountApprovalRepository.kt | 3 +- .../data/repository/LoanAccountRepository.kt | 3 +- .../repository/LoanRepaymentRepository.kt | 3 +- .../repository/PinPointClientRepository.kt | 8 +- .../repository/SavingsAccountRepository.kt | 2 +- .../SyncLoanRepaymentTransactionRepository.kt | 3 +- .../CheckerInboxTasksRepositoryImp.kt | 3 +- .../DataTableListRepositoryImp.kt | 2 +- .../GroupLoanAccountRepositoryImp.kt | 2 +- .../LoanAccountApprovalRepositoryImp.kt | 3 +- .../repositoryImp/LoanAccountRepositoryImp.kt | 3 +- .../LoanRepaymentRepositoryImp.kt | 3 +- .../PinPointClientRepositoryImp.kt | 8 +- .../SavingsAccountRepositoryImp.kt | 2 +- ...ncLoanRepaymentTransactionRepositoryImp.kt | 3 +- .../core/databasehelper/DatabaseHelperLoan.kt | 5 +- .../mifos/core/entity/accounts/loan/Loan.kt | 6 +- .../accounts/loan/LoanWithAssociations.kt | 6 +- .../mifos/core/entity/accounts/loan/Loans.kt | 6 +- .../core/entity/accounts/loan/Summary.kt | 3 +- .../core/entity/accounts/savings/Charge.kt | 6 +- .../savings/SavingsAccountWithAssociations.kt | 14 +-- .../CollectionSheetResponse.kt | 3 +- .../IndividualCollectionSheet.kt | 3 +- .../entity/templates/loans/LoanTemplate.kt | 27 ++--- .../com/mifos/core/datastore/PrefManager.kt | 6 +- .../AddClientPinpointLocationUseCase.kt | 3 +- .../CreateGroupLoansAccountUseCase.kt | 2 +- .../useCases/CreateSavingsAccountUseCase.kt | 2 +- .../core/domain/useCases/GetAllLoanUseCase.kt | 7 +- .../GetClientPinpointLocationsUseCase.kt | 3 +- .../useCases/UpdateClientPinpointUseCase.kt | 3 +- core/model/build.gradle.kts | 16 ++- .../com/mifos/core/model}/objects/Changes.kt | 19 +-- .../model}/objects/ErrorSyncServerMessage.kt | 4 +- .../core/model}/objects/SearchedEntity.kt | 8 +- .../account/loan/AccountLinkingOptions.kt | 6 +- .../objects/account/loan/AmortizationType.kt | 6 +- .../model}/objects/account/loan/Currency.kt | 8 +- .../objects/account/loan/DaysInMonthType.kt | 6 +- .../objects/account/loan/DaysInYearType.kt | 6 +- .../loan/InterestCalculationPeriodType.kt | 6 +- .../account/loan/InterestRateFrequencyType.kt | 6 +- .../objects/account/loan/InterestType.kt | 6 +- .../objects/account/loan/LoanApproval.kt | 6 +- .../account/loan/LoanApprovalRequest.kt | 6 +- .../objects/account/loan/LoanDisbursement.kt | 6 +- .../account/loan/LoanPurposeOptions.kt | 6 +- .../account/loan/LoanRepaymentResponse.kt | 16 +-- .../objects/account/loan/PaymentDetailData.kt | 6 +- .../objects/account/loan/PaymentType.kt | 6 +- .../account/loan/PaymentTypeOptions.kt | 6 +- .../model}/objects/account/loan/Period.kt | 6 +- .../loan/RepaymentFrequencyDayOfWeekType.kt | 6 +- .../loan/RepaymentFrequencyNthDayType.kt | 6 +- .../account/loan/RepaymentFrequencyType.kt | 6 +- .../loan/RepaymentFrequencyTypeOptions.kt | 6 +- .../objects/account/loan/RepaymentSchedule.kt | 6 +- .../objects/account/loan/SavingsApproval.kt | 6 +- .../account/loan/TermFrequencyTypeOptions.kt | 6 +- .../account/loan/TermPeriodFrequencyType.kt | 6 +- .../objects/account/loan/Transaction.kt | 6 +- .../loan/TransactionProcessingStrategy.kt | 6 +- .../core/model/objects/account}/loan/Type.kt | 6 +- .../account/saving/ChargeCalculationType.kt | 8 +- .../objects/account/saving/ChargeTimeType.kt | 9 +- .../account/saving/FieldOfficerOptions.kt | 6 +- .../InterestCalculationDaysInYearType.kt | 6 +- .../account/saving/InterestCalculationType.kt | 6 +- .../saving/InterestCompoundingPeriodType.kt | 6 +- .../saving/InterestPostingPeriodType.kt | 6 +- .../saving/LockinPeriodFrequencyType.kt | 6 +- .../SavingsAccountTransactionResponse.kt | 12 +- .../model}/objects/account/saving/Timeline.kt | 6 +- .../CheckerInboxSearchTemplate.kt | 10 +- .../objects/checkerinboxtask/CheckerTask.kt | 7 +- .../checkerinboxtask/RescheduleLoansTask.kt | 8 +- .../RescheduleReasonCodeValue.kt | 6 +- .../model}/objects/clients/ActivatePayload.kt | 6 +- .../core/model}/objects/clients/Address.kt | 6 +- .../objects/clients/ChargeCreationResponse.kt | 6 +- .../model}/objects/clients/ChargesRename.kt | 2 +- .../objects/clients/ClientAddressRequest.kt | 6 +- .../objects/clients/ClientAddressResponse.kt | 6 +- .../mifos/core/model}/objects/clients/Page.kt | 2 +- .../core/model}/objects/clients/Permission.kt | 2 +- .../mifos/core/model}/objects/clients/Role.kt | 2 +- .../collectionsheets/AttendanceTypeOption.kt | 6 +- .../BulkSavingsDueTransaction.kt | 6 +- .../collectionsheets/CollectionFrequency.kt | 2 +- .../CollectionMeetingCalendar.kt | 6 +- .../CollectionSheetRequestPayload.kt | 6 +- .../objects/collectionsheets/EntityType.kt | 6 +- .../collectionsheets/LoanAndClientName.kt | 6 +- .../collectionsheets/LoanCollectionSheet.kt | 37 +++--- .../collectionsheets/SavingsProduct.kt | 6 +- .../objects/commonfiles/InterestType.kt | 6 +- .../model}/objects/databaseobjects/Account.kt | 6 +- .../objects/databaseobjects/AttendanceType.kt | 8 +- .../model}/objects/databaseobjects/Client.kt | 8 +- .../CollectionMeetingCalendar.kt | 6 +- .../databaseobjects/CollectionSheet.kt | 8 +- .../objects/databaseobjects/Currency.kt | 8 +- .../objects/databaseobjects/EntityType.kt | 6 +- .../model}/objects/databaseobjects/Loan.kt | 8 +- .../objects/databaseobjects/MeetingCenter.kt | 6 +- .../objects/databaseobjects/MeetingDate.kt | 6 +- .../objects/databaseobjects/MifosGroup.kt | 8 +- .../objects/databaseobjects/OfflineCenter.kt | 6 +- .../databaseobjects/RepaymentTransaction.kt | 6 +- .../model}/objects/databaseobjects/Status.kt | 6 +- .../mifos/core/model}/objects/error/Arg.kt | 6 +- .../mifos/core/model}/objects/error/Errors.kt | 6 +- .../core/model}/objects/error/MifosError.kt | 6 +- .../core/model}/objects/groups/CenterInfo.kt | 6 +- .../core/model}/objects/nav/ClientArgs.kt | 6 +- .../objects/nav/DataTableNavigationArg.kt | 2 +- .../model}/objects/noncoreobjects/Document.kt | 6 +- .../objects/noncoreobjects/DocumentType.kt | 6 +- .../objects/noncoreobjects/Identifier.kt | 6 +- .../IdentifierCreationResponse.kt | 6 +- .../noncoreobjects/IdentifierPayload.kt | 6 +- .../noncoreobjects/IdentifierTemplate.kt | 6 +- .../objects/noncoreobjects/IdentifierType.kt | 6 +- .../objects/organisations/AccountingRule.kt | 8 +- .../organisations/AllowAttributeOverrides.kt | 8 +- .../objects/organisations/AmortizationType.kt | 8 +- .../ClientClassificationOptions.kt | 2 +- .../organisations/ClientTypeOptions.kt | 2 +- .../model}/objects/organisations/Currency.kt | 8 +- .../objects/organisations/DaysInMonthType.kt | 8 +- .../objects/organisations/DaysInYearType.kt | 8 +- .../objects/organisations/GenderOptions.kt | 2 +- .../InterestCalculationDaysInYearType.kt | 2 +- .../InterestCalculationPeriodType.kt | 8 +- .../InterestCalculationTypeOptions.kt | 2 +- .../InterestCompoundingPeriod.kt | 2 +- .../InterestPostingPeriodType.kt | 2 +- .../InterestRateFrequencyType.kt | 8 +- .../objects/organisations/InterestType.kt | 8 +- .../model}/objects/organisations/LoanFund.kt | 2 +- .../objects/organisations/LoanProducts.kt | 110 +++++++++--------- .../objects/organisations/LoanPurpose.kt | 2 +- .../objects/organisations/ProductSavings.kt | 2 +- .../organisations/RepaymentFrequencyType.kt | 8 +- .../model/objects}/payloads/ChargesPayload.kt | 2 +- .../objects}/payloads/GroupLoanPayload.kt | 6 +- .../model/objects}/payloads/SavingsPayload.kt | 2 +- .../model}/objects/responses/SaveResponse.kt | 20 ++-- .../model}/objects/runreport/ColumnHeader.kt | 6 +- .../core/model}/objects/runreport/DataRow.kt | 6 +- .../runreport/FullParameterListResponse.kt | 6 +- .../runreport/client/ClientReportTypeItem.kt | 6 +- .../core/model}/objects/surveys/Scorecard.kt | 8 +- .../model}/objects/surveys/ScorecardValues.kt | 6 +- .../mifos/core/model}/objects/systems/Code.kt | 2 +- .../core/model}/objects/systems/CodeValue.kt | 2 +- .../template/client/ChargeAppliesTo.kt | 6 +- .../template/client/ChargeCalculationType.kt | 6 +- .../objects/template/client/ChargeOptions.kt | 6 +- .../template/client/ChargePaymentMode.kt | 6 +- .../objects/template/client/ChargeTemplate.kt | 6 +- .../objects/template/client/ChargeTimeType.kt | 10 +- .../objects/template/client/Currency.kt | 6 +- .../client/IncomeOrLiabilityAccount.kt | 6 +- .../objects/template/loan/AccountingRule.kt | 6 +- .../template/loan/AllowAttributeOverrides.kt | 6 +- .../objects/template/loan/AmortizationType.kt | 6 +- .../template/loan/AmortizationTypeOptions.kt | 6 +- .../objects/template/loan/CalendarOptions.kt | 6 +- .../template/loan/CalendarOptionsType.kt | 6 +- .../objects/template/loan/ChargeAppliesTo.kt | 6 +- .../template/loan/ChargeCalculationType.kt | 6 +- .../objects/template/loan/ChargeOptions.kt | 6 +- .../template/loan/ChargePaymentMode.kt | 6 +- .../objects/template/loan/ChargeTimeType.kt | 6 +- .../model}/objects/template/loan/Charges.kt | 6 +- .../model}/objects/template/loan/Currency.kt | 6 +- .../objects/template/loan/DaysInMonthType.kt | 6 +- .../objects/template/loan/DaysInYearType.kt | 6 +- .../objects/template/loan/EntityType.kt | 6 +- .../model}/objects/template/loan/Frequency.kt | 6 +- .../objects/template/loan/FundOptions.kt | 6 +- .../model}/objects/template/loan/Group.kt | 6 +- .../template/loan/GroupLoanTemplate.kt | 6 +- .../objects/template/loan/GroupTimeline.kt | 6 +- .../loan/InterestCalculationPeriodType.kt | 6 +- .../InterestCalculationPeriodTypeOptions.kt | 6 +- .../loan/InterestRateFrequencyType.kt | 6 +- .../loan/InterestRateFrequencyTypeOptions.kt | 6 +- .../InterestRecalculationCompoundingType.kt | 6 +- .../loan/InterestRecalculationData.kt | 6 +- .../objects/template/loan/InterestType.kt | 6 +- .../template/loan/InterestTypeOptions.kt | 6 +- .../template/loan/LoanCollateralOptions.kt | 6 +- .../template/loan/LoanOfficerOptions.kt | 6 +- .../template/loan/LoanPurposeOptions.kt | 6 +- .../objects/template/loan/OverdueCharges.kt | 6 +- .../PreClosureInterestCalculationStrategy.kt | 6 +- .../model}/objects/template/loan/Product.kt | 6 +- .../objects/template/loan/ProductOptions.kt | 6 +- .../loan/RecalculationRestFrequencyType.kt | 6 +- ...RepaymentFrequencyDaysOfWeekTypeOptions.kt | 6 +- .../RepaymentFrequencyNthDayTypeOptions.kt | 6 +- .../template/loan/RepaymentFrequencyType.kt | 6 +- .../loan/RepaymentFrequencyTypeOptions.kt | 6 +- .../template/loan/RepeatsOnNthDayOfMonth.kt | 6 +- .../template/loan/RescheduleStrategyType.kt | 6 +- .../model}/objects/template/loan/Status.kt | 6 +- .../model}/objects/template/loan/TaxGroup.kt | 6 +- .../template/loan/TermFrequencyTypeOptions.kt | 6 +- .../template/loan/TermPeriodFrequencyType.kt | 6 +- .../model}/objects/template/loan/Timeline.kt | 6 +- .../TransactionProcessingStrategyOptions.kt | 6 +- .../core/model/objects/template}/loan/Type.kt | 6 +- .../objects/template/saving/AccountOptions.kt | 8 +- .../model}/objects/template/saving/TagId.kt | 6 +- .../mifos/core/model}/objects/users/User.kt | 4 +- .../core/model/objects/users/UserLatLng.kt | 82 +++++++++++++ .../core/model}/objects/users/UserLocation.kt | 6 +- .../mifos/core/objects/users/UserLatLng.kt | 64 ---------- .../com/mifos/core/network/BaseApiManager.kt | 2 +- .../com/mifos/core/network/DataManager.kt | 8 +- .../datamanager/DataManagerCheckerInbox.kt | 3 +- .../network/datamanager/DataManagerClient.kt | 8 +- .../network/datamanager/DataManagerLoan.kt | 6 +- .../network/datamanager/DataManagerSavings.kt | 2 +- .../network/services/CheckerInboxService.kt | 3 +- .../core/network/services/ClientService.kt | 8 +- .../core/network/services/LoanService.kt | 11 +- .../network/services/SavingsAccountService.kt | 2 +- .../feature/auth/login/LoginViewModel.kt | 2 +- .../clientPinpoint/PinPointClientUiState.kt | 4 +- .../clientPinpoint/PinPointClientViewModel.kt | 5 +- .../clientPinpoint/PinpointClientScreen.kt | 24 ++-- .../IndividualCollectionSheetDetailsScreen.kt | 5 +- .../navigation/CollectionSheetNavigation.kt | 5 +- .../paymentDetails/PaymentDetailsScreen.kt | 3 +- .../paymentDetails/PaymentDetailsViewModel.kt | 3 +- .../dataTableList/DataTableListViewModel.kt | 2 +- .../GroupLoanAccountScreen.kt | 7 +- .../GroupLoanAccountViewModel.kt | 5 +- .../loan/loanAccount/LoanAccountScreen.kt | 5 +- .../loan/loanAccount/LoanAccountUiState.kt | 4 +- .../loanApproval/LoanAccountApprovalScreen.kt | 7 +- .../LoanAccountApprovalViewModel.kt | 3 +- .../loan/loanRepayment/LoanRepaymentScreen.kt | 3 +- .../loanRepayment/LoanRepaymentUiState.kt | 3 +- .../loanRepayment/LoanRepaymentViewModel.kt | 5 +- .../LoanRepaymentScheduleScreen.kt | 13 +-- .../SyncLoanRepaymentTransactionViewModel.kt | 5 +- .../pathTracking/PathTrackingScreen.kt | 12 +- .../savingsAccount/SavingAccountViewModel.kt | 2 +- .../savingsAccount/SavingsAccountScreen.kt | 2 +- .../updateServer/UpdateServerConfigScreen.kt | 6 +- .../UpdateServerConfigViewModel.kt | 2 +- 268 files changed, 1141 insertions(+), 916 deletions(-) create mode 100644 core/common/src/commonMain/kotlin/com/mifos/core/common/utils/Parcelize.kt rename core/{model/src/main/kotlin/com/mifos/core/model => common/src/commonMain/kotlin/com/mifos/core/common/utils}/ServerConfig.kt (79%) create mode 100644 core/common/src/desktopMain/kotlin/com/mifos/core/common/utils/Parcelize.desktop.kt create mode 100644 core/common/src/jsMain/kotlin/com/mifos/core/common/utils/Parcelize.js.kt create mode 100644 core/common/src/main/java/com/mifos/core/common/utils/Parcelize.android.kt create mode 100644 core/common/src/nativeMain/kotlin/com/mifos/core/common/utils/Parcelize.native.kt create mode 100644 core/common/src/wasmJsMain/kotlin/com/mifos/core/common/utils/Parcelize.wasmJs.kt rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/Changes.kt (74%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/ErrorSyncServerMessage.kt (89%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/SearchedEntity.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/AccountLinkingOptions.kt (83%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/AmortizationType.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/Currency.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/DaysInMonthType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/DaysInYearType.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/InterestCalculationPeriodType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/InterestRateFrequencyType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/InterestType.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/LoanApproval.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/LoanApprovalRequest.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/LoanDisbursement.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/LoanPurposeOptions.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/LoanRepaymentResponse.kt (68%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/PaymentDetailData.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/PaymentType.kt (75%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/PaymentTypeOptions.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/Period.kt (93%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/RepaymentFrequencyNthDayType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/RepaymentFrequencyType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/RepaymentFrequencyTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/RepaymentSchedule.kt (94%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/SavingsApproval.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/TermFrequencyTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/TermPeriodFrequencyType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/Transaction.kt (86%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/loan/TransactionProcessingStrategy.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core/objects/template => commonMain/kotlin/com/mifos/core/model/objects/account}/loan/Type.kt (88%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/ChargeCalculationType.kt (71%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/ChargeTimeType.kt (71%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/FieldOfficerOptions.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/InterestCalculationDaysInYearType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/InterestCalculationType.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/InterestCompoundingPeriodType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/InterestPostingPeriodType.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/LockinPeriodFrequencyType.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/SavingsAccountTransactionResponse.kt (75%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/account/saving/Timeline.kt (84%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt (57%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/checkerinboxtask/CheckerTask.kt (83%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/checkerinboxtask/RescheduleLoansTask.kt (67%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/checkerinboxtask/RescheduleReasonCodeValue.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/ActivatePayload.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/Address.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/ChargeCreationResponse.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/ChargesRename.kt (93%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/ClientAddressRequest.kt (82%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/ClientAddressResponse.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/Page.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/Permission.kt (92%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/clients/Role.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/AttendanceTypeOption.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/BulkSavingsDueTransaction.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/CollectionFrequency.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/CollectionMeetingCalendar.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/CollectionSheetRequestPayload.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/EntityType.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/LoanAndClientName.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/LoanCollectionSheet.kt (68%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/collectionsheets/SavingsProduct.kt (83%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/commonfiles/InterestType.kt (82%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/Account.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/AttendanceType.kt (71%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/Client.kt (73%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/CollectionMeetingCalendar.kt (84%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/CollectionSheet.kt (69%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/Currency.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/EntityType.kt (75%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/Loan.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/MeetingCenter.kt (85%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/MeetingDate.kt (75%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/MifosGroup.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/OfflineCenter.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/RepaymentTransaction.kt (75%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/databaseobjects/Status.kt (74%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/error/Arg.kt (74%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/error/Errors.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/error/MifosError.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/groups/CenterInfo.kt (85%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/nav/ClientArgs.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/nav/DataTableNavigationArg.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/Document.kt (82%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/DocumentType.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/Identifier.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/IdentifierCreationResponse.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/IdentifierPayload.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/IdentifierTemplate.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/noncoreobjects/IdentifierType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/AccountingRule.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/AllowAttributeOverrides.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/AmortizationType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/ClientClassificationOptions.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/ClientTypeOptions.kt (89%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/Currency.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/DaysInMonthType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/DaysInYearType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/GenderOptions.kt (89%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestCalculationDaysInYearType.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestCalculationPeriodType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestCalculationTypeOptions.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestCompoundingPeriod.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestPostingPeriodType.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestRateFrequencyType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/InterestType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/LoanFund.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/LoanProducts.kt (54%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/LoanPurpose.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/ProductSavings.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/organisations/RepaymentFrequencyType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model/objects}/payloads/ChargesPayload.kt (94%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model/objects}/payloads/GroupLoanPayload.kt (92%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model/objects}/payloads/SavingsPayload.kt (96%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/responses/SaveResponse.kt (58%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/runreport/ColumnHeader.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/runreport/DataRow.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/runreport/FullParameterListResponse.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/runreport/client/ClientReportTypeItem.kt (83%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/surveys/Scorecard.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/surveys/ScorecardValues.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/systems/Code.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/systems/CodeValue.kt (91%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargeAppliesTo.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargeCalculationType.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargeOptions.kt (84%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargePaymentMode.kt (81%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargeTemplate.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/ChargeTimeType.kt (72%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/Currency.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/client/IncomeOrLiabilityAccount.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/AccountingRule.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/AllowAttributeOverrides.kt (85%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/AmortizationType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/AmortizationTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/CalendarOptions.kt (90%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/CalendarOptionsType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ChargeAppliesTo.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ChargeCalculationType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ChargeOptions.kt (86%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ChargePaymentMode.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ChargeTimeType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Charges.kt (88%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Currency.kt (82%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/DaysInMonthType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/DaysInYearType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/EntityType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Frequency.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/FundOptions.kt (77%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Group.kt (85%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/GroupLoanTemplate.kt (96%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/GroupTimeline.kt (84%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestCalculationPeriodType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestCalculationPeriodTypeOptions.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestRateFrequencyType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestRateFrequencyTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestRecalculationCompoundingType.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestRecalculationData.kt (88%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/InterestTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/LoanCollateralOptions.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/LoanOfficerOptions.kt (84%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/LoanPurposeOptions.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/OverdueCharges.kt (74%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/PreClosureInterestCalculationStrategy.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Product.kt (95%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/ProductOptions.kt (87%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RecalculationRestFrequencyType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt (79%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RepaymentFrequencyType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RepaymentFrequencyTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RepeatsOnNthDayOfMonth.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/RescheduleStrategyType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Status.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/TaxGroup.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/TermFrequencyTypeOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/TermPeriodFrequencyType.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/Timeline.kt (76%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/loan/TransactionProcessingStrategyOptions.kt (78%) rename core/model/src/{main/kotlin/com/mifos/core/objects/account => commonMain/kotlin/com/mifos/core/model/objects/template}/loan/Type.kt (88%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/saving/AccountOptions.kt (80%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/template/saving/TagId.kt (73%) rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/users/User.kt (94%) create mode 100644 core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLatLng.kt rename core/model/src/{main/kotlin/com/mifos/core => commonMain/kotlin/com/mifos/core/model}/objects/users/UserLocation.kt (83%) delete mode 100644 core/model/src/main/kotlin/com/mifos/core/objects/users/UserLatLng.kt diff --git a/core/common/build.gradle.kts b/core/common/build.gradle.kts index caa0b29982..4d3561c395 100644 --- a/core/common/build.gradle.kts +++ b/core/common/build.gradle.kts @@ -8,7 +8,10 @@ * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ plugins { - alias(libs.plugins.mifos.android.library) + alias(libs.plugins.mifos.kmp.library) + id(libs.plugins.kotlin.parcelize.get().pluginId) + id("kotlinx-serialization") + alias(libs.plugins.mifos.android.hilt) alias(libs.plugins.mifos.android.library.jacoco) alias(libs.plugins.secrets) @@ -27,7 +30,7 @@ secrets { } dependencies { - implementation(projects.core.model) +// implementation(projects.core.model) testImplementation(libs.kotlinx.coroutines.test) testImplementation(libs.turbine) diff --git a/core/common/src/commonMain/kotlin/com/mifos/core/common/utils/Parcelize.kt b/core/common/src/commonMain/kotlin/com/mifos/core/common/utils/Parcelize.kt new file mode 100644 index 0000000000..7829760cb8 --- /dev/null +++ b/core/common/src/commonMain/kotlin/com/mifos/core/common/utils/Parcelize.kt @@ -0,0 +1,41 @@ +/* + * Copyright 2024 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +expect annotation class Parcelize() + +expect interface Parcelable + +expect annotation class IgnoredOnParcel() + +expect interface Parceler

{ + fun create(parcel: Parcel): P + + fun P.write(parcel: Parcel, flags: Int) +} + +expect annotation class TypeParceler>() + +expect class Parcel { + fun readByte(): Byte + fun readInt(): Int + + fun readFloat(): Float + fun readDouble(): Double + fun readString(): String? + + fun writeByte(value: Byte) + fun writeInt(value: Int) + + fun writeFloat(value: Float) + + fun writeDouble(value: Double) + fun writeString(value: String?) +} diff --git a/core/model/src/main/kotlin/com/mifos/core/model/ServerConfig.kt b/core/common/src/commonMain/kotlin/com/mifos/core/common/utils/ServerConfig.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/model/ServerConfig.kt rename to core/common/src/commonMain/kotlin/com/mifos/core/common/utils/ServerConfig.kt index 03a55d62cc..f0de6cbcc2 100644 --- a/core/model/src/main/kotlin/com/mifos/core/model/ServerConfig.kt +++ b/core/common/src/commonMain/kotlin/com/mifos/core/common/utils/ServerConfig.kt @@ -7,15 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.model - -import com.google.gson.annotations.SerializedName +package com.mifos.core.common.utils +@Serializable data class ServerConfig( val protocol: String, - @SerializedName("end_point") + @SerialName("end_point") val endPoint: String, - @SerializedName("api_path") + @SerialName("api_path") val apiPath: String, val port: String, val tenant: String, diff --git a/core/common/src/desktopMain/kotlin/com/mifos/core/common/utils/Parcelize.desktop.kt b/core/common/src/desktopMain/kotlin/com/mifos/core/common/utils/Parcelize.desktop.kt new file mode 100644 index 0000000000..1e3ec70a23 --- /dev/null +++ b/core/common/src/desktopMain/kotlin/com/mifos/core/common/utils/Parcelize.desktop.kt @@ -0,0 +1,46 @@ +/* + * 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +actual interface Parcelable +actual annotation class IgnoredOnParcel +actual annotation class Parcelize +actual interface Parceler

{ + actual fun create(parcel: Parcel): P + actual fun P.write(parcel: Parcel, flags: Int) +} + +actual annotation class TypeParceler> + +actual class Parcel { + actual fun readString(): String? = null + actual fun readByte(): Byte = 1 + + actual fun readInt(): Int = 1 + + actual fun readFloat(): Float = 1f + + actual fun readDouble(): Double = 1.0 + + actual fun writeByte(value: Byte) { + } + + actual fun writeInt(value: Int) { + } + + actual fun writeFloat(value: Float) { + } + + actual fun writeDouble(value: Double) { + } + + actual fun writeString(value: String?) { + } +} diff --git a/core/common/src/jsMain/kotlin/com/mifos/core/common/utils/Parcelize.js.kt b/core/common/src/jsMain/kotlin/com/mifos/core/common/utils/Parcelize.js.kt new file mode 100644 index 0000000000..1e3ec70a23 --- /dev/null +++ b/core/common/src/jsMain/kotlin/com/mifos/core/common/utils/Parcelize.js.kt @@ -0,0 +1,46 @@ +/* + * 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +actual interface Parcelable +actual annotation class IgnoredOnParcel +actual annotation class Parcelize +actual interface Parceler

{ + actual fun create(parcel: Parcel): P + actual fun P.write(parcel: Parcel, flags: Int) +} + +actual annotation class TypeParceler> + +actual class Parcel { + actual fun readString(): String? = null + actual fun readByte(): Byte = 1 + + actual fun readInt(): Int = 1 + + actual fun readFloat(): Float = 1f + + actual fun readDouble(): Double = 1.0 + + actual fun writeByte(value: Byte) { + } + + actual fun writeInt(value: Int) { + } + + actual fun writeFloat(value: Float) { + } + + actual fun writeDouble(value: Double) { + } + + actual fun writeString(value: String?) { + } +} diff --git a/core/common/src/main/java/com/mifos/core/common/utils/JsonExtension.kt b/core/common/src/main/java/com/mifos/core/common/utils/JsonExtension.kt index 1e5598377e..90a21b2e86 100644 --- a/core/common/src/main/java/com/mifos/core/common/utils/JsonExtension.kt +++ b/core/common/src/main/java/com/mifos/core/common/utils/JsonExtension.kt @@ -10,9 +10,9 @@ package com.mifos.core.common.utils import com.google.gson.Gson -import com.mifos.core.model.ServerConfig +import core.mifos.core.model.ServerConfig -fun String.asServerConfig(): ServerConfig { +fun String.asServerConfig(): core.mifos.core.model.ServerConfig { val jsonString = this.replace("'", "\"") - return Gson().fromJson(jsonString, ServerConfig::class.java) + return Gson().fromJson(jsonString, core.mifos.core.model.ServerConfig::class.java) } diff --git a/core/common/src/main/java/com/mifos/core/common/utils/Parcelize.android.kt b/core/common/src/main/java/com/mifos/core/common/utils/Parcelize.android.kt new file mode 100644 index 0000000000..2e79735e3b --- /dev/null +++ b/core/common/src/main/java/com/mifos/core/common/utils/Parcelize.android.kt @@ -0,0 +1,29 @@ +/* + * 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +import android.os.Parcel +import android.os.Parcelable +import kotlinx.parcelize.IgnoredOnParcel +import kotlinx.parcelize.Parceler +import kotlinx.parcelize.Parcelize +import kotlinx.parcelize.TypeParceler + +actual typealias Parcelize = Parcelize + +actual typealias Parcelable = Parcelable + +actual typealias IgnoredOnParcel = IgnoredOnParcel + +actual typealias Parceler

= Parceler

+ +actual typealias TypeParceler = TypeParceler + +actual typealias Parcel = Parcel diff --git a/core/common/src/nativeMain/kotlin/com/mifos/core/common/utils/Parcelize.native.kt b/core/common/src/nativeMain/kotlin/com/mifos/core/common/utils/Parcelize.native.kt new file mode 100644 index 0000000000..1e3ec70a23 --- /dev/null +++ b/core/common/src/nativeMain/kotlin/com/mifos/core/common/utils/Parcelize.native.kt @@ -0,0 +1,46 @@ +/* + * 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +actual interface Parcelable +actual annotation class IgnoredOnParcel +actual annotation class Parcelize +actual interface Parceler

{ + actual fun create(parcel: Parcel): P + actual fun P.write(parcel: Parcel, flags: Int) +} + +actual annotation class TypeParceler> + +actual class Parcel { + actual fun readString(): String? = null + actual fun readByte(): Byte = 1 + + actual fun readInt(): Int = 1 + + actual fun readFloat(): Float = 1f + + actual fun readDouble(): Double = 1.0 + + actual fun writeByte(value: Byte) { + } + + actual fun writeInt(value: Int) { + } + + actual fun writeFloat(value: Float) { + } + + actual fun writeDouble(value: Double) { + } + + actual fun writeString(value: String?) { + } +} diff --git a/core/common/src/wasmJsMain/kotlin/com/mifos/core/common/utils/Parcelize.wasmJs.kt b/core/common/src/wasmJsMain/kotlin/com/mifos/core/common/utils/Parcelize.wasmJs.kt new file mode 100644 index 0000000000..1e3ec70a23 --- /dev/null +++ b/core/common/src/wasmJsMain/kotlin/com/mifos/core/common/utils/Parcelize.wasmJs.kt @@ -0,0 +1,46 @@ +/* + * 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.common.utils + +actual interface Parcelable +actual annotation class IgnoredOnParcel +actual annotation class Parcelize +actual interface Parceler

{ + actual fun create(parcel: Parcel): P + actual fun P.write(parcel: Parcel, flags: Int) +} + +actual annotation class TypeParceler> + +actual class Parcel { + actual fun readString(): String? = null + actual fun readByte(): Byte = 1 + + actual fun readInt(): Int = 1 + + actual fun readFloat(): Float = 1f + + actual fun readDouble(): Double = 1.0 + + actual fun writeByte(value: Byte) { + } + + actual fun writeInt(value: Int) { + } + + actual fun writeFloat(value: Float) { + } + + actual fun writeDouble(value: Double) { + } + + actual fun writeString(value: String?) { + } +} diff --git a/core/data/src/main/java/com/mifos/core/data/repository/CheckerInboxTasksRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/CheckerInboxTasksRepository.kt index 0c16cc560a..4c87d53e40 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/CheckerInboxTasksRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/CheckerInboxTasksRepository.kt @@ -10,7 +10,6 @@ package com.mifos.core.data.repository import com.mifos.core.objects.checkerinboxtask.CheckerTask -import com.mifos.core.objects.checkerinboxtask.RescheduleLoansTask import kotlinx.coroutines.flow.Flow /** @@ -19,7 +18,7 @@ import kotlinx.coroutines.flow.Flow interface CheckerInboxTasksRepository { - suspend fun getRescheduleLoansTaskList(): Flow> + suspend fun getRescheduleLoansTaskList(): Flow> suspend fun getCheckerTaskList( actionName: String? = null, diff --git a/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt index 1296abb087..1858764eeb 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt @@ -13,7 +13,7 @@ import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.entity.client.Client import com.mifos.core.entity.client.ClientPayload import com.mifos.core.network.model.LoansPayload -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt index 5b583c96e5..6334cac6f7 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt @@ -11,7 +11,7 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountApprovalRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountApprovalRepository.kt index 046b7e8455..64058cb1ab 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountApprovalRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountApprovalRepository.kt @@ -10,7 +10,6 @@ package com.mifos.core.data.repository import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.account.loan.LoanApproval import rx.Observable /** @@ -18,5 +17,5 @@ import rx.Observable */ interface LoanAccountApprovalRepository { - fun approveLoan(loanId: Int, loanApproval: LoanApproval?): Observable + fun approveLoan(loanId: Int, loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval?): Observable } diff --git a/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountRepository.kt index 4f0f01290c..acfed11eaf 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/LoanAccountRepository.kt @@ -12,7 +12,6 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.entity.templates.loans.LoanTemplate import com.mifos.core.network.model.LoansPayload -import com.mifos.core.objects.organisations.LoanProducts import rx.Observable /** @@ -20,7 +19,7 @@ import rx.Observable */ interface LoanAccountRepository { - suspend fun allLoans(): Observable> + suspend fun allLoans(): Observable> suspend fun getLoansAccountTemplate(clientId: Int, productId: Int): Observable diff --git a/core/data/src/main/java/com/mifos/core/data/repository/LoanRepaymentRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/LoanRepaymentRepository.kt index f52099b892..e71b519f01 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/LoanRepaymentRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/LoanRepaymentRepository.kt @@ -11,7 +11,6 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import rx.Observable /** @@ -24,7 +23,7 @@ interface LoanRepaymentRepository { fun submitPayment( loanId: Int, request: LoanRepaymentRequest, - ): Observable + ): Observable fun getDatabaseLoanRepaymentByLoanId(loanId: Int): Observable } diff --git a/core/data/src/main/java/com/mifos/core/data/repository/PinPointClientRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/PinPointClientRepository.kt index 2d97750a47..ab62429d2c 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/PinPointClientRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/PinPointClientRepository.kt @@ -10,19 +10,17 @@ package com.mifos.core.data.repository import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.clients.ClientAddressRequest -import com.mifos.core.objects.clients.ClientAddressResponse /** * Created by Aditya Gupta on 08/08/23. */ interface PinPointClientRepository { - suspend fun getClientPinpointLocations(clientId: Int): List + suspend fun getClientPinpointLocations(clientId: Int): List suspend fun addClientPinpointLocation( clientId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): GenericResponse suspend fun deleteClientAddressPinpointLocation( @@ -33,6 +31,6 @@ interface PinPointClientRepository { suspend fun updateClientPinpointLocation( apptableId: Int, datatableId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): GenericResponse } diff --git a/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt index f65704ef60..57745f7629 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt @@ -12,7 +12,7 @@ package com.mifos.core.data.repository import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.payloads.SavingsPayload +import com.mifos.core.model.objects.payloads.SavingsPayload import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repository/SyncLoanRepaymentTransactionRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/SyncLoanRepaymentTransactionRepository.kt index 6f48fc86fb..2d5c5278a1 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/SyncLoanRepaymentTransactionRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/SyncLoanRepaymentTransactionRepository.kt @@ -10,7 +10,6 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import rx.Observable interface SyncLoanRepaymentTransactionRepository { @@ -22,7 +21,7 @@ interface SyncLoanRepaymentTransactionRepository { fun submitPayment( loanId: Int, request: LoanRepaymentRequest, - ): Observable + ): Observable fun deleteAndUpdateLoanRepayments(loanId: Int): Observable> diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/CheckerInboxTasksRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/CheckerInboxTasksRepositoryImp.kt index b926ae11cb..580d60a38c 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/CheckerInboxTasksRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/CheckerInboxTasksRepositoryImp.kt @@ -12,7 +12,6 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.CheckerInboxTasksRepository import com.mifos.core.network.datamanager.DataManagerCheckerInbox import com.mifos.core.objects.checkerinboxtask.CheckerTask -import com.mifos.core.objects.checkerinboxtask.RescheduleLoansTask import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.flow import javax.inject.Inject @@ -24,7 +23,7 @@ import javax.inject.Inject class CheckerInboxTasksRepositoryImp @Inject constructor(private val dataManagerCheckerInbox: DataManagerCheckerInbox) : CheckerInboxTasksRepository { - override suspend fun getRescheduleLoansTaskList(): Flow> { + override suspend fun getRescheduleLoansTaskList(): Flow> { return flow { emit(dataManagerCheckerInbox.getRechdeduleLoansTaskList()) } } diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt index 04c8e6a9d2..e5b8070f39 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt @@ -17,7 +17,7 @@ import com.mifos.core.network.DataManager import com.mifos.core.network.datamanager.DataManagerClient import com.mifos.core.network.datamanager.DataManagerLoan import com.mifos.core.network.model.LoansPayload -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable import javax.inject.Inject diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt index 066b82b882..46f3587542 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt @@ -13,7 +13,7 @@ import com.mifos.core.data.repository.GroupLoanAccountRepository import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.network.DataManager import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable import javax.inject.Inject diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountApprovalRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountApprovalRepositoryImp.kt index 57f320ff4e..b303f0823c 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountApprovalRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountApprovalRepositoryImp.kt @@ -12,7 +12,6 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.LoanAccountApprovalRepository import com.mifos.core.network.DataManager import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.account.loan.LoanApproval import rx.Observable import javax.inject.Inject @@ -24,7 +23,7 @@ class LoanAccountApprovalRepositoryImp @Inject constructor(private val dataManag override fun approveLoan( loanId: Int, - loanApproval: LoanApproval?, + loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval?, ): Observable { return dataManager.approveLoan(loanId, loanApproval) } diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountRepositoryImp.kt index 514451326c..47b89ea34e 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanAccountRepositoryImp.kt @@ -14,7 +14,6 @@ import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.entity.templates.loans.LoanTemplate import com.mifos.core.network.datamanager.DataManagerLoan import com.mifos.core.network.model.LoansPayload -import com.mifos.core.objects.organisations.LoanProducts import rx.Observable import javax.inject.Inject @@ -24,7 +23,7 @@ import javax.inject.Inject class LoanAccountRepositoryImp @Inject constructor(private val dataManagerLoan: DataManagerLoan) : LoanAccountRepository { - override suspend fun allLoans(): Observable> { + override suspend fun allLoans(): Observable> { return dataManagerLoan.allLoans } diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanRepaymentRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanRepaymentRepositoryImp.kt index 8741b01186..0cba5b659e 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanRepaymentRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/LoanRepaymentRepositoryImp.kt @@ -13,7 +13,6 @@ import com.mifos.core.data.repository.LoanRepaymentRepository import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate import com.mifos.core.network.datamanager.DataManagerLoan -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import rx.Observable import javax.inject.Inject @@ -30,7 +29,7 @@ class LoanRepaymentRepositoryImp @Inject constructor(private val dataManagerLoan override fun submitPayment( loanId: Int, request: LoanRepaymentRequest, - ): Observable { + ): Observable { return submitPayment(loanId, request) } diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/PinPointClientRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/PinPointClientRepositoryImp.kt index 7c9bb21cf9..07211b8efe 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/PinPointClientRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/PinPointClientRepositoryImp.kt @@ -12,8 +12,6 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.PinPointClientRepository import com.mifos.core.network.GenericResponse import com.mifos.core.network.datamanager.DataManagerClient -import com.mifos.core.objects.clients.ClientAddressRequest -import com.mifos.core.objects.clients.ClientAddressResponse import javax.inject.Inject /** @@ -22,13 +20,13 @@ import javax.inject.Inject class PinPointClientRepositoryImp @Inject constructor(private val dataManagerClient: DataManagerClient) : PinPointClientRepository { - override suspend fun getClientPinpointLocations(clientId: Int): List { + override suspend fun getClientPinpointLocations(clientId: Int): List { return dataManagerClient.getClientPinpointLocations(clientId) } override suspend fun addClientPinpointLocation( clientId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): GenericResponse { return dataManagerClient.addClientPinpointLocation(clientId, address) } @@ -43,7 +41,7 @@ class PinPointClientRepositoryImp @Inject constructor(private val dataManagerCli override suspend fun updateClientPinpointLocation( apptableId: Int, datatableId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): GenericResponse { return dataManagerClient.updateClientPinpointLocation(apptableId, datatableId, address) } diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt index afcbf7104a..20c3419d3f 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt @@ -14,7 +14,7 @@ import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.network.datamanager.DataManagerSavings import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.payloads.SavingsPayload +import com.mifos.core.model.objects.payloads.SavingsPayload import rx.Observable import javax.inject.Inject diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SyncLoanRepaymentTransactionRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SyncLoanRepaymentTransactionRepositoryImp.kt index 285d57a8a6..47b00a7588 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SyncLoanRepaymentTransactionRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SyncLoanRepaymentTransactionRepositoryImp.kt @@ -12,7 +12,6 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.SyncLoanRepaymentTransactionRepository import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.network.datamanager.DataManagerLoan -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import rx.Observable import javax.inject.Inject @@ -30,7 +29,7 @@ class SyncLoanRepaymentTransactionRepositoryImp @Inject constructor(private val override fun submitPayment( loanId: Int, request: LoanRepaymentRequest, - ): Observable { + ): Observable { return dataManagerLoan.submitPayment(loanId, request) } diff --git a/core/database/src/main/java/com/mifos/core/databasehelper/DatabaseHelperLoan.kt b/core/database/src/main/java/com/mifos/core/databasehelper/DatabaseHelperLoan.kt index 1950c1c842..e3ec9cbc1d 100644 --- a/core/database/src/main/java/com/mifos/core/databasehelper/DatabaseHelperLoan.kt +++ b/core/database/src/main/java/com/mifos/core/databasehelper/DatabaseHelperLoan.kt @@ -17,7 +17,6 @@ import com.mifos.core.entity.accounts.loan.LoanWithAssociations import com.mifos.core.entity.accounts.loan.LoanWithAssociations_Table import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate_Table -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import com.raizlabs.android.dbflow.sql.language.Delete import com.raizlabs.android.dbflow.sql.language.SQLite import rx.Observable @@ -100,14 +99,14 @@ class DatabaseHelperLoan @Inject constructor() { fun saveLoanRepaymentTransaction( loanId: Int, loanRepaymentRequest: LoanRepaymentRequest, - ): Observable { + ): Observable { return Observable.defer { // Setting Loan Id and Time Stamp loanRepaymentRequest.loanId = loanId loanRepaymentRequest.timeStamp = (System.currentTimeMillis() / 1000) // Saving Transaction In Database Table loanRepaymentRequest.save() - Observable.just(LoanRepaymentResponse()) + Observable.just(com.mifos.core.model.objects.account.loan.LoanRepaymentResponse()) } } diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loan.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loan.kt index 3dc91adfe3..5cfb348e9d 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loan.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loan.kt @@ -10,12 +10,10 @@ package com.mifos.core.entity.accounts.loan import com.mifos.core.objects.account.loan.AmortizationType -import com.mifos.core.objects.account.loan.Currency import com.mifos.core.objects.account.loan.InterestCalculationPeriodType import com.mifos.core.objects.account.loan.InterestRateFrequencyType import com.mifos.core.objects.account.loan.InterestType import com.mifos.core.objects.account.loan.RepaymentFrequencyType -import com.mifos.core.objects.account.loan.TermPeriodFrequencyType data class Loan( var id: Int? = null, @@ -46,7 +44,7 @@ data class Loan( var loanType: LoanType? = null, - var currency: Currency? = null, + var currency: com.mifos.core.model.objects.account.loan.Currency? = null, var principal: Double? = null, @@ -54,7 +52,7 @@ data class Loan( var termFrequency: Int? = null, - var termPeriodFrequencyType: TermPeriodFrequencyType? = null, + var termPeriodFrequencyType: com.mifos.core.model.objects.account.loan.TermPeriodFrequencyType? = null, var numberOfRepayments: Int? = null, diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/LoanWithAssociations.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/LoanWithAssociations.kt index db6c8ca818..f443225163 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/LoanWithAssociations.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/LoanWithAssociations.kt @@ -13,13 +13,11 @@ import android.os.Parcelable import com.mifos.core.database.MifosDatabase import com.mifos.core.model.MifosBaseModel import com.mifos.core.objects.account.loan.AmortizationType -import com.mifos.core.objects.account.loan.Currency import com.mifos.core.objects.account.loan.InterestCalculationPeriodType import com.mifos.core.objects.account.loan.InterestRateFrequencyType import com.mifos.core.objects.account.loan.InterestType import com.mifos.core.objects.account.loan.RepaymentFrequencyType import com.mifos.core.objects.account.loan.RepaymentSchedule -import com.mifos.core.objects.account.loan.TermPeriodFrequencyType import com.mifos.core.objects.account.loan.Transaction import com.raizlabs.android.dbflow.annotation.Column import com.raizlabs.android.dbflow.annotation.ForeignKey @@ -71,7 +69,7 @@ data class LoanWithAssociations( var loanType: LoanType = LoanType(), - var currency: Currency = Currency(), + var currency: com.mifos.core.model.objects.account.loan.Currency = com.mifos.core.model.objects.account.loan.Currency(), var principal: Double = 0.0, @@ -79,7 +77,7 @@ data class LoanWithAssociations( var termFrequency: Int = 0, - var termPeriodFrequencyType: TermPeriodFrequencyType = TermPeriodFrequencyType(), + var termPeriodFrequencyType: com.mifos.core.model.objects.account.loan.TermPeriodFrequencyType = com.mifos.core.model.objects.account.loan.TermPeriodFrequencyType(), var numberOfRepayments: Int = 0, diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loans.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loans.kt index 918abb70a4..4514f9e1ea 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loans.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Loans.kt @@ -11,12 +11,10 @@ package com.mifos.core.entity.accounts.loan import android.os.Parcelable import com.mifos.core.objects.account.loan.AmortizationType -import com.mifos.core.objects.account.loan.Currency import com.mifos.core.objects.account.loan.InterestCalculationPeriodType import com.mifos.core.objects.account.loan.InterestRateFrequencyType import com.mifos.core.objects.account.loan.InterestType import com.mifos.core.objects.account.loan.RepaymentFrequencyType -import com.mifos.core.objects.account.loan.TermPeriodFrequencyType import kotlinx.parcelize.Parcelize /** @@ -52,7 +50,7 @@ data class Loans( var loanType: LoanType? = null, - var currency: Currency? = null, + var currency: com.mifos.core.model.objects.account.loan.Currency? = null, var principal: Double? = null, @@ -60,7 +58,7 @@ data class Loans( var termFrequency: Int? = null, - var termPeriodFrequencyType: TermPeriodFrequencyType? = null, + var termPeriodFrequencyType: com.mifos.core.model.objects.account.loan.TermPeriodFrequencyType? = null, var numberOfRepayments: Int? = null, diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Summary.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Summary.kt index 222b1d04d6..43909cf7ac 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Summary.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/loan/Summary.kt @@ -12,7 +12,6 @@ package com.mifos.core.entity.accounts.loan import android.os.Parcelable import com.mifos.core.database.MifosDatabase import com.mifos.core.model.MifosBaseModel -import com.mifos.core.objects.account.loan.Currency import com.raizlabs.android.dbflow.annotation.Column import com.raizlabs.android.dbflow.annotation.ModelContainer import com.raizlabs.android.dbflow.annotation.PrimaryKey @@ -31,7 +30,7 @@ data class Summary( @Transient var loanId: Int? = null, - var currency: Currency? = null, + var currency: com.mifos.core.model.objects.account.loan.Currency? = null, @Column var principalDisbursed: Double? = null, diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/Charge.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/Charge.kt index 0e41a52bf0..3d815e1601 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/Charge.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/Charge.kt @@ -10,8 +10,6 @@ package com.mifos.core.entity.accounts.savings import android.os.Parcelable -import com.mifos.core.objects.account.saving.ChargeCalculationType -import com.mifos.core.objects.account.saving.ChargeTimeType import kotlinx.parcelize.Parcelize import javax.annotation.processing.Generated @@ -26,9 +24,9 @@ data class Charge( var name: String? = null, - var chargeTimeType: ChargeTimeType? = null, + var chargeTimeType: com.mifos.core.model.objects.account.saving.ChargeTimeType? = null, - var chargeCalculationType: ChargeCalculationType? = null, + var chargeCalculationType: com.mifos.core.model.objects.account.saving.ChargeCalculationType? = null, var percentage: Int? = null, diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt index c97861d89a..fc816be70f 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt @@ -13,11 +13,7 @@ import android.os.Parcelable import com.mifos.core.database.MifosDatabase import com.mifos.core.model.MifosBaseModel import com.mifos.core.objects.account.saving.InterestCalculationDaysInYearType -import com.mifos.core.objects.account.saving.InterestCalculationType -import com.mifos.core.objects.account.saving.InterestCompoundingPeriodType -import com.mifos.core.objects.account.saving.InterestPostingPeriodType import com.mifos.core.objects.account.saving.LockinPeriodFrequencyType -import com.mifos.core.objects.account.saving.Timeline import com.raizlabs.android.dbflow.annotation.Column import com.raizlabs.android.dbflow.annotation.ForeignKey import com.raizlabs.android.dbflow.annotation.ModelContainer @@ -51,17 +47,17 @@ data class SavingsAccountWithAssociations( @ForeignKey(saveForeignKeyModel = true) var status: Status? = null, - var timeline: Timeline? = null, + var timeline: com.mifos.core.model.objects.account.saving.Timeline? = null, var currency: Currency? = null, var nominalAnnualInterestRate: Double? = null, - var interestCompoundingPeriodType: InterestCompoundingPeriodType? = null, + var interestCompoundingPeriodType: com.mifos.core.model.objects.account.saving.InterestCompoundingPeriodType? = null, - var interestPostingPeriodType: InterestPostingPeriodType? = null, + var interestPostingPeriodType: com.mifos.core.model.objects.account.saving.InterestPostingPeriodType? = null, - var interestCalculationType: InterestCalculationType? = null, + var interestCalculationType: com.mifos.core.model.objects.account.saving.InterestCalculationType? = null, var interestCalculationDaysInYearType: InterestCalculationDaysInYearType? = null, @@ -93,4 +89,4 @@ data class SavingsAccountWithAssociations( var charges: List = ArrayList(), -) : MifosBaseModel(), Parcelable + ) : MifosBaseModel(), Parcelable diff --git a/core/database/src/main/java/com/mifos/core/entity/collectionsheet/CollectionSheetResponse.kt b/core/database/src/main/java/com/mifos/core/entity/collectionsheet/CollectionSheetResponse.kt index 9face4b8f9..73bfd40cc4 100644 --- a/core/database/src/main/java/com/mifos/core/entity/collectionsheet/CollectionSheetResponse.kt +++ b/core/database/src/main/java/com/mifos/core/entity/collectionsheet/CollectionSheetResponse.kt @@ -12,7 +12,6 @@ package com.mifos.core.entity.collectionsheet import android.os.Parcelable import com.mifos.core.objects.collectionsheets.AttendanceTypeOption import com.mifos.core.objects.collectionsheets.SavingsProduct -import com.mifos.core.objects.organisations.LoanProducts import kotlinx.parcelize.Parcelize /** @@ -26,7 +25,7 @@ data class CollectionSheetResponse( var groups: List = ArrayList(), - var loanProducts: List = ArrayList(), + var loanProducts: List = ArrayList(), var paymentTypeOptions: List = ArrayList(), diff --git a/core/database/src/main/java/com/mifos/core/entity/collectionsheet/IndividualCollectionSheet.kt b/core/database/src/main/java/com/mifos/core/entity/collectionsheet/IndividualCollectionSheet.kt index 62f97ea976..3737fcaf86 100644 --- a/core/database/src/main/java/com/mifos/core/entity/collectionsheet/IndividualCollectionSheet.kt +++ b/core/database/src/main/java/com/mifos/core/entity/collectionsheet/IndividualCollectionSheet.kt @@ -10,7 +10,6 @@ package com.mifos.core.entity.collectionsheet import android.os.Parcelable -import com.mifos.core.objects.account.loan.PaymentTypeOptions import kotlinx.parcelize.Parcelize /** @@ -22,5 +21,5 @@ data class IndividualCollectionSheet( var clients: ArrayList? = null, - var paymentTypeOptions: ArrayList? = null, + var paymentTypeOptions: ArrayList? = null, ) : Parcelable diff --git a/core/database/src/main/java/com/mifos/core/entity/templates/loans/LoanTemplate.kt b/core/database/src/main/java/com/mifos/core/entity/templates/loans/LoanTemplate.kt index f6df0c83b3..0fea08e16f 100644 --- a/core/database/src/main/java/com/mifos/core/entity/templates/loans/LoanTemplate.kt +++ b/core/database/src/main/java/com/mifos/core/entity/templates/loans/LoanTemplate.kt @@ -11,29 +11,20 @@ package com.mifos.core.entity.templates.loans import android.os.Parcelable import com.mifos.core.entity.noncore.DataTable -import com.mifos.core.objects.account.loan.AccountLinkingOptions import com.mifos.core.objects.template.loan.AmortizationType import com.mifos.core.objects.template.loan.AmortizationTypeOptions import com.mifos.core.objects.template.loan.ChargeOptions import com.mifos.core.objects.template.loan.Currency import com.mifos.core.objects.template.loan.DaysInMonthType -import com.mifos.core.objects.template.loan.DaysInYearType import com.mifos.core.objects.template.loan.FundOptions import com.mifos.core.objects.template.loan.InterestCalculationPeriodType -import com.mifos.core.objects.template.loan.InterestRateFrequencyType import com.mifos.core.objects.template.loan.InterestRateFrequencyTypeOptions -import com.mifos.core.objects.template.loan.InterestType -import com.mifos.core.objects.template.loan.InterestTypeOptions -import com.mifos.core.objects.template.loan.LoanCollateralOptions import com.mifos.core.objects.template.loan.LoanOfficerOptions import com.mifos.core.objects.template.loan.LoanPurposeOptions -import com.mifos.core.objects.template.loan.Product -import com.mifos.core.objects.template.loan.ProductOptions import com.mifos.core.objects.template.loan.RepaymentFrequencyDaysOfWeekTypeOptions import com.mifos.core.objects.template.loan.RepaymentFrequencyNthDayTypeOptions import com.mifos.core.objects.template.loan.RepaymentFrequencyType import com.mifos.core.objects.template.loan.RepaymentFrequencyTypeOptions -import com.mifos.core.objects.template.loan.TermFrequencyTypeOptions import com.mifos.core.objects.template.loan.TermPeriodFrequencyType import com.mifos.core.objects.template.loan.Timeline import com.mifos.core.objects.template.loan.TransactionProcessingStrategyOptions @@ -82,7 +73,7 @@ data class LoanTemplate( var interestRatePerPeriod: Double? = null, - var interestRateFrequencyType: InterestRateFrequencyType? = null, + var interestRateFrequencyType: com.mifos.core.model.objects.template.loan.InterestRateFrequencyType? = null, var annualInterestRate: Double? = null, @@ -90,7 +81,7 @@ data class LoanTemplate( var amortizationType: AmortizationType? = null, - var interestType: InterestType? = null, + var interestType: com.mifos.core.model.objects.template.loan.InterestType? = null, var interestCalculationPeriodType: InterestCalculationPeriodType? = null, @@ -102,7 +93,7 @@ data class LoanTemplate( var timeline: Timeline? = null, - var productOptions: List = ArrayList(), + var productOptions: List = ArrayList(), var dataTables: ArrayList = ArrayList(), @@ -112,7 +103,7 @@ data class LoanTemplate( var fundOptions: List = ArrayList(), - var termFrequencyTypeOptions: List = ArrayList(), + var termFrequencyTypeOptions: List = ArrayList(), var repaymentFrequencyTypeOptions: List = ArrayList(), @@ -124,7 +115,7 @@ data class LoanTemplate( var amortizationTypeOptions: List = ArrayList(), - var interestTypeOptions: List = ArrayList(), + var interestTypeOptions: List = ArrayList(), var interestCalculationPeriodTypeOptions: List = ArrayList(), @@ -132,7 +123,7 @@ data class LoanTemplate( var chargeOptions: List = ArrayList(), - var loanCollateralOptions: List = ArrayList(), + var loanCollateralOptions: List = ArrayList(), var multiDisburseLoan: Boolean? = null, @@ -140,11 +131,11 @@ data class LoanTemplate( var canDisburse: Boolean? = null, - var product: Product? = null, + var product: com.mifos.core.model.objects.template.loan.Product? = null, var daysInMonthType: DaysInMonthType? = null, - var daysInYearType: DaysInYearType? = null, + var daysInYearType: com.mifos.core.model.objects.template.loan.DaysInYearType? = null, var isInterestRecalculationEnabled: Boolean? = null, @@ -154,5 +145,5 @@ data class LoanTemplate( var maximumGap: Int? = null, - var accountLinkingOptions: List = ArrayList(), + var accountLinkingOptions: List = ArrayList(), ) : Parcelable diff --git a/core/datastore/src/main/java/com/mifos/core/datastore/PrefManager.kt b/core/datastore/src/main/java/com/mifos/core/datastore/PrefManager.kt index 1a8e8b1d74..d8ca072efb 100644 --- a/core/datastore/src/main/java/com/mifos/core/datastore/PrefManager.kt +++ b/core/datastore/src/main/java/com/mifos/core/datastore/PrefManager.kt @@ -78,12 +78,12 @@ class PrefManager @Inject constructor( preference.edit().putString(AUTH_PASSWORD, value.second).apply() } - val getServerConfig: ServerConfig = + val getServerConfig: com.mifos.core.model.ServerConfig = preference.getString(serverConfigKey.value, null)?.let { - gson.fromJson(it, ServerConfig::class.java) + gson.fromJson(it, com.mifos.core.model.ServerConfig::class.java) } ?: BuildConfig.DEMO_SERVER_CONFIG.asServerConfig() - fun updateServerConfig(config: ServerConfig?) { + fun updateServerConfig(config: com.mifos.core.model.ServerConfig?) { this.put(serverConfigKey, config) } diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/AddClientPinpointLocationUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/AddClientPinpointLocationUseCase.kt index b04fb24a81..e6c74c35eb 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/AddClientPinpointLocationUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/AddClientPinpointLocationUseCase.kt @@ -12,7 +12,6 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.PinPointClientRepository import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.clients.ClientAddressRequest import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.flow import javax.inject.Inject @@ -21,7 +20,7 @@ class AddClientPinpointLocationUseCase @Inject constructor(private val pinPointC suspend operator fun invoke( clientId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): Flow> = flow { try { emit(Resource.Loading()) diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateGroupLoansAccountUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateGroupLoansAccountUseCase.kt index cee79a37f1..7b9ca8a483 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateGroupLoansAccountUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateGroupLoansAccountUseCase.kt @@ -12,7 +12,7 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.GroupLoanAccountRepository import com.mifos.core.entity.accounts.loan.Loans -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import kotlinx.coroutines.channels.awaitClose import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.callbackFlow diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateSavingsAccountUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateSavingsAccountUseCase.kt index f8941a91c0..4c6cbe947d 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateSavingsAccountUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/CreateSavingsAccountUseCase.kt @@ -12,7 +12,7 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.SavingsAccountRepository import com.mifos.core.entity.client.Savings -import com.mifos.core.payloads.SavingsPayload +import com.mifos.core.model.objects.payloads.SavingsPayload import kotlinx.coroutines.channels.awaitClose import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.callbackFlow diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/GetAllLoanUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/GetAllLoanUseCase.kt index 12758b5044..7fa05a6ebf 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/GetAllLoanUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/GetAllLoanUseCase.kt @@ -11,7 +11,6 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.LoanAccountRepository -import com.mifos.core.objects.organisations.LoanProducts import kotlinx.coroutines.channels.awaitClose import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.callbackFlow @@ -22,20 +21,20 @@ import javax.inject.Inject class GetAllLoanUseCase @Inject constructor(private val loanAccountRepository: LoanAccountRepository) { - suspend operator fun invoke(): Flow>> = callbackFlow { + suspend operator fun invoke(): Flow>> = callbackFlow { try { trySend(Resource.Loading()) loanAccountRepository.allLoans() .observeOn(AndroidSchedulers.mainThread()) .subscribeOn(Schedulers.io()) - .subscribe(object : Subscriber>() { + .subscribe(object : Subscriber>() { override fun onCompleted() {} override fun onError(exception: Throwable) { trySend(Resource.Error(exception.message.toString())) } - override fun onNext(products: List) { + override fun onNext(products: List) { trySend(Resource.Success(products)) } }) diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/GetClientPinpointLocationsUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/GetClientPinpointLocationsUseCase.kt index 48c9e8e3de..d25c325d2c 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/GetClientPinpointLocationsUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/GetClientPinpointLocationsUseCase.kt @@ -11,14 +11,13 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.PinPointClientRepository -import com.mifos.core.objects.clients.ClientAddressResponse import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.flow import javax.inject.Inject class GetClientPinpointLocationsUseCase @Inject constructor(private val pinPointClientRepository: PinPointClientRepository) { - suspend operator fun invoke(clientId: Int): Flow>> = flow { + suspend operator fun invoke(clientId: Int): Flow>> = flow { try { emit(Resource.Loading()) val response = pinPointClientRepository.getClientPinpointLocations(clientId) diff --git a/core/domain/src/main/java/com/mifos/core/domain/useCases/UpdateClientPinpointUseCase.kt b/core/domain/src/main/java/com/mifos/core/domain/useCases/UpdateClientPinpointUseCase.kt index 953c1645a1..61e907b89e 100644 --- a/core/domain/src/main/java/com/mifos/core/domain/useCases/UpdateClientPinpointUseCase.kt +++ b/core/domain/src/main/java/com/mifos/core/domain/useCases/UpdateClientPinpointUseCase.kt @@ -12,7 +12,6 @@ package com.mifos.core.domain.useCases import com.mifos.core.common.utils.Resource import com.mifos.core.data.repository.PinPointClientRepository import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.clients.ClientAddressRequest import kotlinx.coroutines.flow.Flow import kotlinx.coroutines.flow.flow import javax.inject.Inject @@ -22,7 +21,7 @@ class UpdateClientPinpointUseCase @Inject constructor(private val pinPointClient suspend operator fun invoke( clientId: Int, datatableId: Int, - address: ClientAddressRequest, + address: com.mifos.core.model.objects.clients.ClientAddressRequest, ): Flow> = flow { try { emit(Resource.Loading()) diff --git a/core/model/build.gradle.kts b/core/model/build.gradle.kts index ccb7fd6519..64927706fd 100644 --- a/core/model/build.gradle.kts +++ b/core/model/build.gradle.kts @@ -8,17 +8,23 @@ * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ plugins { - alias(libs.plugins.mifos.android.library) - alias(libs.plugins.kotlin.android) - alias(libs.plugins.kotlin.serialization) + alias(libs.plugins.mifos.kmp.library) id(libs.plugins.kotlin.parcelize.get().pluginId) + id("kotlinx-serialization") } + android{ namespace = "com.mifos.core.model" defaultConfig { consumerProguardFiles("consumer-rules.pro") } } -dependencies { - implementation(libs.converter.gson) + +kotlin { + sourceSets { + commonMain.dependencies { + implementation(projects.core.common) + implementation(libs.kotlinx.serialization.json) + } + } } diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/Changes.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/Changes.kt similarity index 74% rename from core/model/src/main/kotlin/com/mifos/core/objects/Changes.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/Changes.kt index 466e18cb60..b27e805692 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/Changes.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/Changes.kt @@ -7,41 +7,32 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects +package com.mifos.core.model.objects -import android.os.Parcelable -import com.google.gson.annotations.Expose -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable class Changes( - @Expose var transactionDate: String? = null, - @Expose var transactionAmount: String? = null, - @Expose var locale: String? = null, - @Expose var dateFormat: String? = null, - @Expose var note: String? = null, - @Expose var accountNumber: String? = null, - @Expose var checkNumber: String? = null, - @Expose var routingCode: String? = null, - @Expose var receiptNumber: String? = null, - @Expose var bankNumber: String? = null, ) : Parcelable diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/ErrorSyncServerMessage.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/ErrorSyncServerMessage.kt similarity index 89% rename from core/model/src/main/kotlin/com/mifos/core/objects/ErrorSyncServerMessage.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/ErrorSyncServerMessage.kt index 26bd935f84..4581f2e29c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/ErrorSyncServerMessage.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/ErrorSyncServerMessage.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects +package com.mifos.core.model.objects /** * Created by Rajan Maurya on 23/07/16. @@ -17,7 +17,7 @@ class ErrorSyncServerMessage { var httpStatusCode = 0 var defaultUserMessage: String? = null var userMessageGlobalisationCode: String? = null - var errors: List? = null + var errors: List? = null inner class Error { var developerMessage: String? = null diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/SearchedEntity.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/SearchedEntity.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/SearchedEntity.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/SearchedEntity.kt index d4a695bc75..298f04e0b3 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/SearchedEntity.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/SearchedEntity.kt @@ -7,11 +7,11 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects +package com.mifos.core.model.objects -import android.os.Parcelable -import com.mifos.core.objects.commonfiles.InterestType -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import com.mifos.core.model.objects.commonfiles.InterestType /** * Created by ishankhanna on 14/02/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AccountLinkingOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AccountLinkingOptions.kt similarity index 83% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AccountLinkingOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AccountLinkingOptions.kt index 3b13e662ab..ebfc69038d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AccountLinkingOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AccountLinkingOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 12/16/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AmortizationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AmortizationType.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AmortizationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AmortizationType.kt index be4994b2da..25805fc3bc 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/AmortizationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/AmortizationType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize class AmortizationType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Currency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Currency.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Currency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Currency.kt index 169f99c7fe..c4080e9b08 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Currency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Currency.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by mayankjindal on 22/10/16. */ @Parcelize +@Serializable data class Currency( var code: String? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInMonthType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInMonthType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInMonthType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInMonthType.kt index e00bfe57f4..5ecb1ea0b2 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInMonthType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInMonthType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/21/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInYearType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInYearType.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInYearType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInYearType.kt index 845ce0266e..e02d55b196 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/DaysInYearType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/DaysInYearType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /* * This project is licensed under the open source MPL V2. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestCalculationPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestCalculationPeriodType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestCalculationPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestCalculationPeriodType.kt index ef94c693aa..37aa0a6484 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestCalculationPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestCalculationPeriodType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class InterestCalculationPeriodType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestRateFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestRateFrequencyType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestRateFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestRateFrequencyType.kt index bc8dc0059b..38c5c61e82 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestRateFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestRateFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class InterestRateFrequencyType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestType.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestType.kt index bbbcc0f8c6..b928b9a164 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/InterestType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/InterestType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize class InterestType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApproval.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApproval.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApproval.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApproval.kt index e891be988f..c3089feb16 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApproval.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApproval.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize class LoanApproval( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApprovalRequest.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApprovalRequest.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApprovalRequest.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApprovalRequest.kt index ab22e1fe34..08b1b30418 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanApprovalRequest.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanApprovalRequest.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 23/06/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanDisbursement.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanDisbursement.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanDisbursement.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanDisbursement.kt index 4ed0b63f54..a64e4a7cf9 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanDisbursement.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanDisbursement.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class LoanDisbursement( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanPurposeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanPurposeOptions.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanPurposeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanPurposeOptions.kt index afcd9386ef..8febd230af 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanPurposeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanPurposeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/25/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanRepaymentResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanRepaymentResponse.kt similarity index 68% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanRepaymentResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanRepaymentResponse.kt index 9b042b4797..e71e714055 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/LoanRepaymentResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/LoanRepaymentResponse.kt @@ -7,27 +7,23 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import com.google.gson.annotations.Expose -import com.mifos.core.objects.Changes -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import com.mifos.core.model.objects.Changes +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class LoanRepaymentResponse( - @Expose var officeId: Int? = null, - @Expose var clientId: Int? = null, - @Expose var loanId: Int? = null, - @Expose var resourceId: Int? = null, - @Expose var changes: Changes? = null, ) : Parcelable diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentDetailData.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentDetailData.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentDetailData.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentDetailData.kt index 1eed09c29d..18e289046d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentDetailData.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentDetailData.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class PaymentDetailData( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentType.kt similarity index 75% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentType.kt index 1cb3dc3c87..75f15d432b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class PaymentType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentTypeOptions.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentTypeOptions.kt index e1bb851335..85615018a2 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/PaymentTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/PaymentTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 3/3/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Period.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Period.kt similarity index 93% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Period.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Period.kt index 656b510ea4..598b7c8e54 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Period.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Period.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 19/06/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt index c5f9217a06..0711f2a0e3 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyDayOfWeekType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/21/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyNthDayType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyNthDayType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyNthDayType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyNthDayType.kt index e2cb4de098..862f920a29 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyNthDayType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyNthDayType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/21/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyType.kt index 37b54a3f33..7cd363e2b5 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class RepaymentFrequencyType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyTypeOptions.kt index 39244e8440..49075468e0 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentFrequencyTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentFrequencyTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/25/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentSchedule.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentSchedule.kt similarity index 94% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentSchedule.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentSchedule.kt index 0ad18a506d..001e745f23 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/RepaymentSchedule.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/RepaymentSchedule.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 19/06/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/SavingsApproval.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/SavingsApproval.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/SavingsApproval.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/SavingsApproval.kt index 8e3a96a7f4..4194910210 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/SavingsApproval.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/SavingsApproval.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class SavingsApproval( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermFrequencyTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermFrequencyTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermFrequencyTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermFrequencyTypeOptions.kt index e9ad3e8f6a..7fa79ddbe5 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermFrequencyTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermFrequencyTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/27/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermPeriodFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermPeriodFrequencyType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermPeriodFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermPeriodFrequencyType.kt index be8e56a260..7b184ddbfb 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TermPeriodFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TermPeriodFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class TermPeriodFrequencyType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Transaction.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Transaction.kt similarity index 86% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Transaction.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Transaction.kt index dade75c407..f2a6d160b4 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Transaction.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Transaction.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Transaction( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TransactionProcessingStrategy.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TransactionProcessingStrategy.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TransactionProcessingStrategy.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TransactionProcessingStrategy.kt index 8ebb23187a..e54227f858 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/TransactionProcessingStrategy.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/TransactionProcessingStrategy.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class TransactionProcessingStrategy( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Type.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Type.kt similarity index 88% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Type.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Type.kt index 4837f5f5fd..ca538ad765 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Type.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/loan/Type.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.account.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Type( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeCalculationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeCalculationType.kt similarity index 71% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeCalculationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeCalculationType.kt index 6227b33969..d64a53d6e8 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeCalculationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeCalculationType.kt @@ -7,14 +7,12 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize -import javax.annotation.processing.Generated +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize -@Generated("org.jsonschema2pojo") data class ChargeCalculationType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeTimeType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeTimeType.kt similarity index 71% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeTimeType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeTimeType.kt index ea3569fe8a..22ffe66161 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/ChargeTimeType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/ChargeTimeType.kt @@ -7,14 +7,13 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize -import javax.annotation.processing.Generated +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize -@Generated("org.jsonschema2pojo") +// @Generated("org.jsonschema2pojo") data class ChargeTimeType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/FieldOfficerOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/FieldOfficerOptions.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/FieldOfficerOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/FieldOfficerOptions.kt index 67484cbdd7..a15c2fba8a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/FieldOfficerOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/FieldOfficerOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationDaysInYearType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationDaysInYearType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationDaysInYearType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationDaysInYearType.kt index 228a815e01..e414daad9d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationDaysInYearType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationDaysInYearType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize class InterestCalculationDaysInYearType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationType.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationType.kt index 0f6cc1d3ad..f391bb94fd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCalculationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCalculationType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class InterestCalculationType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCompoundingPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCompoundingPeriodType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCompoundingPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCompoundingPeriodType.kt index 7a315c1af1..ef244bbad2 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestCompoundingPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestCompoundingPeriodType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class InterestCompoundingPeriodType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestPostingPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestPostingPeriodType.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestPostingPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestPostingPeriodType.kt index 589200185a..47ad16ab61 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/InterestPostingPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/InterestPostingPeriodType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class InterestPostingPeriodType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/LockinPeriodFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/LockinPeriodFrequencyType.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/LockinPeriodFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/LockinPeriodFrequencyType.kt index 467ce07f3d..1eb899ae5b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/LockinPeriodFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/LockinPeriodFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class LockinPeriodFrequencyType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/SavingsAccountTransactionResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/SavingsAccountTransactionResponse.kt similarity index 75% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/SavingsAccountTransactionResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/SavingsAccountTransactionResponse.kt index 74d996b363..8ab0cd6b26 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/SavingsAccountTransactionResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/SavingsAccountTransactionResponse.kt @@ -7,27 +7,23 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import com.google.gson.annotations.Expose -import com.mifos.core.objects.Changes +import com.mifos.core.model.objects.Changes +import kotlinx.serialization.Serializable /** * Created by ishankhanna on 12/06/14. */ +@Serializable data class SavingsAccountTransactionResponse( - @Expose var officeId: Int? = null, - @Expose var clientId: Int? = null, - @Expose var savingsId: Int? = null, - @Expose var resourceId: Int? = null, - @Expose var changes: Changes? = null, ) diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/Timeline.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/Timeline.kt similarity index 84% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/saving/Timeline.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/Timeline.kt index dd803937b1..cdae01eee8 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/saving/Timeline.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/account/saving/Timeline.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.saving +package com.mifos.core.model.objects.account.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Timeline( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt similarity index 57% rename from core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt index 4d8b37f5d8..6275a6f97c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerInboxSearchTemplate.kt @@ -7,11 +7,13 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.checkerinboxtask +package com.mifos.core.model.objects.checkerinboxtask -import com.google.gson.annotations.SerializedName +import kotlinx.serialization.SerialName +import kotlinx.serialization.Serializable +@Serializable data class CheckerInboxSearchTemplate( - @SerializedName("actionNames") var actionNames: List, - @SerializedName("entityNames") var entityNames: List, + @SerialName("actionNames") var actionNames: List, + @SerialName("entityNames") var entityNames: List, ) diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerTask.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerTask.kt similarity index 83% rename from core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerTask.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerTask.kt index 0a7dedb64a..46988c700e 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/CheckerTask.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/CheckerTask.kt @@ -7,14 +7,15 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.checkerinboxtask +package com.mifos.core.model.objects.checkerinboxtask -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize import java.sql.Timestamp import java.text.SimpleDateFormat import java.util.Date +// TODO migrate to KMP core.common @Parcelize data class CheckerTask( var id: Int, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleLoansTask.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleLoansTask.kt similarity index 67% rename from core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleLoansTask.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleLoansTask.kt index 3ab237fb08..a1816fe5f6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleLoansTask.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleLoansTask.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.checkerinboxtask +package com.mifos.core.model.objects.checkerinboxtask -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class RescheduleLoansTask( @@ -19,5 +19,5 @@ data class RescheduleLoansTask( var loanAccountNumber: String, var rescheduleFromDate: Array, var actionName: String, - var rescheduleReasonCodeValue: RescheduleReasonCodeValue, + var rescheduleReasonCodeValue: com.mifos.core.model.objects.checkerinboxtask.RescheduleReasonCodeValue, ) : Parcelable diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleReasonCodeValue.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleReasonCodeValue.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleReasonCodeValue.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleReasonCodeValue.kt index 25a2199aef..23e2eabc3a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/checkerinboxtask/RescheduleReasonCodeValue.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/checkerinboxtask/RescheduleReasonCodeValue.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.checkerinboxtask +package com.mifos.core.model.objects.checkerinboxtask -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class RescheduleReasonCodeValue( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ActivatePayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ActivatePayload.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/ActivatePayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ActivatePayload.kt index b7e57ca3b5..c82229b58b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ActivatePayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ActivatePayload.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 09/02/17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Address.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Address.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/Address.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Address.kt index 78f2e689b9..ea0d351f02 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Address.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Address.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 15/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargeCreationResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargeCreationResponse.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargeCreationResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargeCreationResponse.kt index 981be9e498..5073273ac6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargeCreationResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargeCreationResponse.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 13-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargesRename.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargesRename.kt similarity index 93% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargesRename.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargesRename.kt index 0bee6a5eff..b239517712 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ChargesRename.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ChargesRename.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients /** * Created by nellyk on 2/15/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressRequest.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressRequest.kt similarity index 82% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressRequest.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressRequest.kt index dec4d27be6..224de1e16a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressRequest.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressRequest.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class ClientAddressRequest( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressResponse.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressResponse.kt index 85bf8b433f..a52b382489 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/ClientAddressResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/ClientAddressResponse.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class ClientAddressResponse( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Page.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Page.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/Page.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Page.kt index 21c1b3bc86..fe98e418d1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Page.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Page.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients /** * Created by ishankhanna on 09/02/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Permission.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Permission.kt similarity index 92% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/Permission.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Permission.kt index 8b06067ad5..72d04eec5d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Permission.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Permission.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients /** * Created by ishankhanna on 09/02/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Role.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Role.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/clients/Role.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Role.kt index d44b2c5c32..a8d8e22a2c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/clients/Role.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/clients/Role.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.clients +package com.mifos.core.model.objects.clients /** * Created by ishankhanna on 09/02/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/AttendanceTypeOption.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/AttendanceTypeOption.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/AttendanceTypeOption.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/AttendanceTypeOption.kt index 342558e53d..2a675065c4 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/AttendanceTypeOption.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/AttendanceTypeOption.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 21-07-2017. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/BulkSavingsDueTransaction.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/BulkSavingsDueTransaction.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/BulkSavingsDueTransaction.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/BulkSavingsDueTransaction.kt index 3bf68b236d..f871d12b97 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/BulkSavingsDueTransaction.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/BulkSavingsDueTransaction.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 31-07-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionFrequency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionFrequency.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionFrequency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionFrequency.kt index 76c52eed55..47b106c892 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionFrequency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionFrequency.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets /** * Created by ishankhanna on 16/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionMeetingCalendar.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionMeetingCalendar.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionMeetingCalendar.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionMeetingCalendar.kt index 17bd1b30de..fd71991b97 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionMeetingCalendar.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionMeetingCalendar.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 16/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionSheetRequestPayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionSheetRequestPayload.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionSheetRequestPayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionSheetRequestPayload.kt index 7536d8fd1a..8fd618114f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/CollectionSheetRequestPayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/CollectionSheetRequestPayload.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 25-07-2017. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/EntityType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/EntityType.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/EntityType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/EntityType.kt index e7080cac1e..82bd9c3017 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/EntityType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/EntityType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 16/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanAndClientName.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanAndClientName.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanAndClientName.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanAndClientName.kt index 4aa58043e8..60a7247263 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanAndClientName.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanAndClientName.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 17-07-2017. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanCollectionSheet.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanCollectionSheet.kt similarity index 68% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanCollectionSheet.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanCollectionSheet.kt index 66645825ab..570158c679 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/LoanCollectionSheet.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/LoanCollectionSheet.kt @@ -7,15 +7,16 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcel -import android.os.Parcelable -import com.mifos.core.objects.account.loan.Currency +import Currency +import com.mifos.core.common.utils.Parcel +import com.mifos.core.common.utils.Parcelable /** * Created by Tarun on 06-07-2017. */ +// TODO migrate class LoanCollectionSheet() : Parcelable { var accountId: String? = null var accountStatusId: Int = 0 @@ -33,13 +34,13 @@ class LoanCollectionSheet() : Parcelable { accountId = parcel.readString() accountStatusId = parcel.readInt() currency = parcel.readParcelable(Currency::class.java.classLoader) - interestDue = parcel.readValue(Double::class.java.classLoader) as? Double - interestPaid = parcel.readValue(Double::class.java.classLoader) as? Double - loanId = parcel.readValue(Int::class.java.classLoader) as Int - principalDue = parcel.readValue(Double::class.java.classLoader) as? Double - productId = parcel.readValue(Double::class.java.classLoader) as? Double - totalDue = parcel.readValue(Double::class.java.classLoader) as Double - chargesDue = parcel.readValue(Double::class.java.classLoader) as Double + interestDue = parcel.readDouble() + interestPaid = parcel.readDouble() + loanId = parcel.readInt() + principalDue = parcel.readDouble() + productId = parcel.readDouble() + totalDue = parcel.readDouble() + chargesDue = parcel.readDouble() productShortName = parcel.readString() } @@ -51,13 +52,13 @@ class LoanCollectionSheet() : Parcelable { dest.writeString(accountId) dest.writeInt(accountStatusId) dest.writeParcelable(currency, flags) - dest.writeValue(interestDue) - dest.writeValue(interestPaid) - dest.writeValue(loanId) - dest.writeValue(principalDue) - dest.writeValue(productId) - dest.writeValue(totalDue) - dest.writeValue(chargesDue) + dest.writeDouble(interestDue) + dest.writeDouble(interestPaid) + dest.writeInt(loanId) + dest.writeDouble(principalDue) + dest.writeDouble(productId) + dest.writeDouble(totalDue) + dest.writeDouble(chargesDue) dest.writeString(productShortName) } diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/SavingsProduct.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/SavingsProduct.kt similarity index 83% rename from core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/SavingsProduct.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/SavingsProduct.kt index 1d9f0d3ea5..7cd35edb7c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/collectionsheets/SavingsProduct.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/collectionsheets/SavingsProduct.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.collectionsheets +package com.mifos.core.model.objects.collectionsheets -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 31-07-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/commonfiles/InterestType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/commonfiles/InterestType.kt similarity index 82% rename from core/model/src/main/kotlin/com/mifos/core/objects/commonfiles/InterestType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/commonfiles/InterestType.kt index bbd5aefd88..5a9e410ab7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/commonfiles/InterestType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/commonfiles/InterestType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.commonfiles +package com.mifos.core.model.objects.commonfiles -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /* * This project is licensed under the open source MPL V2. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Account.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Account.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Account.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Account.kt index 9d75c4901f..156faeca17 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Account.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Account.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Account( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/AttendanceType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/AttendanceType.kt similarity index 71% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/AttendanceType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/AttendanceType.kt index ab40ae31f5..ff5afdd3c0 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/AttendanceType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/AttendanceType.kt @@ -7,12 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class AttendanceType( var attendanceTypeId: Int = 0, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Client.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Client.kt similarity index 73% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Client.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Client.kt index 2fe7375a00..4f6347ab01 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Client.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Client.kt @@ -7,12 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class Client( var clientId: Int = 0, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionMeetingCalendar.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionMeetingCalendar.kt similarity index 84% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionMeetingCalendar.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionMeetingCalendar.kt index f7d4f847f2..d5710ecd48 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionMeetingCalendar.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionMeetingCalendar.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class CollectionMeetingCalendar( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionSheet.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionSheet.kt similarity index 69% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionSheet.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionSheet.kt index cd8b6b6290..48acf35140 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/CollectionSheet.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/CollectionSheet.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import com.google.gson.Gson +import kotlinx.serialization.Serializable +import kotlinx.serialization.json.Json +@Serializable data class CollectionSheet( var dueDate: IntArray, var groups: List, ) { override fun toString(): String { - return Gson().toJson(this) + return Json.encodeToString(serializer(), this) } } diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Currency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Currency.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Currency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Currency.kt index 6254de4618..bbef0903d4 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Currency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Currency.kt @@ -7,12 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class Currency( var code: String? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/EntityType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/EntityType.kt similarity index 75% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/EntityType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/EntityType.kt index 0fbd0e571c..c408d9c78e 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/EntityType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/EntityType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class EntityType( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Loan.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Loan.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Loan.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Loan.kt index e55823bd1e..f92567ec42 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Loan.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Loan.kt @@ -7,12 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class Loan( var disbursementAmount: Double = 0.0, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingCenter.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingCenter.kt similarity index 85% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingCenter.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingCenter.kt index b0346e3de7..75a4396810 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingCenter.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingCenter.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class MeetingCenter( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingDate.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingDate.kt similarity index 75% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingDate.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingDate.kt index 77a4b077b1..f7872cd2ab 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MeetingDate.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MeetingDate.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class MeetingDate( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MifosGroup.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MifosGroup.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MifosGroup.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MifosGroup.kt index b0ea098ee1..e7e6d4158a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/MifosGroup.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/MifosGroup.kt @@ -7,12 +7,14 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable @Parcelize +@Serializable data class MifosGroup( var staffId: Int = 0, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/OfflineCenter.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/OfflineCenter.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/OfflineCenter.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/OfflineCenter.kt index 687bce2ef7..a741b3a6c1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/OfflineCenter.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/OfflineCenter.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class OfflineCenter( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/RepaymentTransaction.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/RepaymentTransaction.kt similarity index 75% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/RepaymentTransaction.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/RepaymentTransaction.kt index 903d6479a2..685b503275 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/RepaymentTransaction.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/RepaymentTransaction.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class RepaymentTransaction( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Status.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Status.kt similarity index 74% rename from core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Status.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Status.kt index 66bb0aece8..b4dd348190 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/databaseobjects/Status.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/databaseobjects/Status.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.databaseobjects +package com.mifos.core.model.objects.databaseobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Status( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/error/Arg.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Arg.kt similarity index 74% rename from core/model/src/main/kotlin/com/mifos/core/objects/error/Arg.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Arg.kt index c56c40cb8b..1ce24731cc 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/error/Arg.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Arg.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.error +package com.mifos.core.model.objects.error -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Arg( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/error/Errors.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Errors.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/error/Errors.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Errors.kt index 0d2530e966..e653d65e78 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/error/Errors.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/Errors.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.error +package com.mifos.core.model.objects.error -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Errors( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/error/MifosError.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/MifosError.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/error/MifosError.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/MifosError.kt index e4de607772..9d6c2ff373 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/error/MifosError.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/error/MifosError.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.error +package com.mifos.core.model.objects.error -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class MifosError( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/groups/CenterInfo.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/groups/CenterInfo.kt similarity index 85% rename from core/model/src/main/kotlin/com/mifos/core/objects/groups/CenterInfo.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/groups/CenterInfo.kt index eb261ae4d0..1622845d47 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/groups/CenterInfo.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/groups/CenterInfo.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.groups +package com.mifos.core.model.objects.groups -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 05/02/17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/nav/ClientArgs.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/ClientArgs.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/nav/ClientArgs.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/ClientArgs.kt index c6521a79c1..0ee5f95302 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/nav/ClientArgs.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/ClientArgs.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.nav +package com.mifos.core.model.objects.nav -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /* * Created by Aditya Gupta on 22/7/23. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/nav/DataTableNavigationArg.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/DataTableNavigationArg.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/nav/DataTableNavigationArg.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/DataTableNavigationArg.kt index 40549541d3..24c4ca69f6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/nav/DataTableNavigationArg.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/nav/DataTableNavigationArg.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.nav +package com.mifos.core.model.objects.nav data class DataTableNavigationArg( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Document.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Document.kt similarity index 82% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Document.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Document.kt index 6fb241ca2a..8e3aeb7a66 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Document.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Document.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 02/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/DocumentType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/DocumentType.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/DocumentType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/DocumentType.kt index 4842f9c12a..853c482c84 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/DocumentType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/DocumentType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 03/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Identifier.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Identifier.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Identifier.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Identifier.kt index 86b7d844d3..511ed8b8a5 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/Identifier.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/Identifier.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by ishankhanna on 03/07/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierCreationResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierCreationResponse.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierCreationResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierCreationResponse.kt index 39d1dc5403..0c38af39b1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierCreationResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierCreationResponse.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 07-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierPayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierPayload.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierPayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierPayload.kt index c6411cb72f..4b0bf67b48 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierPayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierPayload.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 01/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierTemplate.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierTemplate.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierTemplate.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierTemplate.kt index 502fdb488d..84d709d7bc 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierTemplate.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierTemplate.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 01/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierType.kt index 74b1ec1c34..9f0288b7e6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/noncoreobjects/IdentifierType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/noncoreobjects/IdentifierType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.noncoreobjects +package com.mifos.core.model.objects.noncoreobjects -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 01/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AccountingRule.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AccountingRule.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/AccountingRule.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AccountingRule.kt index 6ddc4bbbe7..a34c52f936 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AccountingRule.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AccountingRule.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class AccountingRule( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AllowAttributeOverrides.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AllowAttributeOverrides.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/AllowAttributeOverrides.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AllowAttributeOverrides.kt index 3ae1ad88a2..339c82a1b9 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AllowAttributeOverrides.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AllowAttributeOverrides.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class AllowAttributeOverrides( var amortizationType: Boolean? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AmortizationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AmortizationType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/AmortizationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AmortizationType.kt index c61b61b2fc..f5b17f0c9a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/AmortizationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/AmortizationType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class AmortizationType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientClassificationOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientClassificationOptions.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientClassificationOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientClassificationOptions.kt index 37fd99747b..87b40598c1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientClassificationOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientClassificationOptions.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientTypeOptions.kt similarity index 89% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientTypeOptions.kt index 7bb380ce07..8b969cba52 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ClientTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ClientTypeOptions.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/Currency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/Currency.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/Currency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/Currency.kt index 6c5779455d..e47e315bb3 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/Currency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/Currency.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class Currency( var code: String? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInMonthType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInMonthType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInMonthType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInMonthType.kt index 890cf85316..646bcc44c8 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInMonthType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInMonthType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class DaysInMonthType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInYearType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInYearType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInYearType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInYearType.kt index f031d1b77a..e69a2bdfc1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/DaysInYearType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/DaysInYearType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class DaysInYearType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/GenderOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/GenderOptions.kt similarity index 89% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/GenderOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/GenderOptions.kt index f3d0024b08..b186c0d38d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/GenderOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/GenderOptions.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationDaysInYearType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationDaysInYearType.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationDaysInYearType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationDaysInYearType.kt index d7237f0d3d..4b88ee01a7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationDaysInYearType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationDaysInYearType.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationPeriodType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationPeriodType.kt index 16c9435f7d..8f604c974e 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationPeriodType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class InterestCalculationPeriodType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationTypeOptions.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationTypeOptions.kt index 167beac18b..e3c9151004 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCalculationTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCalculationTypeOptions.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCompoundingPeriod.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCompoundingPeriod.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCompoundingPeriod.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCompoundingPeriod.kt index cfb9ab7424..0297f47f77 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestCompoundingPeriod.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestCompoundingPeriod.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestPostingPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestPostingPeriodType.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestPostingPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestPostingPeriodType.kt index c7ad38e7c8..cd473aacf9 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestPostingPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestPostingPeriodType.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nkiboi on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestRateFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestRateFrequencyType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestRateFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestRateFrequencyType.kt index 18aa25a5fa..e96de29af7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestRateFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestRateFrequencyType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class InterestRateFrequencyType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestType.kt index 95f3270f47..33149c1850 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/InterestType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/InterestType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class InterestType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanFund.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanFund.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanFund.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanFund.kt index f9e1a62f09..41ffb5e529 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanFund.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanFund.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nellyk on 2/21/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanProducts.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanProducts.kt similarity index 54% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanProducts.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanProducts.kt index 0596d299dc..2e4d263e60 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanProducts.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanProducts.kt @@ -7,165 +7,167 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import com.google.gson.annotations.SerializedName -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.SerialName +import kotlinx.serialization.Serializable /** * * Created by Rajan Maurya on 12/15/2015. */ @Parcelize +@Serializable data class LoanProducts( - @SerializedName("id") + @SerialName("id") var id: Int? = null, - @SerializedName("name") + @SerialName("name") var name: String? = null, - @SerializedName("shortName") + @SerialName("shortName") var shortName: String? = null, - @SerializedName("description") + @SerialName("description") var description: String? = null, - @SerializedName("fundId") + @SerialName("fundId") var fundId: Int? = null, - @SerializedName("fundName") + @SerialName("fundName") var fundName: String? = null, - @SerializedName("includeInBorrowerCycle") + @SerialName("includeInBorrowerCycle") var includeInBorrowerCycle: Boolean? = null, - @SerializedName("useBorrowerCycle") + @SerialName("useBorrowerCycle") var useBorrowerCycle: Boolean? = null, - @SerializedName("startDate") + @SerialName("startDate") var startDate: List? = null, - @SerializedName("closeDate") + @SerialName("closeDate") var closeDate: List? = null, - @SerializedName("status") + @SerialName("status") var status: String? = null, - @SerializedName("currency") + @SerialName("currency") var currency: Currency? = null, - @SerializedName("principal") + @SerialName("principal") var principal: Double? = null, - @SerializedName("minPrincipal") + @SerialName("minPrincipal") var minPrincipal: Double? = null, - @SerializedName("maxPrincipal") + @SerialName("maxPrincipal") var maxPrincipal: Double? = null, - @SerializedName("numberOfRepayments") + @SerialName("numberOfRepayments") var numberOfRepayments: Int? = null, - @SerializedName("minNumberOfRepayments") + @SerialName("minNumberOfRepayments") var minNumberOfRepayments: Int? = null, - @SerializedName("maxNumberOfRepayments") + @SerialName("maxNumberOfRepayments") var maxNumberOfRepayments: Int? = null, - @SerializedName("repaymentEvery") + @SerialName("repaymentEvery") var repaymentEvery: Int? = null, - @SerializedName("repaymentFrequencyType") + @SerialName("repaymentFrequencyType") var repaymentFrequencyType: RepaymentFrequencyType? = null, - @SerializedName("interestRatePerPeriod") + @SerialName("interestRatePerPeriod") var interestRatePerPeriod: Double? = null, - @SerializedName("minInterestRatePerPeriod") + @SerialName("minInterestRatePerPeriod") var minInterestRatePerPeriod: Double? = null, - @SerializedName("maxInterestRatePerPeriod") + @SerialName("maxInterestRatePerPeriod") var maxInterestRatePerPeriod: Double? = null, - @SerializedName("interestRateFrequencyType") + @SerialName("interestRateFrequencyType") var interestRateFrequencyType: InterestRateFrequencyType? = null, - @SerializedName("annualInterestRate") + @SerialName("annualInterestRate") var annualInterestRate: Double? = null, - @SerializedName("isLinkedToFloatingInterestRates") + @SerialName("isLinkedToFloatingInterestRates") var linkedToFloatingInterestRates: Boolean? = null, - @SerializedName("isFloatingInterestRateCalculationAllowed") + @SerialName("isFloatingInterestRateCalculationAllowed") var floatingInterestRateCalculationAllowed: Boolean? = null, - @SerializedName("allowVariableInstallments") + @SerialName("allowVariableInstallments") var allowVariableInstallments: Boolean? = null, - @SerializedName("minimumGap") + @SerialName("minimumGap") var minimumGap: Double? = null, - @SerializedName("maximumGap") + @SerialName("maximumGap") var maximumGap: Double? = null, - @SerializedName("amortizationType") + @SerialName("amortizationType") var amortizationType: AmortizationType? = null, - @SerializedName("interestType") + @SerialName("interestType") var interestType: InterestType? = null, - @SerializedName("interestCalculationPeriodType") + @SerialName("interestCalculationPeriodType") var interestCalculationPeriodType: InterestCalculationPeriodType? = null, - @SerializedName("allowPartialPeriodInterestCalcualtion") + @SerialName("allowPartialPeriodInterestCalcualtion") var allowPartialPeriodInterestCalcualtion: Boolean? = null, - @SerializedName("transactionProcessingStrategyId") + @SerialName("transactionProcessingStrategyId") var transactionProcessingStrategyId: Int? = null, - @SerializedName("transactionProcessingStrategyName") + @SerialName("transactionProcessingStrategyName") var transactionProcessingStrategyName: String? = null, - @SerializedName("graceOnPrincipalPayment") + @SerialName("graceOnPrincipalPayment") var graceOnPrincipalPayment: Int? = null, - @SerializedName("graceOnInterestPayment") + @SerialName("graceOnInterestPayment") var graceOnInterestPayment: Int? = null, - @SerializedName("daysInMonthType") + @SerialName("daysInMonthType") var daysInMonthType: DaysInMonthType? = null, - @SerializedName("daysInYearType") + @SerialName("daysInYearType") var daysInYearType: DaysInYearType? = null, - @SerializedName("isInterestRecalculationEnabled") + @SerialName("isInterestRecalculationEnabled") var interestRecalculationEnabled: Boolean? = null, - @SerializedName("canDefineInstallmentAmount") + @SerialName("canDefineInstallmentAmount") var canDefineInstallmentAmount: Boolean? = null, - @SerializedName("installmentAmountInMultiplesOf") + @SerialName("installmentAmountInMultiplesOf") var installmentAmountInMultiplesOf: Int? = null, - @SerializedName("accountingRule") + @SerialName("accountingRule") var accountingRule: AccountingRule? = null, - @SerializedName("multiDisburseLoan") + @SerialName("multiDisburseLoan") var multiDisburseLoan: Boolean? = null, - @SerializedName("maxTrancheCount") + @SerialName("maxTrancheCount") var maxTrancheCount: Int? = null, - @SerializedName("principalThresholdForLastInstallment") + @SerialName("principalThresholdForLastInstallment") var principalThresholdForLastInstallment: Int? = null, - @SerializedName("holdGuaranteeFunds") + @SerialName("holdGuaranteeFunds") var holdGuaranteeFunds: Boolean? = null, - @SerializedName("accountMovesOutOfNPAOnlyOnArrearsCompletion") + @SerialName("accountMovesOutOfNPAOnlyOnArrearsCompletion") var accountMovesOutOfNPAOnlyOnArrearsCompletion: Boolean? = null, - @SerializedName("allowAttributeOverrides") + @SerialName("allowAttributeOverrides") var allowAttributeOverrides: AllowAttributeOverrides? = null, ) : Parcelable diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanPurpose.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanPurpose.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanPurpose.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanPurpose.kt index 736b95f9f6..e577b7e948 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/LoanPurpose.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/LoanPurpose.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nellyk on 2/21/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ProductSavings.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ProductSavings.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/ProductSavings.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ProductSavings.kt index 154e61c689..7dfdb3f850 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/ProductSavings.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/ProductSavings.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations /** * Created by nellyk on 12/15/2015. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/RepaymentFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/RepaymentFrequencyType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/organisations/RepaymentFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/RepaymentFrequencyType.kt index 9ae424120b..453a4c6be1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/organisations/RepaymentFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/organisations/RepaymentFrequencyType.kt @@ -7,15 +7,17 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.organisations +package com.mifos.core.model.objects.organisations -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.Serializable /** * Created by Rajan Maurya on 15/07/16. */ @Parcelize +@Serializable data class RepaymentFrequencyType( var id: Int? = null, diff --git a/core/model/src/main/kotlin/com/mifos/core/payloads/ChargesPayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/ChargesPayload.kt similarity index 94% rename from core/model/src/main/kotlin/com/mifos/core/payloads/ChargesPayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/ChargesPayload.kt index fc9dada280..7cc9bea860 100644 --- a/core/model/src/main/kotlin/com/mifos/core/payloads/ChargesPayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/ChargesPayload.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.payloads +package com.mifos.core.model.objects.payloads /** * Created by nellyk on 2/15/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/payloads/GroupLoanPayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/GroupLoanPayload.kt similarity index 92% rename from core/model/src/main/kotlin/com/mifos/core/payloads/GroupLoanPayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/GroupLoanPayload.kt index d5c8fab5a7..e2a45fabb8 100644 --- a/core/model/src/main/kotlin/com/mifos/core/payloads/GroupLoanPayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/GroupLoanPayload.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.payloads +package com.mifos.core.model.objects.payloads -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by nellyk on 2/20/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/payloads/SavingsPayload.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/SavingsPayload.kt similarity index 96% rename from core/model/src/main/kotlin/com/mifos/core/payloads/SavingsPayload.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/SavingsPayload.kt index bc1c0a2b85..25d11887b1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/payloads/SavingsPayload.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/payloads/SavingsPayload.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.payloads +package com.mifos.core.model.objects.payloads /** * Created by nellyk on 2/10/2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/responses/SaveResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/responses/SaveResponse.kt similarity index 58% rename from core/model/src/main/kotlin/com/mifos/core/objects/responses/SaveResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/responses/SaveResponse.kt index aa39e14b1e..4204af0e3c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/responses/SaveResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/responses/SaveResponse.kt @@ -7,23 +7,27 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.responses +package com.mifos.core.model.objects.responses -import com.google.gson.Gson -import com.google.gson.annotations.SerializedName -import com.mifos.core.objects.Changes +import com.mifos.core.model.objects.Changes +import kotlinx.serialization.SerialName +import kotlinx.serialization.Serializable +import kotlinx.serialization.json.Json +@Serializable class SaveResponse { - @SerializedName("groupId") + @SerialName("groupId") var groupId: Int? = null - @SerializedName("resourceId") + @SerialName("resourceId") var resourceId: Int? = null - @SerializedName("officeId") + @SerialName("officeId") var officeId: Int? = null + var changes: Changes? = null + override fun toString(): String { - return Gson().toJson(this) + return Json.encodeToString(serializer(), this) } } diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/ColumnHeader.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/ColumnHeader.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/runreport/ColumnHeader.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/ColumnHeader.kt index 90926f717b..f6c8c41379 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/ColumnHeader.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/ColumnHeader.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.runreport +package com.mifos.core.model.objects.runreport -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 03-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/DataRow.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/DataRow.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/runreport/DataRow.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/DataRow.kt index 7b05d316c8..98f005facd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/DataRow.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/DataRow.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.runreport +package com.mifos.core.model.objects.runreport -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 03-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/FullParameterListResponse.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/FullParameterListResponse.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/runreport/FullParameterListResponse.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/FullParameterListResponse.kt index e5d2893bb7..49cf2ca7bc 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/FullParameterListResponse.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/FullParameterListResponse.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.runreport +package com.mifos.core.model.objects.runreport -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 03-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/client/ClientReportTypeItem.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/client/ClientReportTypeItem.kt similarity index 83% rename from core/model/src/main/kotlin/com/mifos/core/objects/runreport/client/ClientReportTypeItem.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/client/ClientReportTypeItem.kt index fb58460ed7..57e1ca63b0 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/runreport/client/ClientReportTypeItem.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/runreport/client/ClientReportTypeItem.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.runreport.client +package com.mifos.core.model.objects.runreport.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Tarun on 03-08-17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/surveys/Scorecard.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/Scorecard.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/surveys/Scorecard.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/Scorecard.kt index 998df1a981..0937268778 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/surveys/Scorecard.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/Scorecard.kt @@ -7,15 +7,15 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.surveys +package com.mifos.core.model.objects.surveys -import android.os.Parcelable -import kotlinx.parcelize.Parcelize -import java.util.Date +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Nasim Banu on 28,January,2016. */ +// TODO date @Parcelize data class Scorecard( var userId: Int = 0, diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/surveys/ScorecardValues.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/ScorecardValues.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/surveys/ScorecardValues.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/ScorecardValues.kt index f80243c8c6..4a136c9e91 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/surveys/ScorecardValues.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/surveys/ScorecardValues.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.surveys +package com.mifos.core.model.objects.surveys -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Nasim Banu on 28,January,2016. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/systems/Code.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/Code.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/systems/Code.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/Code.kt index a7032c6b2d..270b5ca852 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/systems/Code.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/Code.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.systems +package com.mifos.core.model.objects.systems /** * Created by ishankhanna on 16/06/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/systems/CodeValue.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/CodeValue.kt similarity index 91% rename from core/model/src/main/kotlin/com/mifos/core/objects/systems/CodeValue.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/CodeValue.kt index 670d244ae5..c59048e039 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/systems/CodeValue.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/systems/CodeValue.kt @@ -7,7 +7,7 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.systems +package com.mifos.core.model.objects.systems /** * Created by ishankhanna on 16/06/14. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeAppliesTo.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeAppliesTo.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeAppliesTo.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeAppliesTo.kt index c477e4a0b9..8c731e4392 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeAppliesTo.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeAppliesTo.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeCalculationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeCalculationType.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeCalculationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeCalculationType.kt index 2de0efc3a3..ce0ddf4e6e 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeCalculationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeCalculationType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeOptions.kt similarity index 84% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeOptions.kt index 60302dc96f..cde6c830fd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargePaymentMode.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargePaymentMode.kt similarity index 81% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargePaymentMode.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargePaymentMode.kt index 7ec2ad8eb5..cac8228b9f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargePaymentMode.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargePaymentMode.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTemplate.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTemplate.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTemplate.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTemplate.kt index b098ad2462..810ba86ac6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTemplate.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTemplate.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTimeType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTimeType.kt similarity index 72% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTimeType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTimeType.kt index faf7918281..6b5734603d 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/ChargeTimeType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/ChargeTimeType.kt @@ -7,22 +7,18 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import com.google.gson.annotations.SerializedName -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. */ @Parcelize data class ChargeTimeType( - @SerializedName("id") val id: Int? = null, - @SerializedName("code") val code: String? = null, - @SerializedName("value") val value: String? = null, ) : Parcelable { override fun toString(): String { diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/Currency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/Currency.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/Currency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/Currency.kt index 32ddc84430..12cc9b5b4a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/Currency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/Currency.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Currency( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/IncomeOrLiabilityAccount.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/IncomeOrLiabilityAccount.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/client/IncomeOrLiabilityAccount.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/IncomeOrLiabilityAccount.kt index 4e2a6e21cc..aae448b70f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/client/IncomeOrLiabilityAccount.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/client/IncomeOrLiabilityAccount.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.client +package com.mifos.core.model.objects.template.client -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 13/12/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AccountingRule.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AccountingRule.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AccountingRule.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AccountingRule.kt index aac94e0d06..190fbc88de 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AccountingRule.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AccountingRule.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AllowAttributeOverrides.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AllowAttributeOverrides.kt similarity index 85% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AllowAttributeOverrides.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AllowAttributeOverrides.kt index 22b1973e98..d1973a49a9 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AllowAttributeOverrides.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AllowAttributeOverrides.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationType.kt index 11f1897614..4a23e89469 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationTypeOptions.kt index c8b4d1b224..bb827fee78 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/AmortizationTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/AmortizationTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptions.kt similarity index 90% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptions.kt index 3eec60651b..18da505164 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptionsType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptionsType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptionsType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptionsType.kt index 0db28f6470..4cec66febd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/CalendarOptionsType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/CalendarOptionsType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeAppliesTo.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeAppliesTo.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeAppliesTo.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeAppliesTo.kt index dfb38ae3fe..6a7fe27b4b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeAppliesTo.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeAppliesTo.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeCalculationType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeCalculationType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeCalculationType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeCalculationType.kt index 4e3bd0c5d7..b57c552fd0 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeCalculationType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeCalculationType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeOptions.kt similarity index 86% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeOptions.kt index 22b439f514..ffdab1aa09 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargePaymentMode.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargePaymentMode.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargePaymentMode.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargePaymentMode.kt index b217866d9f..808d61e0d7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargePaymentMode.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargePaymentMode.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeTimeType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeTimeType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeTimeType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeTimeType.kt index 43ba0b9248..f075dd950f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ChargeTimeType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ChargeTimeType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Charges.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Charges.kt similarity index 88% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Charges.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Charges.kt index f0d374e3d5..654151d03b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Charges.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Charges.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Currency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Currency.kt similarity index 82% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Currency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Currency.kt index 41b482fcc2..4e35845383 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Currency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Currency.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInMonthType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInMonthType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInMonthType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInMonthType.kt index 7cd405d329..805b4890b1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInMonthType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInMonthType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInYearType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInYearType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInYearType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInYearType.kt index fbeffbabb9..6931475c72 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/DaysInYearType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/DaysInYearType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/EntityType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/EntityType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/EntityType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/EntityType.kt index 8733cc5b96..493ab79a9a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/EntityType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/EntityType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Frequency.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Frequency.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Frequency.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Frequency.kt index f3109fed8f..7430b585e2 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Frequency.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Frequency.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/FundOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/FundOptions.kt similarity index 77% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/FundOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/FundOptions.kt index 492665dce4..e6d0a404d5 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/FundOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/FundOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Group.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Group.kt similarity index 85% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Group.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Group.kt index c6c392d798..0a1a67f696 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Group.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Group.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupLoanTemplate.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupLoanTemplate.kt similarity index 96% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupLoanTemplate.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupLoanTemplate.kt index 22b0bd75c8..35e131ecaf 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupLoanTemplate.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupLoanTemplate.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupTimeline.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupTimeline.kt similarity index 84% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupTimeline.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupTimeline.kt index 7aa856add7..797f9a934a 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/GroupTimeline.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/GroupTimeline.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodType.kt index 9063faa821..7471a48d20 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodTypeOptions.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodTypeOptions.kt index 80136264b9..71c47401c7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestCalculationPeriodTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestCalculationPeriodTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyType.kt index 2797627eda..48241b4f25 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyTypeOptions.kt index 58b5c6edf1..6173fd68be 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRateFrequencyTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRateFrequencyTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationCompoundingType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationCompoundingType.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationCompoundingType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationCompoundingType.kt index d09f5bbc0d..f10b674d34 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationCompoundingType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationCompoundingType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationData.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationData.kt similarity index 88% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationData.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationData.kt index a43c15f361..dfe6abd185 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestRecalculationData.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestRecalculationData.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestType.kt index d206f6295b..108ebf3289 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestTypeOptions.kt index c5af8f6e48..72812ce758 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/InterestTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/InterestTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanCollateralOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanCollateralOptions.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanCollateralOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanCollateralOptions.kt index 42778634d4..751e371f53 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanCollateralOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanCollateralOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanOfficerOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanOfficerOptions.kt similarity index 84% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanOfficerOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanOfficerOptions.kt index 11039c14fc..8106dfe065 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanOfficerOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanOfficerOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanPurposeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanPurposeOptions.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanPurposeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanPurposeOptions.kt index d5c7fa575a..a23fdcb6d9 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/LoanPurposeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/LoanPurposeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/OverdueCharges.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/OverdueCharges.kt similarity index 74% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/OverdueCharges.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/OverdueCharges.kt index 9b6ccaf463..f78966c8bd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/OverdueCharges.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/OverdueCharges.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/PreClosureInterestCalculationStrategy.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/PreClosureInterestCalculationStrategy.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/PreClosureInterestCalculationStrategy.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/PreClosureInterestCalculationStrategy.kt index b780213374..91ce46c27f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/PreClosureInterestCalculationStrategy.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/PreClosureInterestCalculationStrategy.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Product.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Product.kt similarity index 95% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Product.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Product.kt index 8c4b4930fd..cac716554c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Product.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Product.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ProductOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ProductOptions.kt similarity index 87% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ProductOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ProductOptions.kt index fb7d39245f..7b9cda821b 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/ProductOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/ProductOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RecalculationRestFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RecalculationRestFrequencyType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RecalculationRestFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RecalculationRestFrequencyType.kt index 30286f20b3..e5a0a18b28 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RecalculationRestFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RecalculationRestFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt similarity index 79% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt index 7e296493a4..66b39014dd 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyDaysOfWeekTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt index 584cbeb977..2a232160a1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyNthDayTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyType.kt index 46fbf02226..b997672fc1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyTypeOptions.kt index a3c879dda0..5c2ee2eb11 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepaymentFrequencyTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepaymentFrequencyTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepeatsOnNthDayOfMonth.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepeatsOnNthDayOfMonth.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepeatsOnNthDayOfMonth.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepeatsOnNthDayOfMonth.kt index 982fde0645..4b7674a82c 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RepeatsOnNthDayOfMonth.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RepeatsOnNthDayOfMonth.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RescheduleStrategyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RescheduleStrategyType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RescheduleStrategyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RescheduleStrategyType.kt index 2af5c6e363..2e3df15964 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/RescheduleStrategyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/RescheduleStrategyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Status.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Status.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Status.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Status.kt index 2916bf57d0..c1dd9ae7e4 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Status.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Status.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by mayankjindal on 02/10/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TaxGroup.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TaxGroup.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TaxGroup.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TaxGroup.kt index 7970fee016..d1081cf358 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TaxGroup.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TaxGroup.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermFrequencyTypeOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermFrequencyTypeOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermFrequencyTypeOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermFrequencyTypeOptions.kt index 2fdd32475b..cdae74bfd5 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermFrequencyTypeOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermFrequencyTypeOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermPeriodFrequencyType.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermPeriodFrequencyType.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermPeriodFrequencyType.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermPeriodFrequencyType.kt index c0343d9e70..ddf239d77f 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TermPeriodFrequencyType.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TermPeriodFrequencyType.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Timeline.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Timeline.kt similarity index 76% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Timeline.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Timeline.kt index b982fc531b..d0f41acf2e 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/Timeline.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Timeline.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TransactionProcessingStrategyOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TransactionProcessingStrategyOptions.kt similarity index 78% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TransactionProcessingStrategyOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TransactionProcessingStrategyOptions.kt index ad9498b803..3a5b1844de 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/loan/TransactionProcessingStrategyOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/TransactionProcessingStrategyOptions.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 16/07/16. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Type.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Type.kt similarity index 88% rename from core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Type.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Type.kt index e4bef794bc..6f8c4e80e7 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/account/loan/Type.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/loan/Type.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.account.loan +package com.mifos.core.model.objects.template.loan -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class Type( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/saving/AccountOptions.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/AccountOptions.kt similarity index 80% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/saving/AccountOptions.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/AccountOptions.kt index 264edf333c..151c9817df 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/saving/AccountOptions.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/AccountOptions.kt @@ -7,11 +7,11 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.saving +package com.mifos.core.model.objects.template.saving -import android.os.Parcelable -import com.mifos.core.objects.account.loan.InterestType -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import com.mifos.core.model.objects.account.loan.InterestType /* * This project is licensed under the open source MPL V2. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/template/saving/TagId.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/TagId.kt similarity index 73% rename from core/model/src/main/kotlin/com/mifos/core/objects/template/saving/TagId.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/TagId.kt index 2058e0cc07..e023f6dee1 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/template/saving/TagId.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/template/saving/TagId.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.template.saving +package com.mifos.core.model.objects.template.saving -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize @Parcelize data class TagId( diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/users/User.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/User.kt similarity index 94% rename from core/model/src/main/kotlin/com/mifos/core/objects/users/User.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/User.kt index 0352b2bc15..8dc8b9d6c6 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/users/User.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/User.kt @@ -7,9 +7,9 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.users +package com.mifos.core.model.objects.users -import com.mifos.core.objects.clients.Role +import com.mifos.core.model.objects.clients.Role class User { // {"username":"User1","userId":1,"base64EncodedAuthenticationKey":"VXNlcjE6dGVjaDRtZg\u003d diff --git a/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLatLng.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLatLng.kt new file mode 100644 index 0000000000..04dfb3eab7 --- /dev/null +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLatLng.kt @@ -0,0 +1,82 @@ +/* + * Copyright 2024 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/android-client/blob/master/LICENSE.md + */ +package com.mifos.core.model.objects.users + +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize +import kotlinx.serialization.SerialName +import kotlinx.serialization.Serializable + +/** + * Created by Rajan Maurya on 24/01/17. + */ +@Parcelize +@Serializable +data class UserLatLng( + @SerialName("lat") + val lat: Double = 0.0, + + @SerialName("lng") + val lng: Double = 0.0, +) : Parcelable { + override fun toString(): String { + return "{" + + "lat=" + lat + + ", lng=" + lng + + '}' + } +} + +// @Serializable +// class UserLatLng : Parcelable { +// @SerialName("lat") +// var lat: Double = 0.0 +// +// @SerialName("lng") +// var lng: Double = 0.0 +// override fun toString(): String { +// return "{" + +// "lat=" + lat + +// ", lng=" + lng + +// '}' +// } +// +// override fun describeContents(): Int { +// return 0 +// } +// +// override fun writeToParcel(dest: Parcel, flags: Int) { +// dest.writeValue(lat) +// dest.writeValue(lng) +// } +// +// constructor(latitude: Double, longitude: Double) { +// lat = latitude +// lng = longitude +// } +// +// private constructor(parcel: Parcel) { +// lat = parcel.readValue(Double::class.java.classLoader) as Double +// lng = parcel.readValue(Double::class.java.classLoader) as Double +// } +// +// companion object { +// @JvmField +// val CREATOR: Creator = object : Creator { +// override fun createFromParcel(source: Parcel): core.mifos.core.objects.users.UserLatLng { +// return core.mifos.core.objects.users.UserLatLng(source) +// } +// +// override fun newArray(size: Int): Array { +// return arrayOf() +// } +// } +// } +// } diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/users/UserLocation.kt b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLocation.kt similarity index 83% rename from core/model/src/main/kotlin/com/mifos/core/objects/users/UserLocation.kt rename to core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLocation.kt index c63748a0b7..8091af9564 100644 --- a/core/model/src/main/kotlin/com/mifos/core/objects/users/UserLocation.kt +++ b/core/model/src/commonMain/kotlin/com/mifos/core/model/objects/users/UserLocation.kt @@ -7,10 +7,10 @@ * * See https://github.com/openMF/android-client/blob/master/LICENSE.md */ -package com.mifos.core.objects.users +package com.mifos.core.model.objects.users -import android.os.Parcelable -import kotlinx.parcelize.Parcelize +import com.mifos.core.common.utils.Parcelable +import com.mifos.core.common.utils.Parcelize /** * Created by Rajan Maurya on 24/01/17. diff --git a/core/model/src/main/kotlin/com/mifos/core/objects/users/UserLatLng.kt b/core/model/src/main/kotlin/com/mifos/core/objects/users/UserLatLng.kt deleted file mode 100644 index 702cbf59ef..0000000000 --- a/core/model/src/main/kotlin/com/mifos/core/objects/users/UserLatLng.kt +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright 2024 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/android-client/blob/master/LICENSE.md - */ -package com.mifos.core.objects.users - -import android.os.Parcel -import android.os.Parcelable -import android.os.Parcelable.Creator -import com.google.gson.annotations.SerializedName - -/** - * Created by Rajan Maurya on 24/01/17. - */ -class UserLatLng : Parcelable { - @SerializedName("lat") - var lat: Double = 0.0 - - @SerializedName("lng") - var lng: Double = 0.0 - override fun toString(): String { - return "{" + - "lat=" + lat + - ", lng=" + lng + - '}' - } - - override fun describeContents(): Int { - return 0 - } - - override fun writeToParcel(dest: Parcel, flags: Int) { - dest.writeValue(lat) - dest.writeValue(lng) - } - - constructor(latitude: Double, longitude: Double) { - lat = latitude - lng = longitude - } - - private constructor(parcel: Parcel) { - lat = parcel.readValue(Double::class.java.classLoader) as Double - lng = parcel.readValue(Double::class.java.classLoader) as Double - } - - companion object { - @JvmField - val CREATOR: Creator = object : Creator { - override fun createFromParcel(source: Parcel): UserLatLng { - return UserLatLng(source) - } - - override fun newArray(size: Int): Array { - return arrayOf() - } - } - } -} diff --git a/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt b/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt index c47310f2a2..d30c1086a5 100644 --- a/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt +++ b/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt @@ -10,7 +10,6 @@ package com.mifos.core.network import com.google.gson.GsonBuilder -import com.mifos.core.model.getInstanceUrl import com.mifos.core.network.services.CenterService import com.mifos.core.network.services.ChargeService import com.mifos.core.network.services.CheckerInboxService @@ -28,6 +27,7 @@ import com.mifos.core.network.services.SavingsAccountService import com.mifos.core.network.services.SearchService import com.mifos.core.network.services.StaffService import com.mifos.core.network.services.SurveyService +import com.mifos.core.model.getInstanceUrl import org.mifos.core.utils.JsonDateSerializer import retrofit2.Retrofit import retrofit2.adapter.rxjava.RxJavaCallAdapterFactory diff --git a/core/network/src/main/java/com/mifos/core/network/DataManager.kt b/core/network/src/main/java/com/mifos/core/network/DataManager.kt index a47e0447d6..e939ff44b0 100644 --- a/core/network/src/main/java/com/mifos/core/network/DataManager.kt +++ b/core/network/src/main/java/com/mifos/core/network/DataManager.kt @@ -21,17 +21,15 @@ import com.mifos.core.entity.organisation.Staff import com.mifos.core.network.datamanager.DataManagerClient import com.mifos.core.network.model.CollectionSheetPayload import com.mifos.core.network.model.Payload -import com.mifos.core.objects.account.loan.LoanApproval import com.mifos.core.objects.clients.ChargeCreationResponse import com.mifos.core.objects.clients.Page import com.mifos.core.objects.databaseobjects.CollectionSheet import com.mifos.core.objects.databaseobjects.OfflineCenter -import com.mifos.core.objects.organisations.LoanProducts import com.mifos.core.objects.responses.SaveResponse import com.mifos.core.objects.template.client.ChargeTemplate import com.mifos.core.objects.template.loan.GroupLoanTemplate import com.mifos.core.payloads.ChargesPayload -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import okhttp3.ResponseBody import rx.Observable import javax.inject.Inject @@ -173,7 +171,7 @@ class DataManager { return mBaseApiManager.loanApi.getLoanWithTransactions(loan) } - val allLoans: Observable> + val allLoans: Observable> get() = mBaseApiManager.loanApi.allLoans fun getGroupLoansAccountTemplate(groupId: Int, productId: Int): Observable { @@ -188,7 +186,7 @@ class DataManager { return mBaseApiManager.loanApi.getLoanRepaymentSchedule(loanId) } - fun approveLoan(loanId: Int, loanApproval: LoanApproval?): Observable { + fun approveLoan(loanId: Int, loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval?): Observable { return mBaseApiManager.loanApi.approveLoanApplication(loanId, loanApproval) } diff --git a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerCheckerInbox.kt b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerCheckerInbox.kt index 19c282628f..12622e9ca4 100644 --- a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerCheckerInbox.kt +++ b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerCheckerInbox.kt @@ -13,7 +13,6 @@ import com.mifos.core.network.BaseApiManager import com.mifos.core.network.GenericResponse import com.mifos.core.objects.checkerinboxtask.CheckerInboxSearchTemplate import com.mifos.core.objects.checkerinboxtask.CheckerTask -import com.mifos.core.objects.checkerinboxtask.RescheduleLoansTask import rx.Observable import javax.inject.Inject @@ -45,7 +44,7 @@ class DataManagerCheckerInbox @Inject constructor( return mBaseApiManager.checkerInboxApi.deleteCheckerEntry(auditId) } - suspend fun getRechdeduleLoansTaskList(): List { + suspend fun getRechdeduleLoansTaskList(): List { return mBaseApiManager.checkerInboxApi.getRescheduleLoansTaskList() } diff --git a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerClient.kt b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerClient.kt index 42df2d25c9..7d36403983 100644 --- a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerClient.kt +++ b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerClient.kt @@ -21,8 +21,6 @@ import com.mifos.core.network.mappers.clients.GetClientsClientIdAccountMapper import com.mifos.core.network.mappers.clients.GetIdentifiersTemplateMapper import com.mifos.core.network.mappers.clients.IdentifierMapper import com.mifos.core.objects.clients.ActivatePayload -import com.mifos.core.objects.clients.ClientAddressRequest -import com.mifos.core.objects.clients.ClientAddressResponse import com.mifos.core.objects.clients.Page import com.mifos.core.objects.noncoreobjects.Identifier import com.mifos.core.objects.noncoreobjects.IdentifierCreationResponse @@ -350,7 +348,7 @@ class DataManagerClient @Inject constructor( * @param clientId Client Id * @return ClientAddressResponse */ - suspend fun getClientPinpointLocations(clientId: Int): List { + suspend fun getClientPinpointLocations(clientId: Int): List { return mBaseApiManager.clientsApi.getClientPinpointLocations(clientId) } @@ -363,7 +361,7 @@ class DataManagerClient @Inject constructor( */ suspend fun addClientPinpointLocation( clientId: Int, - address: ClientAddressRequest?, + address: com.mifos.core.model.objects.clients.ClientAddressRequest?, ): GenericResponse { return mBaseApiManager.clientsApi.addClientPinpointLocation(clientId, address) } @@ -394,7 +392,7 @@ class DataManagerClient @Inject constructor( suspend fun updateClientPinpointLocation( apptableId: Int, datatableId: Int, - address: ClientAddressRequest?, + address: com.mifos.core.model.objects.clients.ClientAddressRequest?, ): GenericResponse { return mBaseApiManager.clientsApi.updateClientPinpointLocation( apptableId, diff --git a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerLoan.kt b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerLoan.kt index 7dfbc4338a..7f083d764c 100644 --- a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerLoan.kt +++ b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerLoan.kt @@ -20,8 +20,6 @@ import com.mifos.core.network.BaseApiManager import com.mifos.core.network.GenericResponse import com.mifos.core.network.model.LoansPayload import com.mifos.core.objects.account.loan.LoanDisbursement -import com.mifos.core.objects.account.loan.LoanRepaymentResponse -import com.mifos.core.objects.organisations.LoanProducts import rx.Observable import javax.inject.Inject import javax.inject.Singleton @@ -79,7 +77,7 @@ class DataManagerLoan @Inject constructor( } } - val allLoans: Observable> + val allLoans: Observable> get() = mBaseApiManager.loanApi.allLoans fun getLoansAccountTemplate(clientId: Int, productId: Int): Observable { @@ -160,7 +158,7 @@ class DataManagerLoan @Inject constructor( fun submitPayment( loanId: Int, request: LoanRepaymentRequest, - ): Observable { + ): Observable { return when (prefManager.userStatus) { false -> mBaseApiManager.loanApi.submitPayment(loanId, request) .concatMap { loanRepaymentResponse -> Observable.just(loanRepaymentResponse) } diff --git a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt index 72ba9143db..ff066d0de5 100644 --- a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt +++ b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt @@ -20,7 +20,7 @@ import com.mifos.core.network.GenericResponse import com.mifos.core.objects.account.loan.SavingsApproval import com.mifos.core.objects.account.saving.SavingsAccountTransactionResponse import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.payloads.SavingsPayload +import com.mifos.core.model.objects.payloads.SavingsPayload import rx.Observable import javax.inject.Inject import javax.inject.Singleton diff --git a/core/network/src/main/java/com/mifos/core/network/services/CheckerInboxService.kt b/core/network/src/main/java/com/mifos/core/network/services/CheckerInboxService.kt index 1bf935ef7b..66f61708f5 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/CheckerInboxService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/CheckerInboxService.kt @@ -13,7 +13,6 @@ import com.mifos.core.model.APIEndPoint import com.mifos.core.network.GenericResponse import com.mifos.core.objects.checkerinboxtask.CheckerInboxSearchTemplate import com.mifos.core.objects.checkerinboxtask.CheckerTask -import com.mifos.core.objects.checkerinboxtask.RescheduleLoansTask import retrofit2.http.DELETE import retrofit2.http.GET import retrofit2.http.POST @@ -40,7 +39,7 @@ interface CheckerInboxService { suspend fun deleteCheckerEntry(@Path("auditId") auditId: Int): GenericResponse @GET("rescheduleloans?command=pending") - suspend fun getRescheduleLoansTaskList(): List + suspend fun getRescheduleLoansTaskList(): List @GET(APIEndPoint.MAKER_CHECKER + "/searchtemplate?fields=entityNames,actionNames") fun getCheckerInboxSearchTempalate(): Observable diff --git a/core/network/src/main/java/com/mifos/core/network/services/ClientService.kt b/core/network/src/main/java/com/mifos/core/network/services/ClientService.kt index 91b2fd8f94..f68f1d9b89 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/ClientService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/ClientService.kt @@ -16,8 +16,6 @@ import com.mifos.core.entity.templates.clients.ClientsTemplate import com.mifos.core.model.APIEndPoint import com.mifos.core.network.GenericResponse import com.mifos.core.objects.clients.ActivatePayload -import com.mifos.core.objects.clients.ClientAddressRequest -import com.mifos.core.objects.clients.ClientAddressResponse import com.mifos.core.objects.clients.Page import com.mifos.core.objects.noncoreobjects.Identifier import com.mifos.core.objects.noncoreobjects.IdentifierCreationResponse @@ -148,7 +146,7 @@ interface ClientService { @GET(APIEndPoint.DATATABLES + "/client_pinpoint_location/{clientId}") suspend fun getClientPinpointLocations( @Path("clientId") clientId: Int, - ): List + ): List /** * This is the service for adding the new Client Pinpoint Location in dataTable @@ -164,7 +162,7 @@ interface ClientService { @POST(APIEndPoint.DATATABLES + "/client_pinpoint_location/{clientId}") suspend fun addClientPinpointLocation( @Path("clientId") clientId: Int, - @Body clientAddressRequest: ClientAddressRequest?, + @Body clientAddressRequest: com.mifos.core.model.objects.clients.ClientAddressRequest?, ): GenericResponse /** @@ -200,7 +198,7 @@ interface ClientService { suspend fun updateClientPinpointLocation( @Path("apptableId") apptableId: Int, @Path("datatableId") datatableId: Int, - @Body address: ClientAddressRequest?, + @Body address: com.mifos.core.model.objects.clients.ClientAddressRequest?, ): GenericResponse /** diff --git a/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt b/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt index 7a2c2e869e..2ac4ff67e4 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt @@ -19,13 +19,10 @@ import com.mifos.core.entity.templates.loans.LoanTransactionTemplate import com.mifos.core.model.APIEndPoint import com.mifos.core.network.GenericResponse import com.mifos.core.network.model.LoansPayload -import com.mifos.core.objects.account.loan.LoanApproval import com.mifos.core.objects.account.loan.LoanDisbursement -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import com.mifos.core.objects.clients.Page -import com.mifos.core.objects.organisations.LoanProducts import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.payloads.GroupLoanPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import retrofit2.http.Body import retrofit2.http.GET import retrofit2.http.POST @@ -48,7 +45,7 @@ interface LoanService { @POST(APIEndPoint.LOANS + "/{loanId}?command=approve") fun approveLoanApplication( @Path("loanId") loanId: Int, - @Body loanApproval: LoanApproval?, + @Body loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval?, ): Observable // Mandatory Fields @@ -63,7 +60,7 @@ interface LoanService { fun submitPayment( @Path("loanId") loanId: Int, @Body loanRepaymentRequest: LoanRepaymentRequest?, - ): Observable + ): Observable @GET(APIEndPoint.LOANS + "/{loanId}?associations=repaymentSchedule") fun getLoanRepaymentSchedule(@Path("loanId") loanId: Int): Observable @@ -72,7 +69,7 @@ interface LoanService { fun getLoanWithTransactions(@Path("loanId") loanId: Int): Observable @get:GET(APIEndPoint.CREATE_LOANS_PRODUCTS) - val allLoans: Observable> + val allLoans: Observable> @POST(APIEndPoint.CREATE_LOANS_ACCOUNTS) fun createLoansAccount(@Body loansPayload: LoansPayload?): Observable diff --git a/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt b/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt index 21f15494f6..9cf6a52664 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt @@ -19,7 +19,7 @@ import com.mifos.core.network.GenericResponse import com.mifos.core.objects.account.loan.SavingsApproval import com.mifos.core.objects.account.saving.SavingsAccountTransactionResponse import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.payloads.SavingsPayload +import com.mifos.core.model.objects.payloads.SavingsPayload import retrofit2.http.Body import retrofit2.http.GET import retrofit2.http.POST diff --git a/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt b/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt index 6e6fa2f078..26aacc3e0f 100644 --- a/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt +++ b/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt @@ -18,8 +18,8 @@ import com.mifos.core.common.utils.Resource import com.mifos.core.datastore.PrefManager import com.mifos.core.domain.useCases.PasswordValidationUseCase import com.mifos.core.domain.useCases.UsernameValidationUseCase -import com.mifos.core.model.getInstanceUrl import com.mifos.feature.auth.R +import com.mifos.core.model.getInstanceUrl import dagger.hilt.android.lifecycle.HiltViewModel import dagger.hilt.android.qualifiers.ApplicationContext import kotlinx.coroutines.Dispatchers diff --git a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientUiState.kt b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientUiState.kt index fa2c2d89f5..da416bd7df 100644 --- a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientUiState.kt +++ b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientUiState.kt @@ -9,8 +9,6 @@ */ package com.mifos.feature.client.clientPinpoint -import com.mifos.core.objects.clients.ClientAddressResponse - /** * Created by Aditya Gupta on 08/08/23. */ @@ -20,7 +18,7 @@ sealed class PinPointClientUiState { data class Error(val message: Int) : PinPointClientUiState() - data class ClientPinpointLocations(val clientAddressResponses: List) : + data class ClientPinpointLocations(val clientAddressResponses: List) : PinPointClientUiState() data class SuccessMessage(val message: Int) : PinPointClientUiState() diff --git a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientViewModel.kt b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientViewModel.kt index 88ef6a459a..377e1f3d40 100644 --- a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientViewModel.kt +++ b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinPointClientViewModel.kt @@ -17,7 +17,6 @@ import com.mifos.core.domain.useCases.AddClientPinpointLocationUseCase import com.mifos.core.domain.useCases.DeleteClientAddressPinpointUseCase import com.mifos.core.domain.useCases.GetClientPinpointLocationsUseCase import com.mifos.core.domain.useCases.UpdateClientPinpointUseCase -import com.mifos.core.objects.clients.ClientAddressRequest import com.mifos.feature.client.R import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers @@ -74,7 +73,7 @@ class PinPointClientViewModel @Inject constructor( } } - fun addClientPinpointLocation(clientId: Int, addressRequest: ClientAddressRequest) = + fun addClientPinpointLocation(clientId: Int, addressRequest: com.mifos.core.model.objects.clients.ClientAddressRequest) = viewModelScope.launch(Dispatchers.IO) { addClientPinpointLocationUseCase(clientId, addressRequest).collect { result -> when (result) { @@ -115,7 +114,7 @@ class PinPointClientViewModel @Inject constructor( fun updateClientPinpointLocation( apptableId: Int, datatableId: Int, - addressRequest: ClientAddressRequest, + addressRequest: com.mifos.core.model.objects.clients.ClientAddressRequest, ) = viewModelScope.launch(Dispatchers.IO) { updateClientPinpointUseCase(apptableId, datatableId, addressRequest).collect { result -> when (result) { diff --git a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinpointClientScreen.kt b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinpointClientScreen.kt index 72c4feea0e..2781cc6c9f 100644 --- a/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinpointClientScreen.kt +++ b/feature/client/src/main/java/com/mifos/feature/client/clientPinpoint/PinpointClientScreen.kt @@ -76,8 +76,6 @@ import com.mifos.core.designsystem.icon.MifosIcons import com.mifos.core.designsystem.theme.Black import com.mifos.core.designsystem.theme.BlueSecondary import com.mifos.core.designsystem.theme.White -import com.mifos.core.objects.clients.ClientAddressRequest -import com.mifos.core.objects.clients.ClientAddressResponse import com.mifos.feature.client.R @Composable @@ -132,8 +130,8 @@ internal fun PinpointClientScreen( onRefresh: () -> Unit, refreshState: Boolean, onRetry: () -> Unit, - onAddAddress: (ClientAddressRequest) -> Unit, - onUpdateAddress: (Int, Int, ClientAddressRequest) -> Unit, + onAddAddress: (com.mifos.core.model.objects.clients.ClientAddressRequest) -> Unit, + onUpdateAddress: (Int, Int, com.mifos.core.model.objects.clients.ClientAddressRequest) -> Unit, onDeleteAddress: (Int, Int) -> Unit, ) { val snackbarHostState = remember { SnackbarHostState() } @@ -157,7 +155,7 @@ internal fun PinpointClientScreen( showPermissionDialog = false onAddAddress( // TODO Implement Place picker intent and fetch data and put into ClientAddressRequest - ClientAddressRequest(), + com.mifos.core.model.objects.clients.ClientAddressRequest(), ) }, ) @@ -217,8 +215,8 @@ internal fun PinpointClientScreen( @Composable private fun PinPointClientContent( - pinpointLocations: List, - onUpdateAddress: (Int, Int, ClientAddressRequest) -> Unit, + pinpointLocations: List, + onUpdateAddress: (Int, Int, com.mifos.core.model.objects.clients.ClientAddressRequest) -> Unit, onDeleteAddress: (Int, Int) -> Unit, ) { LazyColumn { @@ -234,8 +232,8 @@ private fun PinPointClientContent( @Composable private fun PinpointLocationItem( - pinpointLocation: ClientAddressResponse, - onUpdateAddress: (Int, Int, ClientAddressRequest) -> Unit, + pinpointLocation: com.mifos.core.model.objects.clients.ClientAddressResponse, + onUpdateAddress: (Int, Int, com.mifos.core.model.objects.clients.ClientAddressRequest) -> Unit, onDeleteAddress: (Int, Int) -> Unit, ) { val cameraPositionState = rememberCameraPositionState { @@ -261,7 +259,7 @@ private fun PinpointLocationItem( onUpdateAddress( clientId, id, - ClientAddressRequest(), + com.mifos.core.model.objects.clients.ClientAddressRequest(), ) } } @@ -414,5 +412,9 @@ private fun PinpointClientScreenPreview( } val samplePinpointLocations = List(10) { - ClientAddressResponse(placeAddress = "Address $it", latitude = 0.0, longitude = 0.0) + com.mifos.core.model.objects.clients.ClientAddressResponse( + placeAddress = "Address $it", + latitude = 0.0, + longitude = 0.0, + ) } diff --git a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/individualCollectionSheetDetails/IndividualCollectionSheetDetailsScreen.kt b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/individualCollectionSheetDetails/IndividualCollectionSheetDetailsScreen.kt index 6c9d8a5933..d75fc1df0f 100644 --- a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/individualCollectionSheetDetails/IndividualCollectionSheetDetailsScreen.kt +++ b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/individualCollectionSheetDetails/IndividualCollectionSheetDetailsScreen.kt @@ -68,14 +68,13 @@ import com.mifos.core.entity.collectionsheet.ClientCollectionSheet import com.mifos.core.entity.collectionsheet.IndividualCollectionSheet import com.mifos.core.model.BulkRepaymentTransactions import com.mifos.core.network.model.IndividualCollectionSheetPayload -import com.mifos.core.objects.account.loan.PaymentTypeOptions import com.mifos.core.objects.collectionsheets.LoanAndClientName import com.mifos.feature.collection_sheet.R @Composable internal fun IndividualCollectionSheetDetailsScreen( onBackPressed: () -> Unit, - submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, + submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, viewModel: IndividualCollectionSheetDetailsViewModel = hiltViewModel(), ) { val state by viewModel.individualCollectionSheetDetailsUiState.collectAsStateWithLifecycle() @@ -102,7 +101,7 @@ internal fun IndividualCollectionSheetDetailsScreen( state: IndividualCollectionSheetDetailsUiState, onBackPressed: () -> Unit, onRetry: () -> Unit, - submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, + submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, modifier: Modifier = Modifier, onSave: (IndividualCollectionSheetPayload) -> Unit, ) { diff --git a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/navigation/CollectionSheetNavigation.kt b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/navigation/CollectionSheetNavigation.kt index 601551fe04..a28ea6bd8f 100644 --- a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/navigation/CollectionSheetNavigation.kt +++ b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/navigation/CollectionSheetNavigation.kt @@ -19,7 +19,6 @@ import com.google.gson.Gson import com.mifos.core.common.utils.Constants import com.mifos.core.entity.collectionsheet.IndividualCollectionSheet import com.mifos.core.network.model.IndividualCollectionSheetPayload -import com.mifos.core.objects.account.loan.PaymentTypeOptions import com.mifos.core.objects.collectionsheets.LoanAndClientName import com.mifos.feature.individualCollectionSheet.generateCollectionSheet.GenerateCollectionSheetScreen import com.mifos.feature.individualCollectionSheet.individualCollectionSheet.ui.IndividualCollectionSheetScreen @@ -70,7 +69,7 @@ private fun NavGraphBuilder.individualCollectionSheetScreen( private fun NavGraphBuilder.individualCollectionSheetDetailScreen( onBackPressed: () -> Unit, - submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, + submit: (Int, IndividualCollectionSheetPayload, List, LoanAndClientName, List, Int) -> Unit, ) { composable( route = CollectionSheetScreens.IndividualCollectionSheetDetailScreen.route, @@ -120,7 +119,7 @@ fun NavController.navigateToPaymentDetailsScreen( payload: IndividualCollectionSheetPayload, paymentTypeOptionsName: List, loansAndClientName: LoanAndClientName, - paymentTypeOptions: List, + paymentTypeOptions: List, clientId: Int, ) { val payloadInGsonString = Gson().toJson(payload) diff --git a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsScreen.kt b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsScreen.kt index b1fb32aa9f..a6a0d229d1 100644 --- a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsScreen.kt +++ b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsScreen.kt @@ -53,7 +53,6 @@ import com.mifos.core.designsystem.theme.BluePrimary import com.mifos.core.designsystem.theme.BluePrimaryDark import com.mifos.core.model.BulkRepaymentTransactions import com.mifos.core.network.model.IndividualCollectionSheetPayload -import com.mifos.core.objects.account.loan.PaymentTypeOptions import com.mifos.core.objects.collectionsheets.LoanAndClientName import com.mifos.feature.collection_sheet.R @@ -82,7 +81,7 @@ internal fun PaymentsDetailsScreen( payload: IndividualCollectionSheetPayload, loanAndClientNameItem: LoanAndClientName, paymentTypeOptionList: List, - paymentTypeOptions: List, + paymentTypeOptions: List, modifier: Modifier = Modifier, getClientImage: (Int) -> ImageResult?, ) { diff --git a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsViewModel.kt b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsViewModel.kt index 6289828a4c..3f25e78e98 100644 --- a/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsViewModel.kt +++ b/feature/collectionSheet/src/main/java/com/mifos/feature/individualCollectionSheet/paymentDetails/PaymentDetailsViewModel.kt @@ -17,7 +17,6 @@ import com.google.gson.Gson import com.mifos.core.common.utils.Constants import com.mifos.core.network.model.IndividualCollectionSheetPayload import com.mifos.core.network.utils.ImageLoaderUtils -import com.mifos.core.objects.account.loan.PaymentTypeOptions import com.mifos.core.objects.collectionsheets.LoanAndClientName import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers @@ -43,7 +42,7 @@ class PaymentDetailsViewModel @Inject constructor( Gson().fromJson(payloadArg.value, IndividualCollectionSheetPayload::class.java) val paymentTypeOptionsName = Gson().fromJson(paymentListArg.value, Array::class.java).toList() val loanAndClientName: LoanAndClientName = Gson().fromJson(loanAndClientNameArg.value, LoanAndClientName::class.java) - val paymentTypeOptions = Gson().fromJson(paymentOptionsArg.value, Array::class.java).toList() + val paymentTypeOptions = Gson().fromJson(paymentOptionsArg.value, Array::class.java).toList() fun getClientImageUrl(clientId: Int): ImageResult? { var image: ImageResult? = null diff --git a/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt b/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt index 6153caceac..3735ef6ee5 100644 --- a/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt +++ b/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt @@ -21,8 +21,8 @@ import com.mifos.core.entity.client.ClientPayload import com.mifos.core.entity.noncore.DataTable import com.mifos.core.entity.noncore.DataTablePayload import com.mifos.core.network.model.LoansPayload -import com.mifos.core.payloads.GroupLoanPayload import com.mifos.feature.data_table.R +import com.mifos.core.model.objects.payloads.GroupLoanPayload import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow import kotlinx.coroutines.flow.StateFlow diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt index 022d58d569..abed0f569a 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt @@ -67,10 +67,9 @@ import com.mifos.core.designsystem.component.MifosTextFieldDropdown import com.mifos.core.designsystem.icon.MifosIcons import com.mifos.core.designsystem.theme.BluePrimary import com.mifos.core.designsystem.theme.BluePrimaryDark -import com.mifos.core.objects.organisations.LoanProducts import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.payloads.GroupLoanPayload import com.mifos.feature.loan.R +import com.mifos.core.model.objects.payloads.GroupLoanPayload import java.text.SimpleDateFormat import java.util.Locale @@ -114,7 +113,7 @@ internal fun GroupLoanAccountScreen( internal fun GroupLoanAccountScreen( groupId: Int, state: GroupLoanAccountUiState, - loanProducts: List, + loanProducts: List, onBackPressed: () -> Unit, onRetry: () -> Unit, onLoanProductSelected: (Int) -> Unit, @@ -172,7 +171,7 @@ internal fun GroupLoanAccountScreen( @Composable private fun GroupLoanAccountContent( groupId: Int, - productLoans: List, + productLoans: List, loanTemplate: GroupLoanTemplate, onLoanProductSelected: (Int) -> Unit, createLoanAccount: (GroupLoanPayload) -> Unit, diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt index 5b206b09ae..6b6a5c6903 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt @@ -17,10 +17,9 @@ import com.mifos.core.common.utils.Resource import com.mifos.core.domain.useCases.CreateGroupLoansAccountUseCase import com.mifos.core.domain.useCases.GetAllLoanUseCase import com.mifos.core.domain.useCases.GetGroupLoansAccountTemplateUseCase -import com.mifos.core.objects.organisations.LoanProducts import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.payloads.GroupLoanPayload import com.mifos.feature.loan.R +import com.mifos.core.model.objects.payloads.GroupLoanPayload import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.flow.MutableStateFlow @@ -42,7 +41,7 @@ class GroupLoanAccountViewModel @Inject constructor( MutableStateFlow(GroupLoanAccountUiState.Loading) val groupLoanAccountUiState = _groupLoanAccountUiState.asStateFlow() - private val _loanProducts = MutableStateFlow>(emptyList()) + private val _loanProducts = MutableStateFlow>(emptyList()) val loanProducts = _loanProducts.asStateFlow() fun loadAllLoans() = viewModelScope.launch(Dispatchers.IO) { diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountScreen.kt index d66e23f334..f7ce441d40 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountScreen.kt @@ -70,7 +70,6 @@ import com.mifos.core.designsystem.theme.BluePrimaryDark import com.mifos.core.entity.noncore.DataTable import com.mifos.core.entity.templates.loans.LoanTemplate import com.mifos.core.network.model.LoansPayload -import com.mifos.core.objects.organisations.LoanProducts import com.mifos.feature.loan.R import java.text.SimpleDateFormat import java.util.Locale @@ -178,7 +177,7 @@ fun LoanAccountScreen( @Composable private fun LoanAccountContent( clientsId: Int, - productLoans: List, + productLoans: List, loanTemplate: LoanTemplate, onLoanProductSelected: (Int) -> Unit, createLoanAccount: (LoansPayload) -> Unit, @@ -643,5 +642,5 @@ private fun LoanAccountScreenPreview( } val sampleLoanList = List(10) { - LoanProducts(name = "Loan $it", id = it) + com.mifos.core.model.objects.organisations.LoanProducts(name = "Loan $it", id = it) } diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountUiState.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountUiState.kt index 67a33b13fc..ff2480db57 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountUiState.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanAccount/LoanAccountUiState.kt @@ -9,8 +9,6 @@ */ package com.mifos.feature.loan.loanAccount -import com.mifos.core.objects.organisations.LoanProducts - /** * Created by Aditya Gupta on 08/08/23. */ @@ -18,7 +16,7 @@ sealed class LoanAccountUiState { data object Loading : LoanAccountUiState() - data class AllLoan(val productLoans: List) : LoanAccountUiState() + data class AllLoan(val productLoans: List) : LoanAccountUiState() data class Error(val message: Int) : LoanAccountUiState() diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalScreen.kt index 58f82b4b92..10f0319c69 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalScreen.kt @@ -61,7 +61,6 @@ import com.mifos.core.designsystem.theme.BluePrimary import com.mifos.core.designsystem.theme.BluePrimaryDark import com.mifos.core.entity.accounts.loan.LoanWithAssociations import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.account.loan.LoanApproval import com.mifos.feature.loan.R import java.text.SimpleDateFormat import java.util.Locale @@ -92,7 +91,7 @@ internal fun LoanAccountApprovalScreen( uiState: LoanAccountApprovalUiState, loanWithAssociations: LoanWithAssociations?, navigateBack: () -> Unit, - onLoanApprove: (loanApproval: LoanApproval) -> Unit, + onLoanApprove: (loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval) -> Unit, ) { val snackBarHostState = remember { SnackbarHostState() @@ -153,7 +152,7 @@ internal fun LoanAccountApprovalScreen( @Composable private fun LoanAccountApprovalContent( loanWithAssociations: LoanWithAssociations?, - onLoanApprove: (loanApproval: LoanApproval) -> Unit, + onLoanApprove: (loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval) -> Unit, ) { var approvedAmount by rememberSaveable { mutableStateOf(loanWithAssociations?.approvedPrincipal.toString()) @@ -327,7 +326,7 @@ private fun LoanAccountApprovalContent( ) onLoanApprove.invoke( - LoanApproval( + com.mifos.core.model.objects.account.loan.LoanApproval( note = note, approvedOnDate = approvedOnDate, approvedLoanAmount = approvedAmount, diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalViewModel.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalViewModel.kt index 9a368053bc..7d6df41507 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalViewModel.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanApproval/LoanAccountApprovalViewModel.kt @@ -15,7 +15,6 @@ import com.google.gson.Gson import com.mifos.core.data.repository.LoanAccountApprovalRepository import com.mifos.core.entity.accounts.loan.LoanApprovalData import com.mifos.core.network.GenericResponse -import com.mifos.core.objects.account.loan.LoanApproval import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow import kotlinx.coroutines.flow.StateFlow @@ -45,7 +44,7 @@ class LoanAccountApprovalViewModel @Inject constructor( var loanId = loanAccountData.loanID var loanWithAssociations = loanAccountData.loanWithAssociations - fun approveLoan(loanApproval: LoanApproval?) { + fun approveLoan(loanApproval: com.mifos.core.model.objects.account.loan.LoanApproval?) { _loanAccountApprovalUiState.value = LoanAccountApprovalUiState.ShowProgressbar repository.approveLoan(loanId, loanApproval) .observeOn(AndroidSchedulers.mainThread()) diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentScreen.kt index a6a84e4964..6052fb93ca 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentScreen.kt @@ -72,7 +72,6 @@ import com.mifos.core.designsystem.theme.DarkGray import com.mifos.core.entity.PaymentTypeOption import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import com.mifos.feature.loan.R import java.text.SimpleDateFormat import java.util.Locale @@ -620,7 +619,7 @@ private class LoanRepaymentScreenPreviewProvider : LoanRepaymentUiState.ShowError(R.string.feature_loan_failed_to_load_loan_repayment), LoanRepaymentUiState.ShowLoanRepaymentDoesNotExistInDatabase, LoanRepaymentUiState.ShowProgressbar, - LoanRepaymentUiState.ShowPaymentSubmittedSuccessfully(LoanRepaymentResponse()), + LoanRepaymentUiState.ShowPaymentSubmittedSuccessfully(com.mifos.core.model.objects.account.loan.LoanRepaymentResponse()), ) } diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentUiState.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentUiState.kt index ff53b92514..ccfa145aa1 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentUiState.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentUiState.kt @@ -10,7 +10,6 @@ package com.mifos.feature.loan.loanRepayment import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate -import com.mifos.core.objects.account.loan.LoanRepaymentResponse /** * Created by Aditya Gupta on 10/08/23. @@ -24,7 +23,7 @@ sealed class LoanRepaymentUiState { data class ShowLoanRepayTemplate(val loanRepaymentTemplate: LoanRepaymentTemplate) : LoanRepaymentUiState() - data class ShowPaymentSubmittedSuccessfully(val loanRepaymentResponse: LoanRepaymentResponse?) : + data class ShowPaymentSubmittedSuccessfully(val loanRepaymentResponse: com.mifos.core.model.objects.account.loan.LoanRepaymentResponse?) : LoanRepaymentUiState() data object ShowLoanRepaymentExistInDatabase : LoanRepaymentUiState() diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentViewModel.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentViewModel.kt index 28a9235658..af2883a3c5 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentViewModel.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepayment/LoanRepaymentViewModel.kt @@ -18,7 +18,6 @@ import com.mifos.core.data.repository.LoanRepaymentRepository import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.entity.accounts.loan.LoanWithAssociations import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import com.mifos.feature.loan.R import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow @@ -82,7 +81,7 @@ class LoanRepaymentViewModel @Inject constructor( repository.submitPayment(loanId, request) .observeOn(AndroidSchedulers.mainThread()) .subscribeOn(Schedulers.io()) - .subscribe(object : Subscriber() { + .subscribe(object : Subscriber() { override fun onCompleted() { } @@ -91,7 +90,7 @@ class LoanRepaymentViewModel @Inject constructor( LoanRepaymentUiState.ShowError(R.string.feature_loan_payment_failed) } - override fun onNext(loanRepaymentResponse: LoanRepaymentResponse?) { + override fun onNext(loanRepaymentResponse: com.mifos.core.model.objects.account.loan.LoanRepaymentResponse?) { _loanRepaymentUiState.value = LoanRepaymentUiState.ShowPaymentSubmittedSuccessfully(loanRepaymentResponse) } diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepaymentSchedule/LoanRepaymentScheduleScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepaymentSchedule/LoanRepaymentScheduleScreen.kt index ebbc46ff36..a1e0f34d44 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/loanRepaymentSchedule/LoanRepaymentScheduleScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/loanRepaymentSchedule/LoanRepaymentScheduleScreen.kt @@ -46,7 +46,6 @@ import com.mifos.core.designsystem.component.MifosScaffold import com.mifos.core.designsystem.component.MifosSweetError import com.mifos.core.designsystem.icon.MifosIcons import com.mifos.core.entity.accounts.loan.LoanWithAssociations -import com.mifos.core.objects.account.loan.Period import com.mifos.core.objects.account.loan.RepaymentSchedule import com.mifos.feature.loan.R @@ -114,7 +113,7 @@ internal fun LoanRepaymentScheduleScreen( @Composable private fun LoanRepaymentScheduleContent( - periods: List, + periods: List, ) { Column( modifier = Modifier.fillMaxSize(), @@ -310,31 +309,31 @@ private class LoanRepaymentSchedulePreviewProvider : val loanWithAssociations = LoanWithAssociations( repaymentSchedule = RepaymentSchedule( periods = listOf( - Period( + com.mifos.core.model.objects.account.loan.Period( complete = true, totalDueForPeriod = 123.232, totalPaidForPeriod = 34343.3434, dueDate = listOf(2024, 6, 1), ), - Period( + com.mifos.core.model.objects.account.loan.Period( complete = true, totalDueForPeriod = 123.232, totalPaidForPeriod = 34343.3434, dueDate = listOf(2024, 6, 1), ), - Period( + com.mifos.core.model.objects.account.loan.Period( complete = true, totalDueForPeriod = 123.232, totalPaidForPeriod = 34343.3434, dueDate = listOf(2024, 6, 1), ), - Period( + com.mifos.core.model.objects.account.loan.Period( complete = true, totalDueForPeriod = 123.232, totalPaidForPeriod = 34343.3434, dueDate = listOf(2024, 6, 1), ), - Period( + com.mifos.core.model.objects.account.loan.Period( complete = true, totalDueForPeriod = 123.232, totalPaidForPeriod = 34343.3434, diff --git a/feature/offline/src/main/java/com/mifos/feature/offline/syncLoanRepaymentTransaction/SyncLoanRepaymentTransactionViewModel.kt b/feature/offline/src/main/java/com/mifos/feature/offline/syncLoanRepaymentTransaction/SyncLoanRepaymentTransactionViewModel.kt index 3ecb57e00e..bcfac742ea 100644 --- a/feature/offline/src/main/java/com/mifos/feature/offline/syncLoanRepaymentTransaction/SyncLoanRepaymentTransactionViewModel.kt +++ b/feature/offline/src/main/java/com/mifos/feature/offline/syncLoanRepaymentTransaction/SyncLoanRepaymentTransactionViewModel.kt @@ -17,7 +17,6 @@ import com.mifos.core.datastore.PrefManager import com.mifos.core.entity.PaymentTypeOption import com.mifos.core.entity.accounts.loan.LoanRepaymentRequest import com.mifos.core.entity.center.CenterPayload_Table.errorMessage -import com.mifos.core.objects.account.loan.LoanRepaymentResponse import com.mifos.feature.offline.R import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow @@ -124,7 +123,7 @@ class SyncLoanRepaymentTransactionViewModel @Inject constructor( repository.submitPayment(loanId, loanRepaymentRequest!!) .observeOn(AndroidSchedulers.mainThread()) .subscribeOn(Schedulers.io()) - .subscribe(object : Subscriber() { + .subscribe(object : Subscriber() { override fun onCompleted() {} override fun onError(e: Throwable) { val eLoanRepaymentRequest = mLoanRepaymentRequests[mClientSyncIndex] @@ -132,7 +131,7 @@ class SyncLoanRepaymentTransactionViewModel @Inject constructor( updateLoanRepayment(eLoanRepaymentRequest) } - override fun onNext(loanRepaymentResponse: LoanRepaymentResponse) { + override fun onNext(loanRepaymentResponse: com.mifos.core.model.objects.account.loan.LoanRepaymentResponse) { mLoanRepaymentRequests[mClientSyncIndex].loanId?.let { deleteAndUpdateLoanRepayments( it, diff --git a/feature/path-tracking/src/main/java/com/mifos/feature/pathTracking/PathTrackingScreen.kt b/feature/path-tracking/src/main/java/com/mifos/feature/pathTracking/PathTrackingScreen.kt index 41a4d77176..3f573fe054 100644 --- a/feature/path-tracking/src/main/java/com/mifos/feature/pathTracking/PathTrackingScreen.kt +++ b/feature/path-tracking/src/main/java/com/mifos/feature/pathTracking/PathTrackingScreen.kt @@ -25,7 +25,6 @@ import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding import androidx.compose.foundation.lazy.LazyColumn -import androidx.compose.foundation.lazy.items import androidx.compose.material.ExperimentalMaterialApi import androidx.compose.material.icons.Icons import androidx.compose.material.icons.rounded.MyLocation @@ -78,7 +77,6 @@ import com.mifos.core.designsystem.component.PermissionBox import com.mifos.core.designsystem.icon.MifosIcons import com.mifos.core.designsystem.theme.Black import com.mifos.core.designsystem.theme.White -import com.mifos.core.objects.users.UserLatLng import com.mifos.core.objects.users.UserLocation import com.mifos.feature.path.tracking.R @@ -156,7 +154,7 @@ internal fun PathTrackingScreen( state: PathTrackingUiState, onBackPressed: () -> Unit, onRetry: () -> Unit, - onPathTrackingClick: (List) -> Unit, + onPathTrackingClick: (List) -> Unit, onRefresh: () -> Unit, refreshState: Boolean, userStatus: Boolean, @@ -242,7 +240,7 @@ internal fun PathTrackingScreen( private fun PathTrackingContent( pathTrackingList: List, modifier: Modifier = Modifier, - onPathTrackingClick: (List) -> Unit, + onPathTrackingClick: (List) -> Unit, ) { LazyColumn(modifier = modifier) { items(pathTrackingList) { pathTracking -> @@ -258,7 +256,7 @@ private fun PathTrackingContent( private fun PathTrackingItem( pathTracking: UserLocation, modifier: Modifier = Modifier, - onPathTrackingClick: (List) -> Unit, + onPathTrackingClick: (List) -> Unit, ) { val latLngList = getLatLngList(pathTracking.latLng) val latLng = latLngList[0] @@ -297,11 +295,11 @@ private fun PathTrackingItem( } } -private fun getLatLngList(latLngString: String?): List { +private fun getLatLngList(latLngString: String?): List { val gson = Gson() return gson.fromJson( latLngString, - object : TypeToken>() {}.type, + object : TypeToken>() {}.type, ) } diff --git a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt index eb16ec9e40..3c375d7e1e 100644 --- a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt +++ b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt @@ -19,8 +19,8 @@ import com.mifos.core.domain.useCases.GetClientSavingsAccountTemplateByProductUs import com.mifos.core.domain.useCases.GetGroupSavingsAccountTemplateByProductUseCase import com.mifos.core.domain.useCases.LoadSavingsAccountsAndTemplateUseCase import com.mifos.core.entity.templates.savings.SavingProductsTemplate -import com.mifos.core.payloads.SavingsPayload import com.mifos.feature.savings.R +import com.mifos.core.model.objects.payloads.SavingsPayload import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.flow.MutableStateFlow diff --git a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt index 40e41e7de7..ac3a5aea85 100644 --- a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt +++ b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt @@ -77,8 +77,8 @@ import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.entity.zipmodels.SavingProductsAndTemplate import com.mifos.core.objects.account.saving.FieldOfficerOptions import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.payloads.SavingsPayload import com.mifos.feature.savings.R +import com.mifos.core.model.objects.payloads.SavingsPayload import java.text.SimpleDateFormat import java.util.Locale diff --git a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt index 814215837c..7d63140fb2 100644 --- a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt +++ b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt @@ -54,9 +54,9 @@ import androidx.hilt.navigation.compose.hiltViewModel import androidx.lifecycle.compose.collectAsStateWithLifecycle import com.mifos.core.designsystem.component.MifosOutlinedTextField import com.mifos.core.designsystem.theme.BluePrimary -import com.mifos.core.model.ServerConfig import com.mifos.core.ui.util.DevicePreviews import com.mifos.feature.settings.R +import com.mifos.core.model.ServerConfig @Composable internal fun UpdateServerConfigScreenRoute( @@ -95,7 +95,7 @@ internal fun UpdateServerConfigScreenRoute( @VisibleForTesting @Composable internal fun UpdateServerConfigScreenContent( - serverConfig: ServerConfig, + serverConfig: com.mifos.core.model.ServerConfig, onEvent: (UpdateServerConfigEvent) -> Unit, modifier: Modifier = Modifier, protocolError: Int? = null, @@ -312,7 +312,7 @@ internal fun UpdateServerConfigScreenContent( private fun UpdateServerConfigScreenEmptyData() { MaterialTheme { UpdateServerConfigScreenContent( - serverConfig = ServerConfig( + serverConfig = com.mifos.core.model.ServerConfig( protocol = "", endPoint = "", apiPath = "", diff --git a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigViewModel.kt b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigViewModel.kt index d649bb8b15..9bb7882558 100644 --- a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigViewModel.kt +++ b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigViewModel.kt @@ -35,7 +35,7 @@ class UpdateServerConfigViewModel @Inject constructor( private val serverConfig = prefManager.getServerConfig private val _state = mutableStateOf(serverConfig) - val state: State get() = _state + val state: State get() = _state private val _result = MutableSharedFlow() val result = _result.asSharedFlow() From 73f719dfcc815a496ea9b8300a1b1551ce5bb7ed Mon Sep 17 00:00:00 2001 From: Pronay sarker Date: Tue, 14 Jan 2025 23:45:33 +0600 Subject: [PATCH 2/2] fixed spotless --- .../com/mifos/core/data/repository/DataTableListRepository.kt | 2 +- .../mifos/core/data/repository/GroupLoanAccountRepository.kt | 2 +- .../com/mifos/core/data/repository/SavingsAccountRepository.kt | 2 +- .../mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt | 2 +- .../core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt | 2 +- .../core/data/repositoryImp/SavingsAccountRepositoryImp.kt | 2 +- .../entity/accounts/savings/SavingsAccountWithAssociations.kt | 2 +- .../src/main/java/com/mifos/core/network/BaseApiManager.kt | 2 +- .../network/src/main/java/com/mifos/core/network/DataManager.kt | 2 +- .../com/mifos/core/network/datamanager/DataManagerSavings.kt | 2 +- .../main/java/com/mifos/core/network/services/LoanService.kt | 2 +- .../com/mifos/core/network/services/SavingsAccountService.kt | 2 +- .../main/java/com/mifos/feature/auth/login/LoginViewModel.kt | 2 +- .../feature/dataTable/dataTableList/DataTableListViewModel.kt | 2 +- .../feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt | 2 +- .../feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt | 2 +- .../feature/savings/savingsAccount/SavingAccountViewModel.kt | 2 +- .../feature/savings/savingsAccount/SavingsAccountScreen.kt | 2 +- .../feature/settings/updateServer/UpdateServerConfigScreen.kt | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt index 1858764eeb..0c1a271e32 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/DataTableListRepository.kt @@ -12,8 +12,8 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.entity.client.Client import com.mifos.core.entity.client.ClientPayload -import com.mifos.core.network.model.LoansPayload import com.mifos.core.model.objects.payloads.GroupLoanPayload +import com.mifos.core.network.model.LoansPayload import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt index 6334cac6f7..353cbfc22c 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/GroupLoanAccountRepository.kt @@ -10,8 +10,8 @@ package com.mifos.core.data.repository import com.mifos.core.entity.accounts.loan.Loans -import com.mifos.core.objects.template.loan.GroupLoanTemplate import com.mifos.core.model.objects.payloads.GroupLoanPayload +import com.mifos.core.objects.template.loan.GroupLoanTemplate import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt b/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt index 57745f7629..be2cf7ebd3 100644 --- a/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt +++ b/core/data/src/main/java/com/mifos/core/data/repository/SavingsAccountRepository.kt @@ -11,8 +11,8 @@ package com.mifos.core.data.repository import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate -import com.mifos.core.objects.organisations.ProductSavings import com.mifos.core.model.objects.payloads.SavingsPayload +import com.mifos.core.objects.organisations.ProductSavings import rx.Observable /** diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt index e5b8070f39..5b3a54fb83 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/DataTableListRepositoryImp.kt @@ -13,11 +13,11 @@ import com.mifos.core.data.repository.DataTableListRepository import com.mifos.core.entity.accounts.loan.Loans import com.mifos.core.entity.client.Client import com.mifos.core.entity.client.ClientPayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.network.DataManager import com.mifos.core.network.datamanager.DataManagerClient import com.mifos.core.network.datamanager.DataManagerLoan import com.mifos.core.network.model.LoansPayload -import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable import javax.inject.Inject diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt index 46f3587542..3bf30bf84e 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/GroupLoanAccountRepositoryImp.kt @@ -11,9 +11,9 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.GroupLoanAccountRepository import com.mifos.core.entity.accounts.loan.Loans +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.network.DataManager import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.model.objects.payloads.GroupLoanPayload import rx.Observable import javax.inject.Inject diff --git a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt index 20c3419d3f..f693eeb4e8 100644 --- a/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt +++ b/core/data/src/main/java/com/mifos/core/data/repositoryImp/SavingsAccountRepositoryImp.kt @@ -12,9 +12,9 @@ package com.mifos.core.data.repositoryImp import com.mifos.core.data.repository.SavingsAccountRepository import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate +import com.mifos.core.model.objects.payloads.SavingsPayload import com.mifos.core.network.datamanager.DataManagerSavings import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.model.objects.payloads.SavingsPayload import rx.Observable import javax.inject.Inject diff --git a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt index fc816be70f..bdcf722e32 100644 --- a/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt +++ b/core/database/src/main/java/com/mifos/core/entity/accounts/savings/SavingsAccountWithAssociations.kt @@ -89,4 +89,4 @@ data class SavingsAccountWithAssociations( var charges: List = ArrayList(), - ) : MifosBaseModel(), Parcelable +) : MifosBaseModel(), Parcelable diff --git a/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt b/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt index d30c1086a5..c47310f2a2 100644 --- a/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt +++ b/core/network/src/main/java/com/mifos/core/network/BaseApiManager.kt @@ -10,6 +10,7 @@ package com.mifos.core.network import com.google.gson.GsonBuilder +import com.mifos.core.model.getInstanceUrl import com.mifos.core.network.services.CenterService import com.mifos.core.network.services.ChargeService import com.mifos.core.network.services.CheckerInboxService @@ -27,7 +28,6 @@ import com.mifos.core.network.services.SavingsAccountService import com.mifos.core.network.services.SearchService import com.mifos.core.network.services.StaffService import com.mifos.core.network.services.SurveyService -import com.mifos.core.model.getInstanceUrl import org.mifos.core.utils.JsonDateSerializer import retrofit2.Retrofit import retrofit2.adapter.rxjava.RxJavaCallAdapterFactory diff --git a/core/network/src/main/java/com/mifos/core/network/DataManager.kt b/core/network/src/main/java/com/mifos/core/network/DataManager.kt index e939ff44b0..664a2fc4bd 100644 --- a/core/network/src/main/java/com/mifos/core/network/DataManager.kt +++ b/core/network/src/main/java/com/mifos/core/network/DataManager.kt @@ -18,6 +18,7 @@ import com.mifos.core.entity.group.Group import com.mifos.core.entity.group.GroupWithAssociations import com.mifos.core.entity.organisation.Office import com.mifos.core.entity.organisation.Staff +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.network.datamanager.DataManagerClient import com.mifos.core.network.model.CollectionSheetPayload import com.mifos.core.network.model.Payload @@ -29,7 +30,6 @@ import com.mifos.core.objects.responses.SaveResponse import com.mifos.core.objects.template.client.ChargeTemplate import com.mifos.core.objects.template.loan.GroupLoanTemplate import com.mifos.core.payloads.ChargesPayload -import com.mifos.core.model.objects.payloads.GroupLoanPayload import okhttp3.ResponseBody import rx.Observable import javax.inject.Inject diff --git a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt index ff066d0de5..cb16704d28 100644 --- a/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt +++ b/core/network/src/main/java/com/mifos/core/network/datamanager/DataManagerSavings.kt @@ -15,12 +15,12 @@ import com.mifos.core.entity.accounts.savings.SavingsAccountWithAssociations import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.entity.templates.savings.SavingsAccountTransactionTemplate +import com.mifos.core.model.objects.payloads.SavingsPayload import com.mifos.core.network.BaseApiManager import com.mifos.core.network.GenericResponse import com.mifos.core.objects.account.loan.SavingsApproval import com.mifos.core.objects.account.saving.SavingsAccountTransactionResponse import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.model.objects.payloads.SavingsPayload import rx.Observable import javax.inject.Inject import javax.inject.Singleton diff --git a/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt b/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt index 2ac4ff67e4..d2c618de16 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/LoanService.kt @@ -17,12 +17,12 @@ import com.mifos.core.entity.templates.loans.LoanRepaymentTemplate import com.mifos.core.entity.templates.loans.LoanTemplate import com.mifos.core.entity.templates.loans.LoanTransactionTemplate import com.mifos.core.model.APIEndPoint +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.network.GenericResponse import com.mifos.core.network.model.LoansPayload import com.mifos.core.objects.account.loan.LoanDisbursement import com.mifos.core.objects.clients.Page import com.mifos.core.objects.template.loan.GroupLoanTemplate -import com.mifos.core.model.objects.payloads.GroupLoanPayload import retrofit2.http.Body import retrofit2.http.GET import retrofit2.http.POST diff --git a/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt b/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt index 9cf6a52664..6418dfb7d3 100644 --- a/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt +++ b/core/network/src/main/java/com/mifos/core/network/services/SavingsAccountService.kt @@ -15,11 +15,11 @@ import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.entity.templates.savings.SavingsAccountTransactionTemplate import com.mifos.core.model.APIEndPoint +import com.mifos.core.model.objects.payloads.SavingsPayload import com.mifos.core.network.GenericResponse import com.mifos.core.objects.account.loan.SavingsApproval import com.mifos.core.objects.account.saving.SavingsAccountTransactionResponse import com.mifos.core.objects.organisations.ProductSavings -import com.mifos.core.model.objects.payloads.SavingsPayload import retrofit2.http.Body import retrofit2.http.GET import retrofit2.http.POST diff --git a/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt b/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt index 26aacc3e0f..6e6fa2f078 100644 --- a/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt +++ b/feature/auth/src/main/java/com/mifos/feature/auth/login/LoginViewModel.kt @@ -18,8 +18,8 @@ import com.mifos.core.common.utils.Resource import com.mifos.core.datastore.PrefManager import com.mifos.core.domain.useCases.PasswordValidationUseCase import com.mifos.core.domain.useCases.UsernameValidationUseCase -import com.mifos.feature.auth.R import com.mifos.core.model.getInstanceUrl +import com.mifos.feature.auth.R import dagger.hilt.android.lifecycle.HiltViewModel import dagger.hilt.android.qualifiers.ApplicationContext import kotlinx.coroutines.Dispatchers diff --git a/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt b/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt index 3735ef6ee5..875876bbfd 100644 --- a/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt +++ b/feature/data-table/src/main/java/com/mifos/feature/dataTable/dataTableList/DataTableListViewModel.kt @@ -20,9 +20,9 @@ import com.mifos.core.entity.client.Client import com.mifos.core.entity.client.ClientPayload import com.mifos.core.entity.noncore.DataTable import com.mifos.core.entity.noncore.DataTablePayload +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.network.model.LoansPayload import com.mifos.feature.data_table.R -import com.mifos.core.model.objects.payloads.GroupLoanPayload import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow import kotlinx.coroutines.flow.StateFlow diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt index abed0f569a..b5e1e7f3b1 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountScreen.kt @@ -67,9 +67,9 @@ import com.mifos.core.designsystem.component.MifosTextFieldDropdown import com.mifos.core.designsystem.icon.MifosIcons import com.mifos.core.designsystem.theme.BluePrimary import com.mifos.core.designsystem.theme.BluePrimaryDark +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.objects.template.loan.GroupLoanTemplate import com.mifos.feature.loan.R -import com.mifos.core.model.objects.payloads.GroupLoanPayload import java.text.SimpleDateFormat import java.util.Locale diff --git a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt index 6b6a5c6903..2a4b6416b1 100644 --- a/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt +++ b/feature/loan/src/main/java/com/mifos/feature/loan/groupLoanAccount/GroupLoanAccountViewModel.kt @@ -17,9 +17,9 @@ import com.mifos.core.common.utils.Resource import com.mifos.core.domain.useCases.CreateGroupLoansAccountUseCase import com.mifos.core.domain.useCases.GetAllLoanUseCase import com.mifos.core.domain.useCases.GetGroupLoansAccountTemplateUseCase +import com.mifos.core.model.objects.payloads.GroupLoanPayload import com.mifos.core.objects.template.loan.GroupLoanTemplate import com.mifos.feature.loan.R -import com.mifos.core.model.objects.payloads.GroupLoanPayload import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.flow.MutableStateFlow diff --git a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt index 3c375d7e1e..0efa00871c 100644 --- a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt +++ b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingAccountViewModel.kt @@ -19,8 +19,8 @@ import com.mifos.core.domain.useCases.GetClientSavingsAccountTemplateByProductUs import com.mifos.core.domain.useCases.GetGroupSavingsAccountTemplateByProductUseCase import com.mifos.core.domain.useCases.LoadSavingsAccountsAndTemplateUseCase import com.mifos.core.entity.templates.savings.SavingProductsTemplate -import com.mifos.feature.savings.R import com.mifos.core.model.objects.payloads.SavingsPayload +import com.mifos.feature.savings.R import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.flow.MutableStateFlow diff --git a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt index ac3a5aea85..1d32f7e3c7 100644 --- a/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt +++ b/feature/savings/src/main/java/com/mifos/feature/savings/savingsAccount/SavingsAccountScreen.kt @@ -75,10 +75,10 @@ import com.mifos.core.designsystem.theme.BluePrimaryDark import com.mifos.core.entity.client.Savings import com.mifos.core.entity.templates.savings.SavingProductsTemplate import com.mifos.core.entity.zipmodels.SavingProductsAndTemplate +import com.mifos.core.model.objects.payloads.SavingsPayload import com.mifos.core.objects.account.saving.FieldOfficerOptions import com.mifos.core.objects.organisations.ProductSavings import com.mifos.feature.savings.R -import com.mifos.core.model.objects.payloads.SavingsPayload import java.text.SimpleDateFormat import java.util.Locale diff --git a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt index 7d63140fb2..6545fd90f7 100644 --- a/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt +++ b/feature/settings/src/main/java/com/mifos/feature/settings/updateServer/UpdateServerConfigScreen.kt @@ -54,9 +54,9 @@ import androidx.hilt.navigation.compose.hiltViewModel import androidx.lifecycle.compose.collectAsStateWithLifecycle import com.mifos.core.designsystem.component.MifosOutlinedTextField import com.mifos.core.designsystem.theme.BluePrimary +import com.mifos.core.model.ServerConfig import com.mifos.core.ui.util.DevicePreviews import com.mifos.feature.settings.R -import com.mifos.core.model.ServerConfig @Composable internal fun UpdateServerConfigScreenRoute(