diff --git a/app/Services/PaymentService.php b/app/Services/PaymentService.php index 9b325bd4e447..23b5f4e8f167 100644 --- a/app/Services/PaymentService.php +++ b/app/Services/PaymentService.php @@ -63,7 +63,6 @@ class PaymentService extends BaseService if ($input) { $data = self::convertInputForOmnipay($input); - $data['email'] = $invitation->contact->email; Session::put($key, $data); } elseif (Session::get($key)) { $data = Session::get($key); @@ -95,6 +94,7 @@ class PaymentService extends BaseService $data = [ 'firstName' => $input['first_name'], 'lastName' => $input['last_name'], + 'email' => $input['email'], 'number' => isset($input['card_number']) ? $input['card_number'] : null, 'expiryMonth' => isset($input['expiration_month']) ? $input['expiration_month'] : null, 'expiryYear' => isset($input['expiration_year']) ? $input['expiration_year'] : null, diff --git a/resources/views/payments/payment.blade.php b/resources/views/payments/payment.blade.php index 274361938bac..949723e7f17a 100644 --- a/resources/views/payments/payment.blade.php +++ b/resources/views/payments/payment.blade.php @@ -13,6 +13,7 @@ var data = { name: $('#first_name').val() + ' ' + $('#last_name').val(), + email: $('#email').val(), address_line1: $('#address1').val(), address_line2: $('#address2').val(), address_city: $('#city').val(), @@ -117,6 +118,7 @@ {{ Former::populate($client) }} {{ Former::populateField('first_name', $contact->first_name) }} {{ Former::populateField('last_name', $contact->last_name) }} + {{ Former::populateField('email', $contact->email) }} @if (!$client->country_id && $client->account->country_id) {{ Former::populateField('country_id', $client->account->country_id) }} @endif @@ -178,8 +180,7 @@ ->label('') !!} - @if (isset($paymentTitle)) -