From 4411f0bd017258c61393d306c10a279917720b5f Mon Sep 17 00:00:00 2001 From: maksim Date: Thu, 19 Jun 2025 11:38:24 +0300 Subject: [PATCH] =?UTF-8?q?task=206809=20|=20=D1=83=D0=B4=D0=B0=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D1=8B=20=D0=BB=D0=B8=D1=88=D0=BD=D0=B8=D0=B5=20?= =?UTF-8?q?=D1=84=D0=B0=D0=B9=D0=BB=D1=8B=20WC=20(=D0=BE=D1=81=D1=82=D0=B0?= =?UTF-8?q?=D0=BB=D0=B8=D1=81=D1=8C=20=D1=87=D0=B0=D1=81=D1=82=D0=B8=20?= =?UTF-8?q?=D1=88=D0=B0=D0=B1=D0=BB=D0=BE=D0=BD=D0=BE=D0=B2=20=D0=B2=20php?= =?UTF-8?q?=20=D1=84=D0=B0=D0=B9=D0=BB=D0=B0=D1=85=20woocommerce=20(=D0=B2?= =?UTF-8?q?=20=D0=BE=D1=81=D0=BD=D0=BE=D0=B2=D0=BD=D0=BE=D0=BC=20=D0=BA?= =?UTF-8?q?=D0=B0=D1=81=D1=82=D0=BE=D0=BC=D0=B8=D0=B7=D0=B8=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B0=D0=BD=D0=BD=D1=8B=D0=B5=20=D0=B1=D0=BB=D0=BE=D0=BA?= =?UTF-8?q?=D0=B8=20=D0=B4=D0=BB=D1=8F=20=D0=B4=D0=BE=D1=81=D1=82=D0=B0?= =?UTF-8?q?=D0=B2=D0=BA=D0=B8=20-=20=D0=B7=D0=B0=D0=B2=D0=B5=D0=BB=20?= =?UTF-8?q?=D0=BF=D0=BE=D0=B4=D0=B7=D0=B0=D0=B4=D0=B0=D1=87=D1=83=20=D0=BD?= =?UTF-8?q?=D0=B0=20=D0=BF=D0=B5=D1=80=D0=B5=D0=BD=D0=BE=D1=81=20=D1=88?= =?UTF-8?q?=D0=B0=D0=B1=D0=BB=D0=BE=D0=BD=D0=BE=D0=B2=20=D0=B2=20twig=20?= =?UTF-8?q?=D0=B2=20=D0=B1=D0=B5=D0=BA=D0=BB=D0=BE=D0=B3)=20)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../cosmopet/templates/form-coupon.twig | 38 ++++++ .../woocommerce/checkout/cart-errors.php | 25 ---- .../woocommerce/checkout/form-billing.php | 56 --------- .../woocommerce/checkout/form-login.php | 36 ------ .../woocommerce/checkout/form-pay.php | 109 ---------------- .../checkout/form-verify-email.php | 53 -------- .../woocommerce/checkout/order-received.php | 42 ------- .../woocommerce/checkout/payment-method.php | 33 ----- .../cosmopet/woocommerce/checkout/payment.php | 63 ---------- .../cosmopet/woocommerce/checkout/terms.php | 43 ------- .../woocommerce/myaccount/form-login.php | 119 ------------------ .../woocommerce/myaccount/my-address.php | 93 -------------- .../myaccount/my-subscriptions.php | 0 13 files changed, 38 insertions(+), 672 deletions(-) create mode 100644 wp-content/themes/cosmopet/templates/form-coupon.twig delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/cart-errors.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/form-billing.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/form-login.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/form-pay.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/form-verify-email.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/order-received.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/payment-method.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/payment.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/checkout/terms.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/myaccount/form-login.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/myaccount/my-address.php delete mode 100644 wp-content/themes/cosmopet/woocommerce/myaccount/my-subscriptions.php diff --git a/wp-content/themes/cosmopet/templates/form-coupon.twig b/wp-content/themes/cosmopet/templates/form-coupon.twig new file mode 100644 index 0000000..b287952 --- /dev/null +++ b/wp-content/themes/cosmopet/templates/form-coupon.twig @@ -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) : '' %} + +
+ + + + Ошибка! Промокод введен неверно или не существует. + +
+ +
+ + +
+ +{% endif %} diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/cart-errors.php b/wp-content/themes/cosmopet/woocommerce/checkout/cart-errors.php deleted file mode 100644 index 56c989d..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/cart-errors.php +++ /dev/null @@ -1,25 +0,0 @@ - - -

- - - -

diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/form-billing.php b/wp-content/themes/cosmopet/woocommerce/checkout/form-billing.php deleted file mode 100644 index dbeeb55..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/form-billing.php +++ /dev/null @@ -1,56 +0,0 @@ - -
- cart->needs_shipping() ) : ?> - -

- - - -

- - - - - -
- get_checkout_fields( 'billing' ); - - foreach ( $fields as $key => $field ) { - woocommerce_form_field( $key, $field, $checkout->get_value( $key ) ); - } - ?> -
- - -
- -is_registration_enabled() ) : ?> - - diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/form-login.php b/wp-content/themes/cosmopet/woocommerce/checkout/form-login.php deleted file mode 100644 index f9b9c40..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/form-login.php +++ /dev/null @@ -1,36 +0,0 @@ - -
- ' . esc_html__( 'Click here to login', 'woocommerce' ) . '', 'notice' ); ?> -
- 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, - ) -); diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/form-pay.php b/wp-content/themes/cosmopet/woocommerce/checkout/form-pay.php deleted file mode 100644 index 59d9b34..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/form-pay.php +++ /dev/null @@ -1,109 +0,0 @@ -get_order_item_totals(); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited -?> -
- - - - - - - - - - - get_items() ) > 0 ) : ?> - get_items() as $item_id => $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 ); - ?> - ' . sprintf( '× %s', esc_html( $item->get_quantity() ) ) . '', $item ); ?>get_formatted_line_subtotal( $item ); ?>
- - - -
- needs_payment() ) : ?> -
    - $gateway ) ); - } - } else { - echo '
  • '; - 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 '
  • '; - } - ?> -
- -
- - - - - - - ' . esc_html( $order_button_text ) . '' ); // @codingStandardsIgnoreLine ?> - - - - -
-
-
diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/form-verify-email.php b/wp-content/themes/cosmopet/woocommerce/checkout/form-verify-email.php deleted file mode 100644 index fd86a4d..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/form-verify-email.php +++ /dev/null @@ -1,53 +0,0 @@ - -
- - -

- ', - '' - ); - ?> -

- -

- - -

- -

- -

-
diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/order-received.php b/wp-content/themes/cosmopet/woocommerce/checkout/order-received.php deleted file mode 100644 index 37a7fa4..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/order-received.php +++ /dev/null @@ -1,42 +0,0 @@ - - -

- -

diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/payment-method.php b/wp-content/themes/cosmopet/woocommerce/checkout/payment-method.php deleted file mode 100644 index 05308d8..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/payment-method.php +++ /dev/null @@ -1,33 +0,0 @@ - -
  • - chosen, true ); ?> data-order_button_text="order_button_text ); ?>" /> - - - has_fields() || $gateway->get_description() ) : ?> -
    chosen ) : /* phpcs:ignore Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace */ ?>style="display:none;"> - payment_fields(); ?> -
    - -
  • diff --git a/wp-content/themes/cosmopet/woocommerce/checkout/payment.php b/wp-content/themes/cosmopet/woocommerce/checkout/payment.php deleted file mode 100644 index 3b68df7..0000000 --- a/wp-content/themes/cosmopet/woocommerce/checkout/payment.php +++ /dev/null @@ -1,63 +0,0 @@ - -
    - cart->needs_payment() ) : ?> - - -
    - - - - - - - ' . esc_html( $order_button_text ) . '' ); // @codingStandardsIgnoreLine ?> - - - - -
    -
    - -
    - - - - - - - -
    - - - - -
    - -
    - - - -

    - - - - - -
    - -
    - -

    - -
    > - - - - - -

    - - -

    - - - -

    - - -

    - - - -

    - - -

    - - - -

    - - - - - -

    - - -

    - - - -
    - -
    - -
    - - - diff --git a/wp-content/themes/cosmopet/woocommerce/myaccount/my-address.php b/wp-content/themes/cosmopet/woocommerce/myaccount/my-address.php deleted file mode 100644 index 5bd5a97..0000000 --- a/wp-content/themes/cosmopet/woocommerce/myaccount/my-address.php +++ /dev/null @@ -1,93 +0,0 @@ - __( '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; -?> - -

    - -

    - - -
    - - - $address_title ) : ?> - - -
    -
    -

    - - - -
    -
    - -
    -
    - - - - -
    -