1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-20 16:31:33 +02:00

Merge pull request #6906 from beganovich/jira-745

Stripe: BECS improvements
This commit is contained in:
David Bomba 2021-10-27 03:56:55 +11:00 committed by GitHub
commit ee0c7f9535
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 8 deletions

View File

@ -141,8 +141,8 @@ class BECS
$method = $this->stripe->getStripePaymentMethod($intent->payment_method);
$payment_meta = new \stdClass;
$payment_meta->brand = (string) \sprintf('%s (%s)', $method->sepa_debit->bank_code, ctrans('texts.becs'));
$payment_meta->last4 = (string) $method->sepa_debit->last4;
$payment_meta->brand = (string) \sprintf('%s (%s)', $method->au_becs_debit->bank_code, ctrans('texts.becs'));
$payment_meta->last4 = (string) $method->au_becs_debit->last4;
$payment_meta->state = 'authorized';
$payment_meta->type = GatewayType::BECS;

View File

@ -208,7 +208,7 @@ class StripePaymentDriver extends BaseDriver
&& $this->client->currency()
&& ($this->client->currency()->code == 'AUD')
&& isset($this->client->country)
&& in_array($this->client->country->iso_3166_3, ["AUS", "DEU"]))
&& in_array($this->client->country->iso_3166_3, ['AUS']))
$types[] = GatewayType::BECS;
if ($this->client

View File

@ -4328,7 +4328,7 @@ $LANG = array(
'giropay_law' => 'By entering your Customer information (such as name, sort code and account number) you (the Customer) agree that this information is given voluntarily.',
'eps' => 'EPS',
'becs' => 'BECS Direct Debit',
'becs_mandate' => 'By providing your bank account details, you agree to this <a href="https://stripe.com/au-becs-dd-service-agreement/legal">Direct Debit Request and the Direct Debit Request service agreement</a>, and authorise Stripe Payments Australia Pty Ltd ACN 160 180 343 Direct Debit User ID number 507156 (“Stripe”) to debit your account through the Bulk Electronic Clearing System (BECS) on behalf of :company (the “Merchant”) for any amounts separately communicated to you by the Merchant. You certify that you are either an account holder or an authorised signatory on the account listed above.',
'becs_mandate' => 'By providing your bank account details, you agree to this <a class="underline" href="https://stripe.com/au-becs-dd-service-agreement/legal">Direct Debit Request and the Direct Debit Request service agreement</a>, and authorise Stripe Payments Australia Pty Ltd ACN 160 180 343 Direct Debit User ID number 507156 (“Stripe”) to debit your account through the Bulk Electronic Clearing System (BECS) on behalf of :company (the “Merchant”) for any amounts separately communicated to you by the Merchant. You certify that you are either an account holder or an authorised signatory on the account listed above.',
'you_need_to_accept_the_terms_before_proceeding' => 'You need to accept the terms before proceeding.',
'direct_debit' => 'Direct Debit',
'clone_to_expense' => 'Clone to expense',

View File

@ -12,17 +12,20 @@
<label for="becs-name">
<input class="input w-full" id="becs-name" type="text" placeholder="{{ ctrans('texts.bank_account_holder') }}" required>
</label>
<label for="becs-email" >
<label for="becs-email">
<input class="input w-full" id="becs-email-address" type="email" placeholder="{{ ctrans('texts.email') }}" required>
</label>
<label>
<div class="border p-4 rounded">
<div class="border p-4 rounded mt-2">
<div id="becs-iban"></div>
</div>
</label>
<div id="mandate-acceptance">
<div id="mandate-acceptance" class="mt-2">
<input type="checkbox" id="becs-mandate-acceptance" class="input mr-4">
<label for="becs-mandate-acceptance">{{ctrans('texts.becs_mandate')}}</label>
<label for="becs-mandate-acceptance">{!! ctrans('texts.becs_mandate') !!}</label>
</div>
</form>
@endcomponent