PluginProbe
Better Payment – Instant Payments, Donations, Fundraising with Subscriptions & More / 2.4.1
Better Payment – Instant Payments, Donations, Fundraising with Subscriptions & More v2.4.1
2.4.1 2.4.0 2.3.4 2.3.3 2.3.2 2.3.1 2.3.0 2.2.2 2.2.1 2.2.0 2.1.2 2.1.1 trunk 0.0.1 0.0.2 0.0.3 0.0.4 0.0.5 0.0.6 0.0.7 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 All 68 releases
← All changes | includes/Admin/Elementor/User_Dashboard.php +2 -24 2.3.1 → 2.4.1 View file →
@@ -1518,13 +1518,8 @@
1518 1518 'restUrl' => get_rest_url( null, 'better-payment/v1/user-transactions' ),
1519 1519 ] );
1520 1520 wp_enqueue_script( 'bp-dashboard-pagination' );
1521 1521
1522 - if( $this->pro_enabled ){
1523 - wp_enqueue_script( 'better-payment-common-script' );
1524 - wp_enqueue_style( 'better-payment-common-style' );
1525 - }
1526 -
1527 1522 $action = esc_url( admin_url( 'admin-post.php' ) );
1528 1523 $setting_meta = wp_json_encode( [
1529 1524 'page_id' => get_the_ID(),
1530 1525 'widget_id' => esc_attr( $this->get_id() ),
@@ -1546,18 +1541,11 @@
1546 1541 $extraDatas = $data;
1547 1542
1548 1543 $better_payment_form_layout = sanitize_text_field($settings[ 'better_payment_user_dashboard_layout' ]);
1549 1544
1545 + // There are no Pro dashboard layouts; Pro extends this widget through the
1546 + // `better_payment/widget/user-dashboard/*` actions instead.
1550 1547 $template_file = BETTER_PAYMENT_ADMIN_VIEWS_PATH . '/elementor/user-dashboard/' . $better_payment_form_layout . '.php';
1551 - $is_pro_layout = false !== strpos( $better_payment_form_layout, '-pro' );
1552 -
1553 - if ( $this->pro_enabled && $is_pro_layout ){
1554 - $template_file = BETTER_PAYMENT_PRO_ADMIN_VIEWS_PATH . '/elementor/layouts/' . $better_payment_form_layout . '.php';
1555 - }
1556 -
1557 - if ( ( ! $this->pro_enabled ) && $is_pro_layout ){
1558 - $template_file = BETTER_PAYMENT_ADMIN_VIEWS_PATH . '/partials/layout-pro-banners.php';
1559 - }
1560 1548
1561 1549 if( $better_payment_form_layout !== 'layout-1' ){
1562 1550 $template_file = $this->get_template( $better_payment_form_layout );
1563 1551 }
@@ -1581,18 +1569,8 @@
1581 1569 'layout-1' => 'Layout 1',
1582 1570 // 'layout-2' => 'Layout 2',
1583 1571 // 'layout-3' => 'Layout 3'
1584 1572 ]);
1585 -
1586 - if ( ! $this->pro_enabled ) {
1587 - $pro_banners = [
1588 - // 'layout-4-pro' => 'Layout 4 (Pro)',
1589 - // 'layout-5-pro' => 'Layout 5 (Pro)',
1590 - // 'layout-6-pro' => 'Layout 6 (Pro)',
1591 - ];
1592 -
1593 - $layouts = array_merge( $layouts, $pro_banners );
1594 - }
1595 1573
1596 1574 return $layouts;
1597 1575 }
1598 1576