PluginProbe
Visualizer – Tables & Charts Manager with Built-in AI Generator / 3.7.9
Visualizer – Tables & Charts Manager with Built-in AI Generator v3.7.9
4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 3.0.5 3.0.6 3.0.7 3.0.8 3.0.9 3.1.0 3.1.1 3.1.2 3.1.3 3.10.0 3.10.1 3.10.10 3.10.11 3.10.12 3.10.13 3.10.14 3.10.15 3.10.2 3.10.3 3.10.4 All 148 releases
← All changes | classes/Visualizer/Module/Sources.php +6 -15 4.0.63.7.9 View file →
@@ -52,9 +52,9 @@
52 52 public function __construct( Visualizer_Plugin $plugin ) {
53 53 parent::__construct( $plugin );
54 54 $this->_addFilter( Visualizer_Plugin::FILTER_GET_CHART_SERIES, 'filterChartSeries', 1, 2 );
55 55 $this->_addFilter( Visualizer_Plugin::FILTER_GET_CHART_DATA, 'filterChartData', 1, 2 );
56 - $this->_addFilter( 'visualizer_pro_upsell', 'addProUpsell', 10, 3 );
56 + $this->_addFilter( 'visualizer_pro_upsell', 'addProUpsell', 10, 2 );
57 57 }
58 58
59 59 /**
60 60 * Filters chart sereis.
@@ -128,9 +128,9 @@
128 128 * @param string $feature What feature is this filter running for.
129 129 *
130 130 * @return string The new html code.
131 131 */
132 - public function addProUpsell( $old, $feature = null, string $docs_url = '' ) {
132 + public function addProUpsell( $old, $feature = null ) {
133 133 $pro_features = Visualizer_Module::get_features_for_license( 1 );
134 134 $biz_features = Visualizer_Module::get_features_for_license( 2 );
135 135 $return = '';
136 136 $feature = strval( $feature );
@@ -137,27 +137,17 @@
137 137 if ( empty( $feature ) ||
138 138 ( in_array( $feature, $biz_features, true ) && ! apply_filters( 'visualizer_is_business', false ) ) ||
139 139 ( in_array( $feature, $pro_features, true ) && ! Visualizer_Module::is_pro() )
140 140 ) {
141 - // translators: $s - the name of the plan (PRO).
142 141 $msg = sprintf( __( 'Upgrade to %s to activate this feature!', 'visualizer' ), 'PRO' );
143 - // translators: $s - the name of the plan (Plus).
144 - $plus_msg = sprintf( __( 'Upgrade to %s plan to activate this feature!', 'visualizer' ), 'Plus' );
145 - if ( in_array( $feature, $biz_features, true ) && Visualizer_Module::is_pro() ) {
146 - $msg = $plus_msg;
142 + if ( Visualizer_Module::is_pro() && in_array( $feature, $biz_features, true ) ) {
143 + $msg = sprintf( __( 'Upgrade your license to at least the %s version to activate this feature!', 'visualizer' ), 'DEVELOPER' );
147 144 }
148 - if ( in_array( $feature, array( 'db-query', 'chart-permissions' ), true ) ) {
149 - $msg = $plus_msg;
150 - }
151 -
152 145 $return = '<div class="only-pro-content">';
153 146 $return .= ' <div class="only-pro-container">';
154 147 $return .= ' <div class="only-pro-inner">';
155 148 $return .= ' <p>' . $msg . '</p>';
156 - if ( ! empty( $docs_url ) ) {
157 - $return .= ' <a target="_blank" href="' . esc_url( $docs_url ) . '" class="button button-secondary">' . esc_html__( 'Documentation', 'visualizer' ) . '</a>';
158 - }
159 - $return .= ' <a target="_blank" href="' . tsdk_utmify( Visualizer_Plugin::PRO_TEASER_URL, esc_attr( $feature ) ) . '" title="' . __( 'Upgrade Now', 'visualizer' ) . '" class="button button-primary">' . __( 'Upgrade Now', 'visualizer' ) . '</a>';
149 + $return .= ' <a target="_blank" href="' . Visualizer_Plugin::PRO_TEASER_URL . '" title="' . __( 'Buy now', 'visualizer' ) . '">' . __( 'Buy now', 'visualizer' ) . '</a>';
160 150 $return .= ' </div>';
161 151 $return .= ' </div>';
162 152 $return .= '</div>';
163 153 }
@@ -167,5 +157,6 @@
167 157 }
168 158
169 159 return $return;
170 160 }
161 +
171 162 }