mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 05:02:36 +01:00
Conditionally show ACH for US customers
This commit is contained in:
parent
ba0210fff6
commit
33f0b6b7c6
@ -50,9 +50,17 @@ class GoCardlessPaymentDriver extends BaseDriver
|
||||
|
||||
public function gatewayTypes(): array
|
||||
{
|
||||
return [
|
||||
GatewayType::BANK_TRANSFER,
|
||||
];
|
||||
$types = [];
|
||||
|
||||
if (
|
||||
$this->client
|
||||
&& isset($this->client->country)
|
||||
&& in_array($this->client->country->iso_3166_3, ['USA'])
|
||||
) {
|
||||
$types[] = GatewayType::BANK_TRANSFER;
|
||||
}
|
||||
|
||||
return $types;
|
||||
}
|
||||
|
||||
public function authorizeView(array $data)
|
||||
|
Loading…
Reference in New Issue
Block a user