PluginProbe
ShopBuilder – WooCommerce Builder For Elementor / 2.1.3
ShopBuilder – WooCommerce Builder For Elementor v2.1.3
3.4.2 3.4.1 3.4.0 2.0.1 2.0.2 2.0.3 2.1.0 2.1.1 2.1.10 2.1.11 2.1.12 2.1.13 2.1.14 2.1.15 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.1.9 2.2.0 2.2.1 2.2.2 All 63 releases
← All changes | app/Controllers/BuilderController.php +16 -35 2.1.92.1.3 View file →
@@ -107,24 +107,20 @@
107 107 *
108 108 * @return void
109 109 */
110 110 public function add_elementor_widget_categories( $elements_manager ) {
111 - $categories = [];
112 - $type = BuilderFns::builder_type( get_the_ID() );
113 - if ( $type ) {
114 - $builder_type = ! empty( BuilderFns::builder_page_types()[ $type ] ) ? BuilderFns::builder_page_types()[ $type ] : '';
115 - $builder_type = str_replace( 'My Account - ', '', $builder_type );
116 - $categories['rtsb-shopbuilder'] = [
117 - 'title' => esc_html__( 'ShopBuilder', 'shopbuilder' ) . ' - ' . ucfirst( $builder_type ),
118 - 'icon' => 'fa fa-plug',
119 - ];
120 - }
121 - if ( 'quick-view' !== $type ) {
122 - $categories['rtsb-shopbuilder-general'] = [
123 - 'title' => esc_html__( 'Shopbuilder - General', 'shopbuilder' ),
124 - 'icon' => 'fa fa-plug',
125 - ];
126 - }
111 + $type = BuilderFns::builder_type( get_the_ID() );
112 + $builder_type = ! empty( BuilderFns::builder_page_types()[ $type ] ) ? BuilderFns::builder_page_types()[ $type ] : '';
113 + $builder_type = str_replace( 'My Account - ', '', $builder_type );
114 + $categories['rtsb-shopbuilder'] = [
115 + 'title' => esc_html__( 'ShopBuilder', 'shopbuilder' ) . ' - ' . ucfirst( $builder_type ),
116 + 'icon' => 'fa fa-plug',
117 + ];
118 + $categories['rtsb-shopbuilder-general'] = [
119 + 'title' => esc_html__( 'Shopbuilder - General', 'shopbuilder' ),
120 + 'icon' => 'fa fa-plug',
121 + ];
122 +
127 123 $categories = apply_filters( 'rtsb_elementor_widgets_category_lists', $categories );
128 124 $other_categories = $elements_manager->get_categories();
129 125 $categories = array_merge(
130 126 array_slice( $other_categories, 0, 1 ),
@@ -293,18 +289,8 @@
293 289
294 290 if ( BuilderFns::is_product() ) {
295 291 $product_id = Fns::get_prepared_product_id();
296 292 $parent_class = wc_get_product_class( $parent_class, $product_id );
297 - if ( function_exists( 'rtwpvs' ) ) {
298 - $_product = Fns::get_product();
299 - if ( $_product->is_type( 'variable' ) ) {
300 - $parent_class[] = 'rtwpvs-product';
301 - $beside_label = function_exists( 'rtwpvsp' ) && rtwpvs()->get_option( 'attribute_on_click_behavior' );
302 - if ( $beside_label ) {
303 - $parent_class[] = 'rtwpvs-selected-term-beside-label';
304 - }
305 - }
306 - }
307 293 }
308 294
309 295 if ( BuilderFns::is_shop() ) {
310 296 $parent_class[] = 'shop';
@@ -368,15 +354,14 @@
368 354 *
369 355 * @return void
370 356 */
371 357 public function select2_ajax_posts_filter_autocomplete() {
372 - if ( ! wp_verify_nonce( Fns::get_nonce(), rtsb()->nonceText ) ) {
373 - wp_send_json_error( [] );
374 - }
358 +
375 359 $query_per_page = 15;
376 360 $post_type = 'post';
377 361 $source_name = 'post_type';
378 - $paged = absint( $_POST['page'] ?? 1 );
362 + $paged = $_POST['page'] ?? 1;
363 +
379 364 if ( ! empty( $_POST['post_type'] ) ) {
380 365 $post_type = sanitize_text_field( $_POST['post_type'] );
381 366 }
382 367
@@ -444,12 +429,8 @@
444 429 * @return void
445 430 */
446 431 public function select2_ajax_get_posts_value_titles() {
447 432
448 - if ( ! wp_verify_nonce( Fns::get_nonce(), rtsb()->nonceText ) ) {
449 - wp_send_json_error( [] );
450 - }
451 -
452 433 if ( empty( $_POST['id'] ) ) {
453 434 wp_send_json_error( [] );
454 435 }
455 436
@@ -548,9 +529,9 @@
548 529 $where .= $wpdb->prepare( " AND {$wpdb->posts}.post_title LIKE %s", '%' . esc_sql( $search ) . '%' );
549 530 }
550 531
551 532 $query = "select post_title,ID from $wpdb->posts where post_status = 'publish' {$where} {$limit}";
552 - $results = $wpdb->get_results( $query ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.NoCaching
533 + $results = $wpdb->get_results( $query );
553 534
554 535 if ( ! empty( $results ) ) {
555 536 foreach ( $results as $row ) {
556 537 $data[ $row->ID ] = $row->post_title . ' [#' . $row->ID . ']';