Split AccountTransaction.userSetDisplayName into userSetReference and userSetOtherPartyName, and added userSetDisplayName to TanMedium, TanMethod and Holding

This commit is contained in:
dankito 2024-09-17 15:29:03 +02:00
parent 045774ff3f
commit 9af8d0eb1d
4 changed files with 16 additions and 9 deletions

View File

@ -124,7 +124,8 @@ open class AccountTransaction(
*/ */
val isReversal: Boolean = false, val isReversal: Boolean = false,
var userSetDisplayName: String? = null, var userSetReference: String? = null,
var userSetOtherPartyName: String? = null,
var category: String? = null, var category: String? = null,
var notes: String? = null, var notes: String? = null,
) { ) {

View File

@ -44,6 +44,8 @@ open class Holding(
open var pricingTime: Instant? = null, open var pricingTime: Instant? = null,
open var buyingDate: LocalDate? = null, open var buyingDate: LocalDate? = null,
var userSetDisplayName: String? = null,
) { ) {
open val identifier: String by lazy { "${isin}_$wkn" } open val identifier: String by lazy { "${isin}_$wkn" }

View File

@ -14,7 +14,9 @@ open class TanMedium(
/** /**
* Only set if [type] is [TanMediumType.MobilePhone]. * Only set if [type] is [TanMediumType.MobilePhone].
*/ */
val mobilePhone: MobilePhoneTanMedium? = null val mobilePhone: MobilePhoneTanMedium? = null,
var userSetDisplayName: String? = null
) { ) {
/** /**
@ -52,12 +54,13 @@ open class TanMedium(
} }
val displayName: String by lazy { val displayName: String by lazy {
identifier + " " + when (status) { userSetDisplayName
TanMediumStatus.Used -> "Aktiv" ?: (identifier + " " + when (status) {
TanMediumStatus.Available -> "Verfügbar" TanMediumStatus.Used -> "Aktiv"
TanMediumStatus.ActiveFollowUpCard -> " Folgekarte, aktiv bei erster Nutzung" TanMediumStatus.Available -> "Verfügbar"
TanMediumStatus.AvailableFollowUpCard -> " Folgekarte, die erst aktiviert werden muss" TanMediumStatus.ActiveFollowUpCard -> " Folgekarte, aktiv bei erster Nutzung"
} TanMediumStatus.AvailableFollowUpCard -> " Folgekarte, die erst aktiviert werden muss"
})
} }
override fun toString() = "$mediumName $status" override fun toString() = "$mediumName $status"

View File

@ -10,7 +10,8 @@ open class TanMethod(
open val type: TanMethodType, open val type: TanMethodType,
open val identifier: String, open val identifier: String,
open val maxTanInputLength: Int? = null, open val maxTanInputLength: Int? = null,
open val allowedTanFormat: AllowedTanFormat = AllowedTanFormat.Alphanumeric open val allowedTanFormat: AllowedTanFormat = AllowedTanFormat.Alphanumeric,
open var userSetDisplayName: String? = null
) { ) {
@get:JsonIgnore @get:JsonIgnore