Customer invoice payment methods offline payment last step issue solved.
This commit is contained in:
		| @@ -10,7 +10,4 @@ return [ | ||||
|     'order'            => 'Order', | ||||
|     'payment_gateways' => 'Offline Payment Methods', | ||||
|  | ||||
|     'confirm' => 'Confirm', | ||||
|     'loading' => 'Loading', | ||||
|  | ||||
| ]; | ||||
|   | ||||
| @@ -4,36 +4,4 @@ | ||||
| <div class="well well-sm"> | ||||
|     {{ $gateway['description'] }} | ||||
| </div> | ||||
| @endif | ||||
| <div class="buttons"> | ||||
|     <div class="pull-right"> | ||||
|         <input type="button" value="{{ trans('offlinepayment::offlinepayment.confirm') }}" id="button-confirm" class="btn btn-success" data-loading-text="{{ trans('offlinepayment::offlinepayment.loading') }}" /> | ||||
|     </div> | ||||
| </div> | ||||
| <script type="text/javascript"><!-- | ||||
|     $('#button-confirm').on('click', function() { | ||||
|         $.ajax({ | ||||
|             url: '{{ url("customers/invoices/" . $invoice->id . "/confirm") }}', | ||||
|             type: 'POST', | ||||
|             dataType: 'JSON', | ||||
|             data: {payment_method: '{{ $gateway['code'] }}'}, | ||||
|             cache: false, | ||||
|             headers: { 'X-CSRF-TOKEN': '{{ csrf_token() }}' }, | ||||
|             beforeSend: function() { | ||||
|                 $('#button-confirm').button('loading'); | ||||
|             }, | ||||
|             complete: function() { | ||||
|                 $('#button-confirm').button('reset'); | ||||
|             }, | ||||
|             success: function(data) { | ||||
|                 if (data['error']) { | ||||
|                     alert(data['error']); | ||||
|                 } | ||||
|  | ||||
|                 if (data['success']) { | ||||
|                     location.reload(); | ||||
|                 } | ||||
|             } | ||||
|         }); | ||||
|     }); | ||||
|     //--></script> | ||||
| @endif | ||||
		Reference in New Issue
	
	Block a user