From 134ab5c184c2aac18658fe895da36cc64779d6cd Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Mon, 27 Jul 2020 20:21:41 -0300 Subject: [PATCH] Fixed coding standards --- .../meta-boxes/views/html-order-items.php | 37 +++++++++---------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/includes/admin/meta-boxes/views/html-order-items.php b/includes/admin/meta-boxes/views/html-order-items.php index 554eca52ef9..d35c4d966c4 100644 --- a/includes/admin/meta-boxes/views/html-order-items.php +++ b/includes/admin/meta-boxes/views/html-order-items.php @@ -147,7 +147,7 @@ if ( wc_tax_enabled() ) { - get_subtotal(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_subtotal(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> get_total_discount() ) : ?> @@ -155,7 +155,7 @@ if ( wc_tax_enabled() ) { - - get_total_discount(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_total_discount(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> @@ -164,7 +164,7 @@ if ( wc_tax_enabled() ) { - get_total_fees(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_total_fees(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> @@ -176,7 +176,7 @@ if ( wc_tax_enabled() ) { - get_shipping_total(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_shipping_total(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> @@ -189,7 +189,7 @@ if ( wc_tax_enabled() ) { label ); ?>: - amount, array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + amount, array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> @@ -201,7 +201,7 @@ if ( wc_tax_enabled() ) { : - get_total(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_total(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?> @@ -209,7 +209,7 @@ if ( wc_tax_enabled() ) {
- get_status(), array( 'processing', 'completed', 'refunded' ) ) && ! empty( $order->get_date_paid() ) ) : ?> + get_status(), array( 'processing', 'completed', 'refunded' ), true ) && ! empty( $order->get_date_paid() ) ) : ?> @@ -237,7 +237,7 @@ if ( wc_tax_enabled() ) { - + get_id() ); ?> @@ -246,7 +246,7 @@ if ( wc_tax_enabled() ) { @@ -308,11 +308,11 @@ if ( wc_tax_enabled() ) { - + - + - +
: -get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?>-get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
: - get_total() - $order->get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?> + get_total() - $order->get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
:-get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?>-get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
:get_total() - $order->get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // WPCS: XSS ok. ?>get_total() - $order->get_total_refunded(), array( 'currency' => $order->get_currency() ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
@@ -393,7 +393,7 @@ if ( wc_tax_enabled() ) { ?>
@@ -433,18 +433,17 @@ if ( wc_tax_enabled() ) { get_results( "SELECT * FROM {$wpdb->prefix}woocommerce_tax_rates ORDER BY tax_rate_name LIMIT 100" ); - + $rates = $wpdb->get_results( "SELECT * FROM {$wpdb->prefix}woocommerce_tax_rates ORDER BY tax_rate_name LIMIT 100" ); foreach ( $rates as $rate ) { echo ' - - ' . ( isset( $classes_options[ $rate->tax_rate_class ] ) ? $classes_options[ $rate->tax_rate_class ] : '-' ) . ' - ' . WC_Tax::get_rate_code( $rate ) . ' - ' . WC_Tax::get_rate_percent( $rate ) . ' + + ' . ( isset( $classes_options[ $rate->tax_rate_class ] ) ? esc_html( $classes_options[ $rate->tax_rate_class ] ) : '-' ) . ' + ' . esc_html( WC_Tax::get_rate_code( $rate ) ) . ' + ' . esc_html( WC_Tax::get_rate_percent( $rate ) ) . ' - '; // WPCS: XSS ok. + '; } ?>