Skip to content

Commit

Permalink
remove inheritance of Account in ShareAccount, SavingAccount and Loan…
Browse files Browse the repository at this point in the history
…Account
  • Loading branch information
HekmatullahAmin committed Jan 10, 2025
1 parent b89d071 commit b2885d8
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 26 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@ package org.mifos.mobile.core.model.entity.accounts.loan

import org.mifos.mobile.core.model.Parcelable
import org.mifos.mobile.core.model.Parcelize
import org.mifos.mobile.core.model.entity.accounts.Account

@Parcelize
data class LoanAccount(
val id: Long = 0,

val loanProductId: Long = 0,

val externalId: String? = null,
Expand Down Expand Up @@ -56,5 +57,4 @@ data class LoanAccount(
val loanPurposeName: String? = null,

val timeline: Timeline?,

) : Account(), Parcelable
) : Parcelable
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@ package org.mifos.mobile.core.model.entity.accounts.savings

import org.mifos.mobile.core.model.Parcelable
import org.mifos.mobile.core.model.Parcelize
import org.mifos.mobile.core.model.entity.accounts.Account
import org.mifos.mobile.core.model.entity.client.DepositType

@Parcelize
data class SavingAccount(

val id: Long = 0,

val accountNo: String? = null,

val productName: String? = null,
Expand Down Expand Up @@ -48,7 +49,7 @@ data class SavingAccount(
val lastActiveTransactionDate: List<Int>? = null,

val timeLine: TimeLine? = null,
) : Parcelable, Account() {
) : Parcelable {
fun isRecurring(): Boolean {
return this.depositType != null && (this.depositType?.isRecurring() == true)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@ package org.mifos.mobile.core.model.entity.accounts.share

import org.mifos.mobile.core.model.Parcelable
import org.mifos.mobile.core.model.Parcelize
import org.mifos.mobile.core.model.entity.accounts.Account
import org.mifos.mobile.core.model.entity.accounts.savings.Currency

@Parcelize
data class ShareAccount(

val id: Long = 0,

val accountNo: String? = null,

val totalApprovedShares: Int? = null,
Expand All @@ -35,4 +36,4 @@ data class ShareAccount(

val timeline: Timeline? = null,

) : Account(), Parcelable
) : Parcelable

0 comments on commit b2885d8

Please sign in to comment.