- Issue created by @carsonw
- 🇮🇱Israel jsacksick
if (!$this->order->getTotalPrice() || $this->order->isPaid() || $this->order->getTotalPrice()->isZero()) { // No payment is needed if the order is free or has already been paid. // In that case, collect just the billing information. $pane_form['#title'] = $this->t('Billing information'); $pane_form = $this->buildBillingProfileForm($pane_form, $form_state); return $pane_form; }
Hm... You probably have to implement
hook_form_alter()
to alter the checkout form and set #access FALSE to the billing information form element.
Should be accessible under$form['payment_information']['billing_information']
.
I haven't tested that though... Otherwise you could swap the payment information pane checkout pane with your own class to you can override the isVisible() method for example and return FALSE from there if the order is free.I don't see a no code solution for this unfortunately.
- Status changed to Fixed
7 months ago 1:50pm 24 May 2024 Automatically closed - issue fixed for 2 weeks with no activity.