rtsb_name = esc_html__( 'Cart Table', 'shopbuilder' ); $this->rtsb_base = 'rtsb-product-carttable'; parent::__construct( $data, $args ); } /** * Widget Field * * @return array */ public function widget_fields() { return CartTableSettings::widget_fields( $this ); } /** * Set Widget Keyword. * * @return array */ public function get_keywords() { return [ 'Cart' ] + parent::get_keywords(); } /** * Set Widget Keyword. * * @return array */ public function cart_empty_message() { $controllers = $this->get_settings_for_display(); return $controllers['cart_empty_message']; } /** * Set Widget Keyword. * * @return array */ public function return_to_shop_text() { $controllers = $this->get_settings_for_display(); return $controllers['return_to_shop_text']; } /** * Set Widget Keyword. * * @return array */ public function before_quantity_input_field() { global $product; $is_visible_qty = Fns::is_visible_qty_input( $product ); $controllers = $this->get_settings_for_display(); $inner_border = ! empty( $controllers['show_inner_border'] ) ? 'show-inner-border' : ''; ?>
get_settings_for_display(); if ( in_array( $controllers['quantity_style'], [ 'style-1', 'style-2' ] ) && $is_visible_qty ) { ?>
get_settings_for_display(); $this->apply_the_hooks(); do_action( 'rtsb/before/product/cart/table', $controllers, $this ); $this->theme_support(); $data = [ 'template' => 'elementor/cart/cart-table', 'controllers' => $controllers, 'is_builder' => $this->is_builder_mode(), ]; if ( $data['is_builder'] ) { wc_load_cart(); } if ( ! empty( $controllers['cart_empty_message'] ) ) { add_filter( 'wc_empty_cart_message', [ $this, 'cart_empty_message' ] ); } if ( ! empty( $controllers['return_to_shop_text'] ) ) { add_filter( 'woocommerce_return_to_shop_text', [ $this, 'return_to_shop_text' ] ); } // Check cart items are valid. do_action( 'woocommerce_check_cart_items' ); WC()->cart->calculate_totals(); Fns::load_template( $data['template'], $data ); do_action( 'rtsb/after/product/cart/table', $controllers, $this ); $this->theme_support( 'render_reset' ); } }