From 74d30df248608783d56013a6206686d054ad595b Mon Sep 17 00:00:00 2001 From: dankito Date: Mon, 28 Sep 2020 16:58:26 +0200 Subject: [PATCH] Implemented displaying bank and bank account data --- .../settings/BankAccountSettingsDialog.kt | 6 +++ .../dialogs/settings/BankSettingsDialog.kt | 5 ++ .../main/res/layout/dialog_add_account.xml | 1 + .../layout/dialog_bank_account_settings.xml | 51 +++++++++++++++++++ .../main/res/layout/dialog_bank_settings.xml | 47 ++++++++++++++++- .../res/layout/view_form_section_title.xml | 1 - .../src/main/res/values-de/strings.xml | 12 +++++ .../src/main/res/values/dimens.xml | 5 +- .../src/main/res/values/strings.xml | 12 +++++ .../Base.lproj/Localizable.strings | 2 +- 10 files changed, 137 insertions(+), 5 deletions(-) diff --git a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankAccountSettingsDialog.kt b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankAccountSettingsDialog.kt index 6fc2d7b9..b4783fdd 100644 --- a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankAccountSettingsDialog.kt +++ b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankAccountSettingsDialog.kt @@ -43,6 +43,12 @@ open class BankAccountSettingsDialog : SettingsDialogBase() { } edtxtBankAccountName.text = account.displayName + + lvlAccountHolderName.value = account.accountHolderName + lvlAccountIdentifier.value = account.identifier + lvlSubAccountNumber.setValueAndVisibilityIfValueIsSet(account.subAccountNumber) + lvlIban.setValueAndVisibilityIfValueIsSet(account.iban) + lvlAccountType.value = account.type.toString() // TODO: translate } } diff --git a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankSettingsDialog.kt b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankSettingsDialog.kt index 5483ee52..e1a97d33 100644 --- a/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankSettingsDialog.kt +++ b/ui/BankingAndroidApp/src/main/java/net/dankito/banking/ui/android/dialogs/settings/BankSettingsDialog.kt @@ -65,6 +65,11 @@ open class BankSettingsDialog : SettingsDialogBase() { bankAccountsAdapter.onClickListener = { navigationToBankAccountSettingsDialog(it.account) } bankAccountsAdapter.itemDropped = { oldPosition, oldItem, newPosition, newItem -> reorderedBankAccounts(oldPosition, oldItem.account, newPosition, newItem.account) } + lvlBankCode.value = bank.bankCode + lvlBic.value = bank.bic + lvlCustomerName.value = bank.customerName + lvlFinTsServerAddress.value = bank.finTsServerAddress + btnDeleteAccount.setOnClickListener { askUserToDeleteAccount() } } } diff --git a/ui/BankingAndroidApp/src/main/res/layout/dialog_add_account.xml b/ui/BankingAndroidApp/src/main/res/layout/dialog_add_account.xml index 4b2db192..e0661c54 100644 --- a/ui/BankingAndroidApp/src/main/res/layout/dialog_add_account.xml +++ b/ui/BankingAndroidApp/src/main/res/layout/dialog_add_account.xml @@ -19,6 +19,7 @@ diff --git a/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_account_settings.xml b/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_account_settings.xml index 81c03829..076b2f7d 100644 --- a/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_account_settings.xml +++ b/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_account_settings.xml @@ -63,6 +63,57 @@ + + + + + + + + + + + + + + + + + + diff --git a/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_settings.xml b/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_settings.xml index f46f8768..1fbdcd0d 100644 --- a/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_settings.xml +++ b/ui/BankingAndroidApp/src/main/res/layout/dialog_bank_settings.xml @@ -65,6 +65,7 @@ @@ -92,7 +93,50 @@ android:orientation="vertical" android:layout_width="match_parent" android:layout_height="wrap_content" - android:layout_marginBottom="@dimen/dialog_bank_settings_bank_accounts_section_margin_bottom" + > + + + + + + + + + + + + + + + diff --git a/ui/BankingAndroidApp/src/main/res/layout/view_form_section_title.xml b/ui/BankingAndroidApp/src/main/res/layout/view_form_section_title.xml index 57233feb..0a1b91fb 100644 --- a/ui/BankingAndroidApp/src/main/res/layout/view_form_section_title.xml +++ b/ui/BankingAndroidApp/src/main/res/layout/view_form_section_title.xml @@ -11,7 +11,6 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginTop="@dimen/form_section_title_margin_top" - android:layout_marginBottom="@dimen/form_section_title_margin_bottom" android:textSize="@dimen/form_section_title_text_size" android:textColor="@color/colorPrimary" /> diff --git a/ui/BankingAndroidApp/src/main/res/values-de/strings.xml b/ui/BankingAndroidApp/src/main/res/values-de/strings.xml index b307a10d..29fa05af 100644 --- a/ui/BankingAndroidApp/src/main/res/values-de/strings.xml +++ b/ui/BankingAndroidApp/src/main/res/values-de/strings.xml @@ -22,6 +22,12 @@ Konten Bankzugänge + Bankleitzahl + BIC + IBAN + Kontoinhaber + FinTS Server + Seitenleiste öffnen Seitenleiste schließen @string/app_name @@ -104,9 +110,15 @@ Name + Bankdaten Konto löschen Name + Kontodaten + Kontoinhaber + Kontonummer + Unterkontenmerkmal + Typ Nicht gespeicherte Änderungen diff --git a/ui/BankingAndroidApp/src/main/res/values/dimens.xml b/ui/BankingAndroidApp/src/main/res/values/dimens.xml index ef4437d3..d6793aa5 100644 --- a/ui/BankingAndroidApp/src/main/res/values/dimens.xml +++ b/ui/BankingAndroidApp/src/main/res/values/dimens.xml @@ -19,6 +19,7 @@ 12dp 60dp 6dp + 8dp 6dp 15sp 18dp @@ -158,10 +159,10 @@ 8dp 16sp - 18dp + 18dp 50dp - 35dp + 32dp 2dp 16sp diff --git a/ui/BankingAndroidApp/src/main/res/values/strings.xml b/ui/BankingAndroidApp/src/main/res/values/strings.xml index a20eb531..6664100a 100644 --- a/ui/BankingAndroidApp/src/main/res/values/strings.xml +++ b/ui/BankingAndroidApp/src/main/res/values/strings.xml @@ -22,6 +22,12 @@ Accounts Bank credentials + Bank code + BIC + IBAN + Customer name + FinTS server + Open navigation drawer Close navigation drawer @string/app_name @@ -104,9 +110,15 @@ Name + Bank data Delete account Name + Account data + Account holder name + Account identifier + Sub account number + Type Unsaved changed diff --git a/ui/BankingiOSApp/BankingiOSApp/Base.lproj/Localizable.strings b/ui/BankingiOSApp/BankingiOSApp/Base.lproj/Localizable.strings index 11870e70..31f5b823 100644 --- a/ui/BankingiOSApp/BankingiOSApp/Base.lproj/Localizable.strings +++ b/ui/BankingiOSApp/BankingiOSApp/Base.lproj/Localizable.strings @@ -164,7 +164,7 @@ Unfortunately, Bankmeister cannot know whether a bank charges for real-time tran "Credentials" = "Credentials"; "Customer name" = "Customer name"; -"FinTS server address" = "FinTS server address"; +"FinTS server address" = "FinTS server"; "Delete account" = "Delete account";