task 6809 | удалены лишние файлы WC (остались части шаблонов в php файлах woocommerce (в основном кастомизированные блоки для доставки - завел подзадачу на перенос шаблонов в twig в беклог) )
parent
dddac1236f
commit
4411f0bd01
@ -0,0 +1,38 @@ |
|||||||
|
{% if fn('wc_coupons_enabled') %} |
||||||
|
|
||||||
|
{% set applied_coupons = fn('WC').cart.get_applied_coupons %} |
||||||
|
{% set has_coupon = applied_coupons is not empty %} |
||||||
|
{% set first_coupon = has_coupon ? applied_coupons[0] : '' %} |
||||||
|
{% set cText = has_coupon ? ('Применен промокод: ' ~ first_coupon) : '' %} |
||||||
|
|
||||||
|
<div class="order-your__promo" id="promo_form" {% if has_coupon %}style="display: none;"{% endif %}> |
||||||
|
<input type="text" name="coupon_code" class="form__input form__input--grey" placeholder="Промокод" id="coupon_code" value="" /> |
||||||
|
<button type="button" |
||||||
|
class="button button--white button--red-48-px active order-your-promo__button" |
||||||
|
name="apply_coupon" |
||||||
|
value="Применить"> |
||||||
|
Применить |
||||||
|
</button> |
||||||
|
<span class="form-input__error form-input__error--absolute" id="promo_err"> |
||||||
|
Ошибка! Промокод введен неверно или не существует. |
||||||
|
</span> |
||||||
|
</div> |
||||||
|
|
||||||
|
<div class="order-your__promo" id="promo_delete" {% if not has_coupon %}style="display: none;"{% endif %}> |
||||||
|
<input type="text" |
||||||
|
name="coupon_code_applied" |
||||||
|
readonly |
||||||
|
class="form__input form__input--grey" |
||||||
|
placeholder="Промокод" |
||||||
|
id="coupon_code_app" |
||||||
|
value="{{ cText }}" /> |
||||||
|
<button type="button" |
||||||
|
class="button button--white button--red-48-px active order-your-promo__button" |
||||||
|
id="delete_coupon" |
||||||
|
value="Применить" |
||||||
|
data-coupon="{{ first_coupon }}"> |
||||||
|
Удалить |
||||||
|
</button> |
||||||
|
</div> |
||||||
|
|
||||||
|
{% endif %} |
@ -1,25 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Cart errors page |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/cart-errors.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 3.5.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
?> |
|
||||||
|
|
||||||
<p><?php esc_html_e( 'There are some issues with the items in your cart. Please go back to the cart page and resolve these issues before checking out.', 'woocommerce' ); ?></p>
|
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_cart_has_errors' ); ?> |
|
||||||
|
|
||||||
<p><a class="button wc-backward" href="<?php echo esc_url( wc_get_cart_url() ); ?>"><?php esc_html_e( 'Return to cart', 'woocommerce' ); ?></a></p>
|
|
@ -1,56 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Checkout billing information form |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/form-billing.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 3.6.0 |
|
||||||
* @global WC_Checkout $checkout |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
?> |
|
||||||
<div class="woocommerce-billing-fields"> |
|
||||||
<?php if ( wc_ship_to_billing_address_only() && WC()->cart->needs_shipping() ) : ?> |
|
||||||
|
|
||||||
<h3><?php esc_html_e( 'Billing & Shipping', 'woocommerce' ); ?></h3>
|
|
||||||
|
|
||||||
<?php else : ?> |
|
||||||
|
|
||||||
<h3><?php esc_html_e( 'Billing details', 'woocommerce' ); ?></h3>
|
|
||||||
|
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_before_checkout_billing_form', $checkout ); ?> |
|
||||||
|
|
||||||
<div class="woocommerce-billing-fields__field-wrapper"> |
|
||||||
<?php |
|
||||||
$fields = $checkout->get_checkout_fields( 'billing' ); |
|
||||||
|
|
||||||
foreach ( $fields as $key => $field ) { |
|
||||||
woocommerce_form_field( $key, $field, $checkout->get_value( $key ) ); |
|
||||||
} |
|
||||||
?> |
|
||||||
</div> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_after_checkout_billing_form', $checkout ); ?> |
|
||||||
</div> |
|
||||||
|
|
||||||
<?php if ( ! is_user_logged_in() && $checkout->is_registration_enabled() ) : ?> |
|
||||||
<div class="modal-form-content__line"> |
|
||||||
<div class="form-agreement__check"> |
|
||||||
<input id="reg" type="checkbox" name="reg" value="1" class="form-agreement__input"> |
|
||||||
<div class="form-agreement__square"> |
|
||||||
</div> |
|
||||||
<label for="reg" class="form-agreement__label">Запомнить меня</label> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
<?php endif; ?> |
|
@ -1,36 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Checkout login form |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/form-login.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 3.8.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
|
|
||||||
if ( is_user_logged_in() || 'no' === get_option( 'woocommerce_enable_checkout_login_reminder' ) ) { |
|
||||||
return; |
|
||||||
} |
|
||||||
|
|
||||||
?> |
|
||||||
<div class="woocommerce-form-login-toggle"> |
|
||||||
<?php wc_print_notice( apply_filters( 'woocommerce_checkout_login_message', esc_html__( 'Returning customer?', 'woocommerce' ) ) . ' <a href="#" class="showlogin">' . esc_html__( 'Click here to login', 'woocommerce' ) . '</a>', 'notice' ); ?> |
|
||||||
</div> |
|
||||||
<?php |
|
||||||
|
|
||||||
woocommerce_login_form( |
|
||||||
array( |
|
||||||
'message' => esc_html__( 'If you have shopped with us before, please enter your details below. If you are a new customer, please proceed to the Billing section.', 'woocommerce' ), |
|
||||||
'redirect' => wc_get_checkout_url(), |
|
||||||
'hidden' => true, |
|
||||||
) |
|
||||||
); |
|
@ -1,109 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Pay for order form |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/form-pay.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 8.2.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
|
|
||||||
$totals = $order->get_order_item_totals(); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited |
|
||||||
?> |
|
||||||
<form id="order_review" method="post"> |
|
||||||
|
|
||||||
<table class="shop_table"> |
|
||||||
<thead> |
|
||||||
<tr> |
|
||||||
<th class="product-name"><?php esc_html_e( 'Product', 'woocommerce' ); ?></th>
|
|
||||||
<th class="product-quantity"><?php esc_html_e( 'Qty', 'woocommerce' ); ?></th>
|
|
||||||
<th class="product-total"><?php esc_html_e( 'Totals', 'woocommerce' ); ?></th>
|
|
||||||
</tr> |
|
||||||
</thead> |
|
||||||
<tbody> |
|
||||||
<?php if ( count( $order->get_items() ) > 0 ) : ?> |
|
||||||
<?php foreach ( $order->get_items() as $item_id => $item ) : ?> |
|
||||||
<?php |
|
||||||
if ( ! apply_filters( 'woocommerce_order_item_visible', true, $item ) ) { |
|
||||||
continue; |
|
||||||
} |
|
||||||
?> |
|
||||||
<tr class="<?php echo esc_attr( apply_filters( 'woocommerce_order_item_class', 'order_item', $item, $order ) ); ?>">
|
|
||||||
<td class="product-name"> |
|
||||||
<?php |
|
||||||
echo wp_kses_post( apply_filters( 'woocommerce_order_item_name', $item->get_name(), $item, false ) ); |
|
||||||
|
|
||||||
do_action( 'woocommerce_order_item_meta_start', $item_id, $item, $order, false ); |
|
||||||
|
|
||||||
wc_display_item_meta( $item ); |
|
||||||
|
|
||||||
do_action( 'woocommerce_order_item_meta_end', $item_id, $item, $order, false ); |
|
||||||
?> |
|
||||||
</td> |
|
||||||
<td class="product-quantity"><?php echo apply_filters( 'woocommerce_order_item_quantity_html', ' <strong class="product-quantity">' . sprintf( '× %s', esc_html( $item->get_quantity() ) ) . '</strong>', $item ); ?></td><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
<td class="product-subtotal"><?php echo $order->get_formatted_line_subtotal( $item ); ?></td><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
</tr> |
|
||||||
<?php endforeach; ?> |
|
||||||
<?php endif; ?> |
|
||||||
</tbody> |
|
||||||
<tfoot> |
|
||||||
<?php if ( $totals ) : ?> |
|
||||||
<?php foreach ( $totals as $total ) : ?> |
|
||||||
<tr> |
|
||||||
<th scope="row" colspan="2"><?php echo $total['label']; ?></th><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
<td class="product-total"><?php echo $total['value']; ?></td><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
</tr> |
|
||||||
<?php endforeach; ?> |
|
||||||
<?php endif; ?> |
|
||||||
</tfoot> |
|
||||||
</table> |
|
||||||
|
|
||||||
<?php |
|
||||||
/** |
|
||||||
* Triggered from within the checkout/form-pay.php template, immediately before the payment section. |
|
||||||
* |
|
||||||
* @since 8.2.0 |
|
||||||
*/ |
|
||||||
do_action( 'woocommerce_pay_order_before_payment' ); |
|
||||||
?> |
|
||||||
|
|
||||||
<div id="payment"> |
|
||||||
<?php if ( $order->needs_payment() ) : ?> |
|
||||||
<ul class="wc_payment_methods payment_methods methods"> |
|
||||||
<?php |
|
||||||
if ( ! empty( $available_gateways ) ) { |
|
||||||
foreach ( $available_gateways as $gateway ) { |
|
||||||
wc_get_template( 'checkout/payment-method.php', array( 'gateway' => $gateway ) ); |
|
||||||
} |
|
||||||
} else { |
|
||||||
echo '<li>'; |
|
||||||
wc_print_notice( apply_filters( 'woocommerce_no_available_payment_methods_message', esc_html__( 'Sorry, it seems that there are no available payment methods for your location. Please contact us if you require assistance or wish to make alternate arrangements.', 'woocommerce' ) ), 'notice' ); // phpcs:ignore WooCommerce.Commenting.CommentHooks.MissingHookComment |
|
||||||
echo '</li>'; |
|
||||||
} |
|
||||||
?> |
|
||||||
</ul> |
|
||||||
<?php endif; ?> |
|
||||||
<div class="form-row"> |
|
||||||
<input type="hidden" name="woocommerce_pay" value="1" /> |
|
||||||
|
|
||||||
<?php wc_get_template( 'checkout/terms.php' ); ?> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_pay_order_before_submit' ); ?> |
|
||||||
|
|
||||||
<?php echo apply_filters( 'woocommerce_pay_order_button_html', '<button type="submit" class="button alt' . esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ? ' ' . wc_wp_theme_get_element_class_name( 'button' ) : '' ) . '" id="place_order" value="' . esc_attr( $order_button_text ) . '" data-value="' . esc_attr( $order_button_text ) . '">' . esc_html( $order_button_text ) . '</button>' ); // @codingStandardsIgnoreLine ?>
|
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_pay_order_after_submit' ); ?> |
|
||||||
|
|
||||||
<?php wp_nonce_field( 'woocommerce-pay', 'woocommerce-pay-nonce' ); ?> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
</form> |
|
@ -1,53 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Email verification page. |
|
||||||
* |
|
||||||
* This displays instead of the thankyou page any time that the customer cannot be identified. |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/thankyou-verify-email.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you (the theme developer) will need to copy |
|
||||||
* the new files to your theme to maintain compatibility. We try to do this as little as possible, but it does happen. |
|
||||||
* When this occurs the version of the template file will be bumped and the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 7.9.0 |
|
||||||
* |
|
||||||
* @var bool $failed_submission Indicates if the last attempt to verify failed. |
|
||||||
* @var string $verify_url The URL for the email verification form. |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
?> |
|
||||||
<form name="checkout" method="post" class="woocommerce-form woocommerce-verify-email" action="<?php echo esc_url( $verify_url ); ?>" enctype="multipart/form-data">
|
|
||||||
|
|
||||||
<?php |
|
||||||
wp_nonce_field( 'wc_verify_email', 'check_submission' ); |
|
||||||
|
|
||||||
if ( $failed_submission ) { |
|
||||||
wc_print_notice( esc_html__( 'We were unable to verify the email address you provided. Please try again.', 'woocommerce' ), 'error' ); |
|
||||||
} |
|
||||||
?> |
|
||||||
<p> |
|
||||||
<?php |
|
||||||
printf( |
|
||||||
/* translators: 1: opening login link 2: closing login link */ |
|
||||||
esc_html__( 'To view this page, you must either %1$slogin%2$s or verify the email address associated with the order.', 'woocommerce' ), |
|
||||||
'<a href="' . esc_url( wc_get_page_permalink( 'myaccount' ) ) . '">', |
|
||||||
'</a>' |
|
||||||
); |
|
||||||
?> |
|
||||||
</p> |
|
||||||
|
|
||||||
<p class="form-row"> |
|
||||||
<label for="email"><?php esc_html_e( 'Email address', 'woocommerce' ); ?> <span class="required">*</span></label>
|
|
||||||
<input type="email" class="input-text" name="email" id="email" autocomplete="email" /> |
|
||||||
</p> |
|
||||||
|
|
||||||
<p class="form-row"> |
|
||||||
<button type="submit" class="woocommerce-button button <?php echo esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ); ?>" name="verify" value="1">
|
|
||||||
<?php esc_html_e( 'Verify', 'woocommerce' ); ?> |
|
||||||
</button> |
|
||||||
</p> |
|
||||||
</form> |
|
@ -1,42 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* "Order received" message. |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/order-received.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 8.8.0 |
|
||||||
* |
|
||||||
* @var WC_Order|false $order |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
?> |
|
||||||
|
|
||||||
<p class="woocommerce-notice woocommerce-notice--success woocommerce-thankyou-order-received"> |
|
||||||
<?php |
|
||||||
/** |
|
||||||
* Filter the message shown after a checkout is complete. |
|
||||||
* |
|
||||||
* @since 2.2.0 |
|
||||||
* |
|
||||||
* @param string $message The message. |
|
||||||
* @param WC_Order|false $order The order created during checkout, or false if order data is not available. |
|
||||||
*/ |
|
||||||
$message = apply_filters( |
|
||||||
'woocommerce_thankyou_order_received_text', |
|
||||||
esc_html( __( 'Thank you. Your order has been received.', 'woocommerce' ) ), |
|
||||||
$order |
|
||||||
); |
|
||||||
|
|
||||||
// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped |
|
||||||
echo $message; |
|
||||||
?> |
|
||||||
</p> |
|
@ -1,33 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Output a single payment method |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/payment-method.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 3.5.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
if ( ! defined( 'ABSPATH' ) ) { |
|
||||||
exit; |
|
||||||
} |
|
||||||
?> |
|
||||||
<li class="wc_payment_method payment_method_<?php echo esc_attr( $gateway->id ); ?>">
|
|
||||||
<input id="payment_method_<?php echo esc_attr( $gateway->id ); ?>" type="radio" class="input-radio" name="payment_method" value="<?php echo esc_attr( $gateway->id ); ?>" <?php checked( $gateway->chosen, true ); ?> data-order_button_text="<?php echo esc_attr( $gateway->order_button_text ); ?>" />
|
|
||||||
|
|
||||||
<label for="payment_method_<?php echo esc_attr( $gateway->id ); ?>">
|
|
||||||
<?php echo $gateway->get_title(); /* phpcs:ignore WordPress.XSS.EscapeOutput.OutputNotEscaped */ ?> <?php echo $gateway->get_icon(); /* phpcs:ignore WordPress.XSS.EscapeOutput.OutputNotEscaped */ ?> |
|
||||||
</label> |
|
||||||
<?php if ( $gateway->has_fields() || $gateway->get_description() ) : ?> |
|
||||||
<div class="payment_box payment_method_<?php echo esc_attr( $gateway->id ); ?>" <?php if ( ! $gateway->chosen ) : /* phpcs:ignore Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace */ ?>style="display:none;"<?php endif; /* phpcs:ignore Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace */ ?>>
|
|
||||||
<?php $gateway->payment_fields(); ?> |
|
||||||
</div> |
|
||||||
<?php endif; ?> |
|
||||||
</li> |
|
@ -1,63 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Checkout Payment Section |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/checkout/payment.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 8.1.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
|
|
||||||
if ( ! wp_doing_ajax() ) { |
|
||||||
do_action( 'woocommerce_review_order_before_payment' ); |
|
||||||
} |
|
||||||
?> |
|
||||||
<div id="payment" class="woocommerce-checkout-payment"> |
|
||||||
<?php if ( WC()->cart->needs_payment() ) : ?> |
|
||||||
<ul class="wc_payment_methods payment_methods methods"> |
|
||||||
<?php |
|
||||||
if ( ! empty( $available_gateways ) ) { |
|
||||||
foreach ( $available_gateways as $gateway ) { |
|
||||||
wc_get_template( 'checkout/payment-method.php', array( 'gateway' => $gateway ) ); |
|
||||||
} |
|
||||||
} else { |
|
||||||
echo '<li>'; |
|
||||||
wc_print_notice( apply_filters( 'woocommerce_no_available_payment_methods_message', WC()->customer->get_billing_country() ? esc_html__( 'Sorry, it seems that there are no available payment methods. Please contact us if you require assistance or wish to make alternate arrangements.', 'woocommerce' ) : esc_html__( 'Please fill in your details above to see available payment methods.', 'woocommerce' ) ), 'notice' ); // phpcs:ignore WooCommerce.Commenting.CommentHooks.MissingHookComment |
|
||||||
echo '</li>'; |
|
||||||
} |
|
||||||
?> |
|
||||||
</ul> |
|
||||||
<?php endif; ?> |
|
||||||
<div class="form-row place-order"> |
|
||||||
<noscript> |
|
||||||
<?php |
|
||||||
/* translators: $1 and $2 opening and closing emphasis tags respectively */ |
|
||||||
printf( esc_html__( 'Since your browser does not support JavaScript, or it is disabled, please ensure you click the %1$sUpdate Totals%2$s button before placing your order. You may be charged more than the amount stated above if you fail to do so.', 'woocommerce' ), '<em>', '</em>' ); |
|
||||||
?> |
|
||||||
<br/><button type="submit" class="button alt<?php echo esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ? ' ' . wc_wp_theme_get_element_class_name( 'button' ) : '' ); ?>" name="woocommerce_checkout_update_totals" value="<?php esc_attr_e( 'Update totals', 'woocommerce' ); ?>"><?php esc_html_e( 'Update totals', 'woocommerce' ); ?></button>
|
|
||||||
</noscript> |
|
||||||
|
|
||||||
<?php wc_get_template( 'checkout/terms.php' ); ?> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_review_order_before_submit' ); ?> |
|
||||||
|
|
||||||
<?php echo apply_filters( 'woocommerce_order_button_html', '<button type="submit" class="button alt' . esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ? ' ' . wc_wp_theme_get_element_class_name( 'button' ) : '' ) . '" name="woocommerce_checkout_place_order" id="place_order" value="' . esc_attr( $order_button_text ) . '" data-value="' . esc_attr( $order_button_text ) . '">' . esc_html( $order_button_text ) . '</button>' ); // @codingStandardsIgnoreLine ?>
|
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_review_order_after_submit' ); ?> |
|
||||||
|
|
||||||
<?php wp_nonce_field( 'woocommerce-process_checkout', 'woocommerce-process-checkout-nonce' ); ?> |
|
||||||
</div> |
|
||||||
</div> |
|
||||||
<?php |
|
||||||
if ( ! wp_doing_ajax() ) { |
|
||||||
do_action( 'woocommerce_review_order_after_payment' ); |
|
||||||
} |
|
@ -1,43 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Checkout terms and conditions area. |
|
||||||
* |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 3.4.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
|
|
||||||
if ( apply_filters( 'woocommerce_checkout_show_terms', true ) && function_exists( 'wc_terms_and_conditions_checkbox_enabled' ) ) { |
|
||||||
do_action( 'woocommerce_checkout_before_terms_and_conditions' ); |
|
||||||
|
|
||||||
?> |
|
||||||
<div class="woocommerce-terms-and-conditions-wrapper"> |
|
||||||
<?php |
|
||||||
/** |
|
||||||
* Terms and conditions hook used to inject content. |
|
||||||
* |
|
||||||
* @since 3.4.0. |
|
||||||
* @hooked wc_checkout_privacy_policy_text() Shows custom privacy policy text. Priority 20. |
|
||||||
* @hooked wc_terms_and_conditions_page_content() Shows t&c page content. Priority 30. |
|
||||||
*/ |
|
||||||
do_action( 'woocommerce_checkout_terms_and_conditions' ); |
|
||||||
?> |
|
||||||
|
|
||||||
<?php if ( wc_terms_and_conditions_checkbox_enabled() ) : ?> |
|
||||||
|
|
||||||
|
|
||||||
<div class="modal-form-content__line"> |
|
||||||
<div class="form-agreement__check"> |
|
||||||
<input type="checkbox" name="terms" <?php checked( apply_filters( 'woocommerce_terms_is_checked_default', isset( $_POST['terms'] ) ), true ); // WPCS: input var ok, csrf ok. ?> id="terms" class="form-agreement__input">
|
|
||||||
<label for="terms" class="form-agreement__square"> |
|
||||||
</label> |
|
||||||
<label for="terms" class="form-agreement__label"><?php wc_terms_and_conditions_checkbox_text(); ?></label>
|
|
||||||
</div> |
|
||||||
</div> |
|
||||||
<?php endif; ?> |
|
||||||
</div> |
|
||||||
<?php |
|
||||||
|
|
||||||
do_action( 'woocommerce_checkout_after_terms_and_conditions' ); |
|
||||||
} |
|
@ -1,119 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* Login Form |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/myaccount/form-login.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 9.7.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
if ( ! defined( 'ABSPATH' ) ) { |
|
||||||
exit; // Exit if accessed directly. |
|
||||||
} |
|
||||||
|
|
||||||
do_action( 'woocommerce_before_customer_login_form' ); ?> |
|
||||||
|
|
||||||
<?php if ( 'yes' === get_option( 'woocommerce_enable_myaccount_registration' ) ) : ?> |
|
||||||
|
|
||||||
<div class="u-columns col2-set" id="customer_login"> |
|
||||||
|
|
||||||
<div class="u-column1 col-1"> |
|
||||||
|
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<h2><?php esc_html_e( 'Login', 'woocommerce' ); ?></h2>
|
|
||||||
|
|
||||||
<form class="woocommerce-form woocommerce-form-login login" method="post" novalidate> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_login_form_start' ); ?> |
|
||||||
|
|
||||||
<p class="woocommerce-form-row woocommerce-form-row--wide form-row form-row-wide"> |
|
||||||
<label for="username"><?php esc_html_e( 'Username or email address', 'woocommerce' ); ?> <span class="required" aria-hidden="true">*</span><span class="screen-reader-text"><?php esc_html_e( 'Required', 'woocommerce' ); ?></span></label>
|
|
||||||
<input type="text" class="woocommerce-Input woocommerce-Input--text input-text" name="username" id="username" autocomplete="username" value="<?php echo ( ! empty( $_POST['username'] ) ) ? esc_attr( wp_unslash( $_POST['username'] ) ) : ''; ?>" required aria-required="true" /><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
</p> |
|
||||||
<p class="woocommerce-form-row woocommerce-form-row--wide form-row form-row-wide"> |
|
||||||
<label for="password"><?php esc_html_e( 'Password', 'woocommerce' ); ?> <span class="required" aria-hidden="true">*</span><span class="screen-reader-text"><?php esc_html_e( 'Required', 'woocommerce' ); ?></span></label>
|
|
||||||
<input class="woocommerce-Input woocommerce-Input--text input-text" type="password" name="password" id="password" autocomplete="current-password" required aria-required="true" /> |
|
||||||
</p> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_login_form' ); ?> |
|
||||||
|
|
||||||
<p class="form-row"> |
|
||||||
<label class="woocommerce-form__label woocommerce-form__label-for-checkbox woocommerce-form-login__rememberme"> |
|
||||||
<input class="woocommerce-form__input woocommerce-form__input-checkbox" name="rememberme" type="checkbox" id="rememberme" value="forever" /> <span><?php esc_html_e( 'Remember me', 'woocommerce' ); ?></span>
|
|
||||||
</label> |
|
||||||
<?php wp_nonce_field( 'woocommerce-login', 'woocommerce-login-nonce' ); ?> |
|
||||||
<button type="submit" class="woocommerce-button button woocommerce-form-login__submit<?php echo esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ? ' ' . wc_wp_theme_get_element_class_name( 'button' ) : '' ); ?>" name="login" value="<?php esc_attr_e( 'Log in', 'woocommerce' ); ?>"><?php esc_html_e( 'Log in', 'woocommerce' ); ?></button>
|
|
||||||
</p> |
|
||||||
<p class="woocommerce-LostPassword lost_password"> |
|
||||||
<a href="<?php echo esc_url( wp_lostpassword_url() ); ?>"><?php esc_html_e( 'Lost your password?', 'woocommerce' ); ?></a>
|
|
||||||
</p> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_login_form_end' ); ?> |
|
||||||
|
|
||||||
</form> |
|
||||||
|
|
||||||
<?php if ( 'yes' === get_option( 'woocommerce_enable_myaccount_registration' ) ) : ?> |
|
||||||
|
|
||||||
</div> |
|
||||||
|
|
||||||
<div class="u-column2 col-2"> |
|
||||||
|
|
||||||
<h2><?php esc_html_e( 'Register', 'woocommerce' ); ?></h2>
|
|
||||||
|
|
||||||
<form method="post" class="woocommerce-form woocommerce-form-register register" <?php do_action( 'woocommerce_register_form_tag' ); ?> >
|
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_register_form_start' ); ?> |
|
||||||
|
|
||||||
<?php if ( 'no' === get_option( 'woocommerce_registration_generate_username' ) ) : ?> |
|
||||||
|
|
||||||
<p class="woocommerce-form-row woocommerce-form-row--wide form-row form-row-wide"> |
|
||||||
<label for="reg_username"><?php esc_html_e( 'Username', 'woocommerce' ); ?> <span class="required" aria-hidden="true">*</span><span class="screen-reader-text"><?php esc_html_e( 'Required', 'woocommerce' ); ?></span></label>
|
|
||||||
<input type="text" class="woocommerce-Input woocommerce-Input--text input-text" name="username" id="reg_username" autocomplete="username" value="<?php echo ( ! empty( $_POST['username'] ) ) ? esc_attr( wp_unslash( $_POST['username'] ) ) : ''; ?>" required aria-required="true" /><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
</p> |
|
||||||
|
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<p class="woocommerce-form-row woocommerce-form-row--wide form-row form-row-wide"> |
|
||||||
<label for="reg_email"><?php esc_html_e( 'Email address', 'woocommerce' ); ?> <span class="required" aria-hidden="true">*</span><span class="screen-reader-text"><?php esc_html_e( 'Required', 'woocommerce' ); ?></span></label>
|
|
||||||
<input type="email" class="woocommerce-Input woocommerce-Input--text input-text" name="email" id="reg_email" autocomplete="email" value="<?php echo ( ! empty( $_POST['email'] ) ) ? esc_attr( wp_unslash( $_POST['email'] ) ) : ''; ?>" required aria-required="true" /><?php // @codingStandardsIgnoreLine ?>
|
|
||||||
</p> |
|
||||||
|
|
||||||
<?php if ( 'no' === get_option( 'woocommerce_registration_generate_password' ) ) : ?> |
|
||||||
|
|
||||||
<p class="woocommerce-form-row woocommerce-form-row--wide form-row form-row-wide"> |
|
||||||
<label for="reg_password"><?php esc_html_e( 'Password', 'woocommerce' ); ?> <span class="required" aria-hidden="true">*</span><span class="screen-reader-text"><?php esc_html_e( 'Required', 'woocommerce' ); ?></span></label>
|
|
||||||
<input type="password" class="woocommerce-Input woocommerce-Input--text input-text" name="password" id="reg_password" autocomplete="new-password" required aria-required="true" /> |
|
||||||
</p> |
|
||||||
|
|
||||||
<?php else : ?> |
|
||||||
|
|
||||||
<p><?php esc_html_e( 'A link to set a new password will be sent to your email address.', 'woocommerce' ); ?></p>
|
|
||||||
|
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_register_form' ); ?> |
|
||||||
|
|
||||||
<p class="woocommerce-form-row form-row"> |
|
||||||
<?php wp_nonce_field( 'woocommerce-register', 'woocommerce-register-nonce' ); ?> |
|
||||||
<button type="submit" class="woocommerce-Button woocommerce-button button<?php echo esc_attr( wc_wp_theme_get_element_class_name( 'button' ) ? ' ' . wc_wp_theme_get_element_class_name( 'button' ) : '' ); ?> woocommerce-form-register__submit" name="register" value="<?php esc_attr_e( 'Register', 'woocommerce' ); ?>"><?php esc_html_e( 'Register', 'woocommerce' ); ?></button>
|
|
||||||
</p> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_register_form_end' ); ?> |
|
||||||
|
|
||||||
</form> |
|
||||||
|
|
||||||
</div> |
|
||||||
|
|
||||||
</div> |
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<?php do_action( 'woocommerce_after_customer_login_form' ); ?> |
|
@ -1,93 +0,0 @@ |
|||||||
<?php |
|
||||||
/** |
|
||||||
* My Addresses |
|
||||||
* |
|
||||||
* This template can be overridden by copying it to yourtheme/woocommerce/myaccount/my-address.php. |
|
||||||
* |
|
||||||
* HOWEVER, on occasion WooCommerce will need to update template files and you |
|
||||||
* (the theme developer) will need to copy the new files to your theme to |
|
||||||
* maintain compatibility. We try to do this as little as possible, but it does |
|
||||||
* happen. When this occurs the version of the template file will be bumped and |
|
||||||
* the readme will list any important changes. |
|
||||||
* |
|
||||||
* @see https://woocommerce.com/document/template-structure/ |
|
||||||
* @package WooCommerce\Templates |
|
||||||
* @version 9.3.0 |
|
||||||
*/ |
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit; |
|
||||||
|
|
||||||
$customer_id = get_current_user_id(); |
|
||||||
|
|
||||||
if ( ! wc_ship_to_billing_address_only() && wc_shipping_enabled() ) { |
|
||||||
$get_addresses = apply_filters( |
|
||||||
'woocommerce_my_account_get_addresses', |
|
||||||
array( |
|
||||||
'billing' => __( 'Billing address', 'woocommerce' ), |
|
||||||
'shipping' => __( 'Shipping address', 'woocommerce' ), |
|
||||||
), |
|
||||||
$customer_id |
|
||||||
); |
|
||||||
} else { |
|
||||||
$get_addresses = apply_filters( |
|
||||||
'woocommerce_my_account_get_addresses', |
|
||||||
array( |
|
||||||
'billing' => __( 'Billing address', 'woocommerce' ), |
|
||||||
), |
|
||||||
$customer_id |
|
||||||
); |
|
||||||
} |
|
||||||
|
|
||||||
$oldcol = 1; |
|
||||||
$col = 1; |
|
||||||
?> |
|
||||||
|
|
||||||
<p> |
|
||||||
<?php echo apply_filters( 'woocommerce_my_account_my_address_description', esc_html__( 'The following addresses will be used on the checkout page by default.', 'woocommerce' ) ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
|
||||||
</p> |
|
||||||
|
|
||||||
<?php if ( ! wc_ship_to_billing_address_only() && wc_shipping_enabled() ) : ?> |
|
||||||
<div class="u-columns woocommerce-Addresses col2-set addresses"> |
|
||||||
<?php endif; ?> |
|
||||||
|
|
||||||
<?php foreach ( $get_addresses as $name => $address_title ) : ?> |
|
||||||
<?php |
|
||||||
$address = wc_get_account_formatted_address( $name ); |
|
||||||
$col = $col * -1; |
|
||||||
$oldcol = $oldcol * -1; |
|
||||||
?> |
|
||||||
|
|
||||||
<div class="u-column<?php echo $col < 0 ? 1 : 2; ?> col-<?php echo $oldcol < 0 ? 1 : 2; ?> woocommerce-Address">
|
|
||||||
<header class="woocommerce-Address-title title"> |
|
||||||
<h2><?php echo esc_html( $address_title ); ?></h2>
|
|
||||||
<a href="<?php echo esc_url( wc_get_endpoint_url( 'edit-address', $name ) ); ?>" class="edit">
|
|
||||||
<?php |
|
||||||
printf( |
|
||||||
/* translators: %s: Address title */ |
|
||||||
$address ? esc_html__( 'Edit %s', 'woocommerce' ) : esc_html__( 'Add %s', 'woocommerce' ), |
|
||||||
esc_html( $address_title ) |
|
||||||
); |
|
||||||
?> |
|
||||||
</a> |
|
||||||
</header> |
|
||||||
<address> |
|
||||||
<?php |
|
||||||
echo $address ? wp_kses_post( $address ) : esc_html_e( 'You have not set up this type of address yet.', 'woocommerce' ); |
|
||||||
|
|
||||||
/** |
|
||||||
* Used to output content after core address fields. |
|
||||||
* |
|
||||||
* @param string $name Address type. |
|
||||||
* @since 8.7.0 |
|
||||||
*/ |
|
||||||
do_action( 'woocommerce_my_account_after_my_address', $name ); |
|
||||||
?> |
|
||||||
</address> |
|
||||||
</div> |
|
||||||
|
|
||||||
<?php endforeach; ?> |
|
||||||
|
|
||||||
<?php if ( ! wc_ship_to_billing_address_only() && wc_shipping_enabled() ) : ?> |
|
||||||
</div> |
|
||||||
<?php |
|
||||||
endif; |
|
Loading…
Reference in new issue