Deposit method instructions are now part of the prompt
This hides the instructions if the answer is already given in the input line.
This commit is contained in:
parent
2fbc833011
commit
5c16008038
2 changed files with 4 additions and 4 deletions
|
@ -26,9 +26,9 @@ sub amount :Tab(13.37,42) {
|
|||
$self->{amount} = parse_amount($amount)
|
||||
or return REJECT, "Invalid amount";
|
||||
|
||||
call_hooks("deposit_methods", $self->{deposit_methods} = {});
|
||||
call_hooks("deposit_methods", \my $message, $self->{deposit_methods} = {});
|
||||
|
||||
return "How are we receiving this EUR $amount?", \&how
|
||||
return $message . "How are we receiving this EUR $amount?", \&how
|
||||
if keys %{ $self->{deposit_methods} };
|
||||
|
||||
$cart->add(undef, +$self->{amount}, "Deposit", { is_deposit => 1 });
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
sub command { NEXT }
|
||||
|
||||
sub hook_deposit_methods {
|
||||
my ($class, $hash) = @_;
|
||||
my ($class, $message, $hash) = @_;
|
||||
|
||||
print <<"END";
|
||||
$$message = <<"END";
|
||||
|
||||
Please type one of the following:
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue