Added hint that for instant payment transfers may fees are charged
This commit is contained in:
parent
a3bb940d46
commit
9de40b4cc8
|
@ -126,10 +126,11 @@
|
|||
android:id="@+id/chkbxInstantPayment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="30dp"
|
||||
android:text="@string/dialog_transfer_money_instant_payment"
|
||||
style="@style/TextAppearance.AppCompat.Medium"
|
||||
android:layout_marginTop="@dimen/dialog_transfer_money_instant_payment_margin_top"
|
||||
android:layout_marginBottom="@dimen/dialog_transfer_money_instant_payment_margin_bottom"
|
||||
style="@style/TextAppearance.AppCompat.Medium"
|
||||
android:textSize="@dimen/dialog_transfer_money_instant_payment_text_size"
|
||||
android:text="@string/dialog_transfer_money_instant_payment"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
<string name="dialog_transfer_money_could_not_determine_bic_from_iban">Keine BIC gefunden für BLZ %1$s</string>
|
||||
<string name="dialog_transfer_money_amount">Betrag:</string>
|
||||
<string name="dialog_transfer_money_usage">Verwendungszweck:</string>
|
||||
<string name="dialog_transfer_money_instant_payment">Echtzeitüberweisung</string>
|
||||
<string name="dialog_transfer_money_instant_payment">Echtzeitüberweisung (evtl. kostenpflichtig)</string>
|
||||
<string name="dialog_transfer_money_transfer">Überweisen</string>
|
||||
<string name="dialog_transfer_money_message_transfer_successful">%1$s %2$s wurden erfolgreich an %3$s überwiesen.</string>
|
||||
<string name="dialog_transfer_money_message_transfer_failed">Konnte nicht %1$s %2$s an %3$s überweisen.\n\nFehlermeldung Ihrer Bank:\n\n%4$s</string>
|
||||
|
|
|
@ -54,6 +54,7 @@
|
|||
<dimen name="dialog_transfer_money_label_margin_right">4dp</dimen>
|
||||
<dimen name="dialog_transfer_money_bank_accounts_margin_bottom">12dp</dimen>
|
||||
<dimen name="dialog_transfer_money_autocomplete_fields_height">50dp</dimen>
|
||||
<dimen name="dialog_transfer_money_instant_payment_text_size">14sp</dimen>
|
||||
<dimen name="dialog_transfer_money_instant_payment_margin_top">6dp</dimen>
|
||||
<dimen name="dialog_transfer_money_instant_payment_margin_bottom">6dp</dimen>
|
||||
<dimen name="dialog_transfer_money_buttons_width">120dp</dimen>
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
<string name="dialog_transfer_money_could_not_determine_bic_from_iban">No BIC found for bank code %1$s</string>
|
||||
<string name="dialog_transfer_money_amount">Amount:</string>
|
||||
<string name="dialog_transfer_money_usage">Usage:</string>
|
||||
<string name="dialog_transfer_money_instant_payment">Instant payment</string>
|
||||
<string name="dialog_transfer_money_instant_payment">Instant payment (may with costs)</string>
|
||||
<string name="dialog_transfer_money_transfer">Transfer</string>
|
||||
<string name="dialog_transfer_money_message_transfer_successful">Successfully transferred %1$s %2$s to %3$s.</string>
|
||||
<string name="dialog_transfer_money_message_transfer_failed">Could not transfer %1$s %2$s to %3$s.\n\nError message from your bank:\n\n%4$s</string>
|
||||
|
|
|
@ -80,7 +80,14 @@
|
|||
"No BIC found for bank code %@" = "No BIC found for bank code %@";
|
||||
"Amount" = "Amount";
|
||||
"Usage" = "Usage";
|
||||
|
||||
"Instant Payment" = "Instant Payment";
|
||||
"may with costs" = "may with costs";
|
||||
"Instant payment information" = "Bank transfers are usually credited within one business day. However, this only applies during bank business hours, and therefore not at weekends and on public holidays. In addition, business hours vary from bank to bank. Mostly they are from 10 - 18 o'clock, sometimes also until 22 o'clock, but sometimes (e. g. Fridays) only until 14 o'clock.\n
|
||||
Instant payment transfers on the other hand are transferred within a maximum of 10 seconds, regardless of the day and time of day.\n
|
||||
However, real-time transfers are often subject to a fee.\n
|
||||
Unfortunately, Bankmeister cannot know whether a bank charges for instant payment transfers. Please refer to the list of prices and services of your bank.";
|
||||
|
||||
"Transfer Money" = "Transfer";
|
||||
|
||||
"Successfully transferred %@ %@ to %@." = "Successfully transferred %@ %@ to %@.";
|
||||
|
|
|
@ -80,7 +80,14 @@
|
|||
"No BIC found for bank code %@" = "Keine BIC gefunden für BLZ %@";
|
||||
"Amount" = "Betrag";
|
||||
"Usage" = "Verwendungszweck";
|
||||
|
||||
"Instant Payment" = "Echtzeitüberweisung";
|
||||
"may with costs" = "evtl. kostenpflichtig";
|
||||
"Instant payment information" = "Normale Überweisungen werden in der Regel innerhalb eines Werktages gutgeschrieben. Dies gilt jedoch nur zu Geschäftszeiten der Banken, also schon mal nicht am Wochenende und an Feiertagen. Zudem unterscheiden sich die Geschäftszeiten von Bank zu Bank. Meistens gehen diese von 10 - 18 Uhr, manchmal auch bis 22 Uhr, manchmal (Freitags) aber auch nur bis 14 Uhr.\n
|
||||
Echtzeitüberweisungen werden hingegen innerhalb von maximal 10 Sekunden überwiesen, egal an welchem Tag und zu welcher Uhrzeit.\n
|
||||
Häufig sind Echtzeitüberweisungen jedoch kostenpflichtig.\n
|
||||
Ob eine Bank Gebühren für Echtzeitüberweisungen erhebt, kann Bankmeister leider nicht wissen. Dies entnehmen Sie bitte dem Preis- / Leistungsverzeichnis Ihrer Bank.";
|
||||
|
||||
"Transfer Money" = "Überweisen";
|
||||
|
||||
"Successfully transferred %@ %@ to %@." = "%@ %@ wurden erfolgreich an %@ überwiesen.";
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
import SwiftUI
|
||||
|
||||
|
||||
class SelectorWrapper : NSObject {
|
||||
|
||||
private let _action: () -> ()
|
||||
|
||||
|
||||
init(_ action: @escaping () -> ()) {
|
||||
_action = action
|
||||
super.init()
|
||||
}
|
||||
|
||||
|
||||
@objc func action() {
|
||||
_action()
|
||||
}
|
||||
|
||||
}
|
|
@ -26,6 +26,37 @@ extension UIResponder {
|
|||
|
||||
}
|
||||
|
||||
|
||||
extension UIDevice {
|
||||
|
||||
static var deviceType: UIUserInterfaceIdiom {
|
||||
get {
|
||||
return UIDevice.current.deviceType
|
||||
}
|
||||
}
|
||||
|
||||
var deviceType: UIUserInterfaceIdiom {
|
||||
get {
|
||||
return self.userInterfaceIdiom
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static var isRunningOniPad: Bool {
|
||||
get {
|
||||
return UIDevice.current.userInterfaceIdiom == .pad
|
||||
}
|
||||
}
|
||||
|
||||
var isRunningOniPad: Bool {
|
||||
get {
|
||||
return self.userInterfaceIdiom == .pad
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
extension UserDefaults {
|
||||
|
||||
func string(forKey key: String, defaultValue: String) -> String {
|
||||
|
|
|
@ -0,0 +1,62 @@
|
|||
import SwiftUI
|
||||
|
||||
|
||||
struct InstantPaymentInfoView: View {
|
||||
|
||||
@State private var showInstantPaymentInfoPopover = false
|
||||
|
||||
|
||||
var body: some View {
|
||||
HStack {
|
||||
Text("may with costs")
|
||||
.font(.caption)
|
||||
.styleAsDetail()
|
||||
.lineLimit(1)
|
||||
.minimumScaleFactor(0.5)
|
||||
.padding(.horizontal, 0)
|
||||
|
||||
UIKitButton(.infoLight) { self.showInstantPaymentInfoPopover = true }
|
||||
.popover(isPresented: $showInstantPaymentInfoPopover, arrowEdge: .leading ) {
|
||||
if UIDevice.isRunningOniPad {
|
||||
ScrollView {
|
||||
Text("Instant payment information")
|
||||
.padding()
|
||||
.detailForegroundColor()
|
||||
}
|
||||
}
|
||||
else {
|
||||
VStack {
|
||||
Text("Instant payment information")
|
||||
.padding()
|
||||
.detailForegroundColor()
|
||||
|
||||
HStack {
|
||||
Spacer()
|
||||
|
||||
Button("OK") { self.showInstantPaymentInfoPopover = false }
|
||||
|
||||
Spacer()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
struct InstantPaymentInfoView_Previews: PreviewProvider {
|
||||
|
||||
static var previews: some View {
|
||||
Form {
|
||||
Section {
|
||||
Toggle(isOn: .constant(true)) {
|
||||
InstantPaymentInfoView()
|
||||
}
|
||||
}
|
||||
}
|
||||
.environment(\.locale, .init(identifier: "de"))
|
||||
}
|
||||
|
||||
}
|
|
@ -161,7 +161,18 @@ struct TransferMoneyDialog: View {
|
|||
|
||||
if supportsInstantPayment {
|
||||
Section {
|
||||
Toggle("Instant Payment", isOn: $instantPayment)
|
||||
VStack {
|
||||
Toggle(isOn: $instantPayment) {
|
||||
HStack {
|
||||
Text("Instant Payment")
|
||||
.lineLimit(1)
|
||||
|
||||
if instantPayment {
|
||||
InstantPaymentInfoView()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -404,5 +415,6 @@ struct TransferMoneyDialog: View {
|
|||
struct TransferMoneyDialog_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
TransferMoneyDialog()
|
||||
.environment(\.locale, .init(identifier: "de"))
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,47 @@
|
|||
import SwiftUI
|
||||
|
||||
|
||||
struct UIKitButton: UIViewRepresentable {
|
||||
|
||||
private let type: UIButton.ButtonType
|
||||
|
||||
private let text: String?
|
||||
|
||||
private let selectorWrapper: SelectorWrapper
|
||||
|
||||
|
||||
init(_ type: UIButton.ButtonType = .system, text: String? = nil, _ action: @escaping () -> Void) {
|
||||
self.type = type
|
||||
|
||||
self.text = text
|
||||
|
||||
self.selectorWrapper = SelectorWrapper(action)
|
||||
}
|
||||
|
||||
|
||||
func makeUIView(context: UIViewRepresentableContext<UIKitButton>) -> UIButton {
|
||||
let button = UIButton(type: type)
|
||||
|
||||
if let text = text {
|
||||
button.setTitle(text, for: .normal)
|
||||
}
|
||||
|
||||
button.addTarget(selectorWrapper, action: #selector(selectorWrapper.action), for: .touchUpInside)
|
||||
|
||||
return button
|
||||
}
|
||||
|
||||
func updateUIView(_ uiView: UIButton, context: UIViewRepresentableContext<UIKitButton>) {
|
||||
uiView.addTarget(selectorWrapper, action: #selector(selectorWrapper.action), for: .touchUpInside) // why gets the target removed at some point and needs to be refreshed?
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
struct UIKitButton_Previews: PreviewProvider {
|
||||
|
||||
static var previews: some View {
|
||||
UIKitButton(.infoLight) { }
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue