@@ -7,31 +7,31 @@ discard block |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | // Cart table columns. |
13 | 13 | $columns = array( |
14 | - 'name' => __( 'Item', 'invoicing' ), |
|
15 | - 'price' => __( 'Price', 'invoicing' ), |
|
16 | - 'quantity' => __( 'Quantity', 'invoicing' ), |
|
17 | - 'subtotal' => __( 'Subtotal', 'invoicing' ), |
|
14 | + 'name' => __('Item', 'invoicing'), |
|
15 | + 'price' => __('Price', 'invoicing'), |
|
16 | + 'quantity' => __('Quantity', 'invoicing'), |
|
17 | + 'subtotal' => __('Subtotal', 'invoicing'), |
|
18 | 18 | ); |
19 | 19 | |
20 | -if ( ! empty( $form->invoice ) ) { |
|
21 | - $columns = getpaid_invoice_item_columns( $form->invoice ); |
|
20 | +if (!empty($form->invoice)) { |
|
21 | + $columns = getpaid_invoice_item_columns($form->invoice); |
|
22 | 22 | } |
23 | 23 | |
24 | -$columns = apply_filters( 'getpaid_payment_form_cart_table_columns', $columns, $form ); |
|
24 | +$columns = apply_filters('getpaid_payment_form_cart_table_columns', $columns, $form); |
|
25 | 25 | |
26 | -do_action( 'getpaid_before_payment_form_cart', $form ); |
|
26 | +do_action('getpaid_before_payment_form_cart', $form); |
|
27 | 27 | |
28 | 28 | ?> |
29 | 29 | <div class="getpaid-payment-form-items-cart border form-group"> |
30 | 30 | <div class="getpaid-payment-form-items-cart-header border-bottom py-2 px-3 font-weight-bold bg-light"> |
31 | 31 | <div class="form-row"> |
32 | - <?php foreach ( $columns as $key => $label ) : ?> |
|
33 | - <div class="<?php echo 'name' == $key ? 'col-12 col-sm-5' : 'col-12 col-sm' ?> getpaid-form-cart-item-<?php echo esc_attr( $key ); ?>"> |
|
34 | - <?php echo sanitize_text_field( $label ); ?> |
|
32 | + <?php foreach ($columns as $key => $label) : ?> |
|
33 | + <div class="<?php echo 'name' == $key ? 'col-12 col-sm-5' : 'col-12 col-sm' ?> getpaid-form-cart-item-<?php echo esc_attr($key); ?>"> |
|
34 | + <?php echo sanitize_text_field($label); ?> |
|
35 | 35 | </div> |
36 | 36 | <?php endforeach; ?> |
37 | 37 | </div> |
@@ -39,16 +39,16 @@ discard block |
||
39 | 39 | <?php |
40 | 40 | |
41 | 41 | // Display the item totals. |
42 | - foreach ( $form->get_items() as $item ) { |
|
43 | - wpinv_get_template( 'payment-forms/cart-item.php', compact( 'form', 'item', 'columns' ) ); |
|
42 | + foreach ($form->get_items() as $item) { |
|
43 | + wpinv_get_template('payment-forms/cart-item.php', compact('form', 'item', 'columns')); |
|
44 | 44 | } |
45 | 45 | |
46 | 46 | // Display the cart totals. |
47 | - wpinv_get_template( 'payment-forms/cart-totals.php', compact( 'form' ) ); |
|
47 | + wpinv_get_template('payment-forms/cart-totals.php', compact('form')); |
|
48 | 48 | |
49 | 49 | ?> |
50 | 50 | </div> |
51 | 51 | |
52 | 52 | <?php |
53 | 53 | |
54 | -do_action( 'getpaid_after_payment_form_cart', $form ); |
|
54 | +do_action('getpaid_after_payment_form_cart', $form); |