@extends('payments.bank_transfer')
@section('head')
@parent
@stop
@section('payment_details')
{!! Former::open($url)
->autocomplete('on')
->addClass('payment-form')
->id('payment-form')
->rules(array(
'country_id' => 'required',
'currency_id' => 'required',
'account_number' => 'required',
'routing_number' => 'required',
'account_holder_name' => 'required',
'account_holder_type' => 'required',
'authorize_ach' => 'required',
)) !!}
{!! Former::populateField('account_holder_type', 'individual') !!}
{!! Former::populateField('country_id', $client->country_id) !!}
{!! Former::populateField('currency_id', $client->getCurrencyCode()) !!}
@if (Utils::isNinjaDev())
{!! Former::populateField('account_holder_name', 'Test Client') !!}
@endif
@if ($accountGateway->getPlaidEnabled())
@endif
@if($accountGateway->getPlaidEnabled())
{{ trans('texts.or') }}
{{ trans('texts.link_manually') }}
@endif
{{ trans('texts.ach_verification_delay_help') }}
{!! Former::radios('account_holder_type')->radios(array(
trans('texts.individual_account') => array('value' => 'individual'),
trans('texts.company_account') => array('value' => 'company'),
))->inline()->label(trans('texts.account_holder_type')); !!}
{!! Former::text('account_holder_name')
->label(trans('texts.account_holder_name')) !!}
{!! Former::select('country_id')
->label(trans('texts.country_id'))
->addOption('','')
->fromQuery(Cache::get('countries'), 'name', 'id')
->addGroupClass('country-select') !!}
{!! Former::select('currency_id')
->label(trans('texts.currency_id'))
->addOption('','')
->fromQuery(Cache::get('currencies'), 'name', 'code')
->addGroupClass('currency-select') !!}
{!! Former::text('')
->id('routing_number')
->label(trans('texts.routing_number')) !!}
{!! Former::text('')
->id('account_number')
->label(trans('texts.account_number')) !!}
{!! Former::text('')
->id('confirm_account_number')
->label(trans('texts.confirm_account_number')) !!}
{!! Former::checkbox('authorize_ach')
->text(trans('texts.ach_authorization', ['company'=>$account->getDisplayName(), 'email' => $account->work_email]))
->label(' ')
->value(1) !!}
{!! Button::normal(strtoupper(trans('texts.cancel')))->large()->asLinkTo($invitation->getLink()) !!}
{!! Button::success(strtoupper(trans('texts.add_account')))
->submit()
->withAttributes(['id'=>'add_account_button'])
->large() !!}
@if ($accountGateway->getPlaidEnabled() && !empty($amount))
{!! Button::success(request()->capture ? strtoupper(trans('texts.submit')) : strtoupper(trans('texts.pay_now') . ' - ' . $account->formatMoney($amount, $client, CURRENCY_DECORATOR_CODE) ))
->submit()
->withAttributes(['style'=>'display:none', 'id'=>'pay_now_button'])
->large() !!}
@endif
{!! Former::close() !!}
@stop