diff --git a/app/Livewire/Flow2/PaymentMethod.php b/app/Livewire/Flow2/PaymentMethod.php index 796eabb3e773..2879b6cb91c6 100644 --- a/app/Livewire/Flow2/PaymentMethod.php +++ b/app/Livewire/Flow2/PaymentMethod.php @@ -52,18 +52,18 @@ class PaymentMethod extends Component if(count($this->methods) == 1) { $this->dispatch('payment-method-selected', company_gateway_id: $this->methods[0]['company_gateway_id'], gateway_type_id: $this->methods[0]['gateway_type_id'], amount: $this->invoice->balance); } - - $this->isLoading=false; - + else { + $this->isLoading = false; + $this->dispatch('loadingCompleted'); + } + } public function render() { - //If there is only one payment method, skip display and push straight to the form!! - return render('components.livewire.payment_method-flow2', ['methods' => $this->methods, 'amount' => $this->invoice->balance]); } } diff --git a/resources/views/portal/ninja2020/components/livewire/payment_method-flow2.blade.php b/resources/views/portal/ninja2020/components/livewire/payment_method-flow2.blade.php index 4d2418971b56..09afec9c68a0 100644 --- a/resources/views/portal/ninja2020/components/livewire/payment_method-flow2.blade.php +++ b/resources/views/portal/ninja2020/components/livewire/payment_method-flow2.blade.php @@ -1,4 +1,4 @@ -
+
@@ -9,15 +9,15 @@ @foreach($methods as $index => $method) - {{ $method['label'] }} - + @endforeach @@ -25,6 +25,10 @@ @script