Skip to content

Commit 2aaa95e

Browse files
authored
Merge pull request #156 from contactashish13/#54
test new version #54
2 parents 7615571 + 03f9e65 commit 2aaa95e

File tree

5 files changed

+34
-27
lines changed

5 files changed

+34
-27
lines changed

classes/Visualizer/Module/Admin.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,10 @@ public static function _getChartTypesLocalized( $enabledOnly = false, $get2Darra
212212
if ( $enabledOnly ) {
213213
$filtered = array();
214214
foreach ( $types as $type => $array ) {
215+
if ( ! is_array( $array ) ) {
216+
// support for old pro
217+
$array = array( 'enabled' => true, 'name' => $array );
218+
}
215219
if ( ! $array['enabled'] ) {
216220
continue;
217221
}
@@ -222,6 +226,10 @@ public static function _getChartTypesLocalized( $enabledOnly = false, $get2Darra
222226
if ( $get2Darray ) {
223227
$doubleD = array();
224228
foreach ( $types as $type => $array ) {
229+
if ( ! is_array( $array ) ) {
230+
// support for old pro
231+
$array = array( 'enabled' => true, 'name' => $array );
232+
}
225233
$doubleD[ $type ] = $array['name'];
226234
}
227235
$types = $doubleD;

classes/Visualizer/Module/Chart.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ public function uploadData() {
401401
$source = new Visualizer_Source_Csv( $_FILES['local_data']['tmp_name'] );
402402
// Added by Ash/Upwork
403403
} elseif ( isset( $_POST['chart_data'] ) && strlen( $_POST['chart_data'] ) > 0 ) {
404-
$source = apply_filters( 'visualizer_pro_handle_chart_data', '', $_POST['chart_data'] );
404+
$source = apply_filters( 'visualizer_pro_handle_chart_data', $_POST['chart_data'], '' );
405405
// Added by Ash/Upwork
406406
} else {
407407
$render->message = esc_html__( 'CSV file with chart data was not uploaded. Please, try again.', 'visualizer' );

classes/Visualizer/Render/Library.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ private function _renderLibrary() {
8181
echo '<div id="visualizer-types" class="visualizer-clearfix">';
8282
echo '<ul class="subsubsub">';
8383
foreach ( $this->types as $type => $array ) {
84+
if ( ! is_array( $array ) ) {
85+
// support for old pro
86+
$array = array( 'enabled' => true, 'name' => $array );
87+
}
8488
$label = $array['name'];
8589
$link = '<a class=" " href="' . esc_url( add_query_arg( array(
8690
'type' => $type,

css/frame.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -933,6 +933,7 @@ button#editor-chart-button {
933933
.only-pro-feature button,
934934
.only-pro-feature select {
935935
cursor: not-allowed !important;
936+
pointer-events: none;
936937
}
937938

938939
.only-pro-feature > div {

languages/visualizer.pot

Lines changed: 20 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ msgid ""
44
msgstr ""
55
"Project-Id-Version: Visualizer: Charts and Graphs Lite 2.0.0\n"
66
"Report-Msgid-Bugs-To: https://github.com/Codeinwp/visualizer/issues\n"
7-
"POT-Creation-Date: 2017-04-11 13:25:03+00:00\n"
7+
"POT-Creation-Date: 2017-04-12 10:19:50+00:00\n"
88
"MIME-Version: 1.0\n"
99
"Content-Type: text/plain; charset=utf-8\n"
1010
"Content-Transfer-Encoding: 8bit\n"
@@ -84,20 +84,20 @@ msgstr ""
8484
msgid "Combo"
8585
msgstr ""
8686

87-
#: classes/Visualizer/Module/Admin.php:305
87+
#: classes/Visualizer/Module/Admin.php:313
8888
#: classes/Visualizer/Render/Library.php:42
8989
msgid "Visualizer Library"
9090
msgstr ""
9191

92-
#: classes/Visualizer/Module/Admin.php:432
92+
#: classes/Visualizer/Module/Admin.php:440
9393
msgid "Library"
9494
msgstr ""
9595

96-
#: classes/Visualizer/Module/Admin.php:457
96+
#: classes/Visualizer/Module/Admin.php:465
9797
msgid "Knowledge Base"
9898
msgstr ""
9999

100-
#: classes/Visualizer/Module/Admin.php:462
100+
#: classes/Visualizer/Module/Admin.php:470
101101
msgid "Pro Addon"
102102
msgstr ""
103103

@@ -144,66 +144,66 @@ msgid ""
144144
"its value to 1. This option increases the speed of remote CSV uploading."
145145
msgstr ""
146146

147-
#: classes/Visualizer/Render/Library.php:108
147+
#: classes/Visualizer/Render/Library.php:112
148148
msgid "Search"
149149
msgstr ""
150150

151-
#: classes/Visualizer/Render/Library.php:129
151+
#: classes/Visualizer/Render/Library.php:133
152152
#: classes/Visualizer/Render/Templates.php:85
153153
msgid "No charts found"
154154
msgstr ""
155155

156-
#: classes/Visualizer/Render/Library.php:180
156+
#: classes/Visualizer/Render/Library.php:184
157157
#: classes/Visualizer/Render/Templates.php:68
158158
msgid "Delete"
159159
msgstr ""
160160

161-
#: classes/Visualizer/Render/Library.php:181
161+
#: classes/Visualizer/Render/Library.php:185
162162
msgid "Clone"
163163
msgstr ""
164164

165-
#: classes/Visualizer/Render/Library.php:182
165+
#: classes/Visualizer/Render/Library.php:186
166166
msgid "Edit"
167167
msgstr ""
168168

169-
#: classes/Visualizer/Render/Library.php:183
169+
#: classes/Visualizer/Render/Library.php:187
170170
msgid "Export"
171171
msgstr ""
172172

173-
#: classes/Visualizer/Render/Library.php:184
173+
#: classes/Visualizer/Render/Library.php:188
174174
#: classes/Visualizer/Render/Templates.php:71
175175
msgid "Click to select"
176176
msgstr ""
177177

178-
#: classes/Visualizer/Render/Library.php:200
178+
#: classes/Visualizer/Render/Library.php:204
179179
msgid "Gain more editing power"
180180
msgstr ""
181181

182-
#: classes/Visualizer/Render/Library.php:201
182+
#: classes/Visualizer/Render/Library.php:205
183183
msgid "Spreadsheet like editor"
184184
msgstr ""
185185

186-
#: classes/Visualizer/Render/Library.php:202
186+
#: classes/Visualizer/Render/Library.php:206
187187
msgid "Import from other charts"
188188
msgstr ""
189189

190-
#: classes/Visualizer/Render/Library.php:203
190+
#: classes/Visualizer/Render/Library.php:207
191191
msgid "Auto-sync with online files"
192192
msgstr ""
193193

194-
#: classes/Visualizer/Render/Library.php:204
194+
#: classes/Visualizer/Render/Library.php:208
195195
msgid "3 more chart types"
196196
msgstr ""
197197

198-
#: classes/Visualizer/Render/Library.php:205
198+
#: classes/Visualizer/Render/Library.php:209
199199
msgid "View more features"
200200
msgstr ""
201201

202-
#: classes/Visualizer/Render/Library.php:213
202+
#: classes/Visualizer/Render/Library.php:217
203203
msgid "Enable Tracking"
204204
msgstr ""
205205

206-
#: classes/Visualizer/Render/Library.php:214
206+
#: classes/Visualizer/Render/Library.php:218
207207
msgid ""
208208
"Allow Visualizer to anonymously track how this plugin is used and help us "
209209
"make the plugin better. No sensitive data is tracked."
@@ -1473,12 +1473,6 @@ msgstr ""
14731473
msgid "Insert"
14741474
msgstr ""
14751475

1476-
#: vendor/codeinwp/themeisle-sdk/class-themeisle-sdk-licenser.php:453
1477-
msgid ""
1478-
"Updating this theme will lose any customizations you have made. Cancel to "
1479-
"stop, OK to update."
1480-
msgstr ""
1481-
14821476
#. Plugin Name of the plugin/theme
14831477
msgid "Visualizer: Charts and Graphs Lite"
14841478
msgstr ""

0 commit comments

Comments
 (0)