Product Import Export for WooCommerce - Version 2.0.0

Version Description

  • Heads up! This version has been revamped majorly. The new version update will not automatically adopt the existing settings.
  • Please make sure you record/note the existing plugin settings and redo them in the new version after an update.
  • Improved UI for better user experience
  • Export/Import options: via a pre-saved template or a quick(standard columns) export/import
  • Option to export/import selective columns
  • Option to reorder columns during export
  • Import: Support for different types of delimiters
  • Export/Import options: Batch option with configurable batch count
  • History of all the Import/Export process
  • Dedicated logs for debugging failures
Download this release

Release Info

Developer webtoffee
Plugin Icon 128x128 Product Import Export for WooCommerce
Version 2.0.0
Comparing to
See all releases

Code changes from version 1.9.3 to 2.0.0

Files changed (89) hide show
  1. Product_Commercial_Sample_CSV.csv +0 -12
  2. Product_WooCommerce_Sample_CSV.csv +0 -12
  3. admin/class-wt-import-export-for-woo-admin.php +365 -0
  4. admin/classes/class-csvreader.php +252 -0
  5. admin/classes/class-csvwriter.php +160 -0
  6. admin/classes/class-log.php +105 -0
  7. admin/classes/class-logreader.php +113 -0
  8. admin/classes/class-logwriter.php +97 -0
  9. admin/css/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  10. admin/css/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
  11. admin/css/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  12. admin/css/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  13. admin/css/images/ui-bg_glass_75_dadada_1x400.png +0 -0
  14. admin/css/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  15. admin/css/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  16. admin/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  17. admin/css/images/ui-icons_222222_256x240.png +0 -0
  18. admin/css/images/ui-icons_2e83ff_256x240.png +0 -0
  19. admin/css/images/ui-icons_454545_256x240.png +0 -0
  20. admin/css/images/ui-icons_888888_256x240.png +0 -0
  21. admin/css/images/ui-icons_cd0a0a_256x240.png +0 -0
  22. admin/css/jquery-ui.css +470 -0
  23. admin/css/select2.css +1 -0
  24. admin/css/wt-import-export-for-woo-admin.css +806 -0
  25. admin/index.php +1 -0
  26. admin/js/dropzone.min.js +1 -0
  27. admin/js/select2.js +1 -0
  28. admin/js/tiptip.js +1 -0
  29. admin/js/wt-import-export-for-woo-admin.js +738 -0
  30. admin/modules/export/assets/js/main.js +906 -0
  31. admin/modules/export/classes/class-export-ajax.php +707 -0
  32. admin/modules/export/export.php +816 -0
  33. admin/modules/export/views/_export_advanced_page.php +52 -0
  34. admin/modules/export/views/_export_filter_page.php +15 -0
  35. admin/modules/export/views/_export_footer.php +73 -0
  36. admin/modules/export/views/_export_header.php +15 -0
  37. admin/modules/export/views/_export_mapping_page.php +97 -0
  38. admin/modules/export/views/_export_mapping_tr_html.php +18 -0
  39. admin/modules/export/views/_export_meta_step_page.php +56 -0
  40. admin/modules/export/views/_export_method_export_page.php +90 -0
  41. admin/modules/export/views/_export_post_type_page.php +30 -0
  42. admin/modules/export/views/main.php +67 -0
  43. admin/modules/history/assets/js/main.js +196 -0
  44. admin/modules/history/history.php +857 -0
  45. admin/modules/history/views/_history_list.php +198 -0
  46. admin/modules/history/views/_log_list.php +73 -0
  47. admin/modules/history/views/_log_table.php +130 -0
  48. admin/modules/history/views/settings.php +46 -0
  49. admin/modules/import/assets/js/main.js +1482 -0
  50. admin/modules/import/classes/class-import-ajax.php +1209 -0
  51. admin/modules/import/import.php +1287 -0
  52. admin/modules/import/views/_import_advanced_page.php +25 -0
  53. admin/modules/import/views/_import_footer.php +73 -0
  54. admin/modules/import/views/_import_header.php +15 -0
  55. admin/modules/import/views/_import_mapping_page.php +282 -0
  56. admin/modules/import/views/_import_mapping_tr_html.php +17 -0
  57. admin/modules/import/views/_import_meta_step_page.php +43 -0
  58. admin/modules/import/views/_import_method_import_page.php +75 -0
  59. admin/modules/import/views/_import_post_type_page.php +31 -0
  60. admin/modules/import/views/main.php +82 -0
  61. admin/modules/product/data/data-allowed-product-types.php +75 -0
  62. admin/modules/product/data/data-product-post-columns.php +111 -0
  63. {includes/exporter → admin/modules/product}/data/data-wf-hidden-meta-columns.php +2 -2
  64. admin/modules/product/data/data/data-wf-reserved-fields-pair.php +414 -0
  65. admin/modules/product/export/export.php +611 -0
  66. admin/modules/product/import/import.php +1802 -0
  67. admin/modules/product/product.php +814 -0
  68. admin/partials/_form_field_generator.php +378 -0
  69. admin/partials/wt-import-export-for-woo-admin-display.php +76 -0
  70. admin/views/_save_template_popup.php +34 -0
  71. admin/views/admin-settings-advanced.php +20 -0
  72. admin/views/admin-settings-debug.php +8 -0
  73. admin/views/admin-settings-help.php +43 -0
  74. admin/views/admin-settings-marketing.php +528 -0
  75. admin/views/admin-settings-save-button.php +20 -0
  76. admin/views/market.php +31 -0
  77. assets/images/documentation.png +0 -0
  78. assets/images/drag_icon.png +0 -0
  79. assets/images/loading.gif +0 -0
  80. assets/images/sample-csv.png +0 -0
  81. assets/images/support.png +0 -0
  82. assets/images/upgrade/crown.svg +15 -0
  83. assets/images/upgrade/customer-ie.svg +24 -0
  84. assets/images/upgrade/money-back-badge.svg +32 -0
  85. assets/images/upgrade/no.svg +10 -0
  86. assets/images/upgrade/order-ie.svg +24 -0
  87. assets/images/upgrade/pre-icon.svg +3 -0
  88. assets/images/upgrade/product-ie.svg +19 -0
  89. assets/images/upgrade/suite-cover.svg +3 -0
Product_Commercial_Sample_CSV.csv DELETED
@@ -1,12 +0,0 @@
1
- Parent SKU,SKU,Product Name,Short Description,Description,Regular Price,Sale Price,Weight,Images,Product Type,Prodcut Categories,Product Tags,meta:attribute_pa_color,attribute:pa_care-instructions,attribute_data:pa_care-instructions,attribute:pa_color,attribute_data:pa_color,attribute_default:pa_color,attribute:pa_fabric,attribute_data:pa_fabric,attribute:pa_fitting-type,attribute_data:pa_fitting-type
2
- ,A11,Samsung Galaxy Ace Duos,"-5 MP Primary Camera
3
- -3.5 inch Capacitive Touchscreen
4
- -Wi-Fi Enabled
5
- ","Having a much vaunted reputation of being one of the world’s leading budget smartphone makers, the Samsung Galaxy Ace Duos S6802 does quite well to maintain Samsung’s authority in the current market. The device comes in a bar shape and has a sleek look to it. The Ace Duos S6802 is a Smart Dual Active SIM, (GSM + GSM) device with both the inserted SIM cards being active at the same time. If you are on a call on sim 1 and you get a call on sim 2, the call would be diverted to sim 1 and the display would show it as call waiting.The same will be apply for both the Sims. So that we cannot miss out any calls on sim 1 and sim 2. This Samsung phone is run on the Android v2.3 (Gingerbread) OS with a snappy processor speed of 832 MHz. To assure the smooth running of apps, the device comes with an adequate 512 MB of RAM.",29.99,11.52,0.5,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-mobile.jpg|https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-mobile-2.jpg,simple,Mobile Phone,Smart Phone,,,,,,,,,,
6
- ,A12,Formal shoe,Formal shoe leather made,"Formal shoe leather made , black color",10,8,0.5,,simple,Shoes,Foot Wears,,,,,,,,,,
7
- ,A13,LED TV,LED TV 20 inches,LED TV 20 inches by samsung,30,29,1,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-tv.jpg,simple,Tele Vision,Electronics,,,,,,,,,,
8
- ,A14,Refrigerator,Double door Refrigerator,Double door Refrigerator with auto power saving,35,32,2,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-fridge.jpg,simple,Refrigerator,Electronics,,,,,,,,,,
9
- ,A15,Washing machine,Washing machine with remote control,Washing machine with remote controle and much more options,20,18,2,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-wm.jpg,simple,washing Machine,Electronics,,,,,,,,,,
10
- ,B11,Men's Cotton T-Shirt,The images represent actual product though color of the image and product may slightly differ.,Strut on the streets in comfort adorning this slim-fit T-Shirt from the house of Tinted. This unique creation is made using rayon that will highlight your torso. Work hard and play hard as you party through the night in this utterly comfortable T-Shirt.,10,,1,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-red.png,variable,Clothing & Accessories > Men > Tops & Tees > T-Shirts,T-Shirts,,Wash dark colors seperately,2|1|0,Blue|Red,3|0|1,red,Cotton,0|1|0,Regular Fit,1|1|0
11
- B11,B11V2,,,,24,12,,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-red.png,,,,red,,,,,,,,,
12
- B11,B11V1,,,,22,11,,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-blue.png,,,,blue,,,,,,,,,
 
 
 
 
 
 
 
 
 
 
 
 
Product_WooCommerce_Sample_CSV.csv DELETED
@@ -1,12 +0,0 @@
1
- parent_sku,sku,post_title,post_excerpt,post_content,regular_price,sale_price,weight,Images,tax:product_type,tax:product_cat,tax:product_tag,meta:attribute_pa_color,attribute:pa_care-instructions,attribute_data:pa_care-instructions,attribute:pa_color,attribute_data:pa_color,attribute_default:pa_color,attribute:pa_fabric,attribute_data:pa_fabric,attribute:pa_fitting-type,attribute_data:pa_fitting-type
2
- ,A11,Samsung Galaxy Ace Duos,"-5 MP Primary Camera
3
- -3.5 inch Capacitive Touchscreen
4
- -Wi-Fi Enabled
5
- ","Having a much vaunted reputation of being one of the world’s leading budget smartphone makers, the Samsung Galaxy Ace Duos S6802 does quite well to maintain Samsung’s authority in the current market. The device comes in a bar shape and has a sleek look to it. The Ace Duos S6802 is a Smart Dual Active SIM, (GSM + GSM) device with both the inserted SIM cards being active at the same time. If you are on a call on sim 1 and you get a call on sim 2, the call would be diverted to sim 1 and the display would show it as call waiting.The same will be apply for both the Sims. So that we cannot miss out any calls on sim 1 and sim 2. This Samsung phone is run on the Android v2.3 (Gingerbread) OS with a snappy processor speed of 832 MHz. To assure the smooth running of apps, the device comes with an adequate 512 MB of RAM.",29.99,11.52,0.5,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-mobile.jpg|https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-mobile-2.jpg,simple,Mobile Phone,Smart Phone,,,,,,,,,,
6
- ,A12,Formal shoe,Formal shoe leather made,"Formal shoe leather made , black color",10,8,0.5,,simple,Shoes,Foot Wears,,,,,,,,,,
7
- ,A13,LED TV,LED TV 20 inches,LED TV 20 inches by samsung,30,29,1,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-tv.jpg,simple,Tele Vision,Electronics,,,,,,,,,,
8
- ,A14,Refrigerator,Double door Refrigerator,Double door Refrigerator with auto power saving,35,32,2,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-fridge.jpg,simple,Refrigerator,Electronics,,,,,,,,,,
9
- ,A15,Washing machine,Washing machine with remote control,Washing machine with remote controle and much more options,20,18,2,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-model-wm.jpg,simple,washing Machine,Electronics,,,,,,,,,,
10
- ,B11,Men's Cotton T-Shirt,The images represent actual product though color of the image and product may slightly differ.,Strut on the streets in comfort adorning this slim-fit T-Shirt from the house of Tinted. This unique creation is made using rayon that will highlight your torso. Work hard and play hard as you party through the night in this utterly comfortable T-Shirt.,10,,1,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-red.png,variable,Clothing & Accessories > Men > Tops & Tees > T-Shirts,T-Shirts,,Wash dark colors seperately,2|1|0,Blue|Red,3|0|1,red,Cotton,0|1|0,Regular Fit,1|1|0
11
- B11,B11V2,,,,24,12,,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-red.png,,,,red,,,,,,,,,
12
- B11,B11V1,,,,22,11,,https://media.wtdev.xyz/wp-content/uploads/2020/04/wt-men-t-shirt-blue.png,,,,blue,,,,,,,,,
 
 
 
 
 
 
 
 
 
 
 
 
admin/class-wt-import-export-for-woo-admin.php ADDED
@@ -0,0 +1,365 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * The admin-specific functionality of the plugin.
5
+ *
6
+ * @link https://www.webtoffee.com/
7
+ * @since 1.0.0
8
+ *
9
+ * @package Wt_Import_Export_For_Woo
10
+ * @subpackage Wt_Import_Export_For_Woo/admin
11
+ */
12
+
13
+ /**
14
+ * The admin-specific functionality of the plugin.
15
+ *
16
+ * Defines the plugin name, version, and two examples hooks for how to
17
+ * enqueue the admin-specific stylesheet and JavaScript.
18
+ *
19
+ * @package Wt_Import_Export_For_Woo
20
+ * @subpackage Wt_Import_Export_For_Woo/admin
21
+ * @author Webtoffee <info@webtoffee.com>
22
+ */
23
+ if(!class_exists('Wt_Import_Export_For_Woo_Admin_Basic')){
24
+ class Wt_Import_Export_For_Woo_Admin_Basic {
25
+
26
+ /**
27
+ * The ID of this plugin.
28
+ *
29
+ * @since 1.0.0
30
+ * @access private
31
+ * @var string $plugin_name The ID of this plugin.
32
+ */
33
+ private $plugin_name;
34
+
35
+ /**
36
+ * The version of this plugin.
37
+ *
38
+ * @since 1.0.0
39
+ * @access private
40
+ * @var string $version The current version of this plugin.
41
+ */
42
+ private $version;
43
+
44
+ /*
45
+ * module list, Module folder and main file must be same as that of module name
46
+ * Please check the `register_modules` method for more details
47
+ */
48
+ public static $modules=array(
49
+ 'history',
50
+ 'export',
51
+ 'import',
52
+ );
53
+
54
+ public static $existing_modules=array();
55
+
56
+ public static $addon_modules=array();
57
+
58
+
59
+ /**
60
+ * Initialize the class and set its properties.
61
+ *
62
+ * @since 1.0.0
63
+ * @param string $plugin_name The name of this plugin.
64
+ * @param string $version The version of this plugin.
65
+ */
66
+ public function __construct( $plugin_name, $version ) {
67
+
68
+ $this->plugin_name = $plugin_name;
69
+ $this->version = $version;
70
+
71
+ }
72
+
73
+ /**
74
+ * Register the stylesheets for the admin area.
75
+ *
76
+ * @since 1.0.0
77
+ */
78
+ public function enqueue_styles() {
79
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_is_screen_allowed()){
80
+ wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/wt-import-export-for-woo-admin.css', array(), $this->version, 'all' );
81
+ }
82
+ }
83
+
84
+ /**
85
+ * Register the JavaScript for the admin area.
86
+ *
87
+ * @since 1.0.0
88
+ */
89
+ public function enqueue_scripts()
90
+ {
91
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_is_screen_allowed()){
92
+ /* enqueue scripts */
93
+ if(!function_exists('is_plugin_active'))
94
+ {
95
+ include_once(ABSPATH.'wp-admin/includes/plugin.php');
96
+ }
97
+ if(is_plugin_active('woocommerce/woocommerce.php'))
98
+ {
99
+ wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/wt-import-export-for-woo-admin.js', array( 'jquery', 'jquery-tiptip'), $this->version, false );
100
+ }else
101
+ {
102
+ wp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/wt-import-export-for-woo-admin.js', array( 'jquery'), $this->version, false );
103
+ wp_enqueue_script(WT_IEW_PLUGIN_ID_BASIC.'-tiptip', WT_P_IEW_PLUGIN_URL.'admin/js/tiptip.js', array('jquery'), WT_P_IEW_VERSION, false);
104
+ }
105
+
106
+ $params=array(
107
+ 'nonces' => array(
108
+ 'main' => wp_create_nonce(WT_IEW_PLUGIN_ID_BASIC),
109
+ ),
110
+ 'ajax_url' => admin_url('admin-ajax.php'),
111
+ 'plugin_id' =>WT_IEW_PLUGIN_ID_BASIC,
112
+ 'msgs'=>array(
113
+ 'settings_success'=>__('Settings updated.'),
114
+ 'all_fields_mandatory'=>__('All fields are mandatory'),
115
+ 'settings_error'=>__('Unable to update Settings.'),
116
+ 'value_empty'=>__('Value is empty.'),
117
+ 'error'=>sprintf(__('An unknown error has occurred! Refer to our %stroubleshooting guide%s for assistance.'), '<a href="'.WT_IEW_DEBUG_BASIC_TROUBLESHOOT.'" target="_blank">', '</a>'),
118
+ 'success'=>__('Success.'),
119
+ 'loading'=>__('Loading...'),
120
+ 'sure'=>__('Are you sure?'),
121
+ 'use_expression'=>__('Use expression as value.'),
122
+ 'cancel'=>__('Cancel'),
123
+ )
124
+ );
125
+ wp_localize_script($this->plugin_name, 'wt_iew_basic_params', $params);
126
+ }
127
+
128
+ }
129
+
130
+ /**
131
+ * Registers menu options
132
+ * Hooked into admin_menu
133
+ *
134
+ * @since 1.0.0
135
+ */
136
+ public function admin_menu()
137
+ {
138
+ $menus=array(
139
+ 'general-settings'=>array(
140
+ 'menu',
141
+ __('General Settings'),
142
+ __('General Settings'),
143
+ apply_filters('wt_import_export_allowed_capability', 'import'),
144
+ WT_IEW_PLUGIN_ID_BASIC,
145
+ array($this,'admin_settings_page'),
146
+ 'dashicons-controls-repeat',
147
+ 56
148
+ )
149
+ );
150
+ $menus=apply_filters('wt_iew_admin_menu_basic',$menus);
151
+
152
+ $menu_order=array("export","export-sub","import","history","history_log");
153
+ $this->wt_menu_order_changer($menus,$menu_order);
154
+
155
+ $main_menu = reset($menus); //main menu must be first one
156
+
157
+ $parent_menu_key=$main_menu ? $main_menu[4] : WT_IEW_PLUGIN_ID_BASIC;
158
+
159
+
160
+ /* adding general settings menu */
161
+ $menus['general-settings-sub']=array(
162
+ 'submenu',
163
+ $parent_menu_key,
164
+ __('General Settings'),
165
+ __('General Settings'),
166
+ apply_filters('wt_import_export_allowed_capability', 'import'),
167
+ WT_IEW_PLUGIN_ID_BASIC,
168
+ array($this, 'admin_settings_page')
169
+ );
170
+ if(count($menus)>0)
171
+ {
172
+ foreach($menus as $menu)
173
+ {
174
+ if($menu[0]=='submenu')
175
+ {
176
+ /* currently we are only allowing one parent menu */
177
+ add_submenu_page($parent_menu_key,$menu[2],$menu[3],$menu[4],$menu[5],$menu[6]);
178
+ }else
179
+ {
180
+ add_menu_page($menu[1],$menu[2],$menu[3],$menu[4],$menu[5],$menu[6],$menu[7]);
181
+ }
182
+ }
183
+ }
184
+ if(function_exists('remove_submenu_page')){
185
+ //remove_submenu_page(WT_PIEW_POST_TYPE, WT_PIEW_POST_TYPE);
186
+ }
187
+ }
188
+
189
+ public function wt_menu_order_changer( &$arr, $index_arr ) {
190
+ $arr_t = array();
191
+ foreach ( $index_arr as $i => $v ) {
192
+ foreach ( $arr as $k => $b ) {
193
+ if ( $k == $v )
194
+ $arr_t[ $k ] = $b;
195
+ }
196
+ }
197
+ $arr = $arr_t;
198
+ }
199
+
200
+ public function admin_settings_page()
201
+ {
202
+ include(plugin_dir_path( __FILE__ ).'partials/wt-import-export-for-woo-admin-display.php');
203
+ }
204
+
205
+ /**
206
+ * Save admin settings and module settings ajax hook
207
+ */
208
+ public function save_settings()
209
+ {
210
+ $out=array(
211
+ 'status'=>false,
212
+ 'msg'=>__('Error'),
213
+ );
214
+
215
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
216
+ {
217
+ $advanced_settings=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings();
218
+ $advanced_fields=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings_fields();
219
+ $validation_rule=Wt_Import_Export_For_Woo_Basic_Common_Helper::extract_validation_rules($advanced_fields);
220
+ $new_advanced_settings=array();
221
+ foreach($advanced_fields as $key => $value)
222
+ {
223
+ $form_field_name = isset($value['field_name']) ? $value['field_name'] : '';
224
+ $field_name=(substr($form_field_name,0,8)!=='wt_iew_' ? 'wt_iew_' : '').$form_field_name;
225
+ $validation_key=str_replace('wt_iew_', '', $field_name);
226
+ if(isset($_POST[$field_name]))
227
+ {
228
+ $new_advanced_settings[$field_name]=Wt_Iew_Sh::sanitize_data($_POST[$field_name], $validation_key, $validation_rule);
229
+ }
230
+ }
231
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::set_advanced_settings($new_advanced_settings);
232
+ $out['status']=true;
233
+ $out['msg']=__('Settings Updated');
234
+ do_action('wt_iew_after_advanced_setting_update_basic', $new_advanced_settings);
235
+ }
236
+ echo json_encode($out);
237
+ exit();
238
+ }
239
+
240
+ /**
241
+ Registers modules: admin
242
+ */
243
+ public function admin_modules()
244
+ {
245
+ $wt_iew_admin_modules=get_option('wt_iew_admin_modules');
246
+ if($wt_iew_admin_modules===false)
247
+ {
248
+ $wt_iew_admin_modules=array();
249
+ }
250
+ foreach (self::$modules as $module) //loop through module list and include its file
251
+ {
252
+ $is_active=1;
253
+ if(isset($wt_iew_admin_modules[$module]))
254
+ {
255
+ $is_active=$wt_iew_admin_modules[$module]; //checking module status
256
+ }else
257
+ {
258
+ $wt_iew_admin_modules[$module]=1; //default status is active
259
+ }
260
+ $module_file=plugin_dir_path( __FILE__ )."modules/$module/$module.php";
261
+ if(file_exists($module_file) && $is_active==1)
262
+ {
263
+ self::$existing_modules[]=$module; //this is for module_exits checking
264
+ require_once $module_file;
265
+ }else
266
+ {
267
+ $wt_iew_admin_modules[$module]=0;
268
+ }
269
+ }
270
+ $out=array();
271
+ foreach($wt_iew_admin_modules as $k=>$m)
272
+ {
273
+ if(in_array($k, self::$modules))
274
+ {
275
+ $out[$k]=$m;
276
+ }
277
+ }
278
+ update_option('wt_iew_admin_modules',$out);
279
+
280
+
281
+ /**
282
+ * Add on modules
283
+ */
284
+ include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
285
+ foreach (self::$addon_modules as $module) //loop through module list and include its file
286
+ {
287
+ $plugin_file="wt-import-export-for-woo-$module/wt-import-export-for-woo-$module.php";
288
+ if(is_plugin_active($plugin_file))
289
+ {
290
+ $module_file=WP_PLUGIN_DIR."/wt-import-export-for-woo-$module/$module/$module.php";
291
+ if(file_exists($module_file))
292
+ {
293
+ self::$existing_modules[]=$module;
294
+ require_once $module_file;
295
+ }
296
+ }
297
+ }
298
+
299
+
300
+ $addon_modules_basic = array(
301
+ 'order'=>'order-import-export-for-woocommerce',
302
+ 'coupon'=>'order-import-export-for-woocommerce',
303
+ 'product'=>'product-import-export-for-woo',
304
+ 'user'=>'users-customers-import-export-for-wp-woocommerce',
305
+ );
306
+ foreach ($addon_modules_basic as $module_key => $module_path)
307
+ {
308
+ if(is_plugin_active("{$module_path}/{$module_path}.php"))
309
+ {
310
+ $module_file=WP_CONTENT_DIR."/plugins/{$module_path}/admin/modules/$module_key/$module_key.php";
311
+ if(file_exists($module_file))
312
+ {
313
+ self::$existing_modules[]=$module_key;
314
+ require_once $module_file;
315
+ }
316
+ }
317
+ }
318
+
319
+ }
320
+
321
+ public static function module_exists($module)
322
+ {
323
+ return in_array($module, self::$existing_modules);
324
+ }
325
+
326
+ /**
327
+ * Envelope settings tab content with tab div.
328
+ * relative path is not acceptable in view file
329
+ */
330
+ public static function envelope_settings_tabcontent($target_id,$view_file="",$html="",$variables=array(),$need_submit_btn=0)
331
+ {
332
+ extract($variables);
333
+ ?>
334
+ <div class="wt-iew-tab-content" data-id="<?php echo $target_id;?>">
335
+ <?php
336
+ if($view_file!="" && file_exists($view_file))
337
+ {
338
+ include_once $view_file;
339
+ }else
340
+ {
341
+ echo $html;
342
+ }
343
+ ?>
344
+ <?php
345
+ if($need_submit_btn==1)
346
+ {
347
+ include WT_P_IEW_PLUGIN_PATH."admin/views/admin-settings-save-button.php";
348
+ }
349
+ ?>
350
+ </div>
351
+ <?php
352
+ }
353
+
354
+ /**
355
+ * Plugin page action links
356
+ */
357
+ public function plugin_action_links($links)
358
+ {
359
+ $links[] = '<a href="'.admin_url('admin.php?page='.WT_IEW_PLUGIN_ID_BASIC).'">'.__('Settings').'</a>';
360
+ $links[] = '<a href="https://www.webtoffee.com/" target="_blank">'.__('Documentation').'</a>';
361
+ $links[] = '<a href="https://www.webtoffee.com/support/" target="_blank">'.__('Support').'</a>';
362
+ return $links;
363
+ }
364
+ }
365
+ }
admin/classes/class-csvreader.php ADDED
@@ -0,0 +1,252 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * CSV reading section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Csvreader')){
13
+ class Wt_Import_Export_For_Woo_Basic_Csvreader
14
+ {
15
+ public $delimiter=',';
16
+ public $fgetcsv_esc_check=0;
17
+ public function __construct($delimiter=',')
18
+ {
19
+ $this->delimiter=$delimiter;
20
+ $this->delimiter=($this->delimiter=='tab' ? "\t" : $this->delimiter);
21
+
22
+ /* version 5.3.0 onwards 5th escaping argument introduced in `fgetcsv` function */
23
+ $this->fgetcsv_esc_check = (version_compare(PHP_VERSION, '5.3.0') >= 0);
24
+ }
25
+
26
+ /**
27
+ * Taking sample data for mapping screen preparation
28
+ * This function skip empty rows and take first two non empty rows
29
+ */
30
+ public function get_sample_data($file, $grouping=false)
31
+ {
32
+ $enc = mb_detect_encoding($file, 'UTF-8, ISO-8859-1', true);
33
+ if($enc)
34
+ {
35
+ setlocale(LC_ALL, 'en_US.'.$enc);
36
+ }
37
+ @ini_set('auto_detect_line_endings', true);
38
+
39
+ $sample_data_key=array();
40
+ $sample_data_val=array();
41
+ $sample_data=array();
42
+
43
+ if(($handle=@fopen($file, "r"))!== false)
44
+ {
45
+ $row_count=0;
46
+ while(($row=($this->fgetcsv_esc_check) ? fgetcsv($handle, 0, $this->delimiter, '"', '"') : fgetcsv($handle, 0, $this->delimiter, '"') )!==false)
47
+ {
48
+ if(count(array_filter($row))==0)
49
+ {
50
+ continue;
51
+ }else
52
+ {
53
+ $row_count++;
54
+ }
55
+
56
+ if($row_count==1) //taking heading row
57
+ {
58
+ $sample_data_key=$row;
59
+ }else //taking data row
60
+ {
61
+ $sample_data_val=$row;
62
+ break; //only single data row needed
63
+ }
64
+ }
65
+
66
+ foreach($sample_data_key as $k => $key)
67
+ {
68
+ if(!$key)
69
+ {
70
+ continue;
71
+ }
72
+
73
+ $val=(isset($sample_data_val[$k]) ? $this->format_data_from_csv($sample_data_val[$k], $enc) : '');
74
+
75
+ /* removing BOM like non characters */
76
+ // $key=preg_replace('/[\x00-\x1F\x80-\xFF]/', '', $key);
77
+ $key= wt_removeBomUtf8_basic($key);
78
+ if($grouping)
79
+ {
80
+ if(strrpos($key, ':')!==false)
81
+ {
82
+ $key_arr=explode(":", $key);
83
+ if(count($key_arr)>1)
84
+ {
85
+ $meta_key=$key_arr[0];
86
+ if(!isset($sample_data[$meta_key]))
87
+ {
88
+ $sample_data[$meta_key]=array();
89
+ }
90
+ $sample_data[$meta_key][$key]=$val;
91
+ }else
92
+ {
93
+ $sample_data[$key]=$val;
94
+ }
95
+ }else
96
+ {
97
+ $sample_data[$key]=$val;
98
+ }
99
+ }else
100
+ {
101
+ $sample_data[$key]=$val;
102
+ }
103
+ }
104
+
105
+ fclose($handle);
106
+ }
107
+
108
+ return $sample_data;
109
+ }
110
+
111
+ /**
112
+ * Get data from CSV as batch
113
+ */
114
+ public function get_data_as_batch($file, $offset, $batch_count, $module_obj, $form_data)
115
+ {
116
+ // Set locale
117
+ $enc = mb_detect_encoding( $file, 'UTF-8, ISO-8859-1', true );
118
+ if($enc)
119
+ {
120
+ setlocale( LC_ALL, 'en_US.' . $enc );
121
+ }
122
+ @ini_set('auto_detect_line_endings', true);
123
+
124
+ $out=array(
125
+ 'response'=>false,
126
+ 'offset'=>$offset,
127
+ 'data_arr'=>array(),
128
+ );
129
+
130
+ if(($handle=@fopen($file, "r"))!== false)
131
+ {
132
+ /**
133
+ * taking head
134
+ */
135
+ $head_arr=array();
136
+ while(($row=($this->fgetcsv_esc_check) ? fgetcsv($handle, 0, $this->delimiter, '"', '"') : fgetcsv($handle, 0, $this->delimiter, '"') )!==false)
137
+ {
138
+ if(count(array_filter($row))!=0) /* first non empty array */
139
+ {
140
+ $head_arr=$row;
141
+ if($offset==0) /* on first batch */
142
+ {
143
+ $offset_after_head=ftell($handle);
144
+ fseek($handle, $offset_after_head); /* skipping head row */
145
+ }
146
+ break;
147
+ }
148
+ }
149
+
150
+ $empty_head_columns=array();
151
+ foreach($head_arr as $head_key=>$head_val)
152
+ {
153
+ if(trim($head_val)=='')
154
+ {
155
+ $empty_head_columns[]=$head_key;
156
+ unset($head_arr[$head_key]);
157
+ }else
158
+ {
159
+ /* removing BOM like non characters */
160
+ // $head_arr[$head_key]=preg_replace('/[\x00-\x1F\x80-\xFF]/', '', $head_val);
161
+ $head_arr[$head_key]= wt_removeBomUtf8_basic($head_val);
162
+ }
163
+ }
164
+
165
+ /* moving the pointer to corresponding batch. If not first batch */
166
+ if($offset!=0)
167
+ {
168
+ fseek($handle, $offset);
169
+ }
170
+
171
+ $out_arr=array();
172
+
173
+ $row_count=0;
174
+ /* taking data */
175
+ while(($row=($this->fgetcsv_esc_check) ? fgetcsv($handle, 0, $this->delimiter, '"', '"') : fgetcsv($handle, 0, $this->delimiter, '"') )!==false)
176
+ {
177
+ $offset=ftell($handle); /* next offset */
178
+
179
+ /*
180
+ * Skipping empty rows
181
+ */
182
+ if(count(array_filter($row))==0)
183
+ {
184
+ continue;
185
+ }
186
+
187
+ /*
188
+ * Remove values of empty head
189
+ */
190
+ foreach($empty_head_columns as $key)
191
+ {
192
+ unset($row[$key]);
193
+ }
194
+
195
+ /*
196
+ * Creating associative array with heading and data
197
+ */
198
+ $row_column_count=count($row);
199
+ $head_column_count=count($head_arr);
200
+ if($row_column_count<$head_column_count)
201
+ {
202
+ $empty_row=array_fill($row_column_count, ($head_column_count-$row_column_count), '');
203
+ $row=array_merge($row, $empty_row);
204
+ $empty_row=null;
205
+ unset($empty_row);
206
+ }
207
+ elseif($row_column_count>$head_column_count)
208
+ {
209
+ continue;
210
+ }
211
+
212
+ /* clearing temp variables */
213
+ $row_column_count=$head_column_count=null;
214
+ unset($row_column_count, $head_column_count);
215
+
216
+ /* preparing associative array */
217
+ $data_row=array_combine($head_arr, $row);
218
+
219
+ $out_arr[]=$module_obj->process_column_val($data_row, $form_data);
220
+ //$out_arr[]=$data_row;
221
+
222
+ unset($data_row);
223
+
224
+ $row_count++;
225
+ if($row_count==$batch_count)
226
+ {
227
+ break;
228
+ }
229
+ }
230
+ fclose($handle);
231
+
232
+ $out=array(
233
+ 'response'=>true,
234
+ 'offset'=>$offset,
235
+ 'rows_processed'=>$row_count,
236
+ 'data_arr'=>$out_arr,
237
+ );
238
+
239
+ $head_arr=$form_data=$row=$out_arr=null;
240
+ unset($head_arr, $form_data, $row, $out_arr);
241
+ }
242
+
243
+ return $out;
244
+ }
245
+
246
+ protected function format_data_from_csv($data, $enc)
247
+ {
248
+ //return sanitize_text_field(( $enc == 'UTF-8' ) ? trim($data) : utf8_encode(trim($data))); sanitize_text_field stripping html content
249
+ return (( $enc == 'UTF-8' ) ? trim($data) : utf8_encode(trim($data)));
250
+ }
251
+ }
252
+ }
admin/classes/class-csvwriter.php ADDED
@@ -0,0 +1,160 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * CSV writing section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Csvwriter')){
13
+ class Wt_Import_Export_For_Woo_Basic_Csvwriter
14
+ {
15
+ public $file_path='';
16
+ public $data_ar='';
17
+ public $csv_delimiter='';
18
+ public function __construct($file_path, $offset, $csv_delimiter=",")
19
+ {
20
+ $this->csv_delimiter=$csv_delimiter;
21
+ $this->file_path=$file_path;
22
+ $this->get_file_pointer($offset);
23
+ }
24
+
25
+ /**
26
+ * This is used in XML to CSV converting
27
+ */
28
+ public function write_row($row_data, $offset=0, $is_last_offset=false)
29
+ {
30
+ if($is_last_offset)
31
+ {
32
+ $this->close_file_pointer();
33
+ }else
34
+ {
35
+ if($offset==0) /* set heading */
36
+ {
37
+ $this->fput_csv($this->file_pointer, array_keys($row_data), $this->csv_delimiter);
38
+ }
39
+ $this->fput_csv($this->file_pointer, $row_data, $this->csv_delimiter);
40
+ }
41
+ }
42
+
43
+ /**
44
+ * Create CSV
45
+ *
46
+ */
47
+ public function write_to_file($export_data, $offset, $is_last_offset, $to_export)
48
+ {
49
+ $this->export_data=$export_data;
50
+ $this->set_head($export_data, $offset, $this->csv_delimiter);
51
+ $this->set_content($export_data, $this->csv_delimiter);
52
+ $this->close_file_pointer();
53
+ }
54
+ private function get_file_pointer($offset)
55
+ {
56
+ if($offset==0)
57
+ {
58
+ $this->file_pointer=fopen($this->file_path, 'w');
59
+ }else
60
+ {
61
+ $this->file_pointer=fopen($this->file_path, 'a+');
62
+ }
63
+ }
64
+ private function close_file_pointer()
65
+ {
66
+ if($this->file_pointer!=null)
67
+ {
68
+ fclose($this->file_pointer);
69
+ }
70
+ }
71
+ /**
72
+ * Escape a string to be used in a CSV context
73
+ *
74
+ * Malicious input can inject formulas into CSV files, opening up the possibility
75
+ * for phishing attacks and disclosure of sensitive information.
76
+ *
77
+ * Additionally, Excel exposes the ability to launch arbitrary commands through
78
+ * the DDE protocol.
79
+ *
80
+ * @see http://www.contextis.com/resources/blog/comma-separated-vulnerabilities/
81
+ * @see https://hackerone.com/reports/72785
82
+ *
83
+ * @param string $data CSV field to escape.
84
+ * @return string
85
+ */
86
+ public function escape_data( $data )
87
+ {
88
+ $active_content_triggers = array( '=', '+', '-', '@' );
89
+
90
+ if ( in_array( mb_substr( $data, 0, 1 ), $active_content_triggers, true ) ) {
91
+ $data = "'" . $data;
92
+ }
93
+
94
+ return $data;
95
+ }
96
+ public function format_data( $data )
97
+ {
98
+ if ( ! is_scalar( $data ) ) {
99
+ if ( is_a( $data, 'WC_Datetime' ) ) {
100
+ $data = $data->date( 'Y-m-d G:i:s' );
101
+ } else {
102
+ $data = ''; // Not supported.
103
+ }
104
+ } elseif ( is_bool( $data ) ) {
105
+ $data = $data ? 1 : 0;
106
+ }
107
+
108
+ $use_mb = function_exists( 'mb_convert_encoding' );
109
+
110
+ if ( $use_mb ) {
111
+ $encoding = mb_detect_encoding( $data, 'UTF-8, ISO-8859-1', true );
112
+ $data = 'UTF-8' === $encoding ? $data : utf8_encode( $data );
113
+ }
114
+
115
+ return $this->escape_data( $data );
116
+ }
117
+ private function set_content($export_data, $delm=',')
118
+ {
119
+ if(isset($export_data) && isset($export_data['body_data']) && count($export_data['body_data'])>0)
120
+ {
121
+ $row_datas=array_values($export_data['body_data']);
122
+ foreach($row_datas as $row_data)
123
+ {
124
+ foreach($row_data as $key => $value)
125
+ {
126
+ $row_data[$key]=$this->format_data($value);
127
+ }
128
+ $this->fput_csv($this->file_pointer, $row_data, $delm);
129
+ }
130
+ }
131
+ }
132
+ private function set_head($export_data, $offset, $delm=',')
133
+ {
134
+ if($offset==0 && isset($export_data) && isset($export_data['head_data']) && count($export_data['head_data'])>0)
135
+ {
136
+ foreach($export_data['head_data'] as $key => $value)
137
+ {
138
+ $export_data['head_data'][$key]=$this->format_data($value);
139
+ }
140
+ $this->fput_csv($this->file_pointer, $export_data['head_data'], $delm);
141
+ }
142
+ }
143
+ private function fput_csv($fp, $row, $delm=',', $encloser='"' )
144
+ {
145
+ fputcsv($fp,$row,$delm,$encloser);
146
+ }
147
+ private function array_to_csv($arr, $delm=',', $encloser='"')
148
+ {
149
+ $fp=fopen('php://memory','rw');
150
+ foreach($arr as $row)
151
+ {
152
+ $this->fput_csv($fp, $row, $delm, $encloser);
153
+ }
154
+ rewind($fp);
155
+ $csv=stream_get_contents($fp);
156
+ fclose($fp);
157
+ return $csv;
158
+ }
159
+ }
160
+ }
admin/classes/class-log.php ADDED
@@ -0,0 +1,105 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Log writing section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Log')){
13
+ class Wt_Import_Export_For_Woo_Basic_Log
14
+ {
15
+ public static $log_dir=WP_CONTENT_DIR.'/webtoffee_iew_log';
16
+ public static $history_id='';
17
+ public function __construct()
18
+ {
19
+
20
+ }
21
+
22
+ /**
23
+ * Get given temp file path.
24
+ * If file name is empty then file path will return
25
+ */
26
+ public static function get_file_path($file_name="")
27
+ {
28
+ if(!is_dir(self::$log_dir))
29
+ {
30
+ if(!mkdir(self::$log_dir, 0700))
31
+ {
32
+ return false;
33
+ }else
34
+ {
35
+ $files_to_create=array('.htaccess' => 'deny from all', 'index.php'=>'<?php // Silence is golden');
36
+ foreach($files_to_create as $file=>$file_content)
37
+ {
38
+ if(!file_exists(self::$log_dir.'/'.$file))
39
+ {
40
+ $fh=@fopen(self::$log_dir.'/'.$file, "w");
41
+ if(is_resource($fh))
42
+ {
43
+ fwrite($fh, $file_content);
44
+ fclose($fh);
45
+ }
46
+ }
47
+ }
48
+ }
49
+ }
50
+ return self::$log_dir.'/'.$file_name;
51
+ }
52
+
53
+ /**
54
+ * Checks a log file created for the history entry for current day
55
+ * @param int $history_id id of history entry
56
+ * @return string/bool if file found returns file name otherwise false
57
+ */
58
+ public static function check_log_exists_for_entry($history_id)
59
+ {
60
+ $log_dir=self::get_file_path();
61
+ $exp='~^'.$history_id.'.*\.log$~';
62
+ $files = preg_grep($exp, scandir($log_dir));
63
+
64
+ if(count($files)>0) /* file exists */
65
+ {
66
+ foreach($files as $key => $value)
67
+ {
68
+ $file_name=pathinfo($value, PATHINFO_FILENAME);
69
+ $file_name_arr=explode('_', $file_name);
70
+ $file_date_time=end($file_name_arr);
71
+ $file_date_time_arr=explode(' ', $file_date_time);
72
+ $file_time=strtotime($file_date_time_arr[0]);
73
+ if($file_time) //file time exists
74
+ {
75
+ $today=strtotime(date('Y-m-d'));
76
+ $file_time=strtotime(date('Y-m-d', $file_time));
77
+ if($today==$file_time) //file exists with the current day
78
+ {
79
+ return $value;
80
+ }
81
+ }
82
+ }
83
+ }
84
+ return false;
85
+ }
86
+
87
+ /**
88
+ * Generate log file name
89
+ *
90
+ */
91
+ public static function generate_file_name($post_type='', $action_type='', $history_id='')
92
+ {
93
+ $arr=array($history_id, $post_type);
94
+ if(defined( 'WT_IEW_CRON' )) /* this is a cron run so add a schedule prefix */
95
+ {
96
+ $arr[]='schedule';
97
+ }
98
+ $arr[]=$action_type;
99
+ $arr[]=date('Y-m-d h i s A'); /* if changing this format please consider `check_log_exists_for_entry` method */
100
+
101
+ $arr=array_filter($arr);
102
+ return implode("_", $arr).'.log';
103
+ }
104
+ }
105
+ }
admin/classes/class-logreader.php ADDED
@@ -0,0 +1,113 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Log reading section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Logreader')){
13
+ class Wt_Import_Export_For_Woo_Basic_Logreader
14
+ {
15
+ private $file_path='';
16
+ private $file_pointer=null;
17
+ private $mode='';
18
+ public function __construct()
19
+ {
20
+
21
+ }
22
+ public function init($file_path, $mode="r")
23
+ {
24
+ $this->file_path=$file_path;
25
+ $this->mode=$mode;
26
+ $this->file_pointer=@fopen($file_path, 'r');
27
+ }
28
+ public function close_file_pointer()
29
+ {
30
+ if($this->file_pointer!=null)
31
+ {
32
+ fclose($this->file_pointer);
33
+ }
34
+ }
35
+
36
+ public function get_full_data($file_path)
37
+ {
38
+ $out=array(
39
+ 'response'=>false,
40
+ 'data_str'=>'',
41
+ );
42
+ $this->init($file_path);
43
+ if(!is_resource($this->file_pointer))
44
+ {
45
+ return $out;
46
+ }
47
+ $data=fread($this->file_pointer, filesize($file_path));
48
+
49
+ $this->close_file_pointer();
50
+
51
+ $out=array(
52
+ 'response'=>false,
53
+ 'data_str'=>$data,
54
+ );
55
+ return $out;
56
+ }
57
+
58
+ /**
59
+ * Read log file as batch
60
+ * @param string path of file to read
61
+ * @param int offset in bytes. default 0
62
+ * @param int total row in a batch. default 50
63
+ * @return array response, next offset, data array, finished or not flag
64
+ */
65
+ public function get_data_as_batch($file_path, $offset=0, $batch_count=50)
66
+ {
67
+ $out=array(
68
+ 'response'=>false,
69
+ 'offset'=>$offset,
70
+ 'data_arr'=>array(),
71
+ 'finished'=>false, //end of file reached or not
72
+ );
73
+ $this->init($file_path);
74
+ if(!is_resource($this->file_pointer))
75
+ {
76
+ return $out;
77
+ }
78
+
79
+ fseek($this->file_pointer, $offset);
80
+ $row_count=0;
81
+ $next_offset=$offset;
82
+ $finished=false;
83
+ $data_arr=array();
84
+ while(($data=fgets($this->file_pointer))!==false)
85
+ {
86
+ $data=maybe_unserialize($data);
87
+ if(is_array($data))
88
+ {
89
+ $data_arr[]=$data;
90
+ $row_count++;
91
+ $next_offset=ftell($this->file_pointer);
92
+ }
93
+ if($row_count==$batch_count)
94
+ {
95
+ break;
96
+ }
97
+ }
98
+ if($next_offset==filesize($file_path))
99
+ {
100
+ $finished=true;
101
+ }
102
+ $this->close_file_pointer();
103
+
104
+ $out=array(
105
+ 'response'=>true,
106
+ 'offset'=>$next_offset,
107
+ 'data_arr'=>$data_arr,
108
+ 'finished'=>$finished,
109
+ );
110
+ return $out;
111
+ }
112
+ }
113
+ }
admin/classes/class-logwriter.php ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Log writing section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Logwriter')){
13
+ class Wt_Import_Export_For_Woo_Basic_Logwriter extends Wt_Import_Export_For_Woo_Basic_Log
14
+ {
15
+ private static $file_path='';
16
+ private static $file_pointer=null;
17
+ private static $mode='';
18
+ public function __construct()
19
+ {
20
+
21
+ }
22
+ public static function init($file_path, $mode="a+")
23
+ {
24
+ self::$file_path=$file_path;
25
+ self::$mode=$mode;
26
+ self::$file_pointer=@fopen($file_path, $mode);
27
+ }
28
+ public static function write_row($text, $is_writing_finished=false)
29
+ {
30
+ if(is_null(self::$file_pointer))
31
+ {
32
+ return;
33
+ }
34
+ @fwrite(self::$file_pointer, $text.PHP_EOL);
35
+ if($is_writing_finished)
36
+ {
37
+ self::close_file_pointer();
38
+ }
39
+ }
40
+ public static function close_file_pointer()
41
+ {
42
+ if(self::$file_pointer!=null)
43
+ {
44
+ fclose(self::$file_pointer);
45
+ }
46
+ }
47
+
48
+ /**
49
+ * Debug log writing function
50
+ * @param string $post_type post type
51
+ * @param string $action_type action type
52
+ * @param mixed $data array/string of data to write
53
+ */
54
+ public static function write_log($post_type, $action_type, $data)
55
+ {
56
+ /**
57
+ * Checks log file created for the current day
58
+ */
59
+ $old_file_name=self::check_log_exists_for_entry(self::$history_id);
60
+ if(!$old_file_name)
61
+ {
62
+ $file_name=self::generate_file_name($post_type, $action_type, self::$history_id);
63
+ }else
64
+ {
65
+ $file_name=$old_file_name;
66
+ }
67
+ $file_path=self::get_file_path($file_name);
68
+ self::init($file_path);
69
+ $date_string=date_i18n('m-d-Y @ H:i:s');
70
+ if(is_array($data))
71
+ {
72
+ foreach ($data as $value)
73
+ {
74
+ self::write_row($date_string." - ".maybe_serialize($value));
75
+ }
76
+ }else
77
+ {
78
+ self::write_row($date_string." - ".$data);
79
+ }
80
+ }
81
+
82
+ /**
83
+ * Import response log
84
+ * @param array $data array/string of import response data
85
+ * @param string $file_path import log file
86
+ */
87
+ public static function write_import_log($data_arr, $file_path)
88
+ {
89
+ self::init($file_path);
90
+ foreach($data_arr as $key => $data)
91
+ {
92
+ self::write_row(maybe_serialize($data));
93
+ }
94
+ self::close_file_pointer();
95
+ }
96
+ }
97
+ }
admin/css/images/ui-bg_flat_0_aaaaaa_40x100.png ADDED
Binary file
admin/css/images/ui-bg_flat_75_ffffff_40x100.png ADDED
Binary file
admin/css/images/ui-bg_glass_55_fbf9ee_1x400.png ADDED
Binary file
admin/css/images/ui-bg_glass_65_ffffff_1x400.png ADDED
Binary file
admin/css/images/ui-bg_glass_75_dadada_1x400.png ADDED
Binary file
admin/css/images/ui-bg_glass_75_e6e6e6_1x400.png ADDED
Binary file
admin/css/images/ui-bg_glass_95_fef1ec_1x400.png ADDED
Binary file
admin/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png ADDED
Binary file
admin/css/images/ui-icons_222222_256x240.png ADDED
Binary file
admin/css/images/ui-icons_2e83ff_256x240.png ADDED
Binary file
admin/css/images/ui-icons_454545_256x240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 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*! jQuery UI - v1.9.0 - 2012-10-05
2
+ * http://jqueryui.com
3
+ * Includes: jquery.ui.core.css, jquery.ui.accordion.css, jquery.ui.autocomplete.css, jquery.ui.button.css, jquery.ui.datepicker.css, jquery.ui.dialog.css, jquery.ui.menu.css, jquery.ui.progressbar.css, jquery.ui.resizable.css, jquery.ui.selectable.css, jquery.ui.slider.css, jquery.ui.spinner.css, jquery.ui.tabs.css, jquery.ui.tooltip.css, jquery.ui.theme.css
4
+ * Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
5
+
6
+ /* Layout helpers
7
+ ----------------------------------*/
8
+ .ui-helper-hidden { display: none; }
9
+ .ui-helper-hidden-accessible { position: absolute !important; clip: rect(1px 1px 1px 1px); clip: rect(1px,1px,1px,1px); }
10
+ .ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none; }
11
+ .ui-helper-clearfix:before, .ui-helper-clearfix:after { content: ""; display: table; }
12
+ .ui-helper-clearfix:after { clear: both; }
13
+ .ui-helper-clearfix { zoom: 1; }
14
+ .ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter:Alpha(Opacity=0); }
15
+
16
+
17
+ /* Interaction Cues
18
+ ----------------------------------*/
19
+ .ui-state-disabled { cursor: default !important; }
20
+
21
+
22
+ /* Icons
23
+ ----------------------------------*/
24
+
25
+ /* states and images */
26
+ .ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
27
+
28
+
29
+ /* Misc visuals
30
+ ----------------------------------*/
31
+
32
+ /* Overlays */
33
+ .ui-widget-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
34
+
35
+ .ui-accordion .ui-accordion-header { display: block; cursor: pointer; position: relative; margin-top: 2px; padding: .5em .5em .5em .7em; zoom: 1; }
36
+ .ui-accordion .ui-accordion-icons { padding-left: 2.2em; }
37
+ .ui-accordion .ui-accordion-noicons { padding-left: .7em; }
38
+ .ui-accordion .ui-accordion-icons .ui-accordion-icons { padding-left: 2.2em; }
39
+ .ui-accordion .ui-accordion-header .ui-accordion-header-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
40
+ .ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; overflow: auto; zoom: 1; }
41
+
42
+ .ui-autocomplete { position: absolute; cursor: default; }
43
+
44
+ /* workarounds */
45
+ * html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
46
+
47
+ .ui-button { display: inline-block; position: relative; padding: 0; margin-right: .1em; cursor: pointer; text-align: center; zoom: 1; overflow: visible; } /* the overflow property removes extra width in IE */
48
+ .ui-button, .ui-button:link, .ui-button:visited, .ui-button:hover, .ui-button:active { text-decoration: none; }
49
+ .ui-button-icon-only { width: 2.2em; } /* to make room for the icon, a width needs to be set here */
50
+ button.ui-button-icon-only { width: 2.4em; } /* button elements seem to need a little more width */
51
+ .ui-button-icons-only { width: 3.4em; }
52
+ button.ui-button-icons-only { width: 3.7em; }
53
+
54
+ /*button text element */
55
+ .ui-button .ui-button-text { display: block; line-height: 1.4; }
56
+ .ui-button-text-only .ui-button-text { padding: .4em 1em; }
57
+ .ui-button-icon-only .ui-button-text, .ui-button-icons-only .ui-button-text { padding: .4em; text-indent: -9999999px; }
58
+ .ui-button-text-icon-primary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 1em .4em 2.1em; }
59
+ .ui-button-text-icon-secondary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 2.1em .4em 1em; }
60
+ .ui-button-text-icons .ui-button-text { padding-left: 2.1em; padding-right: 2.1em; }
61
+ /* no icon support for input elements, provide padding by default */
62
+ input.ui-button { padding: .4em 1em; }
63
+
64
+ /*button icon element(s) */
65
+ .ui-button-icon-only .ui-icon, .ui-button-text-icon-primary .ui-icon, .ui-button-text-icon-secondary .ui-icon, .ui-button-text-icons .ui-icon, .ui-button-icons-only .ui-icon { position: absolute; top: 50%; margin-top: -8px; }
66
+ .ui-button-icon-only .ui-icon { left: 50%; margin-left: -8px; }
67
+ .ui-button-text-icon-primary .ui-button-icon-primary, .ui-button-text-icons .ui-button-icon-primary, .ui-button-icons-only .ui-button-icon-primary { left: .5em; }
68
+ .ui-button-text-icon-secondary .ui-button-icon-secondary, .ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
69
+ .ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
70
+
71
+ /*button sets*/
72
+ .ui-buttonset { margin-right: 7px; }
73
+ .ui-buttonset .ui-button { margin-left: 0; margin-right: -.3em; }
74
+
75
+ /* workarounds */
76
+ button.ui-button::-moz-focus-inner { border: 0; padding: 0; } /* reset extra padding in Firefox */
77
+
78
+ .ui-datepicker { width: 17em; padding: .2em .2em 0; display: none; }
79
+ .ui-datepicker .ui-datepicker-header { position:relative; padding:.2em 0; }
80
+ .ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { position:absolute; top: 2px; width: 1.8em; height: 1.8em; }
81
+ .ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker .ui-datepicker-next-hover { top: 1px; }
82
+ .ui-datepicker .ui-datepicker-prev { left:2px; }
83
+ .ui-datepicker .ui-datepicker-next { right:2px; }
84
+ .ui-datepicker .ui-datepicker-prev-hover { left:1px; }
85
+ .ui-datepicker .ui-datepicker-next-hover { right:1px; }
86
+ .ui-datepicker .ui-datepicker-prev span, .ui-datepicker .ui-datepicker-next span { display: block; position: absolute; left: 50%; margin-left: -8px; top: 50%; margin-top: -8px; }
87
+ .ui-datepicker .ui-datepicker-title { margin: 0 2.3em; line-height: 1.8em; text-align: center; }
88
+ .ui-datepicker .ui-datepicker-title select { font-size:1em; margin:1px 0; }
89
+ .ui-datepicker select.ui-datepicker-month-year {width: 100%;}
90
+ .ui-datepicker select.ui-datepicker-month,
91
+ .ui-datepicker select.ui-datepicker-year { width: 49%;}
92
+ .ui-datepicker table {width: 100%; font-size: .9em; border-collapse: collapse; margin:0 0 .4em; }
93
+ .ui-datepicker th { padding: .7em .3em; text-align: center; font-weight: bold; border: 0; }
94
+ .ui-datepicker td { border: 0; padding: 1px; }
95
+ .ui-datepicker td span, .ui-datepicker td a { display: block; padding: .2em; text-align: right; text-decoration: none; }
96
+ .ui-datepicker .ui-datepicker-buttonpane { background-image: none; margin: .7em 0 0 0; padding:0 .2em; border-left: 0; border-right: 0; border-bottom: 0; }
97
+ .ui-datepicker .ui-datepicker-buttonpane button { float: right; margin: .5em .2em .4em; cursor: pointer; padding: .2em .6em .3em .6em; width:auto; overflow:visible; }
98
+ .ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { float:left; }
99
+
100
+ /* with multiple calendars */
101
+ .ui-datepicker.ui-datepicker-multi { width:auto; }
102
+ .ui-datepicker-multi .ui-datepicker-group { float:left; }
103
+ .ui-datepicker-multi .ui-datepicker-group table { width:95%; margin:0 auto .4em; }
104
+ .ui-datepicker-multi-2 .ui-datepicker-group { width:50%; }
105
+ .ui-datepicker-multi-3 .ui-datepicker-group { width:33.3%; }
106
+ .ui-datepicker-multi-4 .ui-datepicker-group { width:25%; }
107
+ .ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header { border-left-width:0; }
108
+ .ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { border-left-width:0; }
109
+ .ui-datepicker-multi .ui-datepicker-buttonpane { clear:left; }
110
+ .ui-datepicker-row-break { clear:both; width:100%; font-size:0em; }
111
+
112
+ /* RTL support */
113
+ .ui-datepicker-rtl { direction: rtl; }
114
+ .ui-datepicker-rtl .ui-datepicker-prev { right: 2px; left: auto; }
115
+ .ui-datepicker-rtl .ui-datepicker-next { left: 2px; right: auto; }
116
+ .ui-datepicker-rtl .ui-datepicker-prev:hover { right: 1px; left: auto; }
117
+ .ui-datepicker-rtl .ui-datepicker-next:hover { left: 1px; right: auto; }
118
+ .ui-datepicker-rtl .ui-datepicker-buttonpane { clear:right; }
119
+ .ui-datepicker-rtl .ui-datepicker-buttonpane button { float: left; }
120
+ .ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current { float:right; }
121
+ .ui-datepicker-rtl .ui-datepicker-group { float:right; }
122
+ .ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
123
+ .ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
124
+
125
+ /* IE6 IFRAME FIX (taken from datepicker 1.5.3 */
126
+ .ui-datepicker-cover {
127
+ position: absolute; /*must have*/
128
+ z-index: -1; /*must have*/
129
+ filter: mask(); /*must have*/
130
+ top: -4px; /*must have*/
131
+ left: -4px; /*must have*/
132
+ width: 200px; /*must have*/
133
+ height: 200px; /*must have*/
134
+ }
135
+ .ui-dialog { position: absolute; padding: .2em; width: 300px; overflow: hidden; }
136
+ .ui-dialog .ui-dialog-titlebar { padding: .4em 1em; position: relative; }
137
+ .ui-dialog .ui-dialog-title { float: left; margin: .1em 16px .1em 0; }
138
+ .ui-dialog .ui-dialog-titlebar-close { position: absolute; right: .3em; top: 50%; width: 19px; margin: -10px 0 0 0; padding: 1px; height: 18px; }
139
+ .ui-dialog .ui-dialog-titlebar-close span { display: block; margin: 1px; }
140
+ .ui-dialog .ui-dialog-titlebar-close:hover, .ui-dialog .ui-dialog-titlebar-close:focus { padding: 0; }
141
+ .ui-dialog .ui-dialog-content { position: relative; border: 0; padding: .5em 1em; background: none; overflow: auto; zoom: 1; }
142
+ .ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin: .5em 0 0 0; padding: .3em 1em .5em .4em; }
143
+ .ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { float: right; }
144
+ .ui-dialog .ui-dialog-buttonpane button { margin: .5em .4em .5em 0; cursor: pointer; }
145
+ .ui-dialog .ui-resizable-se { width: 14px; height: 14px; right: 3px; bottom: 3px; }
146
+ .ui-draggable .ui-dialog-titlebar { cursor: move; }
147
+
148
+ .ui-menu { list-style:none; padding: 2px; margin: 0; display:block; outline: none; }
149
+ .ui-menu .ui-menu { margin-top: -3px; position: absolute; }
150
+ .ui-menu .ui-menu-item { margin: 0; padding: 0; zoom: 1; width: 100%; }
151
+ .ui-menu .ui-menu-divider { margin: 5px -2px 5px -2px; height: 0; font-size: 0; line-height: 0; border-width: 1px 0 0 0; }
152
+ .ui-menu .ui-menu-item a { text-decoration: none; display: block; padding: 2px .4em; line-height: 1.5; zoom: 1; font-weight: normal; }
153
+ .ui-menu .ui-menu-item a.ui-state-focus,
154
+ .ui-menu .ui-menu-item a.ui-state-active { font-weight: normal; margin: -1px; }
155
+
156
+ .ui-menu .ui-state-disabled { font-weight: normal; margin: .4em 0 .2em; line-height: 1.5; }
157
+ .ui-menu .ui-state-disabled a { cursor: default; }
158
+
159
+ /* icon support */
160
+ .ui-menu-icons { position: relative; }
161
+ .ui-menu-icons .ui-menu-item a { position: relative; padding-left: 2em; }
162
+
163
+ /* left-aligned */
164
+ .ui-menu .ui-icon { position: absolute; top: .2em; left: .2em; }
165
+
166
+ /* right-aligned */
167
+ .ui-menu .ui-menu-icon { position: static; float: right; }
168
+
169
+ .ui-progressbar { height:2em; text-align: left; overflow: hidden; }
170
+ .ui-progressbar .ui-progressbar-value {margin: -1px; height:100%; }
171
+ .ui-resizable { position: relative;}
172
+ .ui-resizable-handle { position: absolute;font-size: 0.1px; display: block; }
173
+ .ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
174
+ .ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0; }
175
+ .ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0; }
176
+ .ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%; }
177
+ .ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%; }
178
+ .ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
179
+ .ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
180
+ .ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
181
+ .ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px;}
182
+ .ui-selectable-helper { position: absolute; z-index: 100; border:1px dotted black; }
183
+
184
+ .ui-slider { position: relative; text-align: left; }
185
+ .ui-slider .ui-slider-handle { position: absolute; z-index: 2; width: 1.2em; height: 1.2em; cursor: default; }
186
+ .ui-slider .ui-slider-range { position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0; }
187
+
188
+ .ui-slider-horizontal { height: .8em; }
189
+ .ui-slider-horizontal .ui-slider-handle { top: -.3em; margin-left: -.6em; }
190
+ .ui-slider-horizontal .ui-slider-range { top: 0; height: 100%; }
191
+ .ui-slider-horizontal .ui-slider-range-min { left: 0; }
192
+ .ui-slider-horizontal .ui-slider-range-max { right: 0; }
193
+
194
+ .ui-slider-vertical { width: .8em; height: 100px; }
195
+ .ui-slider-vertical .ui-slider-handle { left: -.3em; margin-left: 0; margin-bottom: -.6em; }
196
+ .ui-slider-vertical .ui-slider-range { left: 0; width: 100%; }
197
+ .ui-slider-vertical .ui-slider-range-min { bottom: 0; }
198
+ .ui-slider-vertical .ui-slider-range-max { top: 0; }
199
+ .ui-spinner { position:relative; display: inline-block; overflow: hidden; padding: 0; vertical-align: middle; }
200
+ .ui-spinner-input { border: none; background: none; padding: 0; margin: .2em 0; vertical-align: middle; margin-left: .4em; margin-right: 22px; }
201
+ .ui-spinner-button { width: 16px; height: 50%; font-size: .5em; padding: 0; margin: 0; z-index: 100; text-align: center; position: absolute; cursor: default; display: block; overflow: hidden; right: 0; }
202
+ .ui-spinner a.ui-spinner-button { border-top: none; border-bottom: none; border-right: none; } /* more specificity required here to overide default borders */
203
+ .ui-spinner .ui-icon { position: absolute; margin-top: -8px; top: 50%; left: 0; } /* vertical centre icon */
204
+ .ui-spinner-up { top: 0; }
205
+ .ui-spinner-down { bottom: 0; }
206
+
207
+ /* TR overrides */
208
+ span.ui-spinner { background: none; }
209
+ .ui-spinner .ui-icon-triangle-1-s {
210
+ /* need to fix icons sprite */
211
+ background-position:-65px -16px;
212
+ }
213
+
214
+ .ui-tabs { position: relative; padding: .2em; zoom: 1; } /* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
215
+ .ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0; }
216
+ .ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 0; margin: 1px .2em 0 0; border-bottom: 0; padding: 0; white-space: nowrap; }
217
+ .ui-tabs .ui-tabs-nav li a { float: left; padding: .5em 1em; text-decoration: none; }
218
+ .ui-tabs .ui-tabs-nav li.ui-tabs-active { margin-bottom: -1px; padding-bottom: 1px; }
219
+ .ui-tabs .ui-tabs-nav li.ui-tabs-active a, .ui-tabs .ui-tabs-nav li.ui-state-disabled a, .ui-tabs .ui-tabs-nav li.ui-tabs-loading a { cursor: text; }
220
+ .ui-tabs .ui-tabs-nav li a, .ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a { cursor: pointer; } /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
221
+ .ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none; }
222
+
223
+ .ui-tooltip {
224
+ padding:8px;
225
+ position:absolute;
226
+ z-index:9999;
227
+ -o-box-shadow: 0 0 5px #aaa;
228
+ -moz-box-shadow: 0 0 5px #aaa;
229
+ -webkit-box-shadow: 0 0 5px #aaa;
230
+ box-shadow: 0 0 5px #aaa;
231
+ }
232
+ /* Fades and background-images don't work well together in IE6, drop the image */
233
+ * html .ui-tooltip {
234
+ background-image: none;
235
+ }
236
+ body .ui-tooltip { border-width:2px; }
237
+
238
+ /* Component containers
239
+ ----------------------------------*/
240
+ .ui-widget { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1.1em/*{fsDefault}*/; }
241
+ .ui-widget .ui-widget { font-size: 1em; }
242
+ .ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1em; }
243
+ .ui-widget-content { border: 1px solid #aaaaaa/*{borderColorContent}*/; background: #ffffff/*{bgColorContent}*/ url(images/ui-bg_flat_75_ffffff_40x100.png)/*{bgImgUrlContent}*/ 50%/*{bgContentXPos}*/ 50%/*{bgContentYPos}*/ repeat-x/*{bgContentRepeat}*/; color: #222222/*{fcContent}*/; }
244
+ .ui-widget-content a { color: #222222/*{fcContent}*/; }
245
+ .ui-widget-header { border: 1px solid #aaaaaa/*{borderColorHeader}*/; background: #cccccc/*{bgColorHeader}*/ url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)/*{bgImgUrlHeader}*/ 50%/*{bgHeaderXPos}*/ 50%/*{bgHeaderYPos}*/ repeat-x/*{bgHeaderRepeat}*/; color: #222222/*{fcHeader}*/; font-weight: bold; }
246
+ .ui-widget-header a { color: #222222/*{fcHeader}*/; }
247
+
248
+ /* Interaction states
249
+ ----------------------------------*/
250
+ .ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #d3d3d3/*{borderColorDefault}*/; background: #e6e6e6/*{bgColorDefault}*/ url(images/ui-bg_glass_75_e6e6e6_1x400.png)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #555555/*{fcDefault}*/; }
251
+ .ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #555555/*{fcDefault}*/; text-decoration: none; }
252
+ .ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 1px solid #999999/*{borderColorHover}*/; background: #dadada/*{bgColorHover}*/ url(images/ui-bg_glass_75_dadada_1x400.png)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcHover}*/; }
253
+ .ui-state-hover a, .ui-state-hover a:hover { color: #212121/*{fcHover}*/; text-decoration: none; }
254
+ .ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #aaaaaa/*{borderColorActive}*/; background: #ffffff/*{bgColorActive}*/ url(images/ui-bg_glass_65_ffffff_1x400.png)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcActive}*/; }
255
+ .ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #212121/*{fcActive}*/; text-decoration: none; }
256
+
257
+ /* Interaction Cues
258
+ ----------------------------------*/
259
+ .ui-state-highlight, .ui-widget-content .ui-state-highlight, .ui-widget-header .ui-state-highlight {border: 1px solid #fcefa1/*{borderColorHighlight}*/; background: #fbf9ee/*{bgColorHighlight}*/ url(images/ui-bg_glass_55_fbf9ee_1x400.png)/*{bgImgUrlHighlight}*/ 50%/*{bgHighlightXPos}*/ 50%/*{bgHighlightYPos}*/ repeat-x/*{bgHighlightRepeat}*/; color: #363636/*{fcHighlight}*/; }
260
+ .ui-state-highlight a, .ui-widget-content .ui-state-highlight a,.ui-widget-header .ui-state-highlight a { color: #363636/*{fcHighlight}*/; }
261
+ .ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {border: 1px solid #cd0a0a/*{borderColorError}*/; background: #fef1ec/*{bgColorError}*/ url(images/ui-bg_glass_95_fef1ec_1x400.png)/*{bgImgUrlError}*/ 50%/*{bgErrorXPos}*/ 50%/*{bgErrorYPos}*/ repeat-x/*{bgErrorRepeat}*/; color: #cd0a0a/*{fcError}*/; }
262
+ .ui-state-error a, .ui-widget-content .ui-state-error a, .ui-widget-header .ui-state-error a { color: #cd0a0a/*{fcError}*/; }
263
+ .ui-state-error-text, .ui-widget-content .ui-state-error-text, .ui-widget-header .ui-state-error-text { color: #cd0a0a/*{fcError}*/; }
264
+ .ui-priority-primary, .ui-widget-content .ui-priority-primary, .ui-widget-header .ui-priority-primary { font-weight: bold; }
265
+ .ui-priority-secondary, .ui-widget-content .ui-priority-secondary, .ui-widget-header .ui-priority-secondary { opacity: .7; filter:Alpha(Opacity=70); font-weight: normal; }
266
+ .ui-state-disabled, .ui-widget-content .ui-state-disabled, .ui-widget-header .ui-state-disabled { opacity: .35; filter:Alpha(Opacity=35); background-image: none; }
267
+
268
+ /* Icons
269
+ ----------------------------------*/
270
+
271
+ /* states and images */
272
+ .ui-icon { width: 16px; height: 16px; background-image: url(images/ui-icons_222222_256x240.png)/*{iconsContent}*/; }
273
+ .ui-widget-content .ui-icon {background-image: url(images/ui-icons_222222_256x240.png)/*{iconsContent}*/; }
274
+ .ui-widget-header .ui-icon {background-image: url(images/ui-icons_222222_256x240.png)/*{iconsHeader}*/; }
275
+ .ui-state-default .ui-icon { background-image: url(images/ui-icons_888888_256x240.png)/*{iconsDefault}*/; }
276
+ .ui-state-hover .ui-icon, .ui-state-focus .ui-icon {background-image: url(images/ui-icons_454545_256x240.png)/*{iconsHover}*/; }
277
+ .ui-state-active .ui-icon {background-image: url(images/ui-icons_454545_256x240.png)/*{iconsActive}*/; }
278
+ .ui-state-highlight .ui-icon {background-image: url(images/ui-icons_2e83ff_256x240.png)/*{iconsHighlight}*/; }
279
+ .ui-state-error .ui-icon, .ui-state-error-text .ui-icon {background-image: url(images/ui-icons_cd0a0a_256x240.png)/*{iconsError}*/; }
280
+
281
+ /* positioning */
282
+ .ui-icon-carat-1-n { background-position: 0 0; }
283
+ .ui-icon-carat-1-ne { background-position: -16px 0; }
284
+ .ui-icon-carat-1-e { background-position: -32px 0; }
285
+ .ui-icon-carat-1-se { background-position: -48px 0; }
286
+ .ui-icon-carat-1-s { background-position: -64px 0; }
287
+ .ui-icon-carat-1-sw { background-position: -80px 0; }
288
+ .ui-icon-carat-1-w { background-position: -96px 0; }
289
+ .ui-icon-carat-1-nw { background-position: -112px 0; }
290
+ .ui-icon-carat-2-n-s { background-position: -128px 0; }
291
+ .ui-icon-carat-2-e-w { background-position: -144px 0; }
292
+ .ui-icon-triangle-1-n { background-position: 0 -16px; }
293
+ .ui-icon-triangle-1-ne { background-position: -16px -16px; }
294
+ .ui-icon-triangle-1-e { background-position: -32px -16px; }
295
+ .ui-icon-triangle-1-se { background-position: -48px -16px; }
296
+ .ui-icon-triangle-1-s { background-position: -64px -16px; }
297
+ .ui-icon-triangle-1-sw { background-position: -80px -16px; }
298
+ .ui-icon-triangle-1-w { background-position: -96px -16px; }
299
+ .ui-icon-triangle-1-nw { background-position: -112px -16px; }
300
+ .ui-icon-triangle-2-n-s { background-position: -128px -16px; }
301
+ .ui-icon-triangle-2-e-w { background-position: -144px -16px; }
302
+ .ui-icon-arrow-1-n { background-position: 0 -32px; }
303
+ .ui-icon-arrow-1-ne { background-position: -16px -32px; }
304
+ .ui-icon-arrow-1-e { background-position: -32px -32px; }
305
+ .ui-icon-arrow-1-se { background-position: -48px -32px; }
306
+ .ui-icon-arrow-1-s { background-position: -64px -32px; }
307
+ .ui-icon-arrow-1-sw { background-position: -80px -32px; }
308
+ .ui-icon-arrow-1-w { background-position: -96px -32px; }
309
+ .ui-icon-arrow-1-nw { background-position: -112px -32px; }
310
+ .ui-icon-arrow-2-n-s { background-position: -128px -32px; }
311
+ .ui-icon-arrow-2-ne-sw { background-position: -144px -32px; }
312
+ .ui-icon-arrow-2-e-w { background-position: -160px -32px; }
313
+ .ui-icon-arrow-2-se-nw { background-position: -176px -32px; }
314
+ .ui-icon-arrowstop-1-n { background-position: -192px -32px; }
315
+ .ui-icon-arrowstop-1-e { background-position: -208px -32px; }
316
+ .ui-icon-arrowstop-1-s { background-position: -224px -32px; }
317
+ .ui-icon-arrowstop-1-w { background-position: -240px -32px; }
318
+ .ui-icon-arrowthick-1-n { background-position: 0 -48px; }
319
+ .ui-icon-arrowthick-1-ne { background-position: -16px -48px; }
320
+ .ui-icon-arrowthick-1-e { background-position: -32px -48px; }
321
+ .ui-icon-arrowthick-1-se { background-position: -48px -48px; }
322
+ .ui-icon-arrowthick-1-s { background-position: -64px -48px; }
323
+ .ui-icon-arrowthick-1-sw { background-position: -80px -48px; }
324
+ .ui-icon-arrowthick-1-w { background-position: -96px -48px; }
325
+ .ui-icon-arrowthick-1-nw { background-position: -112px -48px; }
326
+ .ui-icon-arrowthick-2-n-s { background-position: -128px -48px; }
327
+ .ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; }
328
+ .ui-icon-arrowthick-2-e-w { background-position: -160px -48px; }
329
+ .ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; }
330
+ .ui-icon-arrowthickstop-1-n { background-position: -192px -48px; }
331
+ .ui-icon-arrowthickstop-1-e { background-position: -208px -48px; }
332
+ .ui-icon-arrowthickstop-1-s { background-position: -224px -48px; }
333
+ .ui-icon-arrowthickstop-1-w { background-position: -240px -48px; }
334
+ .ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; }
335
+ .ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; }
336
+ .ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; }
337
+ .ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; }
338
+ .ui-icon-arrowreturn-1-w { background-position: -64px -64px; }
339
+ .ui-icon-arrowreturn-1-n { background-position: -80px -64px; }
340
+ .ui-icon-arrowreturn-1-e { background-position: -96px -64px; }
341
+ .ui-icon-arrowreturn-1-s { background-position: -112px -64px; }
342
+ .ui-icon-arrowrefresh-1-w { background-position: -128px -64px; }
343
+ .ui-icon-arrowrefresh-1-n { background-position: -144px -64px; }
344
+ .ui-icon-arrowrefresh-1-e { background-position: -160px -64px; }
345
+ .ui-icon-arrowrefresh-1-s { background-position: -176px -64px; }
346
+ .ui-icon-arrow-4 { background-position: 0 -80px; }
347
+ .ui-icon-arrow-4-diag { background-position: -16px -80px; }
348
+ .ui-icon-extlink { background-position: -32px -80px; }
349
+ .ui-icon-newwin { background-position: -48px -80px; }
350
+ .ui-icon-refresh { background-position: -64px -80px; }
351
+ .ui-icon-shuffle { background-position: -80px -80px; }
352
+ .ui-icon-transfer-e-w { background-position: -96px -80px; }
353
+ .ui-icon-transferthick-e-w { background-position: -112px -80px; }
354
+ .ui-icon-folder-collapsed { background-position: 0 -96px; }
355
+ .ui-icon-folder-open { background-position: -16px -96px; }
356
+ .ui-icon-document { background-position: -32px -96px; }
357
+ .ui-icon-document-b { background-position: -48px -96px; }
358
+ .ui-icon-note { background-position: -64px -96px; }
359
+ .ui-icon-mail-closed { background-position: -80px -96px; }
360
+ .ui-icon-mail-open { background-position: -96px -96px; }
361
+ .ui-icon-suitcase { background-position: -112px -96px; }
362
+ .ui-icon-comment { background-position: -128px -96px; }
363
+ .ui-icon-person { background-position: -144px -96px; }
364
+ .ui-icon-print { background-position: -160px -96px; }
365
+ .ui-icon-trash { background-position: -176px -96px; }
366
+ .ui-icon-locked { background-position: -192px -96px; }
367
+ .ui-icon-unlocked { background-position: -208px -96px; }
368
+ .ui-icon-bookmark { background-position: -224px -96px; }
369
+ .ui-icon-tag { background-position: -240px -96px; }
370
+ .ui-icon-home { background-position: 0 -112px; }
371
+ .ui-icon-flag { background-position: -16px -112px; }
372
+ .ui-icon-calendar { background-position: -32px -112px; }
373
+ .ui-icon-cart { background-position: -48px -112px; }
374
+ .ui-icon-pencil { background-position: -64px -112px; }
375
+ .ui-icon-clock { background-position: -80px -112px; }
376
+ .ui-icon-disk { background-position: -96px -112px; }
377
+ .ui-icon-calculator { background-position: -112px -112px; }
378
+ .ui-icon-zoomin { background-position: -128px -112px; }
379
+ .ui-icon-zoomout { background-position: -144px -112px; }
380
+ .ui-icon-search { background-position: -160px -112px; }
381
+ .ui-icon-wrench { background-position: -176px -112px; }
382
+ .ui-icon-gear { background-position: -192px -112px; }
383
+ .ui-icon-heart { background-position: -208px -112px; }
384
+ .ui-icon-star { background-position: -224px -112px; }
385
+ .ui-icon-link { background-position: -240px -112px; }
386
+ .ui-icon-cancel { background-position: 0 -128px; }
387
+ .ui-icon-plus { background-position: -16px -128px; }
388
+ .ui-icon-plusthick { background-position: -32px -128px; }
389
+ .ui-icon-minus { background-position: -48px -128px; }
390
+ .ui-icon-minusthick { background-position: -64px -128px; }
391
+ .ui-icon-close { background-position: -80px -128px; }
392
+ .ui-icon-closethick { background-position: -96px -128px; }
393
+ .ui-icon-key { background-position: -112px -128px; }
394
+ .ui-icon-lightbulb { background-position: -128px -128px; }
395
+ .ui-icon-scissors { background-position: -144px -128px; }
396
+ .ui-icon-clipboard { background-position: -160px -128px; }
397
+ .ui-icon-copy { background-position: -176px -128px; }
398
+ .ui-icon-contact { background-position: -192px -128px; }
399
+ .ui-icon-image { background-position: -208px -128px; }
400
+ .ui-icon-video { background-position: -224px -128px; }
401
+ .ui-icon-script { background-position: -240px -128px; }
402
+ .ui-icon-alert { background-position: 0 -144px; }
403
+ .ui-icon-info { background-position: -16px -144px; }
404
+ .ui-icon-notice { background-position: -32px -144px; }
405
+ .ui-icon-help { background-position: -48px -144px; }
406
+ .ui-icon-check { background-position: -64px -144px; }
407
+ .ui-icon-bullet { background-position: -80px -144px; }
408
+ .ui-icon-radio-on { background-position: -96px -144px; }
409
+ .ui-icon-radio-off { background-position: -112px -144px; }
410
+ .ui-icon-pin-w { background-position: -128px -144px; }
411
+ .ui-icon-pin-s { background-position: -144px -144px; }
412
+ .ui-icon-play { background-position: 0 -160px; }
413
+ .ui-icon-pause { background-position: -16px -160px; }
414
+ .ui-icon-seek-next { background-position: -32px -160px; }
415
+ .ui-icon-seek-prev { background-position: -48px -160px; }
416
+ .ui-icon-seek-end { background-position: -64px -160px; }
417
+ .ui-icon-seek-start { background-position: -80px -160px; }
418
+ /* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */
419
+ .ui-icon-seek-first { background-position: -80px -160px; }
420
+ .ui-icon-stop { background-position: -96px -160px; }
421
+ .ui-icon-eject { background-position: -112px -160px; }
422
+ .ui-icon-volume-off { background-position: -128px -160px; }
423
+ .ui-icon-volume-on { background-position: -144px -160px; }
424
+ .ui-icon-power { background-position: 0 -176px; }
425
+ .ui-icon-signal-diag { background-position: -16px -176px; }
426
+ .ui-icon-signal { background-position: -32px -176px; }
427
+ .ui-icon-battery-0 { background-position: -48px -176px; }
428
+ .ui-icon-battery-1 { background-position: -64px -176px; }
429
+ .ui-icon-battery-2 { background-position: -80px -176px; }
430
+ .ui-icon-battery-3 { background-position: -96px -176px; }
431
+ .ui-icon-circle-plus { background-position: 0 -192px; }
432
+ .ui-icon-circle-minus { background-position: -16px -192px; }
433
+ .ui-icon-circle-close { background-position: -32px -192px; }
434
+ .ui-icon-circle-triangle-e { background-position: -48px -192px; }
435
+ .ui-icon-circle-triangle-s { background-position: -64px -192px; }
436
+ .ui-icon-circle-triangle-w { background-position: -80px -192px; }
437
+ .ui-icon-circle-triangle-n { background-position: -96px -192px; }
438
+ .ui-icon-circle-arrow-e { background-position: -112px -192px; }
439
+ .ui-icon-circle-arrow-s { background-position: -128px -192px; }
440
+ .ui-icon-circle-arrow-w { background-position: -144px -192px; }
441
+ .ui-icon-circle-arrow-n { background-position: -160px -192px; }
442
+ .ui-icon-circle-zoomin { background-position: -176px -192px; }
443
+ .ui-icon-circle-zoomout { background-position: -192px -192px; }
444
+ .ui-icon-circle-check { background-position: -208px -192px; }
445
+ .ui-icon-circlesmall-plus { background-position: 0 -208px; }
446
+ .ui-icon-circlesmall-minus { background-position: -16px -208px; }
447
+ .ui-icon-circlesmall-close { background-position: -32px -208px; }
448
+ .ui-icon-squaresmall-plus { background-position: -48px -208px; }
449
+ .ui-icon-squaresmall-minus { background-position: -64px -208px; }
450
+ .ui-icon-squaresmall-close { background-position: -80px -208px; }
451
+ .ui-icon-grip-dotted-vertical { background-position: 0 -224px; }
452
+ .ui-icon-grip-dotted-horizontal { background-position: -16px -224px; }
453
+ .ui-icon-grip-solid-vertical { background-position: -32px -224px; }
454
+ .ui-icon-grip-solid-horizontal { background-position: -48px -224px; }
455
+ .ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; }
456
+ .ui-icon-grip-diagonal-se { background-position: -80px -224px; }
457
+
458
+
459
+ /* Misc visuals
460
+ ----------------------------------*/
461
+
462
+ /* Corner radius */
463
+ .ui-corner-all, .ui-corner-top, .ui-corner-left, .ui-corner-tl { -moz-border-radius-topleft: 4px/*{cornerRadius}*/; -webkit-border-top-left-radius: 4px/*{cornerRadius}*/; -khtml-border-top-left-radius: 4px/*{cornerRadius}*/; border-top-left-radius: 4px/*{cornerRadius}*/; }
464
+ .ui-corner-all, .ui-corner-top, .ui-corner-right, .ui-corner-tr { -moz-border-radius-topright: 4px/*{cornerRadius}*/; -webkit-border-top-right-radius: 4px/*{cornerRadius}*/; -khtml-border-top-right-radius: 4px/*{cornerRadius}*/; border-top-right-radius: 4px/*{cornerRadius}*/; }
465
+ .ui-corner-all, .ui-corner-bottom, .ui-corner-left, .ui-corner-bl { -moz-border-radius-bottomleft: 4px/*{cornerRadius}*/; -webkit-border-bottom-left-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-left-radius: 4px/*{cornerRadius}*/; border-bottom-left-radius: 4px/*{cornerRadius}*/; }
466
+ .ui-corner-all, .ui-corner-bottom, .ui-corner-right, .ui-corner-br { -moz-border-radius-bottomright: 4px/*{cornerRadius}*/; -webkit-border-bottom-right-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-right-radius: 4px/*{cornerRadius}*/; border-bottom-right-radius: 4px/*{cornerRadius}*/; }
467
+
468
+ /* Overlays */
469
+ .ui-widget-overlay { background: #aaaaaa/*{bgColorOverlay}*/ url(images/ui-bg_flat_0_aaaaaa_40x100.png)/*{bgImgUrlOverlay}*/ 50%/*{bgOverlayXPos}*/ 50%/*{bgOverlayYPos}*/ repeat-x/*{bgOverlayRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityOverlay}*/; }
470
+ .ui-widget-shadow { margin: -8px/*{offsetTopShadow}*/ 0 0 -8px/*{offsetLeftShadow}*/; padding: 8px/*{thicknessShadow}*/; background: #aaaaaa/*{bgColorShadow}*/ url(images/ui-bg_flat_0_aaaaaa_40x100.png)/*{bgImgUrlShadow}*/ 50%/*{bgShadowXPos}*/ 50%/*{bgShadowYPos}*/ repeat-x/*{bgShadowRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityShadow}*/; -moz-border-radius: 8px/*{cornerRadiusShadow}*/; -khtml-border-radius: 8px/*{cornerRadiusShadow}*/; -webkit-border-radius: 8px/*{cornerRadiusShadow}*/; border-radius: 8px/*{cornerRadiusShadow}*/; }
admin/css/select2.css ADDED
@@ -0,0 +1 @@
 
1
+ .select2-container{box-sizing:border-box;display:inline-block;margin:0;position:relative;vertical-align:middle}.select2-container .select2-selection--single{box-sizing:border-box;cursor:pointer;display:block;height:28px;user-select:none;-webkit-user-select:none}.select2-container .select2-selection--single .select2-selection__rendered{display:block;padding-left:8px;padding-right:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-selection--single .select2-selection__clear{position:relative}.select2-container[dir="rtl"] .select2-selection--single .select2-selection__rendered{padding-right:8px;padding-left:20px}.select2-container .select2-selection--multiple{box-sizing:border-box;cursor:pointer;display:block;min-height:32px;user-select:none;-webkit-user-select:none}.select2-container .select2-selection--multiple .select2-selection__rendered{display:inline-block;overflow:hidden;padding-left:8px;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-search--inline{float:left}.select2-container .select2-search--inline .select2-search__field{box-sizing:border-box;border:none;font-size:100%;margin-top:5px;padding:0}.select2-container .select2-search--inline .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-dropdown{background-color:white;border:1px solid #aaa;border-radius:4px;box-sizing:border-box;display:block;position:absolute;left:-100000px;width:100%;z-index:1051}.select2-results{display:block}.select2-results__options{list-style:none;margin:0;padding:0}.select2-results__option{padding:6px;user-select:none;-webkit-user-select:none}.select2-results__option[aria-selected]{cursor:pointer}.select2-container--open .select2-dropdown{left:0}.select2-container--open .select2-dropdown--above{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--open .select2-dropdown--below{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-search--dropdown{display:block;padding:4px}.select2-search--dropdown .select2-search__field{padding:4px;width:100%;box-sizing:border-box}.select2-search--dropdown .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-search--dropdown.select2-search--hide{display:none}.select2-close-mask{border:0;margin:0;padding:0;display:block;position:fixed;left:0;top:0;min-height:100%;min-width:100%;height:auto;width:auto;opacity:0;z-index:99;background-color:#fff;filter:alpha(opacity=0)}.select2-hidden-accessible{border:0 !important;clip:rect(0 0 0 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;height:1px !important;overflow:hidden !important;padding:0 !important;position:absolute !important;width:1px !important;white-space:nowrap !important}.select2-container--default .select2-selection--single{background-color:#fff;border:1px solid #aaa;border-radius:4px}.select2-container--default .select2-selection--single .select2-selection__rendered{color:#444;line-height:28px}.select2-container--default .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:bold}.select2-container--default .select2-selection--single .select2-selection__placeholder{color:#999}.select2-container--default .select2-selection--single .select2-selection__arrow{height:26px;position:absolute;top:1px;right:1px;width:20px}.select2-container--default .select2-selection--single .select2-selection__arrow b{border-color:#888 transparent transparent transparent;border-style:solid;border-width:5px 4px 0 4px;height:0;left:50%;margin-left:-4px;margin-top:-2px;position:absolute;top:50%;width:0}.select2-container--default[dir="rtl"] .select2-selection--single .select2-selection__clear{float:left}.select2-container--default[dir="rtl"] .select2-selection--single .select2-selection__arrow{left:1px;right:auto}.select2-container--default.select2-container--disabled .select2-selection--single{background-color:#eee;cursor:default}.select2-container--default.select2-container--disabled .select2-selection--single .select2-selection__clear{display:none}.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow b{border-color:transparent transparent #888 transparent;border-width:0 4px 5px 4px}.select2-container--default .select2-selection--multiple{background-color:white;border:1px solid #ddd;border-radius:0px;cursor:text;line-height: 1.5}.select2-container--default .select2-selection--multiple .select2-selection__rendered{box-sizing:border-box;list-style:none;margin:0;padding:0 5px;width:100%}.select2-container--default .select2-selection--multiple .select2-selection__rendered li{list-style:none;margin: 5px 5px 0 0}.select2-container--default .select2-selection--multiple .select2-selection__placeholder{color:#999;margin-top:5px;float:left}.select2-container--default .select2-selection--multiple .select2-selection__clear{cursor:pointer;float:right;font-weight:bold;margin-top:5px;margin-right:10px}.select2-container--default .select2-selection--multiple .select2-selection__choice{background-color:#e4e4e4;border:1px solid #aaa;border-radius:4px;cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove{color:#999;cursor:pointer;display:inline-block;font-weight:bold;margin-right:2px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover{color:#333}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice,.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__placeholder,.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-search--inline{float:right}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice{margin-left:5px;margin-right:auto}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice__remove{margin-left:2px;margin-right:auto}.select2-container--default.select2-container--focus .select2-selection--multiple{border:solid black 1px;outline:0}.select2-container--default.select2-container--disabled .select2-selection--multiple{background-color:#eee;cursor:default}.select2-container--default.select2-container--disabled .select2-selection__choice__remove{display:none}.select2-container--default.select2-container--open.select2-container--above .select2-selection--single,.select2-container--default.select2-container--open.select2-container--above .select2-selection--multiple{border-top-left-radius:0;border-top-right-radius:0}.select2-container--default.select2-container--open.select2-container--below .select2-selection--single,.select2-container--default.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--default .select2-search--dropdown .select2-search__field{border:1px solid #aaa}.select2-container--default .select2-search--inline .select2-search__field{background:transparent;border:none;outline:0;box-shadow:none;-webkit-appearance:textfield}.select2-container--default .select2-results>.select2-results__options{max-height:200px;overflow-y:auto}.select2-container--default .select2-results__option[role=group]{padding:0}.select2-container--default .select2-results__option[aria-disabled=true]{color:#999}.select2-container--default .select2-results__option[aria-selected=true]{background-color:#ddd}.select2-container--default .select2-results__option .select2-results__option{padding-left:1em}.select2-container--default .select2-results__option .select2-results__option .select2-results__group{padding-left:0}.select2-container--default .select2-results__option .select2-results__option .select2-results__option{margin-left:-1em;padding-left:2em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-2em;padding-left:3em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-3em;padding-left:4em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-4em;padding-left:5em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-5em;padding-left:6em}.select2-container--default .select2-results__option--highlighted[aria-selected]{background-color:#5897fb;color:white}.select2-container--default .select2-results__group{cursor:default;display:block;padding:6px}.select2-container--classic .select2-selection--single{background-color:#f7f7f7;border:1px solid #aaa;border-radius:4px;outline:0;background-image:-webkit-linear-gradient(top, #fff 50%, #eee 100%);background-image:-o-linear-gradient(top, #fff 50%, #eee 100%);background-image:linear-gradient(to bottom, #fff 50%, #eee 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFFFFFF', endColorstr='#FFEEEEEE', GradientType=0)}.select2-container--classic .select2-selection--single:focus{border:1px solid #5897fb}.select2-container--classic .select2-selection--single .select2-selection__rendered{color:#444;line-height:28px}.select2-container--classic .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:bold;margin-right:10px}.select2-container--classic .select2-selection--single .select2-selection__placeholder{color:#999}.select2-container--classic .select2-selection--single .select2-selection__arrow{background-color:#ddd;border:none;border-left:1px solid #aaa;border-top-right-radius:4px;border-bottom-right-radius:4px;height:26px;position:absolute;top:1px;right:1px;width:20px;background-image:-webkit-linear-gradient(top, #eee 50%, #ccc 100%);background-image:-o-linear-gradient(top, #eee 50%, #ccc 100%);background-image:linear-gradient(to bottom, #eee 50%, #ccc 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFEEEEEE', endColorstr='#FFCCCCCC', GradientType=0)}.select2-container--classic .select2-selection--single .select2-selection__arrow b{border-color:#888 transparent transparent transparent;border-style:solid;border-width:5px 4px 0 4px;height:0;left:50%;margin-left:-4px;margin-top:-2px;position:absolute;top:50%;width:0}.select2-container--classic[dir="rtl"] .select2-selection--single .select2-selection__clear{float:left}.select2-container--classic[dir="rtl"] .select2-selection--single .select2-selection__arrow{border:none;border-right:1px solid #aaa;border-radius:0;border-top-left-radius:4px;border-bottom-left-radius:4px;left:1px;right:auto}.select2-container--classic.select2-container--open .select2-selection--single{border:1px solid #5897fb}.select2-container--classic.select2-container--open .select2-selection--single .select2-selection__arrow{background:transparent;border:none}.select2-container--classic.select2-container--open .select2-selection--single .select2-selection__arrow b{border-color:transparent transparent #888 transparent;border-width:0 4px 5px 4px}.select2-container--classic.select2-container--open.select2-container--above .select2-selection--single{border-top:none;border-top-left-radius:0;border-top-right-radius:0;background-image:-webkit-linear-gradient(top, #fff 0%, #eee 50%);background-image:-o-linear-gradient(top, #fff 0%, #eee 50%);background-image:linear-gradient(to bottom, #fff 0%, #eee 50%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFFFFFF', endColorstr='#FFEEEEEE', GradientType=0)}.select2-container--classic.select2-container--open.select2-container--below .select2-selection--single{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;background-image:-webkit-linear-gradient(top, #eee 50%, #fff 100%);background-image:-o-linear-gradient(top, #eee 50%, #fff 100%);background-image:linear-gradient(to bottom, #eee 50%, #fff 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFEEEEEE', endColorstr='#FFFFFFFF', GradientType=0)}.select2-container--classic .select2-selection--multiple{background-color:white;border:1px solid #aaa;border-radius:4px;cursor:text;outline:0}.select2-container--classic .select2-selection--multiple:focus{border:1px solid #5897fb}.select2-container--classic .select2-selection--multiple .select2-selection__rendered{list-style:none;margin:0;padding:0 5px}.select2-container--classic .select2-selection--multiple .select2-selection__clear{display:none}.select2-container--classic .select2-selection--multiple .select2-selection__choice{background-color:#e4e4e4;border:1px solid #aaa;border-radius:4px;cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--classic .select2-selection--multiple .select2-selection__choice__remove{color:#888;cursor:pointer;display:inline-block;font-weight:bold;margin-right:2px}.select2-container--classic .select2-selection--multiple .select2-selection__choice__remove:hover{color:#555}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice{float:right}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice{margin-left:5px;margin-right:auto}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice__remove{margin-left:2px;margin-right:auto}.select2-container--classic.select2-container--open .select2-selection--multiple{border:1px solid #5897fb}.select2-container--classic.select2-container--open.select2-container--above .select2-selection--multiple{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-container--classic.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--classic .select2-search--dropdown .select2-search__field{border:1px solid #aaa;outline:0}.select2-container--classic .select2-search--inline .select2-search__field{outline:0;box-shadow:none}.select2-container--classic .select2-dropdown{background-color:#fff;border:1px solid transparent}.select2-container--classic .select2-dropdown--above{border-bottom:none}.select2-container--classic .select2-dropdown--below{border-top:none}.select2-container--classic .select2-results>.select2-results__options{max-height:200px;overflow-y:auto}.select2-container--classic .select2-results__option[role=group]{padding:0}.select2-container--classic .select2-results__option[aria-disabled=true]{color:grey}.select2-container--classic .select2-results__option--highlighted[aria-selected]{background-color:#3875d7;color:#fff}.select2-container--classic .select2-results__group{cursor:default;display:block;padding:6px}.select2-container--classic.select2-container--open .select2-dropdown{border-color:#5897fb}
admin/css/wt-import-export-for-woo-admin.css ADDED
@@ -0,0 +1,806 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * All of the CSS for your admin-specific functionality should be
3
+ * included in this file.
4
+ */
5
+
6
+ /**
7
+ * Tab section
8
+ */
9
+ .wt_iew_page_hd{ font-size:20px; }
10
+ .wt-iew-tab-head{ margin-right:0px; margin-top:20px; clear:both;}
11
+ .wt-iew-tab-container{ padding:15px; padding-bottom:0px; background:#fff; box-shadow:0px 2px 2px #ccc; float:left; box-sizing:border-box; width:100%; height:auto;}
12
+ .wt-iew-tab-head .nav-tab-active{ background: #fff; border-bottom: solid 1px #fff; }
13
+ .wt-iew-tab-head .nav-tab:focus{ box-shadow:none;}
14
+ .wt-iew-tab-content{ display:none; float:left; width:100%; height:auto; }
15
+ .wt_iew_sub_tab_container{float:left; width:100%; height:auto; padding-bottom:0px;}
16
+ .wt_iew_sub_tab{ display:inline-block; margin:0px;}
17
+ .wt_iew_sub_tab li{ display:inline-block; border-left: solid 1px #ccc; padding:3px 10px; cursor: pointer;}
18
+ .wt_iew_sub_tab_content{ display: none; float:left; width:100%; height:auto; }
19
+ .wt-iew-settings-header{border-bottom:dashed 1px #ccc; margin-left:-15px; margin-right:-15px; padding-top:0px;}
20
+ .wt-iew-settings-header h3{margin-top:0px; margin-left:15px; width:60%; display:inline-block;}
21
+ .wt-iew-settings-header .wt_iew_step_info{float:right; font-weight:bold; margin-right:15px; background:#dceff4; display:inline-block; padding:5px 10px; margin-top:-6px; margin-bottom:-15px; padding-bottom:6px; line-height:24px; border-radius:6px; }
22
+ .wt-iew-plugin-toolbar {
23
+ height: 40px;
24
+ width: 100%;
25
+ margin: 0;
26
+ padding: 0;
27
+ }
28
+ .wt-iew-plugin-toolbar .left {
29
+ float: left;
30
+ margin: 0;
31
+ padding: 0;
32
+ }
33
+ .wt-iew-plugin-toolbar .left img {
34
+ vertical-align: text-bottom;
35
+ margin-right: 10px;
36
+ }
37
+ .wt-iew-plugin-toolbar .right {
38
+ float: right;
39
+ margin: 0 10px 0 0;
40
+ padding: 0;
41
+ }
42
+ .wt-iew-plugin-toolbar.top {
43
+ margin-bottom: -5px;
44
+ }
45
+ .wt-iew-plugin-toolbar.bottom {
46
+ margin-top: 12px;
47
+ background: #f5f5f5;
48
+ border-top: 1px solid #ddd;
49
+ margin-left: -15px;
50
+ margin-right: -15px;
51
+ margin-bottom:0px;
52
+ padding:9px 15px;
53
+ }
54
+ .wt-iew-plugin-toolbar.top {
55
+ margin-top:-15px;
56
+ background: #f5f5f5;
57
+ border-bottom: 1px solid #ddd;
58
+ border-top: 1px solid #ddd;
59
+ margin-left: -15px;
60
+ margin-right: -15px;
61
+ margin-bottom: -15px;
62
+ padding:15px;
63
+ }
64
+ .wt-iew-plugin-toolbar.bottom .button{padding:0.2rem 0.75rem; margin-top:2px; height:auto;}
65
+
66
+
67
+ /**
68
+ * Form section
69
+ */
70
+ .wt_notify_msg{ position:fixed; width:300px; padding:15px; color:#fff; right:60px; top:0px; opacity:0; box-shadow:0px 2px 2px #333; border-radius:5px; z-index:1000000000;}
71
+ .wt_iew_overlayed_loader{ position:absolute; z-index:10000; background:rgba(255,255,255,.5); width:100%; height:auto; margin-left:-15px; margin-top:-15px;}
72
+ .wt_iew_loader_info_box{display:none; position:fixed; z-index:10001; width:300px; left:50%; top:50%; font-size:14px; font-weight:bold; background:#0073aa; text-align:center; line-height:20px; box-shadow:2px 2px 4px 0px #ccc; margin-left:-155px; margin-top:-45px; padding:10px 5px; color:#fff;}
73
+ .wt_iew_loader_info_box a{ color:#fff; text-decoration:underline; cursor:pointer; }
74
+ .wt_iew_loader_info_box .wt_iew_info_box_title{ font-size:16px; }
75
+ .wt_iew_loader_info_box .wt_iew_info_box_finished_text{ display:inline-block; font-weight:normal; margin-top:0px; }
76
+ .wf-help-links li{ float:left; padding:40px; margin:20px; display: inline-block; text-align: center; box-shadow:1px 1px 5px 1px rgba(0,0,0,.1); width: 185px; height: 245px;}
77
+ .wf-help-links li a{ text-decoration: none; height: 28px !important; margin-top: 20px; }
78
+ .wf-help-links li img{
79
+ margin-top: 15px;
80
+ }
81
+ .wt_iew_noselect {
82
+ -webkit-touch-callout: none; /* iOS Safari */
83
+ -webkit-user-select: none; /* Safari */
84
+ -khtml-user-select: none; /* Konqueror HTML */
85
+ -moz-user-select: none; /* Old versions of Firefox */
86
+ -ms-user-select: none; /* Internet Explorer/Edge */
87
+ user-select: none; /* Non-prefixed version, currently
88
+ supported by Chrome, Opera and Firefox */
89
+ }
90
+ /* copied from bootstrap */
91
+ .wt-iew-form-table input[type="text"], .wt-iew-form-table input[type="number"], .wt-iew-form-table input[type="password"], .wt-iew-form-table select, .wt_iew_select, .wt_iew_text{
92
+ display: block;
93
+ width:100%;
94
+ padding: 0.35rem 0.75rem;
95
+ font-size: 1rem;
96
+ line-height: 1.5;
97
+ color: #495057;
98
+ background-color: #fff;
99
+ background-clip: padding-box;
100
+ border: 1px solid #ced4da;
101
+ border-radius: 0.25rem;
102
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
103
+ height:36px;
104
+ max-width:none;
105
+ }
106
+ .wt-iew-form-table *::placeholder{ font-size:12px; }
107
+ .wt-iew-form-table .select2-container .select2-selection--multiple{ border-color:#ced4da !important; }
108
+
109
+
110
+ .wt-iew-form-table select, .wt_iew_select{
111
+ padding: 0.44rem 0.75rem;
112
+ }
113
+ .wt-iew-form-table textarea{
114
+ display: block;
115
+ width:100%;
116
+ padding: 0.375rem 0.75rem;
117
+ font-size: 1rem;
118
+ line-height: 1.5;
119
+ color: #495057;
120
+ background-color: #fff;
121
+ background-clip: padding-box;
122
+ border: 1px solid #ced4da;
123
+ border-radius: 0.25rem;
124
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
125
+ }
126
+ .wt-iew-form-table .select2-selection, .wt-iew-form-table .select2-selection.select2-selection--multiple{
127
+ display: block;
128
+ width:100%;
129
+ color: #495057;
130
+ background-color: #fff;
131
+ background-clip: padding-box;
132
+ border: 1px solid #ced4da;
133
+ border-radius: 0.25rem;
134
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
135
+ min-height: 60px; font-size: 12px;
136
+ }
137
+ .wt-iew-form-table .select2-container {
138
+ width:100% !important;
139
+ }
140
+ .wf_select_multi{
141
+ width:100%;
142
+ }
143
+ .wf_select_multi .select2-container{
144
+ width:100% !important;
145
+ }
146
+ .wt-iew-form-table .button {
147
+ padding:0.2rem 0.75rem; height: auto;
148
+ }
149
+ .wf_settings_form .button {
150
+ padding:0.2rem 0.75rem; height: auto;
151
+ }
152
+ .wt-iew_form_help{ color:#666;font-weight:400; font-size:12px; display:inline-block; width:100%; margin-top:10px; }
153
+ .wt-iew_conditional_help_text{ display:none;}
154
+ .wt-iew-form-table tr th:first-child{ width:40% !important; padding:10px 15px 10px 0; vertical-align:top; }
155
+ .wt-iew-form-table tr th:first-child label{ margin-top:5px; display:inline-block; }
156
+ .wt-iew-form-table tr td:nth-child(2){ width:40%; padding:10px 5px 10px 0; }
157
+ .wt-iew-form-table tr td:nth-child(3){ width:35%; }
158
+ .wt_form_radio_block, .wt_form_checkbox_block{ display:inline-block; margin-top:8px; }
159
+ .wt-iew-tab-container .wp-list-table thead th{ font-weight:bold; }
160
+ .wt-iew-exporter-step-btn, .wt-iew-exporter-step-export-btn{ float:right; }
161
+
162
+ .wt-iew-form-table select.wt_iew_delimiter_preset{ width:70%; float:left; }
163
+ .wt-iew-form-table input[type="text"].wt_iew_custom_delimiter{ width:25%; float:right; }
164
+
165
+ .wt-iew-form-table select.wt_iew_date_format_preset{ width:70%; float:left; }
166
+ .wt-iew-form-table input[type="text"].wt_iew_custom_date_format{ width:25%; float:right; }
167
+
168
+
169
+ .wt_iew_warn_box{padding:20px; padding-bottom:0px;}
170
+ .wt_iew_warn{ display:inline-block; width:100%; box-sizing:border-box; padding:10px; background-color:#fff8e5; border-left:solid 2px #ffb900; color:#333; }
171
+ .wt_iew_rerun_warn{ width:95%; margin:30px 2.5%; }
172
+
173
+ .wt_iew_info_box{padding:20px; padding-bottom:0px;}
174
+ .wt_iew_info{ display:inline-block; width:100%; box-sizing:border-box; padding:10px; background-color:#d1ecf1; border-left:solid 2px #0c5460; color:#185b8d; }
175
+
176
+
177
+ /* mapping step */
178
+ .wt-iew-mapping-tb{ border:1px solid #e5e5e5; width:90%; max-width:700px; }
179
+ .wt-iew-mapping-tb th{ text-align:left; height:30px; /* background:#e5e5e5; */ border-bottom:solid 1px #e5e5e5; }
180
+ .wt-iew-mapping-tb tr td:first-child, .wt-iew-mapping-tb tr th:first-child{ width:50px; }
181
+ .wt-iew-mapping-tb td, .wt-iew-mapping-tb th{ padding:5px; }
182
+ .wt-iew-mapping-tb td input[type="text"], .wt_iew_text_field{
183
+ display: block;
184
+ max-width:500px;
185
+ width:100%;
186
+ color: #495057;
187
+ background-clip: padding-box;
188
+ border: 1px solid #ced4da !important;
189
+ border-radius: 0.25rem;
190
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
191
+ height:32px;
192
+ }
193
+ .wt_iew_sort_handle{ width:25px; cursor:move; }
194
+ .wt-iew-mapping-tb tbody tr:hover td{ background:#f6f6f6; }
195
+ .wt-iew-mapping-tb .wt_iew_mapping_checkbox_main{ margin-left:29px; }
196
+ .wt-iew-mapping-tb .wt_iew_mapping_checkbox_sub{ margin-left:4px; margin-top:2px; }
197
+ .wt_iew_sort_handle{ float:left; }
198
+ .wt_iew_sort_handle img{ margin-top:5px; color:#ccc; height:15px; opacity:.8; }
199
+ .wt_iew_checkbox{ display:inline-block; padding:0px 15px; }
200
+ .wt_iew_mapping_field_val{ width:100%; min-height:32px; display:inline-block; background:#fff; padding:5px 5px; box-sizing:border-box; border:solid 1px #ced4da; border-radius:0.25rem; cursor:text; }
201
+
202
+ .wt-iew-sortable-placeholder td{ height:30px; background:#fff; border-top:dashed 1px #ccc; border-bottom:dashed 1px #ccc; }
203
+ .wt-iew-sortable-placeholder td:first-child{ border:dashed 1px #ccc; border-right:none; }
204
+ .wt-iew-sortable-placeholder td:last-child{ border:dashed 1px #ccc; border-left:none; }
205
+
206
+ .meta_mapping_box{width:100%; float:left; height:auto; margin-bottom:0px;}
207
+ .meta_mapping_box_hd{min-width:720px; width:auto; display:inline-block; height:40px; line-height:40px; font-weight:bold; background:#f6f6f6; box-sizing:border-box; padding:2px 10px; box-shadow:1px 1px 1px #e0e0e0; border-bottom:solid 1px #ccc; border-top:solid 1px #fff; cursor:pointer;}
208
+ .meta_mapping_box_hd_nil{min-width:720px; width:auto; display:inline-block; height:40px; line-height:40px; font-weight:bold; background:#f6f6f6; box-sizing:border-box; padding:2px 10px; box-shadow:1px 1px 1px #e0e0e0; border-bottom:solid 1px #ccc; border-top:solid 1px #fff; cursor:pointer;}
209
+ .meta_mapping_box_hd .dashicons{ margin-top:10px; }
210
+ .meta_mapping_box_selected_count_box{ float:right; margin-top:-3px; font-weight:normal; font-style:italic; }
211
+ .meta_mapping_box_con{min-width:720px; width:auto; display:inline-block; height:auto; padding:0px; display:none;}
212
+ .wt-iew-mapping-tb{ min-width:720px; }
213
+ .meta_mapping_box_toggle{ font-weight:normal; float:right; cursor:pointer; }
214
+ .wt_iew_invalid_mapping_field{ color:red; display:inline-block !important; padding:0px !important; margin:0px !important; }
215
+
216
+
217
+ /* popup */
218
+ .wt_iew_overlay{ position:fixed; z-index:100000000; width:100%; height:100%; background-color:rgba(0,0,0,.5); left:0px; top:0px; display:none;}
219
+ .wt_iew_popup{position:fixed; z-index:100000001; background:#fff; border:solid 1px #eee; text-align:center; box-shadow:0px 2px 5px #333; left:50%; display:none;}
220
+ .wt_iew_popup_hd{display:inline-block; width:100%; box-sizing:border-box; font-weight:bold; background-color:#f3f3f3; height:40px; text-align:left; line-height:40px; padding:0px 20px;}
221
+ .wt_iew_popup_close{float:right; width:40px; height:40px; text-align:right; line-height:40px; cursor:pointer;}
222
+ .wt_iew_popup_footer{width:100%; text-align:right; margin-top:10px;}
223
+
224
+ .wt_iew_data_dv{ display:none; }
225
+ .wt_iew_action_btn{ cursor:pointer; }
226
+
227
+ .wt-iew-form-table .wt_iew_radio_block p{ margin-bottom:15px; line-height:18px; }
228
+ .wt-iew-form-table .wt_iew_radio_block span{ display:inline-block; padding-left:25px; }
229
+ .wt-iew-form-table .wt_iew_radio_block b{ display:inline-block; margin-left:5px; }
230
+
231
+ .wt-iew-form-table .wt_iew_field_group{ padding-left:0px; }
232
+ .wt-iew-form-table .wt_iew_field_group_hd{ display:block; border-bottom:dashed 1px #ccc; padding-bottom:5px; padding-top:20px; font-size:15px; font-weight:bold; cursor:pointer; }
233
+ .wt-iew-form-table .wt_iew_field_group_hd .wt_iew_field_group_toggle_btn{float:left; margin-right:10px; width:20px; height:20px; border-radius:10px; color:#666; cursor:pointer; }
234
+ .wt-iew-form-table .wt_iew_field_group_content{ padding-left:10px; display:none; }
235
+
236
+
237
+ /* Dropdown */
238
+ .wt_iew_dropdown{ position:absolute; z-index:100; background:#fff; border:1px solid #ccc; border-radius:4px; padding:0px; display:none; box-shadow:1px 3px 2px 2px rgba(0,0,0,0.1); }
239
+ .wt_iew_dropdown li{ padding:7px 14px; margin:5px 0px; cursor:pointer; }
240
+ .wt_iew_dropdown li:hover{ background:#fafafa; }
241
+
242
+ /* template saving popup */
243
+ .wt_iew_template_name{width:100%; max-width:320px;}
244
+ .wt_iew_template_name_box{ float:left; width:90%; padding:5%; padding-top:0px; }
245
+ .wt_iew_template_name_wrn{display:none; text-align:left; }
246
+ .wt_iew_template_name_label{ display:inline-block; width:100%; text-align:left; font-weight:bold; padding:3px 0px; }
247
+
248
+ /* file attacher */
249
+ .wt-iew-form-table .wt_iew_file_attacher_dv{width:100%; }
250
+ .wt-iew-form-table .wt_iew_file_attacher_dv input[type="text"]{width:70%; float:left; }
251
+ .wt-iew-form-table .wt_iew_file_attacher_dv input[type="button"]{width:25%; float:right; }
252
+ .wt_iew_file_attacher_dv{ float:left; width:100%; }
253
+
254
+ /* popover */
255
+ .wt_iew_popover{ position: absolute; min-width:250px; min-height:150px; height: auto; background: #fff; border-radius: 5px; box-shadow: 0 5px 10px rgba(0,0,0,.2); top:50px; border: 1px solid #ccc;}
256
+ .wt_iew_popover:after, .wt_iew_popover:before {
257
+ right: 100%;
258
+ top:25%;
259
+ border: solid transparent;
260
+ content: " ";
261
+ height: 0;
262
+ width: 0;
263
+ position: absolute;
264
+ pointer-events: none;
265
+ }
266
+
267
+ .wt_iew_popover:after {
268
+ border-color: rgba(255, 255, 255, 0);
269
+ border-right-color: #fff;
270
+ border-width: 20px;
271
+ margin-top: -20px;
272
+ }
273
+ .wt_iew_popover:before {
274
+ border-color: rgba(204, 204, 204, 0);
275
+ border-right-color: #ccc;
276
+ border-width: 21px;
277
+ margin-top: -21px;
278
+ }
279
+ .wt_iew_popover-title{ background:#f7f7f7; height:35px;
280
+ margin: 0px;
281
+ border-top-left-radius: 5px;
282
+ border-top-right-radius: 5px; padding:5px; padding-left: 15px; line-height: 35px; font-size: 14px;}
283
+ .popover_close_icon_button{ float:right; height:20px; width:20px; border-radius:20px; color:#fff; background:#666; padding:3px; font-weight:bold; text-align:center; line-height:20px; margin-top:5px; margin-right:5px; cursor:pointer; }
284
+ .wt_iew_popover-content{
285
+ min-height:65px; height: auto; padding:15px; float:left; clear:both;
286
+ }
287
+ .wt_iew_popover-footer{ background:#f7f7f7; clear:both; height:30px; margin:0px; margin-top:10px; border-bottom-left-radius:5px; border-bottom-right-radius:5px; padding:7px 15px;}
288
+ .wt_iew_popover-content input[type="text"]{
289
+ margin:5px 0px; border-radius:3px; padding: 0.2rem 0.3rem;
290
+ font-size: 1rem;
291
+ line-height: 1.5;
292
+ }
293
+ .wt_iew_popover-footer .button{
294
+ float: right; margin-left: 5px;
295
+ }
296
+
297
+ /* mapping field editor */
298
+ .wt_iew_mapping_field_editor_container{ display:none; }
299
+ .wt_iew_mapping_field_editor{ float:left; width:400px; padding:0px; background:#fff; margin:0px;}
300
+ .wt_iew_mapping_field_editor *{ box-sizing:border-box; }
301
+ .wt_iew_mapping_field_editor label{ float:left; width:100%; margin-bottom:3px; font-weight:bold; font-size:13px; color:#333; }
302
+ .wt_iew_mapping_field_editor_box{border:solid 1px #ddd; float:left; width:100%; height:auto; min-height:50px; padding:3px; margin-bottom:10px; margin-top:5px;}
303
+ .wt_iew_mapping_field_editor_box textarea{border:none; float:left; width:100%; height:50px; outline:none; resize:none;}
304
+ .wt_iew_mapping_field_editor_box input[type="text"]{width:100%; font-size:12px;}
305
+ .wt_iew_mapping_field_editor_box input[type="text"]::placeholder{ font-size:12px; }
306
+ .wt_iew_mapping_field_editor_info{ margin:0px; }
307
+ .wt_iew_mapping_field_editor_er{ margin:0px; color:red; }
308
+ .wt_iew_mapping_field_selector_box{ float:left; width:100%; height:120px; overflow:auto; margin-top:5px; }
309
+ .wt_iew_mapping_field_selector{ float:left; width:100%; margin:0px; padding:0px; }
310
+ .wt_iew_mapping_field_selector li{ float:left; width:100%; padding:5px; margin:0px; cursor:pointer;}
311
+ .wt_iew_mapping_field_selector li:hover{ background:#0073aa; color:#fff; }
312
+ .wt_iew_mapping_field_selector_no_column{ float:left; width:100%; color:red; }
313
+ .wt_iew_no_sample_mapping_data{ color:gray; display:inline-block !important; padding:0px !important; margin:0px !important; font-style:italic; }
314
+ .wt_evaluation_expression_points{list-style: none;}
315
+ .wt_evaluation_expression_points li::before {
316
+ content: "\2022"; /* Add content: \2022 is the CSS Code/unicode for a bullet */
317
+ color: red; /* Change the color */
318
+ font-weight: bold; /* If you want it to be bold */
319
+ display: inline-block; /* Needed to add space between the bullet and the text */
320
+ width: 1em; /* Also needed for space (tweak if needed) */
321
+ }
322
+
323
+ /* debug panel */
324
+ .wt_iew_debug_panel{ position:fixed; top:30px; right:0px; background:#fff; padding:5px; padding-bottom:0px; box-shadow:2px 2px 2px #ccc; }
325
+ .wt_iew_debug_panel_hd{ width:100%; font-size:12px; font-weight:bold; padding:2px; }
326
+ .wt_iew_debug_panel_con{ width:100%; min-height:30px; font-size:12px; text-align:center;}
327
+ .wt_iew_debug_panel_con a{ display:inline-block; padding:2px; border-right:solid 1px #ccc; cursor:pointer; }
328
+ .wt_iew_debug_panel_con a:last-child{ border-right:solid 0px #ccc; }
329
+
330
+ /* pagination */
331
+ .wt_iew_pagination{ float:right; width:auto; height:auto; margin:10px 0px;}
332
+ .wt_iew_pagination a{ float:left; padding:6px 12px; background:#f3f5f6; border:solid 1px #cccccc; color:#2e8ab6; text-decoration:none; margin-right:5px; border-radius:5px; }
333
+ .wt_iew_pagination a.wt_iew_pageactive{ background:#fff; color:#333; border:solid 1px #ddd; }
334
+ .wt_iew_pagination a.wt_iew_pagedisabled{ background:#f7f7f7; color:#a0a5aa; border:solid 1px #ddd; }
335
+ .wt_iew_pagination a.wt_iew_page{ cursor:pointer; }
336
+ .wt_iew_pagination_total_info{ float:left; padding:8px; }
337
+
338
+ /* listing */
339
+ .wt_iew_badge{ display:inline-block; padding:2px 6px; font-size:12px; border-radius:3px; background:#ccc; color:#fff; text-align:center; }
340
+
341
+ /* responsive */
342
+ @media (max-width:768px) {
343
+ .wt-iew-form-table tr th:first-child{ width:100%; }
344
+ .wt-iew-form-table tr td:nth-child(2){ width:100%; }
345
+ .wt-iew-form-table tr td:nth-child(3){ width:100%; }
346
+ .wt-iew-form-table .wt_iew_file_attacher_dv input[type="text"]{width:50%; float:left; }
347
+ .wt-iew-form-table .wt_iew_file_attacher_dv input[type="button"]{width:45%; float:right; }
348
+ }
349
+
350
+ /* tooltip */
351
+ .wt-iew-tips{ color:#16a7c5; }
352
+ .wt_iew_tooltip_span{ display:inline-block; margin-bottom:9px; line-height:16px; text-align:left; border-top:
353
+ dashed 1px #efefef; }
354
+ #tiptip_content .wt_iew_tooltip_span:first-child{ border:none; margin-top:4px; }
355
+ #tiptip_content .wt_iew_tooltip_span:last-child{ margin-bottom:4px; }
356
+ .tips {
357
+ cursor:help;
358
+ text-decoration:none
359
+ }
360
+ img.tips {
361
+ padding:5px 0 0
362
+ }
363
+ #tiptip_holder {
364
+ display:none;
365
+ z-index:8675309;
366
+ position:absolute;
367
+ top:0;
368
+ left:0
369
+ }
370
+ #tiptip_holder.tip_top {
371
+ padding-bottom:5px
372
+ }
373
+ #tiptip_holder.tip_top #tiptip_arrow_inner {
374
+ margin-top:-7px;
375
+ margin-left:-6px;
376
+ border-top-color:#333
377
+ }
378
+ #tiptip_holder.tip_bottom {
379
+ padding-top:5px
380
+ }
381
+ #tiptip_holder.tip_bottom #tiptip_arrow_inner {
382
+ margin-top:-5px;
383
+ margin-left:-6px;
384
+ border-bottom-color:#333
385
+ }
386
+ #tiptip_holder.tip_right {
387
+ padding-left:5px
388
+ }
389
+ #tiptip_holder.tip_right #tiptip_arrow_inner {
390
+ margin-top:-6px;
391
+ margin-left:-5px;
392
+ border-right-color:#333
393
+ }
394
+ #tiptip_holder.tip_left {
395
+ padding-right:5px
396
+ }
397
+ #tiptip_holder.tip_left #tiptip_arrow_inner {
398
+ margin-top:-6px;
399
+ margin-left:-7px;
400
+ border-left-color:#333
401
+ }
402
+ #tiptip_content,
403
+ .chart-tooltip,
404
+ .wc_error_tip {
405
+ color:#fff;
406
+ font-size:.8em;
407
+ max-width:150px;
408
+ background:#333;
409
+ text-align:center;
410
+ border-radius:3px;
411
+ padding:.618em 1em;
412
+ box-shadow:0 1px 3px rgba(0,
413
+ 0,
414
+ 0,
415
+ .2)
416
+ }
417
+ #tiptip_content code,
418
+ .chart-tooltip code,
419
+ .wc_error_tip code {
420
+ padding:1px;
421
+ background:#888
422
+ }
423
+ #tiptip_arrow,
424
+ #tiptip_arrow_inner {
425
+ position:absolute;
426
+ border-color:transparent;
427
+ border-style:solid;
428
+ border-width:6px;
429
+ height:0;
430
+ width:0
431
+ }
432
+
433
+ /**
434
+ * Dropzone: Drag and Drop file upload
435
+ */
436
+ .wt_iew_dropzone{ text-align:center; cursor:pointer; width:100%; height:200px; border:dashed 3px #ccc; }
437
+ .wt_iew_dropzone.wt_drag_start{ border-color:#92b0b3; background:#c8dadf; }
438
+ .dz-preview{ width:300px; display:inline-block; margin-top:70px; }
439
+ .dz-message{ font-size:1.5em; margin-top:85px; line-height:14px; }
440
+ .wt_iew_dropzone .dz-preview .dz-details{ font-size:14px}
441
+ .wt_iew_dropzone .dz-preview.dz-processing .dz-progress{ opacity:1;-webkit-transition:all .2s linear;-moz-transition:all .2s linear;-ms-transition:all .2s linear;-o-transition:all .2s linear;transition:all .2s linear}
442
+ .wt_iew_dropzone .dz-preview.dz-complete .dz-progress{opacity:0;-webkit-transition:opacity .4s ease-in;-moz-transition:opacity .4s ease-in;-ms-transition:opacity .4s ease-in;-o-transition:opacity .4s ease-in;transition:opacity .4s ease-in}
443
+ .wt_iew_dropzone .dz-preview:not(.dz-processing) .dz-progress{-webkit-animation:pulse 6s ease infinite;-moz-animation:pulse 6s ease infinite;-ms-animation:pulse 6s ease infinite;-o-animation:pulse 6s ease infinite;animation:pulse 6s ease infinite}
444
+ .wt_iew_dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:16px;margin-top:-8px;margin-left:-40px;background:rgba(255,255,255,.9);-webkit-transform:scale(1);border-radius:8px;overflow:hidden}
445
+ .wt_iew_dropzone .dz-preview .dz-progress .dz-upload{background:#333;background:linear-gradient(to bottom,#666,#444);position:absolute;top:0;left:0;bottom:0;width:0;-webkit-transition:width .3s ease-in-out;-moz-transition:width .3s ease-in-out;-ms-transition:width .3s ease-in-out;-o-transition:width .3s ease-in-out;transition:width .3s ease-in-out}
446
+ .wt_iew_dropzone .dz-preview .dz-progress{width:300px;margin-left:0;margin-top:5px}
447
+ .wt_iew_dropzone .dz-preview .dz-progress .dz-upload{background:#2092ea}
448
+ .wt_iew_dz_file_name, .wt_iew_dz_remove_link, .wt_iew_dz_file_success{ display:inline-block; font-size:14px; }
449
+ .wt_iew_dz_remove_link{ cursor:pointer; color:#4289a9; }
450
+ .wt_iew_dz_file_success{ line-height:20px; }
451
+ .wt_iew_dropzone .dz-preview .dz-progress .dz-upload-info{display:inline-block;text-align:center;width:100%;}
452
+ .wt_iew_dropzone.dz-started .dz-message{ display:none;}
453
+
454
+ /* start marketing section */
455
+ .wt-import-export-upsell-wrapper.market-box{
456
+ width:27%;
457
+ float: right;
458
+ }
459
+ .wrap .wt-import-export-upsell-wrapper .ier-premium-upgrade {
460
+ margin-top: 0px;
461
+ margin-right: 0px;
462
+ }
463
+ .wt-import-export-upsell-wrapper .ier-premium-upgrade{
464
+ background: #fff;
465
+ padding: 5px;
466
+ margin-top: 30px;
467
+ margin-right: 15px;
468
+ box-shadow: 2px 2px 4px #ccc;
469
+ }
470
+ .wt-ier-sidebar-wrapper{
471
+ background: #FFFFFF;
472
+ border-radius: 5px;
473
+ max-width: 300px;
474
+ }
475
+ .wt-ier-sidebar-img{
476
+ margin: 0 auto 20px auto;
477
+ display: block;
478
+ }
479
+ .wt-ier-sidebar-title{
480
+ font-weight: 600;
481
+ font-size: 17px;
482
+ line-height: 25px;
483
+ color: #000000;
484
+ margin-bottom: 20px;
485
+ }
486
+ .wt-ier-icon{
487
+ width: auto;
488
+ height: 100%;
489
+ max-height: 25px;
490
+ margin-right: 8px;
491
+ }
492
+ .wt-ier-sidebar-p{
493
+ font-style: normal;
494
+ font-weight: normal;
495
+ font-size: 12px;
496
+ line-height: 16px;
497
+ color: #000000;
498
+ margin: 0;
499
+ }
500
+ .wt-ier-green-btn{
501
+ background: #00CB95;
502
+ border-radius: 4px;
503
+ font-weight: 600;
504
+ font-size: 16px;
505
+ line-height: 19px;
506
+ text-align: center;
507
+ padding: 15px 20px;
508
+ color: #FFFFFF;
509
+ display: inline-block;
510
+ text-decoration: none;
511
+ transition: all .2s ease;
512
+ border:none;
513
+ margin-top: 20px;
514
+ }
515
+ .wt-ier-green-btn:hover,.wt-ier-green-btn:focus{
516
+ color: #fff;
517
+ text-decoration: none;
518
+ opacity: .8;
519
+ transition: all .2s ease;
520
+ border:none;
521
+ transform: translateY(1px);
522
+ }
523
+ .wt-ier-wrapper{
524
+ background-color: #fff;
525
+ padding: 30px;
526
+ }
527
+ .wt-ier-box-wrapper{
528
+ background: #FFFFFF;
529
+ border: 1px solid #D2D2D2;
530
+ border-radius: 6px;
531
+ min-height: 100%;
532
+ }
533
+ .wt-ier-page-title{
534
+ font-style: normal;
535
+ font-weight: 600;
536
+ font-size: 25px;
537
+ line-height: 30px;
538
+ color: #111111;
539
+ margin-bottom: 13px;
540
+ margin-top: 10px;
541
+ }
542
+ .wt-ier-subp{
543
+ font-style: normal;
544
+ font-weight: normal;
545
+ font-size: 15px;
546
+ line-height: 18px;
547
+ margin-bottom: 40px;
548
+ margin-top: 0;
549
+ color: #111111;
550
+ }
551
+ .wt-ier-plugin-name{
552
+ font-style: normal;
553
+ font-weight: 600;
554
+ font-size: 16px;
555
+ line-height: 25px;
556
+ letter-spacing: -0.5px;
557
+ text-transform: uppercase;
558
+ margin-bottom: 15px;
559
+ margin-top: 12px;
560
+ color: #000000;
561
+ }
562
+ .wt-ier-p{
563
+ font-size: 14px;
564
+ line-height: 23px;
565
+ color: #445359;
566
+ margin-top: 15px;
567
+ margin-bottom: 18px;
568
+ }
569
+ .wt-ier-primary-btn{
570
+ background: #007CBA;
571
+ border:1px solid #007CBA;
572
+ color: #FFFFFF;
573
+ }
574
+ .wt-ier-secondary-btn{
575
+ color: #007CBA;
576
+ border:1px solid #007CBA;
577
+ }
578
+ .wt-ier-secondary-btn,.wt-ier-primary-btn{
579
+ font-style: normal;
580
+ font-weight: 500;
581
+ font-size: 13px;
582
+ line-height: 16px;
583
+ text-decoration: none;
584
+ padding:10px 12px;
585
+ border-radius: 5px;
586
+ text-align: center;
587
+ display: inline-block;
588
+ transition: all .2s ease;
589
+ margin-top: 18px;
590
+ }
591
+ .wt-ier-primary-btn:hover,.wt-ier-primary-btn:focus{
592
+ color:#fff;
593
+ }
594
+ .wt-ier-secondary-btn:hover,.wt-ier-primary-btn:hover,
595
+ .wt-ier-secondary-btn:focus,.wt-ier-primary-btn:focus{
596
+ transform: translateY(1px);
597
+ transition: all .2s ease;
598
+ }
599
+ .wt-ier-btn-group{
600
+ justify-content: space-between!important;
601
+ margin: -8px;
602
+ align-items: center;
603
+ position: absolute;
604
+ bottom: 0;
605
+ }
606
+ .wt-ier-btn-group .wt-ier-btn{
607
+ margin: 8px;
608
+ }
609
+ .wt-ier-box-highlight{
610
+ box-shadow: 0px 0px 20px rgba(19, 109, 200, 0.3);
611
+ }
612
+ .wt-ier-center{
613
+ text-align: center;
614
+ }
615
+ .wt-ier-p-5{
616
+ padding:30px;
617
+ }
618
+ .wt-ier-p-4{
619
+ padding:20px;
620
+ }
621
+ .wt-ier-px-3{
622
+ padding-right:12px;
623
+ padding-left:12px;
624
+ }
625
+ .wt-ier-mb-4{
626
+ margin-bottom: 20px;
627
+ }
628
+ .wt-ier-mt-5{
629
+ margin-top: 30px;
630
+ }
631
+ .wt-ier-v-center{
632
+ -ms-flex-align: center;
633
+ align-items: center;
634
+ }
635
+ .wt-ier-row{
636
+ display: -ms-flexbox;
637
+ display: flex;
638
+ -ms-flex-wrap: wrap;
639
+ /*flex-wrap: wrap;*/
640
+ width:95%;
641
+ margin-left: -17px;
642
+ }
643
+ .wt-ier-col-12{
644
+ -ms-flex: 0 0 100%;
645
+ flex: 0 0 100%;
646
+ max-width: 100%;
647
+
648
+ }
649
+ .wt-ier-col-md-6,.wt-ier-col-12{
650
+ position: relative;
651
+ width: 100%;
652
+ padding:15px;
653
+ }
654
+ .wt-ier-flex {
655
+ display: -ms-flexbox;
656
+ display: flex;
657
+ }
658
+ .wt-ier-modal {
659
+ display: none;
660
+ position: fixed;
661
+ z-index: 1;
662
+ padding-top: 50px;
663
+ padding-bottom: 50px;
664
+ left: 0;
665
+ top: 0;
666
+ width: 100%;
667
+ height: 90%;
668
+ overflow: auto;
669
+ background-color: rgb(0,0,0);
670
+ background-color: rgba(0,0,0,0.4);
671
+ }
672
+
673
+ .wt-ier-modal-content {
674
+ background-color: #fefefe;
675
+ margin: auto;
676
+ border: 1px solid #888;
677
+ width: 78%;
678
+ }
679
+ .wt-ier-close {
680
+ color: #aaaaaa;
681
+ float: right;
682
+ font-size: 28px;
683
+ font-weight: bold;
684
+ }
685
+
686
+ .wt-ier-close:hover,
687
+ .wt-ier-close:focus {
688
+ color: #000;
689
+ text-decoration: none;
690
+ cursor: pointer;
691
+ }
692
+ .wt-ier-pre-icon{
693
+ height: 15px;
694
+ margin-right: 9px;
695
+ }
696
+ .wt-ier-resposive-table {
697
+ width: 100%;
698
+ overflow-x: auto;
699
+ }
700
+ .wt-ier-table{
701
+ width: 100%;
702
+ margin-bottom: 1rem;
703
+ background-color: transparent;
704
+ border-collapse: collapse;
705
+ min-width: 700px;
706
+ }
707
+ .wt-ier-table th, .wt-ier-table td{
708
+ padding: 18px 25px;
709
+ }
710
+ .wt-ier-table td{
711
+ border-top: 1px solid #E9E9E9;
712
+ border-right: 1px solid #E9E9E9;
713
+ }
714
+ .wt-ier-table th{
715
+ border-right: 1px solid #E9E9E9;
716
+ }
717
+
718
+ .wt-ier-top-tr th{
719
+ padding-bottom: 0;
720
+ }
721
+ .wt-ier-table th{
722
+ font-style: normal;
723
+ font-weight: bold;
724
+ font-size: 18px;
725
+ line-height: 22px;
726
+ color: #007CBA;
727
+ text-align: center;
728
+ }
729
+ .wt-ier-table tr td{
730
+ width:23%;
731
+ text-align: center;
732
+ font-weight: normal;
733
+ font-size: 12px;
734
+ line-height: 15px;
735
+
736
+ color: #000000;
737
+ }
738
+ .wt-ier-table tr td p,.wt-ier-table tr td{
739
+ margin: 0;
740
+ }
741
+ .wt-ier-table tr td p {
742
+ margin-top: 5px!important;
743
+ }
744
+ .wt-ier-table tr td:first-child{
745
+ width:31%;
746
+ }
747
+ .wt-ier-table tr td:first-child{
748
+ font-weight: normal;
749
+ font-size: 15px;
750
+ line-height: 18px;
751
+ color: #000000;
752
+ }
753
+ .wt-ier-table tr td:first-child,.wt-ier-table tr th:first-child,
754
+ .wt-ier-table tr td:last-child,.wt-ier-table tr th:last-child{
755
+ border-right: none!important;
756
+ }
757
+ .wt-ier-table tr td:first-child,.wt-ier-table tr th:first-child{
758
+ background-color: #F7FAFE;
759
+ text-align: left!important;
760
+ }
761
+ .wt-ier-table tr td li{
762
+ text-align: left;
763
+ list-style: inside;
764
+ }
765
+
766
+ @media (min-width: 992px){
767
+ .wt-ier-col-lg-6{
768
+ -ms-flex: 0 0 50%;
769
+ flex: 0 0 50%;
770
+ max-width: 50%;
771
+ }
772
+ .wt-ier-col-lg-4{
773
+ -ms-flex: 0 0 33.333333%;
774
+ flex: 0 0 33.333333%;
775
+ max-width: 33.333333%;
776
+ }
777
+ .wt-ier-mb-lg-0{
778
+ margin-bottom: 0;
779
+ }
780
+ .wt-ier-suite{
781
+ background-image: url(../../assets/images/upgrade/suite-cover.svg);
782
+ background-position: right;
783
+ background-size: 50% 100%;
784
+ background-repeat: no-repeat;
785
+ }
786
+ }
787
+ @media (min-width: 768px){
788
+ .wt-ier-col-md-6{
789
+ -ms-flex: 0 0 50%;
790
+ flex: 0 0 50%;
791
+ max-width: 50%;
792
+ }
793
+ .wt-ier-mb-md-0{
794
+ margin-bottom: 0;
795
+ }
796
+ .wt-ier-border-md-right{
797
+ border-right: 1px solid #E8E8E8;
798
+ }
799
+
800
+ }
801
+ @media (min-width: 576px){
802
+ .wt-ier-d-sm-flex{
803
+ display: flex;
804
+ }
805
+ }
806
+ /* end marketing */
admin/index.php ADDED
@@ -0,0 +1 @@
 
1
+ <?php // Silence is golden
admin/js/dropzone.min.js ADDED
@@ -0,0 +1 @@
 
1
+ "use strict";function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _possibleConstructorReturn(e,t){return!t||"object"!==_typeof(t)&&"function"!=typeof t?_assertThisInitialized(e):t}function _getPrototypeOf(e){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _inherits(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&_setPrototypeOf(e,t)}function _setPrototypeOf(e,t){return(_setPrototypeOf=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),e}var Emitter=function(){function e(){_classCallCheck(this,e)}return _createClass(e,[{key:"on",value:function(e,t){return this._callbacks=this._callbacks||{},this._callbacks[e]||(this._callbacks[e]=[]),this._callbacks[e].push(t),this}},{key:"emit",value:function(e){this._callbacks=this._callbacks||{};var t=this._callbacks[e];if(t){for(var n=arguments.length,i=new Array(1<n?n-1:0),r=1;r<n;r++)i[r-1]=arguments[r];var o=!0,a=!1,l=void 0;try{for(var s,u=t[Symbol.iterator]();!(o=(s=u.next()).done);o=!0){s.value.apply(this,i)}}catch(e){a=!0,l=e}finally{try{o||null==u.return||u.return()}finally{if(a)throw l}}}return this}},{key:"off",value:function(e,t){if(!this._callbacks||0===arguments.length)return this._callbacks={},this;var n=this._callbacks[e];if(!n)return this;if(1===arguments.length)return delete this._callbacks[e],this;for(var i=0;i<n.length;i++){if(n[i]===t){n.splice(i,1);break}}return this}}]),e}(),Dropzone=function(){function C(e,t){var n,i,r;if(_classCallCheck(this,C),(n=_possibleConstructorReturn(this,_getPrototypeOf(C).call(this))).element=e,n.version=C.version,n.defaultOptions.previewTemplate=n.defaultOptions.previewTemplate.replace(/\n*/g,""),n.clickableElements=[],n.listeners=[],n.files=[],"string"==typeof n.element&&(n.element=document.querySelector(n.element)),!n.element||null==n.element.nodeType)throw new Error("Invalid dropzone element.");if(n.element.dropzone)throw new Error("Dropzone already attached.");C.instances.push(_assertThisInitialized(n)),n.element.dropzone=_assertThisInitialized(n);var o=null!=(r=C.optionsForElement(n.element))?r:{};if(n.options=C.extend({},n.defaultOptions,o,null!=t?t:{}),n.options.forceFallback||!C.isBrowserSupported())return _possibleConstructorReturn(n,n.options.fallback.call(_assertThisInitialized(n)));if(null==n.options.url&&(n.options.url=n.element.getAttribute("action")),!n.options.url)throw new Error("No URL provided.");if(n.options.acceptedFiles&&n.options.acceptedMimeTypes)throw new Error("You can't provide both 'acceptedFiles' and 'acceptedMimeTypes'. 'acceptedMimeTypes' is deprecated.");if(n.options.uploadMultiple&&n.options.chunking)throw new Error("You cannot set both: uploadMultiple and chunking.");return n.options.acceptedMimeTypes&&(n.options.acceptedFiles=n.options.acceptedMimeTypes,delete n.options.acceptedMimeTypes),null!=n.options.renameFilename&&(n.options.renameFile=function(e){return n.options.renameFilename.call(_assertThisInitialized(n),e.name,e)}),n.options.method=n.options.method.toUpperCase(),(i=n.getExistingFallback())&&i.parentNode&&i.parentNode.removeChild(i),!1!==n.options.previewsContainer&&(n.options.previewsContainer?n.previewsContainer=C.getElement(n.options.previewsContainer,"previewsContainer"):n.previewsContainer=n.element),n.options.clickable&&(!0===n.options.clickable?n.clickableElements=[n.element]:n.clickableElements=C.getElements(n.options.clickable,"clickable")),n.init(),n}return _inherits(C,Emitter),_createClass(C,null,[{key:"initClass",value:function(){this.prototype.Emitter=Emitter,this.prototype.events=["drop","dragstart","dragend","dragenter","dragover","dragleave","addedfile","addedfiles","removedfile","thumbnail","error","errormultiple","processing","processingmultiple","uploadprogress","totaluploadprogress","sending","sendingmultiple","success","successmultiple","canceled","canceledmultiple","complete","completemultiple","reset","maxfilesexceeded","maxfilesreached","queuecomplete"],this.prototype.defaultOptions={url:null,method:"post",withCredentials:!1,timeout:3e4,parallelUploads:2,uploadMultiple:!1,chunking:!1,forceChunking:!1,chunkSize:2e6,parallelChunkUploads:!1,retryChunks:!1,retryChunksLimit:3,maxFilesize:256,paramName:"file",createImageThumbnails:!0,maxThumbnailFilesize:10,thumbnailWidth:120,thumbnailHeight:120,thumbnailMethod:"crop",resizeWidth:null,resizeHeight:null,resizeMimeType:null,resizeQuality:.8,resizeMethod:"contain",filesizeBase:1e3,maxFiles:null,headers:null,clickable:!0,ignoreHiddenFiles:!0,acceptedFiles:null,acceptedMimeTypes:null,autoProcessQueue:!0,autoQueue:!0,addRemoveLinks:!1,previewsContainer:null,hiddenInputContainer:"body",capture:null,renameFilename:null,renameFile:null,forceFallback:!1,dictDefaultMessage:"Drop files here to upload",dictFallbackMessage:"Your browser does not support drag'n'drop file uploads.",dictFallbackText:"Please use the fallback form below to upload your files like in the olden days.",dictFileTooBig:"File is too big ({{filesize}}MiB). Max filesize: {{maxFilesize}}MiB.",dictInvalidFileType:"You can't upload files of this type.",dictResponseError:"Server responded with {{statusCode}} code.",dictCancelUpload:"Cancel upload",dictUploadCanceled:"Upload canceled.",dictCancelUploadConfirmation:"Are you sure you want to cancel this upload?",dictRemoveFile:"Remove file",dictRemoveFileConfirmation:null,dictMaxFilesExceeded:"You can not upload any more files.",dictFileSizeUnits:{tb:"TB",gb:"GB",mb:"MB",kb:"KB",b:"b"},init:function(){},params:function(e,t,n){if(n)return{dzuuid:n.file.upload.uuid,dzchunkindex:n.index,dztotalfilesize:n.file.size,dzchunksize:this.options.chunkSize,dztotalchunkcount:n.file.upload.totalChunkCount,dzchunkbyteoffset:n.index*this.options.chunkSize}},accept:function(e,t){return t()},chunksUploaded:function(e,t){t()},fallback:function(){var e;this.element.className="".concat(this.element.className," dz-browser-not-supported");var t=!0,n=!1,i=void 0;try{for(var r,o=this.element.getElementsByTagName("div")[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;if(/(^| )dz-message($| )/.test(a.className)){(e=a).className="dz-message";break}}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}e||(e=C.createElement('<div class="dz-message"><span></span></div>'),this.element.appendChild(e));var l=e.getElementsByTagName("span")[0];return l&&(null!=l.textContent?l.textContent=this.options.dictFallbackMessage:null!=l.innerText&&(l.innerText=this.options.dictFallbackMessage)),this.element.appendChild(this.getFallbackForm())},resize:function(e,t,n,i){var r={srcX:0,srcY:0,srcWidth:e.width,srcHeight:e.height},o=e.width/e.height;null==t&&null==n?(t=r.srcWidth,n=r.srcHeight):null==t?t=n*o:null==n&&(n=t/o);var a=(t=Math.min(t,r.srcWidth))/(n=Math.min(n,r.srcHeight));if(r.srcWidth>t||r.srcHeight>n)if("crop"===i)a<o?(r.srcHeight=e.height,r.srcWidth=r.srcHeight*a):(r.srcWidth=e.width,r.srcHeight=r.srcWidth/a);else{if("contain"!==i)throw new Error("Unknown resizeMethod '".concat(i,"'"));a<o?n=t/o:t=n*o}return r.srcX=(e.width-r.srcWidth)/2,r.srcY=(e.height-r.srcHeight)/2,r.trgWidth=t,r.trgHeight=n,r},transformFile:function(e,t){return(this.options.resizeWidth||this.options.resizeHeight)&&e.type.match(/image.*/)?this.resizeImage(e,this.options.resizeWidth,this.options.resizeHeight,this.options.resizeMethod,t):t(e)},previewTemplate:'<div class="dz-preview dz-file-preview">\n <div class="dz-image"><img data-dz-thumbnail /></div>\n <div class="dz-details">\n <div class="dz-size"><span data-dz-size></span></div>\n <div class="dz-filename"><span data-dz-name></span></div>\n </div>\n <div class="dz-progress"><span class="dz-upload" data-dz-uploadprogress></span></div>\n <div class="dz-error-message"><span data-dz-errormessage></span></div>\n <div class="dz-success-mark">\n <svg width="54px" height="54px" viewBox="0 0 54 54" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">\n <title>Check</title>\n <g stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">\n <path d="M23.5,31.8431458 L17.5852419,25.9283877 C16.0248253,24.3679711 13.4910294,24.366835 11.9289322,25.9289322 C10.3700136,27.4878508 10.3665912,30.0234455 11.9283877,31.5852419 L20.4147581,40.0716123 C20.5133999,40.1702541 20.6159315,40.2626649 20.7218615,40.3488435 C22.2835669,41.8725651 24.794234,41.8626202 26.3461564,40.3106978 L43.3106978,23.3461564 C44.8771021,21.7797521 44.8758057,19.2483887 43.3137085,17.6862915 C41.7547899,16.1273729 39.2176035,16.1255422 37.6538436,17.6893022 L23.5,31.8431458 Z M27,53 C41.3594035,53 53,41.3594035 53,27 C53,12.6405965 41.3594035,1 27,1 C12.6405965,1 1,12.6405965 1,27 C1,41.3594035 12.6405965,53 27,53 Z" stroke-opacity="0.198794158" stroke="#747474" fill-opacity="0.816519475" fill="#FFFFFF"></path>\n </g>\n </svg>\n </div>\n <div class="dz-error-mark">\n <svg width="54px" height="54px" viewBox="0 0 54 54" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">\n <title>Error</title>\n <g stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">\n <g stroke="#747474" stroke-opacity="0.198794158" fill="#FFFFFF" fill-opacity="0.816519475">\n <path d="M32.6568542,29 L38.3106978,23.3461564 C39.8771021,21.7797521 39.8758057,19.2483887 38.3137085,17.6862915 C36.7547899,16.1273729 34.2176035,16.1255422 32.6538436,17.6893022 L27,23.3431458 L21.3461564,17.6893022 C19.7823965,16.1255422 17.2452101,16.1273729 15.6862915,17.6862915 C14.1241943,19.2483887 14.1228979,21.7797521 15.6893022,23.3461564 L21.3431458,29 L15.6893022,34.6538436 C14.1228979,36.2202479 14.1241943,38.7516113 15.6862915,40.3137085 C17.2452101,41.8726271 19.7823965,41.8744578 21.3461564,40.3106978 L27,34.6568542 L32.6538436,40.3106978 C34.2176035,41.8744578 36.7547899,41.8726271 38.3137085,40.3137085 C39.8758057,38.7516113 39.8771021,36.2202479 38.3106978,34.6538436 L32.6568542,29 Z M27,53 C41.3594035,53 53,41.3594035 53,27 C53,12.6405965 41.3594035,1 27,1 C12.6405965,1 1,12.6405965 1,27 C1,41.3594035 12.6405965,53 27,53 Z"></path>\n </g>\n </g>\n </svg>\n </div>\n</div>',drop:function(){return this.element.classList.remove("dz-drag-hover")},dragstart:function(){},dragend:function(){return this.element.classList.remove("dz-drag-hover")},dragenter:function(){return this.element.classList.add("dz-drag-hover")},dragover:function(){return this.element.classList.add("dz-drag-hover")},dragleave:function(){return this.element.classList.remove("dz-drag-hover")},paste:function(){},reset:function(){return this.element.classList.remove("dz-started")},addedfile:function(t){var n=this;if(this.element===this.previewsContainer&&this.element.classList.add("dz-started"),this.previewsContainer){t.previewElement=C.createElement(this.options.previewTemplate.trim()),t.previewTemplate=t.previewElement,this.previewsContainer.appendChild(t.previewElement);var e=!0,i=!1,r=void 0;try{for(var o,a=t.previewElement.querySelectorAll("[data-dz-name]")[Symbol.iterator]();!(e=(o=a.next()).done);e=!0){var l=o.value;l.textContent=t.name}}catch(e){i=!0,r=e}finally{try{e||null==a.return||a.return()}finally{if(i)throw r}}var s=!0,u=!1,c=void 0;try{for(var d,p=t.previewElement.querySelectorAll("[data-dz-size]")[Symbol.iterator]();!(s=(d=p.next()).done);s=!0)(l=d.value).innerHTML=this.filesize(t.size)}catch(e){u=!0,c=e}finally{try{s||null==p.return||p.return()}finally{if(u)throw c}}this.options.addRemoveLinks&&(t._removeLink=C.createElement('<a class="dz-remove" href="javascript:undefined;" data-dz-remove>'.concat(this.options.dictRemoveFile,"</a>")),t.previewElement.appendChild(t._removeLink));var h=function(e){return e.preventDefault(),e.stopPropagation(),t.status===C.UPLOADING?C.confirm(n.options.dictCancelUploadConfirmation,function(){return n.removeFile(t)}):n.options.dictRemoveFileConfirmation?C.confirm(n.options.dictRemoveFileConfirmation,function(){return n.removeFile(t)}):n.removeFile(t)},f=!0,v=!1,m=void 0;try{for(var y,g=t.previewElement.querySelectorAll("[data-dz-remove]")[Symbol.iterator]();!(f=(y=g.next()).done);f=!0){y.value.addEventListener("click",h)}}catch(e){v=!0,m=e}finally{try{f||null==g.return||g.return()}finally{if(v)throw m}}}},removedfile:function(e){return null!=e.previewElement&&null!=e.previewElement.parentNode&&e.previewElement.parentNode.removeChild(e.previewElement),this._updateMaxFilesReachedClass()},thumbnail:function(e,t){if(e.previewElement){e.previewElement.classList.remove("dz-file-preview");var n=!0,i=!1,r=void 0;try{for(var o,a=e.previewElement.querySelectorAll("[data-dz-thumbnail]")[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var l=o.value;l.alt=e.name,l.src=t}}catch(e){i=!0,r=e}finally{try{n||null==a.return||a.return()}finally{if(i)throw r}}return setTimeout(function(){return e.previewElement.classList.add("dz-image-preview")},1)}},error:function(e,t){if(e.previewElement){e.previewElement.classList.add("dz-error"),"String"!=typeof t&&t.error&&(t=t.error);var n=!0,i=!1,r=void 0;try{for(var o,a=e.previewElement.querySelectorAll("[data-dz-errormessage]")[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){o.value.textContent=t}}catch(e){i=!0,r=e}finally{try{n||null==a.return||a.return()}finally{if(i)throw r}}}},errormultiple:function(){},processing:function(e){if(e.previewElement&&(e.previewElement.classList.add("dz-processing"),e._removeLink))return e._removeLink.innerHTML=this.options.dictCancelUpload},processingmultiple:function(){},uploadprogress:function(e,t){if(e.previewElement){var n=!0,i=!1,r=void 0;try{for(var o,a=e.previewElement.querySelectorAll("[data-dz-uploadprogress]")[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){var l=o.value;"PROGRESS"===l.nodeName?l.value=t:l.style.width="".concat(t,"%")}}catch(e){i=!0,r=e}finally{try{n||null==a.return||a.return()}finally{if(i)throw r}}}},totaluploadprogress:function(){},sending:function(){},sendingmultiple:function(){},success:function(e){if(e.previewElement)return e.previewElement.classList.add("dz-success")},successmultiple:function(){},canceled:function(e){return this.emit("error",e,this.options.dictUploadCanceled)},canceledmultiple:function(){},complete:function(e){if(e._removeLink&&(e._removeLink.innerHTML=this.options.dictRemoveFile),e.previewElement)return e.previewElement.classList.add("dz-complete")},completemultiple:function(){},maxfilesexceeded:function(){},maxfilesreached:function(){},queuecomplete:function(){},addedfiles:function(){}},this.prototype._thumbnailQueue=[],this.prototype._processingThumbnail=!1}},{key:"extend",value:function(e){for(var t=arguments.length,n=new Array(1<t?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];for(var r=0,o=n;r<o.length;r++){var a=o[r];for(var l in a){var s=a[l];e[l]=s}}return e}}]),_createClass(C,[{key:"getAcceptedFiles",value:function(){return this.files.filter(function(e){return e.accepted}).map(function(e){return e})}},{key:"getRejectedFiles",value:function(){return this.files.filter(function(e){return!e.accepted}).map(function(e){return e})}},{key:"getFilesWithStatus",value:function(t){return this.files.filter(function(e){return e.status===t}).map(function(e){return e})}},{key:"getQueuedFiles",value:function(){return this.getFilesWithStatus(C.QUEUED)}},{key:"getUploadingFiles",value:function(){return this.getFilesWithStatus(C.UPLOADING)}},{key:"getAddedFiles",value:function(){return this.getFilesWithStatus(C.ADDED)}},{key:"getActiveFiles",value:function(){return this.files.filter(function(e){return e.status===C.UPLOADING||e.status===C.QUEUED}).map(function(e){return e})}},{key:"init",value:function(){var s=this;if("form"===this.element.tagName&&this.element.setAttribute("enctype","multipart/form-data"),this.element.classList.contains("dropzone")&&!this.element.querySelector(".dz-message")&&this.element.appendChild(C.createElement('<div class="dz-default dz-message"><button class="dz-button" type="button">'.concat(this.options.dictDefaultMessage,"</button></div>"))),this.clickableElements.length){!function l(){return s.hiddenFileInput&&s.hiddenFileInput.parentNode.removeChild(s.hiddenFileInput),s.hiddenFileInput=document.createElement("input"),s.hiddenFileInput.setAttribute("type","file"),(null===s.options.maxFiles||1<s.options.maxFiles)&&s.hiddenFileInput.setAttribute("multiple","multiple"),s.hiddenFileInput.className="dz-hidden-input",null!==s.options.acceptedFiles&&s.hiddenFileInput.setAttribute("accept",s.options.acceptedFiles),null!==s.options.capture&&s.hiddenFileInput.setAttribute("capture",s.options.capture),s.hiddenFileInput.style.visibility="hidden",s.hiddenFileInput.style.position="absolute",s.hiddenFileInput.style.top="0",s.hiddenFileInput.style.left="0",s.hiddenFileInput.style.height="0",s.hiddenFileInput.style.width="0",C.getElement(s.options.hiddenInputContainer,"hiddenInputContainer").appendChild(s.hiddenFileInput),s.hiddenFileInput.addEventListener("change",function(){var e=s.hiddenFileInput.files;if(e.length){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;s.addFile(a)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}}return s.emit("addedfiles",e),l()})}()}this.URL=null!==window.URL?window.URL:window.webkitURL;var e=!0,t=!1,n=void 0;try{for(var i,r=this.events[Symbol.iterator]();!(e=(i=r.next()).done);e=!0){var o=i.value;this.on(o,this.options[o])}}catch(e){t=!0,n=e}finally{try{e||null==r.return||r.return()}finally{if(t)throw n}}this.on("uploadprogress",function(){return s.updateTotalUploadProgress()}),this.on("removedfile",function(){return s.updateTotalUploadProgress()}),this.on("canceled",function(e){return s.emit("complete",e)}),this.on("complete",function(e){if(0===s.getAddedFiles().length&&0===s.getUploadingFiles().length&&0===s.getQueuedFiles().length)return setTimeout(function(){return s.emit("queuecomplete")},0)});function a(e){var t;return(t=e).dataTransfer.types&&t.dataTransfer.types.some(function(e){return"Files"==e})&&(e.stopPropagation(),e.preventDefault?e.preventDefault():e.returnValue=!1)}return this.listeners=[{element:this.element,events:{dragstart:function(e){return s.emit("dragstart",e)},dragenter:function(e){return a(e),s.emit("dragenter",e)},dragover:function(e){var t;try{t=e.dataTransfer.effectAllowed}catch(e){}return e.dataTransfer.dropEffect="move"===t||"linkMove"===t?"move":"copy",a(e),s.emit("dragover",e)},dragleave:function(e){return s.emit("dragleave",e)},drop:function(e){return a(e),s.drop(e)},dragend:function(e){return s.emit("dragend",e)}}}],this.clickableElements.forEach(function(t){return s.listeners.push({element:t,events:{click:function(e){return t===s.element&&e.target!==s.element&&!C.elementInside(e.target,s.element.querySelector(".dz-message"))||s.hiddenFileInput.click(),!0}}})}),this.enable(),this.options.init.call(this)}},{key:"destroy",value:function(){return this.disable(),this.removeAllFiles(!0),null!=this.hiddenFileInput&&this.hiddenFileInput.parentNode&&(this.hiddenFileInput.parentNode.removeChild(this.hiddenFileInput),this.hiddenFileInput=null),delete this.element.dropzone,C.instances.splice(C.instances.indexOf(this),1)}},{key:"updateTotalUploadProgress",value:function(){var e,t=0,n=0;if(this.getActiveFiles().length){var i=!0,r=!1,o=void 0;try{for(var a,l=this.getActiveFiles()[Symbol.iterator]();!(i=(a=l.next()).done);i=!0){var s=a.value;t+=s.upload.bytesSent,n+=s.upload.total}}catch(e){r=!0,o=e}finally{try{i||null==l.return||l.return()}finally{if(r)throw o}}e=100*t/n}else e=100;return this.emit("totaluploadprogress",e,n,t)}},{key:"_getParamName",value:function(e){return"function"==typeof this.options.paramName?this.options.paramName(e):"".concat(this.options.paramName).concat(this.options.uploadMultiple?"[".concat(e,"]"):"")}},{key:"_renameFile",value:function(e){return"function"!=typeof this.options.renameFile?e.name:this.options.renameFile(e)}},{key:"getFallbackForm",value:function(){var e,t;if(e=this.getExistingFallback())return e;var n='<div class="dz-fallback">';this.options.dictFallbackText&&(n+="<p>".concat(this.options.dictFallbackText,"</p>")),n+='<input type="file" name="'.concat(this._getParamName(0),'" ').concat(this.options.uploadMultiple?'multiple="multiple"':void 0,' /><input type="submit" value="Upload!"></div>');var i=C.createElement(n);return"FORM"!==this.element.tagName?(t=C.createElement('<form action="'.concat(this.options.url,'" enctype="multipart/form-data" method="').concat(this.options.method,'"></form>'))).appendChild(i):(this.element.setAttribute("enctype","multipart/form-data"),this.element.setAttribute("method",this.options.method)),null!=t?t:i}},{key:"getExistingFallback",value:function(){for(var e=function(e){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;if(/(^| )fallback($| )/.test(a.className))return a}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}},t=0,n=["div","form"];t<n.length;t++){var i,r=n[t];if(i=e(this.element.getElementsByTagName(r)))return i}}},{key:"setupEventListeners",value:function(){return this.listeners.map(function(i){return function(){var e=[];for(var t in i.events){var n=i.events[t];e.push(i.element.addEventListener(t,n,!1))}return e}()})}},{key:"removeEventListeners",value:function(){return this.listeners.map(function(i){return function(){var e=[];for(var t in i.events){var n=i.events[t];e.push(i.element.removeEventListener(t,n,!1))}return e}()})}},{key:"disable",value:function(){var t=this;return this.clickableElements.forEach(function(e){return e.classList.remove("dz-clickable")}),this.removeEventListeners(),this.disabled=!0,this.files.map(function(e){return t.cancelUpload(e)})}},{key:"enable",value:function(){return delete this.disabled,this.clickableElements.forEach(function(e){return e.classList.add("dz-clickable")}),this.setupEventListeners()}},{key:"filesize",value:function(e){var t=0,n="b";if(0<e){for(var i=["tb","gb","mb","kb","b"],r=0;r<i.length;r++){var o=i[r];if(Math.pow(this.options.filesizeBase,4-r)/10<=e){t=e/Math.pow(this.options.filesizeBase,4-r),n=o;break}}t=Math.round(10*t)/10}return"<strong>".concat(t,"</strong> ").concat(this.options.dictFileSizeUnits[n])}},{key:"_updateMaxFilesReachedClass",value:function(){return null!=this.options.maxFiles&&this.getAcceptedFiles().length>=this.options.maxFiles?(this.getAcceptedFiles().length===this.options.maxFiles&&this.emit("maxfilesreached",this.files),this.element.classList.add("dz-max-files-reached")):this.element.classList.remove("dz-max-files-reached")}},{key:"drop",value:function(e){if(e.dataTransfer){this.emit("drop",e);for(var t=[],n=0;n<e.dataTransfer.files.length;n++)t[n]=e.dataTransfer.files[n];if(t.length){var i=e.dataTransfer.items;i&&i.length&&null!=i[0].webkitGetAsEntry?this._addFilesFromItems(i):this.handleFiles(t)}this.emit("addedfiles",t)}}},{key:"paste",value:function(e){if(null!=__guard__(null!=e?e.clipboardData:void 0,function(e){return e.items})){this.emit("paste",e);var t=e.clipboardData.items;return t.length?this._addFilesFromItems(t):void 0}}},{key:"handleFiles",value:function(e){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;this.addFile(a)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}}},{key:"_addFilesFromItems",value:function(s){var u=this;return function(){var e=[],t=!0,n=!1,i=void 0;try{for(var r,o=s[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a,l=r.value;null!=l.webkitGetAsEntry&&(a=l.webkitGetAsEntry())?a.isFile?e.push(u.addFile(l.getAsFile())):a.isDirectory?e.push(u._addFilesFromDirectory(a,a.name)):e.push(void 0):null!=l.getAsFile&&(null==l.kind||"file"===l.kind)?e.push(u.addFile(l.getAsFile())):e.push(void 0)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return e}()}},{key:"_addFilesFromDirectory",value:function(e,s){function t(t){return __guardMethod__(console,"log",function(e){return e.log(t)})}var u=this,n=e.createReader();return function l(){return n.readEntries(function(e){if(0<e.length){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;a.isFile?a.file(function(e){if(!u.options.ignoreHiddenFiles||"."!==e.name.substring(0,1))return e.fullPath="".concat(s,"/").concat(e.name),u.addFile(e)}):a.isDirectory&&u._addFilesFromDirectory(a,"".concat(s,"/").concat(a.name))}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}l()}return null},t)}()}},{key:"accept",value:function(e,t){this.options.maxFilesize&&e.size>1024*this.options.maxFilesize*1024?t(this.options.dictFileTooBig.replace("{{filesize}}",Math.round(e.size/1024/10.24)/100).replace("{{maxFilesize}}",this.options.maxFilesize)):C.isValidFile(e,this.options.acceptedFiles)?null!=this.options.maxFiles&&this.getAcceptedFiles().length>=this.options.maxFiles?(t(this.options.dictMaxFilesExceeded.replace("{{maxFiles}}",this.options.maxFiles)),this.emit("maxfilesexceeded",e)):this.options.accept.call(this,e,t):t(this.options.dictInvalidFileType)}},{key:"addFile",value:function(t){var n=this;t.upload={uuid:C.uuidv4(),progress:0,total:t.size,bytesSent:0,filename:this._renameFile(t)},this.files.push(t),t.status=C.ADDED,this.emit("addedfile",t),this._enqueueThumbnail(t),this.accept(t,function(e){e?(t.accepted=!1,n._errorProcessing([t],e)):(t.accepted=!0,n.options.autoQueue&&n.enqueueFile(t)),n._updateMaxFilesReachedClass()})}},{key:"enqueueFiles",value:function(e){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;this.enqueueFile(a)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return null}},{key:"enqueueFile",value:function(e){var t=this;if(e.status!==C.ADDED||!0!==e.accepted)throw new Error("This file can't be queued because it has already been processed or was rejected.");if(e.status=C.QUEUED,this.options.autoProcessQueue)return setTimeout(function(){return t.processQueue()},0)}},{key:"_enqueueThumbnail",value:function(e){var t=this;if(this.options.createImageThumbnails&&e.type.match(/image.*/)&&e.size<=1024*this.options.maxThumbnailFilesize*1024)return this._thumbnailQueue.push(e),setTimeout(function(){return t._processThumbnailQueue()},0)}},{key:"_processThumbnailQueue",value:function(){var t=this;if(!this._processingThumbnail&&0!==this._thumbnailQueue.length){this._processingThumbnail=!0;var n=this._thumbnailQueue.shift();return this.createThumbnail(n,this.options.thumbnailWidth,this.options.thumbnailHeight,this.options.thumbnailMethod,!0,function(e){return t.emit("thumbnail",n,e),t._processingThumbnail=!1,t._processThumbnailQueue()})}}},{key:"removeFile",value:function(e){if(e.status===C.UPLOADING&&this.cancelUpload(e),this.files=without(this.files,e),this.emit("removedfile",e),0===this.files.length)return this.emit("reset")}},{key:"removeAllFiles",value:function(e){null==e&&(e=!1);var t=!0,n=!1,i=void 0;try{for(var r,o=this.files.slice()[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;a.status===C.UPLOADING&&!e||this.removeFile(a)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return null}},{key:"resizeImage",value:function(r,e,t,n,o){var a=this;return this.createThumbnail(r,e,t,n,!0,function(e,t){if(null==t)return o(r);var n=a.options.resizeMimeType;null==n&&(n=r.type);var i=t.toDataURL(n,a.options.resizeQuality);return"image/jpeg"!==n&&"image/jpg"!==n||(i=ExifRestore.restore(r.dataURL,i)),o(C.dataURItoBlob(i))})}},{key:"createThumbnail",value:function(e,t,n,i,r,o){var a=this,l=new FileReader;l.onload=function(){e.dataURL=l.result,"image/svg+xml"!==e.type?a.createThumbnailFromUrl(e,t,n,i,r,o):null!=o&&o(l.result)},l.readAsDataURL(e)}},{key:"displayExistingFile",value:function(t,e,n,i,r){var o=this,a=!(4<arguments.length&&void 0!==r)||r;if(this.emit("addedfile",t),this.emit("complete",t),a){t.dataURL=e,this.createThumbnailFromUrl(t,this.options.thumbnailWidth,this.options.thumbnailHeight,this.options.resizeMethod,this.options.fixOrientation,function(e){o.emit("thumbnail",t,e),n&&n()},i)}else this.emit("thumbnail",t,e),n&&n()}},{key:"createThumbnailFromUrl",value:function(o,a,l,s,t,u,e){var c=this,d=document.createElement("img");return e&&(d.crossOrigin=e),d.onload=function(){var e=function(e){return e(1)};return"undefined"!=typeof EXIF&&null!==EXIF&&t&&(e=function(e){return EXIF.getData(d,function(){return e(EXIF.getTag(this,"Orientation"))})}),e(function(e){o.width=d.width,o.height=d.height;var t=c.options.resize.call(c,o,a,l,s),n=document.createElement("canvas"),i=n.getContext("2d");switch(n.width=t.trgWidth,n.height=t.trgHeight,4<e&&(n.width=t.trgHeight,n.height=t.trgWidth),e){case 2:i.translate(n.width,0),i.scale(-1,1);break;case 3:i.translate(n.width,n.height),i.rotate(Math.PI);break;case 4:i.translate(0,n.height),i.scale(1,-1);break;case 5:i.rotate(.5*Math.PI),i.scale(1,-1);break;case 6:i.rotate(.5*Math.PI),i.translate(0,-n.width);break;case 7:i.rotate(.5*Math.PI),i.translate(n.height,-n.width),i.scale(-1,1);break;case 8:i.rotate(-.5*Math.PI),i.translate(-n.height,0)}drawImageIOSFix(i,d,null!=t.srcX?t.srcX:0,null!=t.srcY?t.srcY:0,t.srcWidth,t.srcHeight,null!=t.trgX?t.trgX:0,null!=t.trgY?t.trgY:0,t.trgWidth,t.trgHeight);var r=n.toDataURL("image/png");if(null!=u)return u(r,n)})},null!=u&&(d.onerror=u),d.src=o.dataURL}},{key:"processQueue",value:function(){var e=this.options.parallelUploads,t=this.getUploadingFiles().length,n=t;if(!(e<=t)){var i=this.getQueuedFiles();if(0<i.length){if(this.options.uploadMultiple)return this.processFiles(i.slice(0,e-t));for(;n<e;){if(!i.length)return;this.processFile(i.shift()),n++}}}}},{key:"processFile",value:function(e){return this.processFiles([e])}},{key:"processFiles",value:function(e){var t=!0,n=!1,i=void 0;try{for(var r,o=e[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;a.processing=!0,a.status=C.UPLOADING,this.emit("processing",a)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return this.options.uploadMultiple&&this.emit("processingmultiple",e),this.uploadFiles(e)}},{key:"_getFilesWithXhr",value:function(t){return this.files.filter(function(e){return e.xhr===t}).map(function(e){return e})}},{key:"cancelUpload",value:function(e){if(e.status===C.UPLOADING){var t=this._getFilesWithXhr(e.xhr),n=!0,i=!1,r=void 0;try{for(var o,a=t[Symbol.iterator]();!(n=(o=a.next()).done);n=!0){o.value.status=C.CANCELED}}catch(e){i=!0,r=e}finally{try{n||null==a.return||a.return()}finally{if(i)throw r}}void 0!==e.xhr&&e.xhr.abort();var l=!0,s=!1,u=void 0;try{for(var c,d=t[Symbol.iterator]();!(l=(c=d.next()).done);l=!0){var p=c.value;this.emit("canceled",p)}}catch(e){s=!0,u=e}finally{try{l||null==d.return||d.return()}finally{if(s)throw u}}this.options.uploadMultiple&&this.emit("canceledmultiple",t)}else e.status!==C.ADDED&&e.status!==C.QUEUED||(e.status=C.CANCELED,this.emit("canceled",e),this.options.uploadMultiple&&this.emit("canceledmultiple",[e]));if(this.options.autoProcessQueue)return this.processQueue()}},{key:"resolveOption",value:function(e){if("function"!=typeof e)return e;for(var t=arguments.length,n=new Array(1<t?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return e.apply(this,n)}},{key:"uploadFile",value:function(e){return this.uploadFiles([e])}},{key:"uploadFiles",value:function(s){var u=this;this._transformFiles(s,function(e){if(u.options.chunking){var t=e[0];s[0].upload.chunked=u.options.chunking&&(u.options.forceChunking||t.size>u.options.chunkSize),s[0].upload.totalChunkCount=Math.ceil(t.size/u.options.chunkSize)}if(s[0].upload.chunked){var r=s[0],o=e[0];r.upload.chunks=[];var i=function(){for(var e=0;void 0!==r.upload.chunks[e];)e++;if(!(e>=r.upload.totalChunkCount)){0;var t=e*u.options.chunkSize,n=Math.min(t+u.options.chunkSize,r.size),i={name:u._getParamName(0),data:o.webkitSlice?o.webkitSlice(t,n):o.slice(t,n),filename:r.upload.filename,chunkIndex:e};r.upload.chunks[e]={file:r,index:e,dataBlock:i,status:C.UPLOADING,progress:0,retries:0},u._uploadData(s,[i])}};if(r.upload.finishedChunkUpload=function(e){var t=!0;e.status=C.SUCCESS,e.dataBlock=null,e.xhr=null;for(var n=0;n<r.upload.totalChunkCount;n++){if(void 0===r.upload.chunks[n])return i();r.upload.chunks[n].status!==C.SUCCESS&&(t=!1)}t&&u.options.chunksUploaded(r,function(){u._finished(s,"",null)})},u.options.parallelChunkUploads)for(var n=0;n<r.upload.totalChunkCount;n++)i();else i()}else{for(var a=[],l=0;l<s.length;l++)a[l]={name:u._getParamName(l),data:e[l],filename:s[l].upload.filename};u._uploadData(s,a)}})}},{key:"_getChunk",value:function(e,t){for(var n=0;n<e.upload.totalChunkCount;n++)if(void 0!==e.upload.chunks[n]&&e.upload.chunks[n].xhr===t)return e.upload.chunks[n]}},{key:"_uploadData",value:function(t,e){var n=this,i=new XMLHttpRequest,r=!0,o=!1,a=void 0;try{for(var l,s=t[Symbol.iterator]();!(r=(l=s.next()).done);r=!0){l.value.xhr=i}}catch(e){o=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw a}}t[0].upload.chunked&&(t[0].upload.chunks[e[0].chunkIndex].xhr=i);var u=this.resolveOption(this.options.method,t),c=this.resolveOption(this.options.url,t);i.open(u,c,!0),i.timeout=this.resolveOption(this.options.timeout,t),i.withCredentials=!!this.options.withCredentials,i.onload=function(e){n._finishedUploading(t,i,e)},i.ontimeout=function(){n._handleUploadError(t,i,"Request timedout after ".concat(n.options.timeout," seconds"))},i.onerror=function(){n._handleUploadError(t,i)},(null!=i.upload?i.upload:i).onprogress=function(e){return n._updateFilesUploadProgress(t,i,e)};var d={Accept:"application/json","Cache-Control":"no-cache","X-Requested-With":"XMLHttpRequest"};for(var p in this.options.headers&&C.extend(d,this.options.headers),d){var h=d[p];h&&i.setRequestHeader(p,h)}var f=new FormData;if(this.options.params){var v=this.options.params;for(var m in"function"==typeof v&&(v=v.call(this,t,i,t[0].upload.chunked?this._getChunk(t[0],i):null)),v){var y=v[m];f.append(m,y)}}var g=!0,b=!1,k=void 0;try{for(var w,F=t[Symbol.iterator]();!(g=(w=F.next()).done);g=!0){var z=w.value;this.emit("sending",z,i,f)}}catch(e){b=!0,k=e}finally{try{g||null==F.return||F.return()}finally{if(b)throw k}}this.options.uploadMultiple&&this.emit("sendingmultiple",t,i,f),this._addFormElementData(f);for(var x=0;x<e.length;x++){var E=e[x];f.append(E.name,E.data,E.filename)}this.submitRequest(i,f,t)}},{key:"_transformFiles",value:function(n,i){for(var e=this,r=[],o=0,t=function(t){e.options.transformFile.call(e,n[t],function(e){r[t]=e,++o===n.length&&i(r)})},a=0;a<n.length;a++)t(a)}},{key:"_addFormElementData",value:function(e){if("FORM"===this.element.tagName){var t=!0,n=!1,i=void 0;try{for(var r,o=this.element.querySelectorAll("input, textarea, select, button")[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value,l=a.getAttribute("name"),s=a.getAttribute("type");if(s=s&&s.toLowerCase(),null!=l)if("SELECT"===a.tagName&&a.hasAttribute("multiple")){var u=!0,c=!1,d=void 0;try{for(var p,h=a.options[Symbol.iterator]();!(u=(p=h.next()).done);u=!0){var f=p.value;f.selected&&e.append(l,f.value)}}catch(e){c=!0,d=e}finally{try{u||null==h.return||h.return()}finally{if(c)throw d}}}else(!s||"checkbox"!==s&&"radio"!==s||a.checked)&&e.append(l,a.value)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}}}},{key:"_updateFilesUploadProgress",value:function(e,t,n){var i;if(void 0!==n){if(i=100*n.loaded/n.total,e[0].upload.chunked){var r=e[0],o=this._getChunk(r,t);o.progress=i,o.total=n.total,o.bytesSent=n.loaded;r.upload.progress=0,r.upload.total=0;for(var a=r.upload.bytesSent=0;a<r.upload.totalChunkCount;a++)void 0!==r.upload.chunks[a]&&void 0!==r.upload.chunks[a].progress&&(r.upload.progress+=r.upload.chunks[a].progress,r.upload.total+=r.upload.chunks[a].total,r.upload.bytesSent+=r.upload.chunks[a].bytesSent);r.upload.progress=r.upload.progress/r.upload.totalChunkCount}else{var l=!0,s=!1,u=void 0;try{for(var c,d=e[Symbol.iterator]();!(l=(c=d.next()).done);l=!0){var p=c.value;p.upload.progress=i,p.upload.total=n.total,p.upload.bytesSent=n.loaded}}catch(e){s=!0,u=e}finally{try{l||null==d.return||d.return()}finally{if(s)throw u}}}var h=!0,f=!1,v=void 0;try{for(var m,y=e[Symbol.iterator]();!(h=(m=y.next()).done);h=!0){var g=m.value;this.emit("uploadprogress",g,g.upload.progress,g.upload.bytesSent)}}catch(e){f=!0,v=e}finally{try{h||null==y.return||y.return()}finally{if(f)throw v}}}else{var b=!0,k=!0,w=!(i=100),F=void 0;try{for(var z,x=e[Symbol.iterator]();!(k=(z=x.next()).done);k=!0){var E=z.value;100===E.upload.progress&&E.upload.bytesSent===E.upload.total||(b=!1),E.upload.progress=i,E.upload.bytesSent=E.upload.total}}catch(e){w=!0,F=e}finally{try{k||null==x.return||x.return()}finally{if(w)throw F}}if(b)return;var C=!0,_=!1,S=void 0;try{for(var D,T=e[Symbol.iterator]();!(C=(D=T.next()).done);C=!0){var L=D.value;this.emit("uploadprogress",L,i,L.upload.bytesSent)}}catch(e){_=!0,S=e}finally{try{C||null==T.return||T.return()}finally{if(_)throw S}}}}},{key:"_finishedUploading",value:function(e,t,n){var i;if(e[0].status!==C.CANCELED&&4===t.readyState){if("arraybuffer"!==t.responseType&&"blob"!==t.responseType&&(i=t.responseText,t.getResponseHeader("content-type")&&~t.getResponseHeader("content-type").indexOf("application/json")))try{i=JSON.parse(i)}catch(e){n=e,i="Invalid JSON response from server."}this._updateFilesUploadProgress(e),200<=t.status&&t.status<300?e[0].upload.chunked?e[0].upload.finishedChunkUpload(this._getChunk(e[0],t)):this._finished(e,i,n):this._handleUploadError(e,t,i)}}},{key:"_handleUploadError",value:function(e,t,n){if(e[0].status!==C.CANCELED){if(e[0].upload.chunked&&this.options.retryChunks){var i=this._getChunk(e[0],t);if(i.retries++<this.options.retryChunksLimit)return void this._uploadData(e,[i.dataBlock]);console.warn("Retried this chunk too often. Giving up.")}this._errorProcessing(e,n||this.options.dictResponseError.replace("{{statusCode}}",t.status),t)}}},{key:"submitRequest",value:function(e,t){e.send(t)}},{key:"_finished",value:function(e,t,n){var i=!0,r=!1,o=void 0;try{for(var a,l=e[Symbol.iterator]();!(i=(a=l.next()).done);i=!0){var s=a.value;s.status=C.SUCCESS,this.emit("success",s,t,n),this.emit("complete",s)}}catch(e){r=!0,o=e}finally{try{i||null==l.return||l.return()}finally{if(r)throw o}}if(this.options.uploadMultiple&&(this.emit("successmultiple",e,t,n),this.emit("completemultiple",e)),this.options.autoProcessQueue)return this.processQueue()}},{key:"_errorProcessing",value:function(e,t,n){var i=!0,r=!1,o=void 0;try{for(var a,l=e[Symbol.iterator]();!(i=(a=l.next()).done);i=!0){var s=a.value;s.status=C.ERROR,this.emit("error",s,t,n),this.emit("complete",s)}}catch(e){r=!0,o=e}finally{try{i||null==l.return||l.return()}finally{if(r)throw o}}if(this.options.uploadMultiple&&(this.emit("errormultiple",e,t,n),this.emit("completemultiple",e)),this.options.autoProcessQueue)return this.processQueue()}}],[{key:"uuidv4",value:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})}}]),C}();Dropzone.initClass(),Dropzone.version="5.7.0",Dropzone.options={},Dropzone.optionsForElement=function(e){return e.getAttribute("id")?Dropzone.options[camelize(e.getAttribute("id"))]:void 0},Dropzone.instances=[],Dropzone.forElement=function(e){if("string"==typeof e&&(e=document.querySelector(e)),null==(null!=e?e.dropzone:void 0))throw new Error("No Dropzone found for given element. This is probably because you're trying to access it before Dropzone had the time to initialize. Use the `init` option to setup any additional observers on your Dropzone.");return e.dropzone},Dropzone.autoDiscover=!0,Dropzone.discover=function(){var s;if(document.querySelectorAll)s=document.querySelectorAll(".dropzone");else{s=[];var e=function(l){return function(){var e=[],t=!0,n=!1,i=void 0;try{for(var r,o=l[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;/(^| )dropzone($| )/.test(a.className)?e.push(s.push(a)):e.push(void 0)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return e}()};e(document.getElementsByTagName("div")),e(document.getElementsByTagName("form"))}return function(){var e=[],t=!0,n=!1,i=void 0;try{for(var r,o=s[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){var a=r.value;!1!==Dropzone.optionsForElement(a)?e.push(new Dropzone(a)):e.push(void 0)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}return e}()},Dropzone.blacklistedBrowsers=[/opera.*(Macintosh|Windows Phone).*version\/12/i],Dropzone.isBrowserSupported=function(){var e=!0;if(window.File&&window.FileReader&&window.FileList&&window.Blob&&window.FormData&&document.querySelector)if("classList"in document.createElement("a")){var t=!0,n=!1,i=void 0;try{for(var r,o=Dropzone.blacklistedBrowsers[Symbol.iterator]();!(t=(r=o.next()).done);t=!0){r.value.test(navigator.userAgent)&&(e=!1)}}catch(e){n=!0,i=e}finally{try{t||null==o.return||o.return()}finally{if(n)throw i}}}else e=!1;else e=!1;return e},Dropzone.dataURItoBlob=function(e){for(var t=atob(e.split(",")[1]),n=e.split(",")[0].split(":")[1].split(";")[0],i=new ArrayBuffer(t.length),r=new Uint8Array(i),o=0,a=t.length,l=0<=a;l?o<=a:a<=o;l?o++:o--)r[o]=t.charCodeAt(o);return new Blob([i],{type:n})};var without=function(e,t){return e.filter(function(e){return e!==t}).map(function(e){return e})},camelize=function(e){return e.replace(/[\-_](\w)/g,function(e){return e.charAt(1).toUpperCase()})};Dropzone.createElement=function(e){var t=document.createElement("div");return t.innerHTML=e,t.childNodes[0]},Dropzone.elementInside=function(e,t){if(e===t)return!0;for(;e=e.parentNode;)if(e===t)return!0;return!1},Dropzone.getElement=function(e,t){var n;if("string"==typeof e?n=document.querySelector(e):null!=e.nodeType&&(n=e),null==n)throw new Error("Invalid `".concat(t,"` option provided. Please provide a CSS selector or a plain HTML element."));return n},Dropzone.getElements=function(e,t){var n,i;if(e instanceof Array){i=[];try{var r=!0,o=!1,a=void 0;try{for(var l,s=e[Symbol.iterator]();!(r=(l=s.next()).done);r=!0)n=l.value,i.push(this.getElement(n,t))}catch(e){o=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw a}}}catch(e){i=null}}else if("string"==typeof e){var u=!0,c=!(i=[]),d=void 0;try{for(var p,h=document.querySelectorAll(e)[Symbol.iterator]();!(u=(p=h.next()).done);u=!0)n=p.value,i.push(n)}catch(e){c=!0,d=e}finally{try{u||null==h.return||h.return()}finally{if(c)throw d}}}else null!=e.nodeType&&(i=[e]);if(null==i||!i.length)throw new Error("Invalid `".concat(t,"` option provided. Please provide a CSS selector, a plain HTML element or a list of those."));return i},Dropzone.confirm=function(e,t,n){return window.confirm(e)?t():null!=n?n():void 0},Dropzone.isValidFile=function(e,t){if(!t)return!0;t=t.split(",");var n=e.type,i=n.replace(/\/.*$/,""),r=!0,o=!1,a=void 0;try{for(var l,s=t[Symbol.iterator]();!(r=(l=s.next()).done);r=!0){var u=l.value;if("."===(u=u.trim()).charAt(0)){if(-1!==e.name.toLowerCase().indexOf(u.toLowerCase(),e.name.length-u.length))return!0}else if(/\/\*$/.test(u)){if(i===u.replace(/\/.*$/,""))return!0}else if(n===u)return!0}}catch(e){o=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(o)throw a}}return!1},"undefined"!=typeof jQuery&&null!==jQuery&&(jQuery.fn.dropzone=function(e){return this.each(function(){return new Dropzone(this,e)})}),"undefined"!=typeof module&&null!==module?module.exports=Dropzone:window.Dropzone=Dropzone,Dropzone.ADDED="added",Dropzone.QUEUED="queued",Dropzone.ACCEPTED=Dropzone.QUEUED,Dropzone.UPLOADING="uploading",Dropzone.PROCESSING=Dropzone.UPLOADING,Dropzone.CANCELED="canceled",Dropzone.ERROR="error",Dropzone.SUCCESS="success";var detectVerticalSquash=function(e){e.naturalWidth;var t=e.naturalHeight,n=document.createElement("canvas");n.width=1,n.height=t;var i=n.getContext("2d");i.drawImage(e,0,0);for(var r=i.getImageData(1,0,1,t).data,o=0,a=t,l=t;o<l;){0===r[4*(l-1)+3]?a=l:o=l,l=a+o>>1}var s=l/t;return 0==s?1:s},drawImageIOSFix=function(e,t,n,i,r,o,a,l,s,u){var c=detectVerticalSquash(t);return e.drawImage(t,n,i,r,o,a,l,s,u/c)},ExifRestore=function(){function e(){_classCallCheck(this,e)}return _createClass(e,null,[{key:"initClass",value:function(){this.KEY_STR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}},{key:"encode64",value:function(e){for(var t="",n=void 0,i=void 0,r="",o=void 0,a=void 0,l=void 0,s="",u=0;o=(n=e[u++])>>2,a=(3&n)<<4|(i=e[u++])>>4,l=(15&i)<<2|(r=e[u++])>>6,s=63&r,isNaN(i)?l=s=64:isNaN(r)&&(s=64),t=t+this.KEY_STR.charAt(o)+this.KEY_STR.charAt(a)+this.KEY_STR.charAt(l)+this.KEY_STR.charAt(s),n=i=r="",o=a=l=s="",u<e.length;);return t}},{key:"restore",value:function(e,t){if(!e.match("data:image/jpeg;base64,"))return t;var n=this.decode64(e.replace("data:image/jpeg;base64,","")),i=this.slice2Segments(n),r=this.exifManipulation(t,i);return"data:image/jpeg;base64,".concat(this.encode64(r))}},{key:"exifManipulation",value:function(e,t){var n=this.getExifArray(t),i=this.insertExif(e,n);return new Uint8Array(i)}},{key:"getExifArray",value:function(e){for(var t=void 0,n=0;n<e.length;){if(255===(t=e[n])[0]&225===t[1])return t;n++}return[]}},{key:"insertExif",value:function(e,t){var n=e.replace("data:image/jpeg;base64,",""),i=this.decode64(n),r=i.indexOf(255,3),o=i.slice(0,r),a=i.slice(r),l=o;return l=(l=l.concat(t)).concat(a)}},{key:"slice2Segments",value:function(e){for(var t=0,n=[];;){if(255===e[t]&218===e[t+1])break;if(255===e[t]&216===e[t+1])t+=2;else{var i=t+(256*e[t+2]+e[t+3])+2,r=e.slice(t,i);n.push(r),t=i}if(t>e.length)break}return n}},{key:"decode64",value:function(e){var t=void 0,n=void 0,i="",r=void 0,o=void 0,a="",l=0,s=[];for(/[^A-Za-z0-9\+\/\=]/g.exec(e)&&console.warn("There were invalid base64 characters in the input text.\nValid base64 characters are A-Z, a-z, 0-9, '+', '/',and '='\nExpect errors in decoding."),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");t=this.KEY_STR.indexOf(e.charAt(l++))<<2|(r=this.KEY_STR.indexOf(e.charAt(l++)))>>4,n=(15&r)<<4|(o=this.KEY_STR.indexOf(e.charAt(l++)))>>2,i=(3&o)<<6|(a=this.KEY_STR.indexOf(e.charAt(l++))),s.push(t),64!==o&&s.push(n),64!==a&&s.push(i),t=n=i="",r=o=a="",l<e.length;);return s}}]),e}();ExifRestore.initClass();var contentLoaded=function(t,n){function i(e){if("readystatechange"!==e.type||"complete"===o.readyState)return("load"===e.type?t:o)[s](u+e.type,i,!1),!r&&(r=!0)?n.call(t,e.type||e):void 0}var r=!1,e=!0,o=t.document,a=o.documentElement,l=o.addEventListener?"addEventListener":"attachEvent",s=o.addEventListener?"removeEventListener":"detachEvent",u=o.addEventListener?"":"on";if("complete"!==o.readyState){if(o.createEventObject&&a.doScroll){try{e=!t.frameElement}catch(e){}e&&!function t(){try{a.doScroll("left")}catch(e){return void setTimeout(t,50)}return i("poll")}()}return o[l](u+"DOMContentLoaded",i,!1),o[l](u+"readystatechange",i,!1),t[l](u+"load",i,!1)}};function __guard__(e,t){return null!=e?t(e):void 0}function __guardMethod__(e,t,n){return null!=e&&"function"==typeof e[t]?n(e,t):void 0}Dropzone._autoDiscoverFunction=function(){if(Dropzone.autoDiscover)return Dropzone.discover()},contentLoaded(window,Dropzone._autoDiscoverFunction);
admin/js/select2.js ADDED
@@ -0,0 +1 @@
 
1
+ /*! Select2 4.0.6-rc.0 | https://github.com/select2/select2/blob/master/LICENSE.md */!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof module&&module.exports?module.exports=function(b,c){return void 0===c&&(c="undefined"!=typeof window?require("jquery"):require("jquery")(b)),a(c),c}:a(jQuery)}(function(a){var b=function(){if(a&&a.fn&&a.fn.select2&&a.fn.select2.amd)var b=a.fn.select2.amd;var b;return function(){if(!b||!b.requirejs){b?c=b:b={};var a,c,d;!function(b){function e(a,b){return v.call(a,b)}function f(a,b){var c,d,e,f,g,h,i,j,k,l,m,n,o=b&&b.split("/"),p=t.map,q=p&&p["*"]||{};if(a){for(a=a.split("/"),g=a.length-1,t.nodeIdCompat&&x.test(a[g])&&(a[g]=a[g].replace(x,"")),"."===a[0].charAt(0)&&o&&(n=o.slice(0,o.length-1),a=n.concat(a)),k=0;k<a.length;k++)if("."===(m=a[k]))a.splice(k,1),k-=1;else if(".."===m){if(0===k||1===k&&".."===a[2]||".."===a[k-1])continue;k>0&&(a.splice(k-1,2),k-=2)}a=a.join("/")}if((o||q)&&p){for(c=a.split("/"),k=c.length;k>0;k-=1){if(d=c.slice(0,k).join("/"),o)for(l=o.length;l>0;l-=1)if((e=p[o.slice(0,l).join("/")])&&(e=e[d])){f=e,h=k;break}if(f)break;!i&&q&&q[d]&&(i=q[d],j=k)}!f&&i&&(f=i,h=j),f&&(c.splice(0,h,f),a=c.join("/"))}return a}function g(a,c){return function(){var d=w.call(arguments,0);return"string"!=typeof d[0]&&1===d.length&&d.push(null),o.apply(b,d.concat([a,c]))}}function h(a){return function(b){return f(b,a)}}function i(a){return function(b){r[a]=b}}function j(a){if(e(s,a)){var c=s[a];delete s[a],u[a]=!0,n.apply(b,c)}if(!e(r,a)&&!e(u,a))throw new Error("No "+a);return r[a]}function k(a){var b,c=a?a.indexOf("!"):-1;return c>-1&&(b=a.substring(0,c),a=a.substring(c+1,a.length)),[b,a]}function l(a){return a?k(a):[]}function m(a){return function(){return t&&t.config&&t.config[a]||{}}}var n,o,p,q,r={},s={},t={},u={},v=Object.prototype.hasOwnProperty,w=[].slice,x=/\.js$/;p=function(a,b){var c,d=k(a),e=d[0],g=b[1];return a=d[1],e&&(e=f(e,g),c=j(e)),e?a=c&&c.normalize?c.normalize(a,h(g)):f(a,g):(a=f(a,g),d=k(a),e=d[0],a=d[1],e&&(c=j(e))),{f:e?e+"!"+a:a,n:a,pr:e,p:c}},q={require:function(a){return g(a)},exports:function(a){var b=r[a];return void 0!==b?b:r[a]={}},module:function(a){return{id:a,uri:"",exports:r[a],config:m(a)}}},n=function(a,c,d,f){var h,k,m,n,o,t,v,w=[],x=typeof d;if(f=f||a,t=l(f),"undefined"===x||"function"===x){for(c=!c.length&&d.length?["require","exports","module"]:c,o=0;o<c.length;o+=1)if(n=p(c[o],t),"require"===(k=n.f))w[o]=q.require(a);else if("exports"===k)w[o]=q.exports(a),v=!0;else if("module"===k)h=w[o]=q.module(a);else if(e(r,k)||e(s,k)||e(u,k))w[o]=j(k);else{if(!n.p)throw new Error(a+" missing "+k);n.p.load(n.n,g(f,!0),i(k),{}),w[o]=r[k]}m=d?d.apply(r[a],w):void 0,a&&(h&&h.exports!==b&&h.exports!==r[a]?r[a]=h.exports:m===b&&v||(r[a]=m))}else a&&(r[a]=d)},a=c=o=function(a,c,d,e,f){if("string"==typeof a)return q[a]?q[a](c):j(p(a,l(c)).f);if(!a.splice){if(t=a,t.deps&&o(t.deps,t.callback),!c)return;c.splice?(a=c,c=d,d=null):a=b}return c=c||function(){},"function"==typeof d&&(d=e,e=f),e?n(b,a,c,d):setTimeout(function(){n(b,a,c,d)},4),o},o.config=function(a){return o(a)},a._defined=r,d=function(a,b,c){if("string"!=typeof a)throw new Error("See almond README: incorrect module build, no module name");b.splice||(c=b,b=[]),e(r,a)||e(s,a)||(s[a]=[a,b,c])},d.amd={jQuery:!0}}(),b.requirejs=a,b.require=c,b.define=d}}(),b.define("almond",function(){}),b.define("jquery",[],function(){var b=a||$;return null==b&&console&&console.error&&console.error("Select2: An instance of jQuery or a jQuery-compatible library was not found. Make sure that you are including jQuery before Select2 on your web page."),b}),b.define("select2/utils",["jquery"],function(a){function b(a){var b=a.prototype,c=[];for(var d in b){"function"==typeof b[d]&&("constructor"!==d&&c.push(d))}return c}var c={};c.Extend=function(a,b){function c(){this.constructor=a}var d={}.hasOwnProperty;for(var e in b)d.call(b,e)&&(a[e]=b[e]);return c.prototype=b.prototype,a.prototype=new c,a.__super__=b.prototype,a},c.Decorate=function(a,c){function d(){var b=Array.prototype.unshift,d=c.prototype.constructor.length,e=a.prototype.constructor;d>0&&(b.call(arguments,a.prototype.constructor),e=c.prototype.constructor),e.apply(this,arguments)}function e(){this.constructor=d}var f=b(c),g=b(a);c.displayName=a.displayName,d.prototype=new e;for(var h=0;h<g.length;h++){var i=g[h];d.prototype[i]=a.prototype[i]}for(var j=(function(a){var b=function(){};a in d.prototype&&(b=d.prototype[a]);var e=c.prototype[a];return function(){return Array.prototype.unshift.call(arguments,b),e.apply(this,arguments)}}),k=0;k<f.length;k++){var l=f[k];d.prototype[l]=j(l)}return d};var d=function(){this.listeners={}};d.prototype.on=function(a,b){this.listeners=this.listeners||{},a in this.listeners?this.listeners[a].push(b):this.listeners[a]=[b]},d.prototype.trigger=function(a){var b=Array.prototype.slice,c=b.call(arguments,1);this.listeners=this.listeners||{},null==c&&(c=[]),0===c.length&&c.push({}),c[0]._type=a,a in this.listeners&&this.invoke(this.listeners[a],b.call(arguments,1)),"*"in this.listeners&&this.invoke(this.listeners["*"],arguments)},d.prototype.invoke=function(a,b){for(var c=0,d=a.length;c<d;c++)a[c].apply(this,b)},c.Observable=d,c.generateChars=function(a){for(var b="",c=0;c<a;c++){b+=Math.floor(36*Math.random()).toString(36)}return b},c.bind=function(a,b){return function(){a.apply(b,arguments)}},c._convertData=function(a){for(var b in a){var c=b.split("-"),d=a;if(1!==c.length){for(var e=0;e<c.length;e++){var f=c[e];f=f.substring(0,1).toLowerCase()+f.substring(1),f in d||(d[f]={}),e==c.length-1&&(d[f]=a[b]),d=d[f]}delete a[b]}}return a},c.hasScroll=function(b,c){var d=a(c),e=c.style.overflowX,f=c.style.overflowY;return(e!==f||"hidden"!==f&&"visible"!==f)&&("scroll"===e||"scroll"===f||(d.innerHeight()<c.scrollHeight||d.innerWidth()<c.scrollWidth))},c.escapeMarkup=function(a){var b={"\\":"&#92;","&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#47;"};return"string"!=typeof a?a:String(a).replace(/[&<>"'\/\\]/g,function(a){return b[a]})},c.appendMany=function(b,c){if("1.7"===a.fn.jquery.substr(0,3)){var d=a();a.map(c,function(a){d=d.add(a)}),c=d}b.append(c)},c.__cache={};var e=0;return c.GetUniqueElementId=function(a){var b=a.getAttribute("data-select2-id");return null==b&&(a.id?(b=a.id,a.setAttribute("data-select2-id",b)):(a.setAttribute("data-select2-id",++e),b=e.toString())),b},c.StoreData=function(a,b,d){var e=c.GetUniqueElementId(a);c.__cache[e]||(c.__cache[e]={}),c.__cache[e][b]=d},c.GetData=function(b,d){var e=c.GetUniqueElementId(b);return d?c.__cache[e]&&null!=c.__cache[e][d]?c.__cache[e][d]:a(b).data(d):c.__cache[e]},c.RemoveData=function(a){var b=c.GetUniqueElementId(a);null!=c.__cache[b]&&delete c.__cache[b]},c}),b.define("select2/results",["jquery","./utils"],function(a,b){function c(a,b,d){this.$element=a,this.data=d,this.options=b,c.__super__.constructor.call(this)}return b.Extend(c,b.Observable),c.prototype.render=function(){var b=a('<ul class="select2-results__options" role="tree"></ul>');return this.options.get("multiple")&&b.attr("aria-multiselectable","true"),this.$results=b,b},c.prototype.clear=function(){this.$results.empty()},c.prototype.displayMessage=function(b){var c=this.options.get("escapeMarkup");this.clear(),this.hideLoading();var d=a('<li role="treeitem" aria-live="assertive" class="select2-results__option"></li>'),e=this.options.get("translations").get(b.message);d.append(c(e(b.args))),d[0].className+=" select2-results__message",this.$results.append(d)},c.prototype.hideMessages=function(){this.$results.find(".select2-results__message").remove()},c.prototype.append=function(a){this.hideLoading();var b=[];if(null==a.results||0===a.results.length)return void(0===this.$results.children().length&&this.trigger("results:message",{message:"noResults"}));a.results=this.sort(a.results);for(var c=0;c<a.results.length;c++){var d=a.results[c],e=this.option(d);b.push(e)}this.$results.append(b)},c.prototype.position=function(a,b){b.find(".select2-results").append(a)},c.prototype.sort=function(a){return this.options.get("sorter")(a)},c.prototype.highlightFirstItem=function(){var a=this.$results.find(".select2-results__option[aria-selected]"),b=a.filter("[aria-selected=true]");b.length>0?b.first().trigger("mouseenter"):a.first().trigger("mouseenter"),this.ensureHighlightVisible()},c.prototype.setClasses=function(){var c=this;this.data.current(function(d){var e=a.map(d,function(a){return a.id.toString()});c.$results.find(".select2-results__option[aria-selected]").each(function(){var c=a(this),d=b.GetData(this,"data"),f=""+d.id;null!=d.element&&d.element.selected||null==d.element&&a.inArray(f,e)>-1?c.attr("aria-selected","true"):c.attr("aria-selected","false")})})},c.prototype.showLoading=function(a){this.hideLoading();var b=this.options.get("translations").get("searching"),c={disabled:!0,loading:!0,text:b(a)},d=this.option(c);d.className+=" loading-results",this.$results.prepend(d)},c.prototype.hideLoading=function(){this.$results.find(".loading-results").remove()},c.prototype.option=function(c){var d=document.createElement("li");d.className="select2-results__option";var e={role:"treeitem","aria-selected":"false"};c.disabled&&(delete e["aria-selected"],e["aria-disabled"]="true"),null==c.id&&delete e["aria-selected"],null!=c._resultId&&(d.id=c._resultId),c.title&&(d.title=c.title),c.children&&(e.role="group",e["aria-label"]=c.text,delete e["aria-selected"]);for(var f in e){var g=e[f];d.setAttribute(f,g)}if(c.children){var h=a(d),i=document.createElement("strong");i.className="select2-results__group";a(i);this.template(c,i);for(var j=[],k=0;k<c.children.length;k++){var l=c.children[k],m=this.option(l);j.push(m)}var n=a("<ul></ul>",{class:"select2-results__options select2-results__options--nested"});n.append(j),h.append(i),h.append(n)}else this.template(c,d);return b.StoreData(d,"data",c),d},c.prototype.bind=function(c,d){var e=this,f=c.id+"-results";this.$results.attr("id",f),c.on("results:all",function(a){e.clear(),e.append(a.data),c.isOpen()&&(e.setClasses(),e.highlightFirstItem())}),c.on("results:append",function(a){e.append(a.data),c.isOpen()&&e.setClasses()}),c.on("query",function(a){e.hideMessages(),e.showLoading(a)}),c.on("select",function(){c.isOpen()&&(e.setClasses(),e.highlightFirstItem())}),c.on("unselect",function(){c.isOpen()&&(e.setClasses(),e.highlightFirstItem())}),c.on("open",function(){e.$results.attr("aria-expanded","true"),e.$results.attr("aria-hidden","false"),e.setClasses(),e.ensureHighlightVisible()}),c.on("close",function(){e.$results.attr("aria-expanded","false"),e.$results.attr("aria-hidden","true"),e.$results.removeAttr("aria-activedescendant")}),c.on("results:toggle",function(){var a=e.getHighlightedResults();0!==a.length&&a.trigger("mouseup")}),c.on("results:select",function(){var a=e.getHighlightedResults();if(0!==a.length){var c=b.GetData(a[0],"data");"true"==a.attr("aria-selected")?e.trigger("close",{}):e.trigger("select",{data:c})}}),c.on("results:previous",function(){var a=e.getHighlightedResults(),b=e.$results.find("[aria-selected]"),c=b.index(a);if(0!==c){var d=c-1;0===a.length&&(d=0);var f=b.eq(d);f.trigger("mouseenter");var g=e.$results.offset().top,h=f.offset().top,i=e.$results.scrollTop()+(h-g);0===d?e.$results.scrollTop(0):h-g<0&&e.$results.scrollTop(i)}}),c.on("results:next",function(){var a=e.getHighlightedResults(),b=e.$results.find("[aria-selected]"),c=b.index(a),d=c+1;if(!(d>=b.length)){var f=b.eq(d);f.trigger("mouseenter");var g=e.$results.offset().top+e.$results.outerHeight(!1),h=f.offset().top+f.outerHeight(!1),i=e.$results.scrollTop()+h-g;0===d?e.$results.scrollTop(0):h>g&&e.$results.scrollTop(i)}}),c.on("results:focus",function(a){a.element.addClass("select2-results__option--highlighted")}),c.on("results:message",function(a){e.displayMessage(a)}),a.fn.mousewheel&&this.$results.on("mousewheel",function(a){var b=e.$results.scrollTop(),c=e.$results.get(0).scrollHeight-b+a.deltaY,d=a.deltaY>0&&b-a.deltaY<=0,f=a.deltaY<0&&c<=e.$results.height();d?(e.$results.scrollTop(0),a.preventDefault(),a.stopPropagation()):f&&(e.$results.scrollTop(e.$results.get(0).scrollHeight-e.$results.height()),a.preventDefault(),a.stopPropagation())}),this.$results.on("mouseup",".select2-results__option[aria-selected]",function(c){var d=a(this),f=b.GetData(this,"data");if("true"===d.attr("aria-selected"))return void(e.options.get("multiple")?e.trigger("unselect",{originalEvent:c,data:f}):e.trigger("close",{}));e.trigger("select",{originalEvent:c,data:f})}),this.$results.on("mouseenter",".select2-results__option[aria-selected]",function(c){var d=b.GetData(this,"data");e.getHighlightedResults().removeClass("select2-results__option--highlighted"),e.trigger("results:focus",{data:d,element:a(this)})})},c.prototype.getHighlightedResults=function(){return this.$results.find(".select2-results__option--highlighted")},c.prototype.destroy=function(){this.$results.remove()},c.prototype.ensureHighlightVisible=function(){var a=this.getHighlightedResults();if(0!==a.length){var b=this.$results.find("[aria-selected]"),c=b.index(a),d=this.$results.offset().top,e=a.offset().top,f=this.$results.scrollTop()+(e-d),g=e-d;f-=2*a.outerHeight(!1),c<=2?this.$results.scrollTop(0):(g>this.$results.outerHeight()||g<0)&&this.$results.scrollTop(f)}},c.prototype.template=function(b,c){var d=this.options.get("templateResult"),e=this.options.get("escapeMarkup"),f=d(b,c);null==f?c.style.display="none":"string"==typeof f?c.innerHTML=e(f):a(c).append(f)},c}),b.define("select2/keys",[],function(){return{BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46}}),b.define("select2/selection/base",["jquery","../utils","../keys"],function(a,b,c){function d(a,b){this.$element=a,this.options=b,d.__super__.constructor.call(this)}return b.Extend(d,b.Observable),d.prototype.render=function(){var c=a('<span class="select2-selection" role="combobox" aria-haspopup="true" aria-expanded="false"></span>');return this._tabindex=0,null!=b.GetData(this.$element[0],"old-tabindex")?this._tabindex=b.GetData(this.$element[0],"old-tabindex"):null!=this.$element.attr("tabindex")&&(this._tabindex=this.$element.attr("tabindex")),c.attr("title",this.$element.attr("title")),c.attr("tabindex",this._tabindex),this.$selection=c,c},d.prototype.bind=function(a,b){var d=this,e=(a.id,a.id+"-results");this.container=a,this.$selection.on("focus",function(a){d.trigger("focus",a)}),this.$selection.on("blur",function(a){d._handleBlur(a)}),this.$selection.on("keydown",function(a){d.trigger("keypress",a),a.which===c.SPACE&&a.preventDefault()}),a.on("results:focus",function(a){d.$selection.attr("aria-activedescendant",a.data._resultId)}),a.on("selection:update",function(a){d.update(a.data)}),a.on("open",function(){d.$selection.attr("aria-expanded","true"),d.$selection.attr("aria-owns",e),d._attachCloseHandler(a)}),a.on("close",function(){d.$selection.attr("aria-expanded","false"),d.$selection.removeAttr("aria-activedescendant"),d.$selection.removeAttr("aria-owns"),d.$selection.focus(),d._detachCloseHandler(a)}),a.on("enable",function(){d.$selection.attr("tabindex",d._tabindex)}),a.on("disable",function(){d.$selection.attr("tabindex","-1")})},d.prototype._handleBlur=function(b){var c=this;window.setTimeout(function(){document.activeElement==c.$selection[0]||a.contains(c.$selection[0],document.activeElement)||c.trigger("blur",b)},1)},d.prototype._attachCloseHandler=function(c){a(document.body).on("mousedown.select2."+c.id,function(c){var d=a(c.target),e=d.closest(".select2");a(".select2.select2-container--open").each(function(){a(this),this!=e[0]&&b.GetData(this,"element").select2("close")})})},d.prototype._detachCloseHandler=function(b){a(document.body).off("mousedown.select2."+b.id)},d.prototype.position=function(a,b){b.find(".selection").append(a)},d.prototype.destroy=function(){this._detachCloseHandler(this.container)},d.prototype.update=function(a){throw new Error("The `update` method must be defined in child classes.")},d}),b.define("select2/selection/single",["jquery","./base","../utils","../keys"],function(a,b,c,d){function e(){e.__super__.constructor.apply(this,arguments)}return c.Extend(e,b),e.prototype.render=function(){var a=e.__super__.render.call(this);return a.addClass("select2-selection--single"),a.html('<span class="select2-selection__rendered"></span><span class="select2-selection__arrow" role="presentation"><b role="presentation"></b></span>'),a},e.prototype.bind=function(a,b){var c=this;e.__super__.bind.apply(this,arguments);var d=a.id+"-container";this.$selection.find(".select2-selection__rendered").attr("id",d).attr("role","textbox").attr("aria-readonly","true"),this.$selection.attr("aria-labelledby",d),this.$selection.on("mousedown",function(a){1===a.which&&c.trigger("toggle",{originalEvent:a})}),this.$selection.on("focus",function(a){}),this.$selection.on("blur",function(a){}),a.on("focus",function(b){a.isOpen()||c.$selection.focus()})},e.prototype.clear=function(){var a=this.$selection.find(".select2-selection__rendered");a.empty(),a.removeAttr("title")},e.prototype.display=function(a,b){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(a,b))},e.prototype.selectionContainer=function(){return a("<span></span>")},e.prototype.update=function(a){if(0===a.length)return void this.clear();var b=a[0],c=this.$selection.find(".select2-selection__rendered"),d=this.display(b,c);c.empty().append(d),c.attr("title",b.title||b.text)},e}),b.define("select2/selection/multiple",["jquery","./base","../utils"],function(a,b,c){function d(a,b){d.__super__.constructor.apply(this,arguments)}return c.Extend(d,b),d.prototype.render=function(){var a=d.__super__.render.call(this);return a.addClass("select2-selection--multiple"),a.html('<ul class="select2-selection__rendered"></ul>'),a},d.prototype.bind=function(b,e){var f=this;d.__super__.bind.apply(this,arguments),this.$selection.on("click",function(a){f.trigger("toggle",{originalEvent:a})}),this.$selection.on("click",".select2-selection__choice__remove",function(b){if(!f.options.get("disabled")){var d=a(this),e=d.parent(),g=c.GetData(e[0],"data");f.trigger("unselect",{originalEvent:b,data:g})}})},d.prototype.clear=function(){var a=this.$selection.find(".select2-selection__rendered");a.empty(),a.removeAttr("title")},d.prototype.display=function(a,b){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(a,b))},d.prototype.selectionContainer=function(){return a('<li class="select2-selection__choice"><span class="select2-selection__choice__remove" role="presentation">&times;</span></li>')},d.prototype.update=function(a){if(this.clear(),0!==a.length){for(var b=[],d=0;d<a.length;d++){var e=a[d],f=this.selectionContainer(),g=this.display(e,f);f.append(g),f.attr("title",e.title||e.text),c.StoreData(f[0],"data",e),b.push(f)}var h=this.$selection.find(".select2-selection__rendered");c.appendMany(h,b)}},d}),b.define("select2/selection/placeholder",["../utils"],function(a){function b(a,b,c){this.placeholder=this.normalizePlaceholder(c.get("placeholder")),a.call(this,b,c)}return b.prototype.normalizePlaceholder=function(a,b){return"string"==typeof b&&(b={id:"",text:b}),b},b.prototype.createPlaceholder=function(a,b){var c=this.selectionContainer();return c.html(this.display(b)),c.addClass("select2-selection__placeholder").removeClass("select2-selection__choice"),c},b.prototype.update=function(a,b){var c=1==b.length&&b[0].id!=this.placeholder.id;if(b.length>1||c)return a.call(this,b);this.clear();var d=this.createPlaceholder(this.placeholder);this.$selection.find(".select2-selection__rendered").append(d)},b}),b.define("select2/selection/allowClear",["jquery","../keys","../utils"],function(a,b,c){function d(){}return d.prototype.bind=function(a,b,c){var d=this;a.call(this,b,c),null==this.placeholder&&this.options.get("debug")&&window.console&&console.error&&console.error("Select2: The `allowClear` option should be used in combination with the `placeholder` option."),this.$selection.on("mousedown",".select2-selection__clear",function(a){d._handleClear(a)}),b.on("keypress",function(a){d._handleKeyboardClear(a,b)})},d.prototype._handleClear=function(a,b){if(!this.options.get("disabled")){var d=this.$selection.find(".select2-selection__clear");if(0!==d.length){b.stopPropagation();var e=c.GetData(d[0],"data"),f=this.$element.val();this.$element.val(this.placeholder.id);var g={data:e};if(this.trigger("clear",g),g.prevented)return void this.$element.val(f);for(var h=0;h<e.length;h++)if(g={data:e[h]},this.trigger("unselect",g),g.prevented)return void this.$element.val(f);this.$element.trigger("change"),this.trigger("toggle",{})}}},d.prototype._handleKeyboardClear=function(a,c,d){d.isOpen()||c.which!=b.DELETE&&c.which!=b.BACKSPACE||this._handleClear(c)},d.prototype.update=function(b,d){if(b.call(this,d),!(this.$selection.find(".select2-selection__placeholder").length>0||0===d.length)){var e=a('<span class="select2-selection__clear">&times;</span>');c.StoreData(e[0],"data",d),this.$selection.find(".select2-selection__rendered").prepend(e)}},d}),b.define("select2/selection/search",["jquery","../utils","../keys"],function(a,b,c){function d(a,b,c){a.call(this,b,c)}return d.prototype.render=function(b){var c=a('<li class="select2-search select2-search--inline"><input class="select2-search__field" type="search" tabindex="-1" autocomplete="off" autocorrect="off" autocapitalize="none" spellcheck="false" role="textbox" aria-autocomplete="list" /></li>');this.$searchContainer=c,this.$search=c.find("input");var d=b.call(this);return this._transferTabIndex(),d},d.prototype.bind=function(a,d,e){var f=this;a.call(this,d,e),d.on("open",function(){f.$search.trigger("focus")}),d.on("close",function(){f.$search.val(""),f.$search.removeAttr("aria-activedescendant"),f.$search.trigger("focus")}),d.on("enable",function(){f.$search.prop("disabled",!1),f._transferTabIndex()}),d.on("disable",function(){f.$search.prop("disabled",!0)}),d.on("focus",function(a){f.$search.trigger("focus")}),d.on("results:focus",function(a){f.$search.attr("aria-activedescendant",a.id)}),this.$selection.on("focusin",".select2-search--inline",function(a){f.trigger("focus",a)}),this.$selection.on("focusout",".select2-search--inline",function(a){f._handleBlur(a)}),this.$selection.on("keydown",".select2-search--inline",function(a){if(a.stopPropagation(),f.trigger("keypress",a),f._keyUpPrevented=a.isDefaultPrevented(),a.which===c.BACKSPACE&&""===f.$search.val()){var d=f.$searchContainer.prev(".select2-selection__choice");if(d.length>0){var e=b.GetData(d[0],"data");f.searchRemoveChoice(e),a.preventDefault()}}});var g=document.documentMode,h=g&&g<=11;this.$selection.on("input.searchcheck",".select2-search--inline",function(a){if(h)return void f.$selection.off("input.search input.searchcheck");f.$selection.off("keyup.search")}),this.$selection.on("keyup.search input.search",".select2-search--inline",function(a){if(h&&"input"===a.type)return void f.$selection.off("input.search input.searchcheck");var b=a.which;b!=c.SHIFT&&b!=c.CTRL&&b!=c.ALT&&b!=c.TAB&&f.handleSearch(a)})},d.prototype._transferTabIndex=function(a){this.$search.attr("tabindex",this.$selection.attr("tabindex")),this.$selection.attr("tabindex","-1")},d.prototype.createPlaceholder=function(a,b){this.$search.attr("placeholder",b.text)},d.prototype.update=function(a,b){var c=this.$search[0]==document.activeElement;this.$search.attr("placeholder",""),a.call(this,b),this.$selection.find(".select2-selection__rendered").append(this.$searchContainer),this.resizeSearch(),c&&this.$search.focus()},d.prototype.handleSearch=function(){if(this.resizeSearch(),!this._keyUpPrevented){var a=this.$search.val();this.trigger("query",{term:a})}this._keyUpPrevented=!1},d.prototype.searchRemoveChoice=function(a,b){this.trigger("unselect",{data:b}),this.$search.val(b.text),this.handleSearch()},d.prototype.resizeSearch=function(){this.$search.css("width","25px");var a="";if(""!==this.$search.attr("placeholder"))a=this.$selection.find(".select2-selection__rendered").innerWidth();else{a=.75*(this.$search.val().length+1)+"em"}this.$search.css("width",a)},d}),b.define("select2/selection/eventRelay",["jquery"],function(a){function b(){}return b.prototype.bind=function(b,c,d){var e=this,f=["open","opening","close","closing","select","selecting","unselect","unselecting","clear","clearing"],g=["opening","closing","selecting","unselecting","clearing"];b.call(this,c,d),c.on("*",function(b,c){if(-1!==a.inArray(b,f)){c=c||{};var d=a.Event("select2:"+b,{params:c});e.$element.trigger(d),-1!==a.inArray(b,g)&&(c.prevented=d.isDefaultPrevented())}})},b}),b.define("select2/translation",["jquery","require"],function(a,b){function c(a){this.dict=a||{}}return c.prototype.all=function(){return this.dict},c.prototype.get=function(a){return this.dict[a]},c.prototype.extend=function(b){this.dict=a.extend({},b.all(),this.dict)},c._cache={},c.loadPath=function(a){if(!(a in c._cache)){var d=b(a);c._cache[a]=d}return new c(c._cache[a])},c}),b.define("select2/diacritics",[],function(){return{"Ⓐ":"A","A":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","B":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ƃ":"B","Ɓ":"B","Ⓒ":"C","C":"C","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","Ç":"C","Ḉ":"C","Ƈ":"C","Ȼ":"C","Ꜿ":"C","Ⓓ":"D","D":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ƌ":"D","Ɗ":"D","Ɖ":"D","Ꝺ":"D","DZ":"DZ","DŽ":"DZ","Dz":"Dz","Dž":"Dz","Ⓔ":"E","E":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","Ⓕ":"F","F":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","G":"G","Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","Ⓗ":"H","H":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","I":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","J":"J","Ĵ":"J","Ɉ":"J","Ⓚ":"K","K":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","L":"L","Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","LJ":"LJ","Lj":"Lj","Ⓜ":"M","M":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","Ⓝ":"N","N":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ƞ":"N","Ɲ":"N","Ꞑ":"N","Ꞥ":"N","NJ":"NJ","Nj":"Nj","Ⓞ":"O","O":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O","Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","P":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Q":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","R":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","S":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S","Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","T":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Ꜩ":"TZ","Ⓤ":"U","U":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","V":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY","Ⓦ":"W","W":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","X":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Y":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Z":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","a":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a","ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","b":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","ⓒ":"c","c":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c","ⓓ":"d","d":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","ꝺ":"d","dz":"dz","dž":"dz","ⓔ":"e","e":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e","ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ɛ":"e","ǝ":"e","ⓕ":"f","f":"f","ḟ":"f","ƒ":"f","ꝼ":"f","ⓖ":"g","g":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ᵹ":"g","ꝿ":"g","ⓗ":"h","h":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","i":"i","ì":"i","í":"i","î":"i","ĩ":"i","ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","j":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","k":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","l":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","lj":"lj","ⓜ":"m","m":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","n":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n","ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ʼn":"n","ꞑ":"n","ꞥ":"n","nj":"nj","ⓞ":"o","o":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ɔ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","ƣ":"oi","ȣ":"ou","ꝏ":"oo","ⓟ":"p","p":"p","ṕ":"p","ṗ":"p","ƥ":"p","ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ⓠ":"q","q":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","r":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","s":"s","ß":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ⓣ":"t","t":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","ꜩ":"tz","ⓤ":"u","u":"u","ù":"u","ú":"u","û":"u","ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","v":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","w":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","x":"x","ẋ":"x","ẍ":"x","ⓨ":"y","y":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y","ɏ":"y","ỿ":"y","ⓩ":"z","z":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z","Ά":"Α","Έ":"Ε","Ή":"Η","Ί":"Ι","Ϊ":"Ι","Ό":"Ο","Ύ":"Υ","Ϋ":"Υ","Ώ":"Ω","ά":"α","έ":"ε","ή":"η","ί":"ι","ϊ":"ι","ΐ":"ι","ό":"ο","ύ":"υ","ϋ":"υ","ΰ":"υ","ω":"ω","ς":"σ"}}),b.define("select2/data/base",["../utils"],function(a){function b(a,c){b.__super__.constructor.call(this)}return a.Extend(b,a.Observable),b.prototype.current=function(a){throw new Error("The `current` method must be defined in child classes.")},b.prototype.query=function(a,b){throw new Error("The `query` method must be defined in child classes.")},b.prototype.bind=function(a,b){},b.prototype.destroy=function(){},b.prototype.generateResultId=function(b,c){var d=b.id+"-result-";return d+=a.generateChars(4),null!=c.id?d+="-"+c.id.toString():d+="-"+a.generateChars(4),d},b}),b.define("select2/data/select",["./base","../utils","jquery"],function(a,b,c){function d(a,b){this.$element=a,this.options=b,d.__super__.constructor.call(this)}return b.Extend(d,a),d.prototype.current=function(a){var b=[],d=this;this.$element.find(":selected").each(function(){var a=c(this),e=d.item(a);b.push(e)}),a(b)},d.prototype.select=function(a){var b=this;if(a.selected=!0,c(a.element).is("option"))return a.element.selected=!0,void this.$element.trigger("change");if(this.$element.prop("multiple"))this.current(function(d){var e=[];a=[a],a.push.apply(a,d);for(var f=0;f<a.length;f++){var g=a[f].id;-1===c.inArray(g,e)&&e.push(g)}b.$element.val(e),b.$element.trigger("change")});else{var d=a.id;this.$element.val(d),this.$element.trigger("change")}},d.prototype.unselect=function(a){var b=this;if(this.$element.prop("multiple")){if(a.selected=!1,c(a.element).is("option"))return a.element.selected=!1,void this.$element.trigger("change");this.current(function(d){for(var e=[],f=0;f<d.length;f++){var g=d[f].id;g!==a.id&&-1===c.inArray(g,e)&&e.push(g)}b.$element.val(e),b.$element.trigger("change")})}},d.prototype.bind=function(a,b){var c=this;this.container=a,a.on("select",function(a){c.select(a.data)}),a.on("unselect",function(a){c.unselect(a.data)})},d.prototype.destroy=function(){this.$element.find("*").each(function(){b.RemoveData(this)})},d.prototype.query=function(a,b){var d=[],e=this;this.$element.children().each(function(){var b=c(this);if(b.is("option")||b.is("optgroup")){var f=e.item(b),g=e.matches(a,f);null!==g&&d.push(g)}}),b({results:d})},d.prototype.addOptions=function(a){b.appendMany(this.$element,a)},d.prototype.option=function(a){var d;a.children?(d=document.createElement("optgroup"),d.label=a.text):(d=document.createElement("option"),void 0!==d.textContent?d.textContent=a.text:d.innerText=a.text),void 0!==a.id&&(d.value=a.id),a.disabled&&(d.disabled=!0),a.selected&&(d.selected=!0),a.title&&(d.title=a.title);var e=c(d),f=this._normalizeItem(a);return f.element=d,b.StoreData(d,"data",f),e},d.prototype.item=function(a){var d={};if(null!=(d=b.GetData(a[0],"data")))return d;if(a.is("option"))d={id:a.val(),text:a.text(),disabled:a.prop("disabled"),selected:a.prop("selected"),title:a.prop("title")};else if(a.is("optgroup")){d={text:a.prop("label"),children:[],title:a.prop("title")};for(var e=a.children("option"),f=[],g=0;g<e.length;g++){var h=c(e[g]),i=this.item(h);f.push(i)}d.children=f}return d=this._normalizeItem(d),d.element=a[0],b.StoreData(a[0],"data",d),d},d.prototype._normalizeItem=function(a){a!==Object(a)&&(a={id:a,text:a}),a=c.extend({},{text:""},a);var b={selected:!1,disabled:!1};return null!=a.id&&(a.id=a.id.toString()),null!=a.text&&(a.text=a.text.toString()),null==a._resultId&&a.id&&null!=this.container&&(a._resultId=this.generateResultId(this.container,a)),c.extend({},b,a)},d.prototype.matches=function(a,b){return this.options.get("matcher")(a,b)},d}),b.define("select2/data/array",["./select","../utils","jquery"],function(a,b,c){function d(a,b){var c=b.get("data")||[];d.__super__.constructor.call(this,a,b),this.addOptions(this.convertToOptions(c))}return b.Extend(d,a),d.prototype.select=function(a){var b=this.$element.find("option").filter(function(b,c){return c.value==a.id.toString()});0===b.length&&(b=this.option(a),this.addOptions(b)),d.__super__.select.call(this,a)},d.prototype.convertToOptions=function(a){function d(a){return function(){return c(this).val()==a.id}}for(var e=this,f=this.$element.find("option"),g=f.map(function(){return e.item(c(this)).id}).get(),h=[],i=0;i<a.length;i++){var j=this._normalizeItem(a[i]);if(c.inArray(j.id,g)>=0){var k=f.filter(d(j)),l=this.item(k),m=c.extend(!0,{},j,l),n=this.option(m);k.replaceWith(n)}else{var o=this.option(j);if(j.children){var p=this.convertToOptions(j.children);b.appendMany(o,p)}h.push(o)}}return h},d}),b.define("select2/data/ajax",["./array","../utils","jquery"],function(a,b,c){function d(a,b){this.ajaxOptions=this._applyDefaults(b.get("ajax")),null!=this.ajaxOptions.processResults&&(this.processResults=this.ajaxOptions.processResults),d.__super__.constructor.call(this,a,b)}return b.Extend(d,a),d.prototype._applyDefaults=function(a){var b={data:function(a){return c.extend({},a,{q:a.term})},transport:function(a,b,d){var e=c.ajax(a);return e.then(b),e.fail(d),e}};return c.extend({},b,a,!0)},d.prototype.processResults=function(a){return a},d.prototype.query=function(a,b){function d(){var d=f.transport(f,function(d){var f=e.processResults(d,a);e.options.get("debug")&&window.console&&console.error&&(f&&f.results&&c.isArray(f.results)||console.error("Select2: The AJAX results did not return an array in the `results` key of the response.")),b(f)},function(){"status"in d&&(0===d.status||"0"===d.status)||e.trigger("results:message",{message:"errorLoading"})});e._request=d}var e=this;null!=this._request&&(c.isFunction(this._request.abort)&&this._request.abort(),this._request=null);var f=c.extend({type:"GET"},this.ajaxOptions);"function"==typeof f.url&&(f.url=f.url.call(this.$element,a)),"function"==typeof f.data&&(f.data=f.data.call(this.$element,a)),this.ajaxOptions.delay&&null!=a.term?(this._queryTimeout&&window.clearTimeout(this._queryTimeout),this._queryTimeout=window.setTimeout(d,this.ajaxOptions.delay)):d()},d}),b.define("select2/data/tags",["jquery"],function(a){function b(b,c,d){var e=d.get("tags"),f=d.get("createTag");void 0!==f&&(this.createTag=f);var g=d.get("insertTag");if(void 0!==g&&(this.insertTag=g),b.call(this,c,d),a.isArray(e))for(var h=0;h<e.length;h++){var i=e[h],j=this._normalizeItem(i),k=this.option(j);this.$element.append(k)}}return b.prototype.query=function(a,b,c){function d(a,f){for(var g=a.results,h=0;h<g.length;h++){var i=g[h],j=null!=i.children&&!d({results:i.children},!0);if((i.text||"").toUpperCase()===(b.term||"").toUpperCase()||j)return!f&&(a.data=g,void c(a))}if(f)return!0;var k=e.createTag(b);if(null!=k){var l=e.option(k);l.attr("data-select2-tag",!0),e.addOptions([l]),e.insertTag(g,k)}a.results=g,c(a)}var e=this;if(this._removeOldTags(),null==b.term||null!=b.page)return void a.call(this,b,c);a.call(this,b,d)},b.prototype.createTag=function(b,c){var d=a.trim(c.term);return""===d?null:{id:d,text:d}},b.prototype.insertTag=function(a,b,c){b.unshift(c)},b.prototype._removeOldTags=function(b){this._lastTag;this.$element.find("option[data-select2-tag]").each(function(){this.selected||a(this).remove()})},b}),b.define("select2/data/tokenizer",["jquery"],function(a){function b(a,b,c){var d=c.get("tokenizer");void 0!==d&&(this.tokenizer=d),a.call(this,b,c)}return b.prototype.bind=function(a,b,c){a.call(this,b,c),this.$search=b.dropdown.$search||b.selection.$search||c.find(".select2-search__field")},b.prototype.query=function(b,c,d){function e(b){var c=g._normalizeItem(b);if(!g.$element.find("option").filter(function(){return a(this).val()===c.id}).length){var d=g.option(c);d.attr("data-select2-tag",!0),g._removeOldTags(),g.addOptions([d])}f(c)}function f(a){g.trigger("select",{data:a})}var g=this;c.term=c.term||"";var h=this.tokenizer(c,this.options,e);h.term!==c.term&&(this.$search.length&&(this.$search.val(h.term),this.$search.focus()),c.term=h.term),b.call(this,c,d)},b.prototype.tokenizer=function(b,c,d,e){for(var f=d.get("tokenSeparators")||[],g=c.term,h=0,i=this.createTag||function(a){return{id:a.term,text:a.term}};h<g.length;){var j=g[h];if(-1!==a.inArray(j,f)){var k=g.substr(0,h),l=a.extend({},c,{term:k}),m=i(l);null!=m?(e(m),g=g.substr(h+1)||"",h=0):h++}else h++}return{term:g}},b}),b.define("select2/data/minimumInputLength",[],function(){function a(a,b,c){this.minimumInputLength=c.get("minimumInputLength"),a.call(this,b,c)}return a.prototype.query=function(a,b,c){if(b.term=b.term||"",b.term.length<this.minimumInputLength)return void this.trigger("results:message",{message:"inputTooShort",args:{minimum:this.minimumInputLength,input:b.term,params:b}});a.call(this,b,c)},a}),b.define("select2/data/maximumInputLength",[],function(){function a(a,b,c){this.maximumInputLength=c.get("maximumInputLength"),a.call(this,b,c)}return a.prototype.query=function(a,b,c){if(b.term=b.term||"",this.maximumInputLength>0&&b.term.length>this.maximumInputLength)return void this.trigger("results:message",{message:"inputTooLong",args:{maximum:this.maximumInputLength,input:b.term,params:b}});a.call(this,b,c)},a}),b.define("select2/data/maximumSelectionLength",[],function(){function a(a,b,c){this.maximumSelectionLength=c.get("maximumSelectionLength"),a.call(this,b,c)}return a.prototype.query=function(a,b,c){var d=this;this.current(function(e){var f=null!=e?e.length:0;if(d.maximumSelectionLength>0&&f>=d.maximumSelectionLength)return void d.trigger("results:message",{message:"maximumSelected",args:{maximum:d.maximumSelectionLength}});a.call(d,b,c)})},a}),b.define("select2/dropdown",["jquery","./utils"],function(a,b){function c(a,b){this.$element=a,this.options=b,c.__super__.constructor.call(this)}return b.Extend(c,b.Observable),c.prototype.render=function(){var b=a('<span class="select2-dropdown"><span class="select2-results"></span></span>');return b.attr("dir",this.options.get("dir")),this.$dropdown=b,b},c.prototype.bind=function(){},c.prototype.position=function(a,b){},c.prototype.destroy=function(){this.$dropdown.remove()},c}),b.define("select2/dropdown/search",["jquery","../utils"],function(a,b){function c(){}return c.prototype.render=function(b){var c=b.call(this),d=a('<span class="select2-search select2-search--dropdown"><input class="select2-search__field" type="search" tabindex="-1" autocomplete="off" autocorrect="off" autocapitalize="none" spellcheck="false" role="textbox" /></span>');return this.$searchContainer=d,this.$search=d.find("input"),c.prepend(d),c},c.prototype.bind=function(b,c,d){var e=this;b.call(this,c,d),this.$search.on("keydown",function(a){e.trigger("keypress",a),e._keyUpPrevented=a.isDefaultPrevented()}),this.$search.on("input",function(b){a(this).off("keyup")}),this.$search.on("keyup input",function(a){e.handleSearch(a)}),c.on("open",function(){e.$search.attr("tabindex",0),e.$search.focus(),window.setTimeout(function(){e.$search.focus()},0)}),c.on("close",function(){e.$search.attr("tabindex",-1),e.$search.val(""),e.$search.blur()}),c.on("focus",function(){c.isOpen()||e.$search.focus()}),c.on("results:all",function(a){if(null==a.query.term||""===a.query.term){e.showSearch(a)?e.$searchContainer.removeClass("select2-search--hide"):e.$searchContainer.addClass("select2-search--hide")}})},c.prototype.handleSearch=function(a){if(!this._keyUpPrevented){var b=this.$search.val();this.trigger("query",{term:b})}this._keyUpPrevented=!1},c.prototype.showSearch=function(a,b){return!0},c}),b.define("select2/dropdown/hidePlaceholder",[],function(){function a(a,b,c,d){this.placeholder=this.normalizePlaceholder(c.get("placeholder")),a.call(this,b,c,d)}return a.prototype.append=function(a,b){b.results=this.removePlaceholder(b.results),a.call(this,b)},a.prototype.normalizePlaceholder=function(a,b){return"string"==typeof b&&(b={id:"",text:b}),b},a.prototype.removePlaceholder=function(a,b){for(var c=b.slice(0),d=b.length-1;d>=0;d--){var e=b[d];this.placeholder.id===e.id&&c.splice(d,1)}return c},a}),b.define("select2/dropdown/infiniteScroll",["jquery"],function(a){function b(a,b,c,d){this.lastParams={},a.call(this,b,c,d),this.$loadingMore=this.createLoadingMore(),this.loading=!1}return b.prototype.append=function(a,b){this.$loadingMore.remove(),this.loading=!1,a.call(this,b),this.showLoadingMore(b)&&this.$results.append(this.$loadingMore)},b.prototype.bind=function(b,c,d){var e=this;b.call(this,c,d),c.on("query",function(a){e.lastParams=a,e.loading=!0}),c.on("query:append",function(a){e.lastParams=a,e.loading=!0}),this.$results.on("scroll",function(){var b=a.contains(document.documentElement,e.$loadingMore[0]);if(!e.loading&&b){e.$results.offset().top+e.$results.outerHeight(!1)+50>=e.$loadingMore.offset().top+e.$loadingMore.outerHeight(!1)&&e.loadMore()}})},b.prototype.loadMore=function(){this.loading=!0;var b=a.extend({},{page:1},this.lastParams);b.page++,this.trigger("query:append",b)},b.prototype.showLoadingMore=function(a,b){return b.pagination&&b.pagination.more},b.prototype.createLoadingMore=function(){var b=a('<li class="select2-results__option select2-results__option--load-more"role="treeitem" aria-disabled="true"></li>'),c=this.options.get("translations").get("loadingMore");return b.html(c(this.lastParams)),b},b}),b.define("select2/dropdown/attachBody",["jquery","../utils"],function(a,b){function c(b,c,d){this.$dropdownParent=d.get("dropdownParent")||a(document.body),b.call(this,c,d)}return c.prototype.bind=function(a,b,c){var d=this,e=!1;a.call(this,b,c),b.on("open",function(){d._showDropdown(),d._attachPositioningHandler(b),e||(e=!0,b.on("results:all",function(){d._positionDropdown(),d._resizeDropdown()}),b.on("results:append",function(){d._positionDropdown(),d._resizeDropdown()}))}),b.on("close",function(){d._hideDropdown(),d._detachPositioningHandler(b)}),this.$dropdownContainer.on("mousedown",function(a){a.stopPropagation()})},c.prototype.destroy=function(a){a.call(this),this.$dropdownContainer.remove()},c.prototype.position=function(a,b,c){b.attr("class",c.attr("class")),b.removeClass("select2"),b.addClass("select2-container--open"),b.css({position:"absolute",top:-999999}),this.$container=c},c.prototype.render=function(b){var c=a("<span></span>"),d=b.call(this);return c.append(d),this.$dropdownContainer=c,c},c.prototype._hideDropdown=function(a){this.$dropdownContainer.detach()},c.prototype._attachPositioningHandler=function(c,d){var e=this,f="scroll.select2."+d.id,g="resize.select2."+d.id,h="orientationchange.select2."+d.id,i=this.$container.parents().filter(b.hasScroll);i.each(function(){b.StoreData(this,"select2-scroll-position",{x:a(this).scrollLeft(),y:a(this).scrollTop()})}),i.on(f,function(c){var d=b.GetData(this,"select2-scroll-position");a(this).scrollTop(d.y)}),a(window).on(f+" "+g+" "+h,function(a){e._positionDropdown(),e._resizeDropdown()})},c.prototype._detachPositioningHandler=function(c,d){var e="scroll.select2."+d.id,f="resize.select2."+d.id,g="orientationchange.select2."+d.id;this.$container.parents().filter(b.hasScroll).off(e),a(window).off(e+" "+f+" "+g)},c.prototype._positionDropdown=function(){var b=a(window),c=this.$dropdown.hasClass("select2-dropdown--above"),d=this.$dropdown.hasClass("select2-dropdown--below"),e=null,f=this.$container.offset();f.bottom=f.top+this.$container.outerHeight(!1);var g={height:this.$container.outerHeight(!1)};g.top=f.top,g.bottom=f.top+g.height;var h={height:this.$dropdown.outerHeight(!1)},i={top:b.scrollTop(),bottom:b.scrollTop()+b.height()},j=i.top<f.top-h.height,k=i.bottom>f.bottom+h.height,l={left:f.left,top:g.bottom},m=this.$dropdownParent;"static"===m.css("position")&&(m=m.offsetParent());var n=m.offset();l.top-=n.top,l.left-=n.left,c||d||(e="below"),k||!j||c?!j&&k&&c&&(e="below"):e="above",("above"==e||c&&"below"!==e)&&(l.top=g.top-n.top-h.height),null!=e&&(this.$dropdown.removeClass("select2-dropdown--below select2-dropdown--above").addClass("select2-dropdown--"+e),this.$container.removeClass("select2-container--below select2-container--above").addClass("select2-container--"+e)),this.$dropdownContainer.css(l)},c.prototype._resizeDropdown=function(){var a={width:this.$container.outerWidth(!1)+"px"};this.options.get("dropdownAutoWidth")&&(a.minWidth=a.width,a.position="relative",a.width="auto"),this.$dropdown.css(a)},c.prototype._showDropdown=function(a){this.$dropdownContainer.appendTo(this.$dropdownParent),this._positionDropdown(),this._resizeDropdown()},c}),b.define("select2/dropdown/minimumResultsForSearch",[],function(){function a(b){for(var c=0,d=0;d<b.length;d++){var e=b[d];e.children?c+=a(e.children):c++}return c}function b(a,b,c,d){this.minimumResultsForSearch=c.get("minimumResultsForSearch"),this.minimumResultsForSearch<0&&(this.minimumResultsForSearch=1/0),a.call(this,b,c,d)}return b.prototype.showSearch=function(b,c){return!(a(c.data.results)<this.minimumResultsForSearch)&&b.call(this,c)},b}),b.define("select2/dropdown/selectOnClose",["../utils"],function(a){function b(){}return b.prototype.bind=function(a,b,c){var d=this;a.call(this,b,c),b.on("close",function(a){d._handleSelectOnClose(a)})},b.prototype._handleSelectOnClose=function(b,c){if(c&&null!=c.originalSelect2Event){var d=c.originalSelect2Event;if("select"===d._type||"unselect"===d._type)return}var e=this.getHighlightedResults();if(!(e.length<1)){var f=a.GetData(e[0],"data");null!=f.element&&f.element.selected||null==f.element&&f.selected||this.trigger("select",{data:f})}},b}),b.define("select2/dropdown/closeOnSelect",[],function(){function a(){}return a.prototype.bind=function(a,b,c){var d=this;a.call(this,b,c),b.on("select",function(a){d._selectTriggered(a)}),b.on("unselect",function(a){d._selectTriggered(a)})},a.prototype._selectTriggered=function(a,b){var c=b.originalEvent;c&&c.ctrlKey||this.trigger("close",{originalEvent:c,originalSelect2Event:b})},a}),b.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(a){var b=a.input.length-a.maximum,c="Please delete "+b+" character";return 1!=b&&(c+="s"),c},inputTooShort:function(a){return"Please enter "+(a.minimum-a.input.length)+" or more characters"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(a){var b="You can only select "+a.maximum+" item";return 1!=a.maximum&&(b+="s"),b},noResults:function(){return"No results found"},searching:function(){return"Searching…"}}}),b.define("select2/defaults",["jquery","require","./results","./selection/single","./selection/multiple","./selection/placeholder","./selection/allowClear","./selection/search","./selection/eventRelay","./utils","./translation","./diacritics","./data/select","./data/array","./data/ajax","./data/tags","./data/tokenizer","./data/minimumInputLength","./data/maximumInputLength","./data/maximumSelectionLength","./dropdown","./dropdown/search","./dropdown/hidePlaceholder","./dropdown/infiniteScroll","./dropdown/attachBody","./dropdown/minimumResultsForSearch","./dropdown/selectOnClose","./dropdown/closeOnSelect","./i18n/en"],function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C){function D(){this.reset()}return D.prototype.apply=function(l){if(l=a.extend(!0,{},this.defaults,l),null==l.dataAdapter){if(null!=l.ajax?l.dataAdapter=o:null!=l.data?l.dataAdapter=n:l.dataAdapter=m,l.minimumInputLength>0&&(l.dataAdapter=j.Decorate(l.dataAdapter,r)),l.maximumInputLength>0&&(l.dataAdapter=j.Decorate(l.dataAdapter,s)),l.maximumSelectionLength>0&&(l.dataAdapter=j.Decorate(l.dataAdapter,t)),l.tags&&(l.dataAdapter=j.Decorate(l.dataAdapter,p)),null==l.tokenSeparators&&null==l.tokenizer||(l.dataAdapter=j.Decorate(l.dataAdapter,q)),null!=l.query){var C=b(l.amdBase+"compat/query");l.dataAdapter=j.Decorate(l.dataAdapter,C)}if(null!=l.initSelection){var D=b(l.amdBase+"compat/initSelection");l.dataAdapter=j.Decorate(l.dataAdapter,D)}}if(null==l.resultsAdapter&&(l.resultsAdapter=c,null!=l.ajax&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,x)),null!=l.placeholder&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,w)),l.selectOnClose&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,A))),null==l.dropdownAdapter){if(l.multiple)l.dropdownAdapter=u;else{var E=j.Decorate(u,v);l.dropdownAdapter=E}if(0!==l.minimumResultsForSearch&&(l.dropdownAdapter=j.Decorate(l.dropdownAdapter,z)),l.closeOnSelect&&(l.dropdownAdapter=j.Decorate(l.dropdownAdapter,B)),null!=l.dropdownCssClass||null!=l.dropdownCss||null!=l.adaptDropdownCssClass){var F=b(l.amdBase+"compat/dropdownCss");l.dropdownAdapter=j.Decorate(l.dropdownAdapter,F)}l.dropdownAdapter=j.Decorate(l.dropdownAdapter,y)}if(null==l.selectionAdapter){if(l.multiple?l.selectionAdapter=e:l.selectionAdapter=d,null!=l.placeholder&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,f)),l.allowClear&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,g)),l.multiple&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,h)),null!=l.containerCssClass||null!=l.containerCss||null!=l.adaptContainerCssClass){var G=b(l.amdBase+"compat/containerCss");l.selectionAdapter=j.Decorate(l.selectionAdapter,G)}l.selectionAdapter=j.Decorate(l.selectionAdapter,i)}if("string"==typeof l.language)if(l.language.indexOf("-")>0){var H=l.language.split("-"),I=H[0];l.language=[l.language,I]}else l.language=[l.language];if(a.isArray(l.language)){var J=new k;l.language.push("en");for(var K=l.language,L=0;L<K.length;L++){var M=K[L],N={};try{N=k.loadPath(M)}catch(a){try{M=this.defaults.amdLanguageBase+M,N=k.loadPath(M)}catch(a){l.debug&&window.console&&console.warn&&console.warn('Select2: The language file for "'+M+'" could not be automatically loaded. A fallback will be used instead.');continue}}J.extend(N)}l.translations=J}else{var O=k.loadPath(this.defaults.amdLanguageBase+"en"),P=new k(l.language);P.extend(O),l.translations=P}return l},D.prototype.reset=function(){function b(a){function b(a){return l[a]||a}return a.replace(/[^\u0000-\u007E]/g,b)}function c(d,e){if(""===a.trim(d.term))return e;if(e.children&&e.children.length>0){for(var f=a.extend(!0,{},e),g=e.children.length-1;g>=0;g--){null==c(d,e.children[g])&&f.children.splice(g,1)}return f.children.length>0?f:c(d,f)}var h=b(e.text).toUpperCase(),i=b(d.term).toUpperCase();return h.indexOf(i)>-1?e:null}this.defaults={amdBase:"./",amdLanguageBase:"./i18n/",closeOnSelect:!0,debug:!1,dropdownAutoWidth:!1,escapeMarkup:j.escapeMarkup,language:C,matcher:c,minimumInputLength:0,maximumInputLength:0,maximumSelectionLength:0,minimumResultsForSearch:0,selectOnClose:!1,sorter:function(a){return a},templateResult:function(a){return a.text},templateSelection:function(a){return a.text},theme:"default",width:"resolve"}},D.prototype.set=function(b,c){var d=a.camelCase(b),e={};e[d]=c;var f=j._convertData(e);a.extend(!0,this.defaults,f)},new D}),b.define("select2/options",["require","jquery","./defaults","./utils"],function(a,b,c,d){function e(b,e){if(this.options=b,null!=e&&this.fromElement(e),this.options=c.apply(this.options),e&&e.is("input")){var f=a(this.get("amdBase")+"compat/inputData");this.options.dataAdapter=d.Decorate(this.options.dataAdapter,f)}}return e.prototype.fromElement=function(a){var c=["select2"];null==this.options.multiple&&(this.options.multiple=a.prop("multiple")),null==this.options.disabled&&(this.options.disabled=a.prop("disabled")),null==this.options.language&&(a.prop("lang")?this.options.language=a.prop("lang").toLowerCase():a.closest("[lang]").prop("lang")&&(this.options.language=a.closest("[lang]").prop("lang"))),null==this.options.dir&&(a.prop("dir")?this.options.dir=a.prop("dir"):a.closest("[dir]").prop("dir")?this.options.dir=a.closest("[dir]").prop("dir"):this.options.dir="ltr"),a.prop("disabled",this.options.disabled),a.prop("multiple",this.options.multiple),d.GetData(a[0],"select2Tags")&&(this.options.debug&&window.console&&console.warn&&console.warn('Select2: The `data-select2-tags` attribute has been changed to use the `data-data` and `data-tags="true"` attributes and will be removed in future versions of Select2.'),d.StoreData(a[0],"data",d.GetData(a[0],"select2Tags")),d.StoreData(a[0],"tags",!0)),d.GetData(a[0],"ajaxUrl")&&(this.options.debug&&window.console&&console.warn&&console.warn("Select2: The `data-ajax-url` attribute has been changed to `data-ajax--url` and support for the old attribute will be removed in future versions of Select2."),a.attr("ajax--url",d.GetData(a[0],"ajaxUrl")),d.StoreData(a[0],"ajax-Url",d.GetData(a[0],"ajaxUrl")));var e={};e=b.fn.jquery&&"1."==b.fn.jquery.substr(0,2)&&a[0].dataset?b.extend(!0,{},a[0].dataset,d.GetData(a[0])):d.GetData(a[0]);var f=b.extend(!0,{},e);f=d._convertData(f);for(var g in f)b.inArray(g,c)>-1||(b.isPlainObject(this.options[g])?b.extend(this.options[g],f[g]):this.options[g]=f[g]);return this},e.prototype.get=function(a){return this.options[a]},e.prototype.set=function(a,b){this.options[a]=b},e}),b.define("select2/core",["jquery","./options","./utils","./keys"],function(a,b,c,d){var e=function(a,d){null!=c.GetData(a[0],"select2")&&c.GetData(a[0],"select2").destroy(),this.$element=a,this.id=this._generateId(a),d=d||{},this.options=new b(d,a),e.__super__.constructor.call(this);var f=a.attr("tabindex")||0;c.StoreData(a[0],"old-tabindex",f),a.attr("tabindex","-1");var g=this.options.get("dataAdapter");this.dataAdapter=new g(a,this.options);var h=this.render();this._placeContainer(h);var i=this.options.get("selectionAdapter");this.selection=new i(a,this.options),this.$selection=this.selection.render(),this.selection.position(this.$selection,h);var j=this.options.get("dropdownAdapter");this.dropdown=new j(a,this.options),this.$dropdown=this.dropdown.render(),this.dropdown.position(this.$dropdown,h);var k=this.options.get("resultsAdapter");this.results=new k(a,this.options,this.dataAdapter),this.$results=this.results.render(),this.results.position(this.$results,this.$dropdown);var l=this;this._bindAdapters(),this._registerDomEvents(),this._registerDataEvents(),this._registerSelectionEvents(),this._registerDropdownEvents(),this._registerResultsEvents(),this._registerEvents(),this.dataAdapter.current(function(a){l.trigger("selection:update",{data:a})}),a.addClass("select2-hidden-accessible"),a.attr("aria-hidden","true"),this._syncAttributes(),c.StoreData(a[0],"select2",this)};return c.Extend(e,c.Observable),e.prototype._generateId=function(a){var b="";return b=null!=a.attr("id")?a.attr("id"):null!=a.attr("name")?a.attr("name")+"-"+c.generateChars(2):c.generateChars(4),b=b.replace(/(:|\.|\[|\]|,)/g,""),b="select2-"+b},e.prototype._placeContainer=function(a){a.insertAfter(this.$element);var b=this._resolveWidth(this.$element,this.options.get("width"));null!=b&&a.css("width",b)},e.prototype._resolveWidth=function(a,b){var c=/^width:(([-+]?([0-9]*\.)?[0-9]+)(px|em|ex|%|in|cm|mm|pt|pc))/i;if("resolve"==b){var d=this._resolveWidth(a,"style");return null!=d?d:this._resolveWidth(a,"element")}if("element"==b){var e=a.outerWidth(!1);return e<=0?"auto":e+"px"}if("style"==b){var f=a.attr("style");if("string"!=typeof f)return null;for(var g=f.split(";"),h=0,i=g.length;h<i;h+=1){var j=g[h].replace(/\s/g,""),k=j.match(c);if(null!==k&&k.length>=1)return k[1]}return null}return b},e.prototype._bindAdapters=function(){this.dataAdapter.bind(this,this.$container),this.selection.bind(this,this.$container),this.dropdown.bind(this,this.$container),this.results.bind(this,this.$container)},e.prototype._registerDomEvents=function(){var b=this;this.$element.on("change.select2",function(){b.dataAdapter.current(function(a){b.trigger("selection:update",{data:a})})}),this.$element.on("focus.select2",function(a){b.trigger("focus",a)}),this._syncA=c.bind(this._syncAttributes,this),this._syncS=c.bind(this._syncSubtree,this),this.$element[0].attachEvent&&this.$element[0].attachEvent("onpropertychange",this._syncA);var d=window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver;null!=d?(this._observer=new d(function(c){a.each(c,b._syncA),a.each(c,b._syncS)}),this._observer.observe(this.$element[0],{attributes:!0,childList:!0,subtree:!1})):this.$element[0].addEventListener&&(this.$element[0].addEventListener("DOMAttrModified",b._syncA,!1),this.$element[0].addEventListener("DOMNodeInserted",b._syncS,!1),this.$element[0].addEventListener("DOMNodeRemoved",b._syncS,!1))},e.prototype._registerDataEvents=function(){var a=this;this.dataAdapter.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerSelectionEvents=function(){var b=this,c=["toggle","focus"];this.selection.on("toggle",function(){b.toggleDropdown()}),this.selection.on("focus",function(a){b.focus(a)}),this.selection.on("*",function(d,e){-1===a.inArray(d,c)&&b.trigger(d,e)})},e.prototype._registerDropdownEvents=function(){var a=this;this.dropdown.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerResultsEvents=function(){var a=this;this.results.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerEvents=function(){var a=this;this.on("open",function(){a.$container.addClass("select2-container--open")}),this.on("close",function(){a.$container.removeClass("select2-container--open")}),this.on("enable",function(){a.$container.removeClass("select2-container--disabled")}),this.on("disable",function(){a.$container.addClass("select2-container--disabled")}),this.on("blur",function(){a.$container.removeClass("select2-container--focus")}),this.on("query",function(b){a.isOpen()||a.trigger("open",{}),this.dataAdapter.query(b,function(c){a.trigger("results:all",{data:c,query:b})})}),this.on("query:append",function(b){this.dataAdapter.query(b,function(c){a.trigger("results:append",{data:c,query:b})})}),this.on("keypress",function(b){var c=b.which;a.isOpen()?c===d.ESC||c===d.TAB||c===d.UP&&b.altKey?(a.close(),b.preventDefault()):c===d.ENTER?(a.trigger("results:select",{}),b.preventDefault()):c===d.SPACE&&b.ctrlKey?(a.trigger("results:toggle",{}),b.preventDefault()):c===d.UP?(a.trigger("results:previous",{}),b.preventDefault()):c===d.DOWN&&(a.trigger("results:next",{}),b.preventDefault()):(c===d.ENTER||c===d.SPACE||c===d.DOWN&&b.altKey)&&(a.open(),b.preventDefault())})},e.prototype._syncAttributes=function(){this.options.set("disabled",this.$element.prop("disabled")),this.options.get("disabled")?(this.isOpen()&&this.close(),this.trigger("disable",{})):this.trigger("enable",{})},e.prototype._syncSubtree=function(a,b){var c=!1,d=this;if(!a||!a.target||"OPTION"===a.target.nodeName||"OPTGROUP"===a.target.nodeName){if(b)if(b.addedNodes&&b.addedNodes.length>0)for(var e=0;e<b.addedNodes.length;e++){var f=b.addedNodes[e];f.selected&&(c=!0)}else b.removedNodes&&b.removedNodes.length>0&&(c=!0);else c=!0;c&&this.dataAdapter.current(function(a){d.trigger("selection:update",{data:a})})}},e.prototype.trigger=function(a,b){var c=e.__super__.trigger,d={open:"opening",close:"closing",select:"selecting",unselect:"unselecting",clear:"clearing"};if(void 0===b&&(b={}),a in d){var f=d[a],g={prevented:!1,name:a,args:b};if(c.call(this,f,g),g.prevented)return void(b.prevented=!0)}c.call(this,a,b)},e.prototype.toggleDropdown=function(){this.options.get("disabled")||(this.isOpen()?this.close():this.open())},e.prototype.open=function(){this.isOpen()||this.trigger("query",{})},e.prototype.close=function(){this.isOpen()&&this.trigger("close",{})},e.prototype.isOpen=function(){return this.$container.hasClass("select2-container--open")},e.prototype.hasFocus=function(){return this.$container.hasClass("select2-container--focus")},e.prototype.focus=function(a){this.hasFocus()||(this.$container.addClass("select2-container--focus"),this.trigger("focus",{}))},e.prototype.enable=function(a){this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("enable")` method has been deprecated and will be removed in later Select2 versions. Use $element.prop("disabled") instead.'),null!=a&&0!==a.length||(a=[!0]);var b=!a[0];this.$element.prop("disabled",b)},e.prototype.data=function(){this.options.get("debug")&&arguments.length>0&&window.console&&console.warn&&console.warn('Select2: Data can no longer be set using `select2("data")`. You should consider setting the value instead using `$element.val()`.');var a=[];return this.dataAdapter.current(function(b){a=b}),a},e.prototype.val=function(b){if(this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("val")` method has been deprecated and will be removed in later Select2 versions. Use $element.val() instead.'),null==b||0===b.length)return this.$element.val();var c=b[0];a.isArray(c)&&(c=a.map(c,function(a){return a.toString()})),this.$element.val(c).trigger("change")},e.prototype.destroy=function(){this.$container.remove(),this.$element[0].detachEvent&&this.$element[0].detachEvent("onpropertychange",this._syncA),null!=this._observer?(this._observer.disconnect(),this._observer=null):this.$element[0].removeEventListener&&(this.$element[0].removeEventListener("DOMAttrModified",this._syncA,!1),this.$element[0].removeEventListener("DOMNodeInserted",this._syncS,!1),this.$element[0].removeEventListener("DOMNodeRemoved",this._syncS,!1)),this._syncA=null,this._syncS=null,this.$element.off(".select2"),this.$element.attr("tabindex",c.GetData(this.$element[0],"old-tabindex")),this.$element.removeClass("select2-hidden-accessible"),this.$element.attr("aria-hidden","false"),c.RemoveData(this.$element[0]),this.dataAdapter.destroy(),this.selection.destroy(),this.dropdown.destroy(),this.results.destroy(),this.dataAdapter=null,this.selection=null,this.dropdown=null,this.results=null},e.prototype.render=function(){var b=a('<span class="select2 select2-container"><span class="selection"></span><span class="dropdown-wrapper" aria-hidden="true"></span></span>');return b.attr("dir",this.options.get("dir")),this.$container=b,this.$container.addClass("select2-container--"+this.options.get("theme")),c.StoreData(b[0],"element",this.$element),b},e}),b.define("jquery-mousewheel",["jquery"],function(a){return a}),b.define("jquery.select2",["jquery","jquery-mousewheel","./select2/core","./select2/defaults","./select2/utils"],function(a,b,c,d,e){if(null==a.fn.select2){var f=["open","close","destroy"];a.fn.select2=function(b){if("object"==typeof(b=b||{}))return this.each(function(){var d=a.extend(!0,{},b);new c(a(this),d)}),this;if("string"==typeof b){var d,g=Array.prototype.slice.call(arguments,1);return this.each(function(){var a=e.GetData(this,"select2");null==a&&window.console&&console.error&&console.error("The select2('"+b+"') method was called on an element that is not using Select2."),d=a[b].apply(a,g)}),a.inArray(b,f)>-1?this:d}throw new Error("Invalid arguments for Select2: "+b)}}return null==a.fn.select2.defaults&&(a.fn.select2.defaults=d),c}),{define:b.define,require:b.require}}(),c=b.require("jquery.select2");return a.fn.select2.amd=b,c});
admin/js/tiptip.js ADDED
@@ -0,0 +1 @@
 
1
+ !function(t){t.fn.tipTip=function(e){var o={activation:"hover",keepAlive:!1,maxWidth:"200px",edgeOffset:3,defaultPosition:"bottom",delay:400,fadeIn:200,fadeOut:200,attribute:"title",content:!1,enter:function(){},exit:function(){}},i=t.extend(o,e);if(t("#tiptip_holder").length<=0){var n=t('<div id="tiptip_holder" style="max-width:'+i.maxWidth+';"></div>'),r=t('<div id="tiptip_content"></div>'),a=t('<div id="tiptip_arrow"></div>');t("body").append(n.html(r).prepend(a.html('<div id="tiptip_arrow_inner"></div>')))}else var n=t("#tiptip_holder"),r=t("#tiptip_content"),a=t("#tiptip_arrow");return this.each(function(){function e(){i.enter.call(this),r.html(d),n.hide().removeAttr("class").css("margin","0"),a.removeAttr("style");var e=parseInt(f.offset().top),o=parseInt(f.offset().left),p=parseInt(f.outerWidth()),l=parseInt(f.outerHeight()),h=n.outerWidth(),c=n.outerHeight(),s=Math.round((p-h)/2),_=Math.round((l-c)/2),v=Math.round(o+s),m=Math.round(e+l+i.edgeOffset),g="",b="",M=Math.round(h-12)/2;"bottom"==i.defaultPosition?g="_bottom":"top"==i.defaultPosition?g="_top":"left"==i.defaultPosition?g="_left":"right"==i.defaultPosition&&(g="_right");var w=s+o<parseInt(t(window).scrollLeft()),O=h+o>parseInt(t(window).width());w&&s<0||"_right"==g&&!O||"_left"==g&&o<h+i.edgeOffset+5?(g="_right",b=Math.round(c-13)/2,M=-12,v=Math.round(o+p+i.edgeOffset),m=Math.round(e+_)):(O&&s<0||"_left"==g&&!w)&&(g="_left",b=Math.round(c-13)/2,M=Math.round(h),v=Math.round(o-(h+i.edgeOffset+5)),m=Math.round(e+_));var x=e+l+i.edgeOffset+c+8>parseInt(t(window).height()+t(window).scrollTop()),I=e+l-(i.edgeOffset+c+8)<0;x||"_bottom"==g&&x||"_top"==g&&!I?("_top"==g||"_bottom"==g?g="_top":g+="_top",b=c,m=Math.round(e-(c+5+i.edgeOffset))):(I|("_top"==g&&I)||"_bottom"==g&&!x)&&("_top"==g||"_bottom"==g?g="_bottom":g+="_bottom",b=-12,m=Math.round(e+l+i.edgeOffset)),"_right_top"==g||"_left_top"==g?m+=5:"_right_bottom"!=g&&"_left_bottom"!=g||(m-=5),"_left_top"!=g&&"_left_bottom"!=g||(v+=5),a.css({"margin-left":M+"px","margin-top":b+"px"}),n.css({"margin-left":v+"px","margin-top":m+"px"}).attr("class","tip"+g),u&&clearTimeout(u),u=setTimeout(function(){n.stop(!0,!0).fadeIn(i.fadeIn)},i.delay)}function o(){i.exit.call(this),u&&clearTimeout(u),n.fadeOut(i.fadeOut)}var f=t(this);if(i.content)d=i.content;else var d=f.attr(i.attribute);if(""!=d){i.content||f.removeAttr(i.attribute);var u=!1;"hover"==i.activation?(f.hover(function(){e()},function(){i.keepAlive||o()}),i.keepAlive&&n.hover(function(){},function(){o()})):"focus"==i.activation?f.focus(function(){e()}).blur(function(){o()}):"click"==i.activation&&(f.click(function(){return e(),!1}).hover(function(){},function(){i.keepAlive||o()}),i.keepAlive&&n.hover(function(){},function(){o()}))}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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ (function( $ ) {
2
+ 'use strict';
3
+
4
+ $(function() {
5
+
6
+ $(".wt-iew-tips").tipTip({'attribute': 'data-wt-iew-tip'});
7
+
8
+
9
+ /* tab view */
10
+ var wf_tab_view=
11
+ {
12
+ Set:function(prnt_selector)
13
+ {
14
+ var wf_prnt_obj=$(prnt_selector);
15
+ var wf_nav_tab=wf_prnt_obj.find('.wt-iew-tab-head .nav-tab');
16
+ if(wf_nav_tab.length>0)
17
+ {
18
+ wf_nav_tab.click(function(){
19
+ var wf_tab_hash=$(this).attr('href');
20
+ wf_nav_tab.removeClass('nav-tab-active');
21
+ $(this).addClass('nav-tab-active');
22
+ wf_tab_hash=wf_tab_hash.charAt(0)=='#' ? wf_tab_hash.substring(1) : wf_tab_hash;
23
+ var wf_tab_elm=$('div[data-id="'+wf_tab_hash+'"]');
24
+ wf_prnt_obj.find('.wt-iew-tab-content').hide();
25
+ if(wf_tab_elm.length>0 && wf_tab_elm.is(':hidden'))
26
+ {
27
+ wf_tab_elm.fadeIn();
28
+ }
29
+ });
30
+ $(window).on('hashchange', function (e) {
31
+ var location_hash=window.location.hash;
32
+ if(location_hash!="")
33
+ {
34
+ wf_tab_view.showTab(location_hash);
35
+ }
36
+ }).trigger('hashchange');
37
+
38
+ var location_hash=window.location.hash;
39
+ if(location_hash!="")
40
+ {
41
+ wf_tab_view.showTab(location_hash);
42
+ }else
43
+ {
44
+ wf_nav_tab.eq(0).click();
45
+ }
46
+ }
47
+ this.subTab(wf_prnt_obj);
48
+ },
49
+ showTab:function(location_hash)
50
+ {
51
+ var wf_tab_hash=location_hash.charAt(0)=='#' ? location_hash.substring(1) : location_hash;
52
+ if(wf_tab_hash!="")
53
+ {
54
+ var wf_tab_elm=$('div[data-id="'+wf_tab_hash+'"]');
55
+ if(wf_tab_elm.length>0 && wf_tab_elm.is(':hidden'))
56
+ {
57
+ $('a[href="#'+wf_tab_hash+'"]').click();
58
+ }
59
+ }
60
+ },
61
+ subTab:function(wf_prnt_obj)
62
+ {
63
+ wf_prnt_obj.find('.wt_iew_sub_tab li').click(function(){
64
+ var trgt=$(this).attr('data-target');
65
+ var prnt=$(this).parent('.wt_iew_sub_tab');
66
+ var ctnr=prnt.siblings('.wt_iew_sub_tab_container');
67
+ prnt.find('li a').css({'color':'#0073aa','cursor':'pointer'});
68
+ $(this).find('a').css({'color':'#000','cursor':'default'});
69
+ ctnr.find('.wt_iew_sub_tab_content').hide();
70
+ ctnr.find('.wt_iew_sub_tab_content[data-id="'+trgt+'"]').fadeIn();
71
+ });
72
+ wf_prnt_obj.find('.wt_iew_sub_tab').each(function(){
73
+ var elm=$(this).children('li').eq(0);
74
+ elm.click();
75
+ });
76
+ }
77
+ }
78
+ wf_tab_view.Set('#'+wt_iew_basic_params.plugin_id); /* set plugin main div as parent object to avoid conflict with other WT plugins */
79
+ /* tab view */
80
+
81
+ });
82
+
83
+ })( jQuery );
84
+
85
+ var wt_iew_settings_form_basic=
86
+ {
87
+ Set:function(prnt_selector)
88
+ {
89
+ var wf_prnt_obj=jQuery(prnt_selector);
90
+ wf_prnt_obj.find('.wt_iew_settings_form_basic').submit(function(e){
91
+ e.preventDefault();
92
+ var data=jQuery(this).serialize();
93
+
94
+ var submit_btn=jQuery(this).find('input[type="submit"]');
95
+ var spinner=submit_btn.siblings('.spinner');
96
+ spinner.css({'visibility':'visible'});
97
+ submit_btn.css({'opacity':'.5','cursor':'default'}).prop('disabled',true);
98
+
99
+ jQuery.ajax({
100
+ url:wt_iew_basic_params.ajax_url,
101
+ type:'POST',
102
+ dataType:'json',
103
+ data:data+'&action=wt_iew_save_settings_basic',
104
+ success:function(data)
105
+ {
106
+ spinner.css({'visibility':'hidden'});
107
+ submit_btn.css({'opacity':'1','cursor':'pointer'}).prop('disabled',false);
108
+ if(data.status==true)
109
+ {
110
+ wt_iew_notify_msg.success(data.msg);
111
+ }else
112
+ {
113
+ wt_iew_notify_msg.error(data.msg);
114
+ }
115
+ },
116
+ error:function ()
117
+ {
118
+ spinner.css({'visibility':'hidden'});
119
+ submit_btn.css({'opacity':'1','cursor':'pointer'}).prop('disabled',false);
120
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.settings_error);
121
+ }
122
+ });
123
+ });
124
+ }
125
+ }
126
+ var wt_drp_menu=
127
+ {
128
+ Set:function()
129
+ {
130
+ jQuery(document).on('click', '.wt_iew_drp_menu', function(){
131
+ var trgt=jQuery(this).attr('data-target');
132
+ var drp_menu=jQuery('.wt_iew_dropdown[data-id="'+trgt+'"]');
133
+ if(drp_menu.is(':visible'))
134
+ {
135
+ drp_menu.hide();
136
+ }else
137
+ {
138
+ var pos=jQuery(this).position();
139
+ var t=pos.top+(jQuery(this).height()/2)+5;
140
+ var l=pos.left; //-drp_menu.outerWidth()+jQuery(this).outerWidth();
141
+ var w=jQuery(this).outerWidth();
142
+ drp_menu.css({'display':'block','left':l,'top':t,'opacity':0,'width':w}).stop(true, true).animate({'top':t+5, 'opacity':1});
143
+ }
144
+ });
145
+
146
+ jQuery(document).on('click', 'body, body *', function(e){
147
+ var drp_menu=jQuery('.wt_iew_dropdown');
148
+ if(drp_menu.is(':visible'))
149
+ {
150
+ if(jQuery(e.target).hasClass('wt_iew_dropdown')===false && jQuery(e.target).hasClass('wt_iew_drp_menu')===false && jQuery(e.target).hasClass('dashicons')===false)
151
+ {
152
+ drp_menu.hide();
153
+ }
154
+ }
155
+ });
156
+ }
157
+ }
158
+
159
+ var wt_iew_notify_msg=
160
+ {
161
+ error:function(message, auto_close)
162
+ {
163
+ var auto_close=(auto_close!== undefined ? auto_close : false);
164
+ var er_elm=jQuery('<div class="wt_notify_msg" style="background:#f8d7da; border:solid 1px #f5c6cb; color: #721c24">'+message+'</div>');
165
+ this.setNotify(er_elm, auto_close);
166
+ },
167
+ success:function(message, auto_close)
168
+ {
169
+ var auto_close=(auto_close!== undefined ? auto_close : false);
170
+ var suss_elm=jQuery('<div class="wt_notify_msg" style="background:#d4edda; border:solid 1px #c3e6cb; color: #155724;">'+message+'</div>');
171
+ this.setNotify(suss_elm, auto_close);
172
+ },
173
+ setNotify:function(elm, auto_close)
174
+ {
175
+ jQuery('body').append(elm);
176
+ jQuery('.wt_notify_msg').click(function(){
177
+ jQuery(this).remove();
178
+ });
179
+ elm.stop(true,true).animate({'opacity':1,'top':'50px'},1000);
180
+ if(auto_close)
181
+ {
182
+ setTimeout(function(){
183
+ wt_iew_notify_msg.fadeOut(elm);
184
+ },5000);
185
+ }else
186
+ {
187
+ jQuery('body').click(function(){
188
+ wt_iew_notify_msg.fadeOut(elm);
189
+ });
190
+ }
191
+ },
192
+ fadeOut:function(elm)
193
+ {
194
+ elm.animate({'opacity':0,'top':'100px'},1000,function(){
195
+ elm.remove();
196
+ });
197
+ }
198
+ }
199
+
200
+ wt_iew_popup={
201
+ Set:function()
202
+ {
203
+ this.regPopupOpen();
204
+ this.regPopupClose();
205
+ jQuery('body').prepend('<div class="wt_iew_overlay"></div>');
206
+ },
207
+ regPopupOpen:function()
208
+ {
209
+ jQuery('[data-wt_iew_popup]').click(function(){
210
+ var elm_class=jQuery(this).attr('data-wt_iew_popup');
211
+ var elm=jQuery('.'+elm_class);
212
+ if(elm.length>0)
213
+ {
214
+ wt_iew_popup.showPopup(elm);
215
+ }
216
+ });
217
+ },
218
+ showPopup:function(popup_elm)
219
+ {
220
+ var pw=popup_elm.outerWidth();
221
+ var wh=jQuery(window).height();
222
+ var ph=wh-150;
223
+ popup_elm.css({'margin-left':((pw/2)*-1),'display':'block','top':'20px'}).animate({'top':'50px'});
224
+ popup_elm.find('.wt_iew_popup_body').css({'max-height':ph+'px','overflow':'auto'});
225
+ jQuery('.wt_iew_overlay').show();
226
+ },
227
+ hidePopup:function()
228
+ {
229
+ jQuery('.wt_iew_popup_close').click();
230
+ },
231
+ regPopupClose:function(popup_elm)
232
+ {
233
+ jQuery(document).keyup(function(e){
234
+ if(e.keyCode==27)
235
+ {
236
+ wt_iew_popup.hidePopup();
237
+ }
238
+ });
239
+ jQuery('.wt_iew_popup_close, .wt_iew_popup_cancel').unbind('click').click(function(){
240
+ jQuery('.wt_iew_overlay, .wt_iew_popup').hide();
241
+ });
242
+ }
243
+ }
244
+
245
+ var wt_field_group=
246
+ {
247
+ Set:function()
248
+ {
249
+ //jQuery('.wt_iew_field_group_children').hide();
250
+ jQuery('.wt_iew_field_group_hd .wt_iew_field_group_toggle_btn').each(function(){
251
+ var group_id = jQuery(this).attr('data-id');
252
+ var group_content_dv = jQuery(this).parents('tr').find('.wt_iew_field_group_content');
253
+ var visibility = jQuery(this).attr('data-visibility');
254
+ jQuery('.wt_iew_field_group_children[data-field-group="'+group_id+'"]').appendTo(group_content_dv.find('table'));
255
+ if(visibility==1)
256
+ {
257
+ group_content_dv.show();
258
+ }
259
+ });
260
+ jQuery('.wt_iew_field_group_hd').click(function(){
261
+
262
+ var toggle_btn=jQuery(this).find('.wt_iew_field_group_toggle_btn');
263
+ var visibility=toggle_btn.attr('data-visibility');
264
+ var group_content_dv=toggle_btn.parents('tr').find('.wt_iew_field_group_content');
265
+ if(visibility==1)
266
+ {
267
+ toggle_btn.attr('data-visibility',0);
268
+ toggle_btn.find('.dashicons').removeClass('dashicons-arrow-down').addClass('dashicons-arrow-right');
269
+ group_content_dv.hide();
270
+ }else
271
+ {
272
+ toggle_btn.attr('data-visibility',1);
273
+ toggle_btn.find('.dashicons').removeClass('dashicons-arrow-right').addClass('dashicons-arrow-down');
274
+ group_content_dv.show();
275
+ }
276
+ });
277
+ }
278
+ }
279
+ var wt_iew_form_toggler=
280
+ {
281
+ Set:function()
282
+ {
283
+ this.runToggler();
284
+ jQuery('select.wt_iew_form_toggler').change(function(){
285
+ wt_iew_form_toggler.toggle(jQuery(this));
286
+ });
287
+ jQuery('input[type="radio"].wt_iew_form_toggler').click(function(){
288
+ if(jQuery(this).is(':checked'))
289
+ {
290
+ wt_iew_form_toggler.toggle(jQuery(this));
291
+ }
292
+ });
293
+ jQuery('input[type="checkbox"].wt_iew_form_toggler').click(function(){
294
+ wt_iew_form_toggler.toggle(jQuery(this),1);
295
+ });
296
+ },
297
+ runToggler:function(prnt)
298
+ {
299
+ prnt=prnt ? prnt : jQuery('body');
300
+ prnt.find('select.wt_iew_form_toggler').each(function(){
301
+ wt_iew_form_toggler.toggle(jQuery(this));
302
+ });
303
+ prnt.find('input[type="radio"].wt_iew_form_toggler, input[type="checkbox"].wt_iew_form_toggler').each(function(){
304
+ if(jQuery(this).is(':checked'))
305
+ {
306
+ wt_iew_form_toggler.toggle(jQuery(this));
307
+ }
308
+ });
309
+ prnt.find('input[type="checkbox"].wt_iew_form_toggler').each(function(){
310
+ wt_iew_form_toggler.toggle(jQuery(this),1);
311
+ });
312
+ },
313
+ toggle:function(elm, checkbox)
314
+ {
315
+ var vl=elm.val();
316
+ var trgt=elm.attr('wf_frm_tgl-target');
317
+ jQuery('[wf_frm_tgl-id="'+trgt+'"]').hide();
318
+ if(!elm.is(':visible'))
319
+ {
320
+ return false;
321
+ }
322
+ if(elm.css('display')!='none') /* if parent is visible. `:visible` method. it will not work on JS tabview */
323
+ {
324
+ var elms=this.getElms(elm,trgt,vl,checkbox);
325
+ elms.show().find('th label').css({'margin-left':'0px'})
326
+ elms.each(function(){
327
+ var lvl=jQuery(this).attr('wf_frm_tgl-lvl');
328
+ var mrgin=25;
329
+ if (typeof lvl!== typeof undefined && lvl!== false) {
330
+ mrgin=lvl*mrgin;
331
+ }
332
+ jQuery(this).find('th label').animate({'margin-left':mrgin+'px'},1000);
333
+ });
334
+ }
335
+
336
+ /* in case of greater than 1 level */
337
+ jQuery('[wf_frm_tgl-id="'+trgt+'"]').each(function(){
338
+ wt_iew_form_toggler.runToggler(jQuery(this));
339
+ });
340
+ },
341
+ getElms:function(elm,trgt,vl,checkbox)
342
+ {
343
+
344
+ return jQuery('[wf_frm_tgl-id="'+trgt+'"]').filter(function(){
345
+ if(jQuery(this).attr('wf_frm_tgl-val')==vl)
346
+ {
347
+ if(checkbox)
348
+ {
349
+ if(elm.is(':checked'))
350
+ {
351
+ if(jQuery(this).attr('wf_frm_tgl-chk')=='true')
352
+ {
353
+ return true;
354
+ }else
355
+ {
356
+ return false;
357
+ }
358
+ }else
359
+ {
360
+ if(jQuery(this).attr('wf_frm_tgl-chk')=='false')
361
+ {
362
+ return true;
363
+ }else
364
+ {
365
+ return false;
366
+ }
367
+ }
368
+ }else
369
+ {
370
+ return true;
371
+ }
372
+ }else
373
+ {
374
+ return false;
375
+ }
376
+ });
377
+ }
378
+ }
379
+
380
+ var wt_iew_file_attacher={
381
+
382
+ Set:function()
383
+ {
384
+ var file_frame;
385
+ jQuery(".wt_iew_file_attacher").click(function(event){
386
+ event.preventDefault();
387
+ if(jQuery(this).data('file_frame'))
388
+ {
389
+
390
+ }else
391
+ {
392
+ /* reset user preference. This will open file uploader by default. */
393
+ wp.media.controller.Library.prototype.defaults.contentUserSetting=false;
394
+
395
+
396
+ /* Create the media frame. */
397
+ var file_frame = wp.media.frames.file_frame = wp.media({
398
+ title: jQuery( this ).data( 'invoice_uploader_title' ),
399
+ button: {
400
+ text: jQuery( this ).data( 'invoice_uploader_button_text' ),
401
+ },
402
+ /* Set to true to allow multiple files to be selected */
403
+ multiple: false
404
+ });
405
+ jQuery(this).data('file_frame',file_frame);
406
+ var wf_file_target=jQuery(this).attr('wt_iew_file_attacher_target');
407
+ var wt_file_attacher_choosed=jQuery(this).parent('.wt_iew_file_attacher_dv').find('.wt_iew_file_attacher_choosed');
408
+ var elm=jQuery(this);
409
+
410
+ /* When an image is selected, run a callback. */
411
+ jQuery(this).data('file_frame').on( 'select', function() {
412
+ /* We set multiple to false so only get one image from the uploader */
413
+ var attachment =file_frame.state().get('selection').first().toJSON();
414
+ /* Send the value of attachment.url back to shipment label printing settings form */
415
+ jQuery(wf_file_target).val(attachment.url);
416
+ if(wt_file_attacher_choosed.length>0)
417
+ {
418
+ wt_file_attacher_choosed.css({'visibility':'visible'}).html(attachment.filename);
419
+ }
420
+ });
421
+ /* Finally, open the modal */
422
+ }
423
+ jQuery(this).data('file_frame').open();
424
+ });
425
+ function wf_update_file_choosed(wf_file_target, wt_file_attacher_choosed)
426
+ {
427
+ if(jQuery(wf_file_target).val()=="")
428
+ {
429
+ wt_file_attacher_choosed.css({'visibility':'hidden'});
430
+ }else
431
+ {
432
+ wt_file_attacher_choosed.css({'visibility':'visible'});
433
+ }
434
+ }
435
+ jQuery(".wt_iew_file_attacher").each(function(){
436
+ var wf_file_target=jQuery(this).attr('wt_iew_file_attacher_target');
437
+ var wt_file_attacher_choosed=jQuery(this).parent('.wt_iew_file_attacher_dv').find('.wt_iew_file_attacher_choosed');
438
+ if(wt_file_attacher_choosed.length>0)
439
+ {
440
+ wf_update_file_choosed(wf_file_target, wt_file_attacher_choosed);
441
+ jQuery(wf_file_target).change(function(){
442
+ wf_update_file_choosed(wf_file_target, wt_file_attacher_choosed);
443
+ });
444
+ }
445
+ });
446
+ }
447
+ }
448
+
449
+ var wt_iew_popover=
450
+ {
451
+ action_module:false,
452
+ Set:function()
453
+ {
454
+ jQuery('[data-wt_iew_popover="1"]').unbind('click').click(function(){
455
+
456
+ /* check popover is visible now */
457
+ if(jQuery('.wt_iew_popover').length>0 && jQuery('.wt_iew_popover').is(':visible'))
458
+ {
459
+ wt_iew_popover.remove_active_row();
460
+ }
461
+
462
+ var cr_elm=jQuery(this);
463
+ if(cr_elm.attr('data-popup-opened')==1)
464
+ {
465
+ jQuery('[data-wt_iew_popover="1"]').attr('data-popup-opened',0);
466
+ wt_iew_popover.closePop();
467
+ return false;
468
+ }else
469
+ {
470
+ jQuery('[data-wt_iew_popover="1"]').attr('data-popup-opened',0);
471
+ cr_elm.attr('data-popup-opened',1);
472
+ }
473
+ if(jQuery('.wt_iew_popover').length==0)
474
+ {
475
+ var template='<div class="wt_iew_popover"><h3 class="wt_iew_popover-title">'
476
+ +'<span class="wt_iew_popover-title-text"></span><span class="popover_close_icon_button popover_close">X</span></h3>'
477
+ +'<div class="wt_iew_popover-content"></div><div class="wt_iew_popover-footer">'
478
+ +'<button name="wt_iew_popover_do_action" type="button" class="button button-primary">'+wt_iew_basic_params.msgs.use_expression+'</button>'
479
+ +'<button name="popover_close" type="button" class="button button-secondary popover_close">'+wt_iew_basic_params.msgs.cancel+'</button>'
480
+ +'<span class="spinner" style="margin-top:5px"></span>'
481
+ +'</div></div>';
482
+ jQuery('body').append(template);
483
+ wt_iew_popover.regclosePop();
484
+ }
485
+
486
+ var ttle=jQuery.trim(cr_elm.attr('data-title'));
487
+ var pp_elm=jQuery('.wt_iew_popover');
488
+ var pp_html='';
489
+ var pp_html_cntr=cr_elm.attr('data-content-container');
490
+ if(typeof pp_html_cntr!==typeof undefined && pp_html_cntr!==false)
491
+ {
492
+ pp_html=jQuery(pp_html_cntr).html();
493
+ ttle=(ttle=="" ? jQuery(pp_html_cntr).attr('data-title') : ttle);
494
+ wt_iew_popover.action_module=jQuery(pp_html_cntr).attr('data-module');
495
+ }else
496
+ {
497
+ pp_html=cr_elm.attr('data-content');
498
+ }
499
+ pp_elm.css({'display':'block'}).find('.wt_iew_popover-content').html(pp_html);
500
+ pp_elm.find('.wt_iew_popover-footer').show();
501
+ var cr_elm_w=cr_elm.width();
502
+ var cr_elm_h=cr_elm.height();
503
+ var pp_elm_w=pp_elm.width();
504
+ var pp_elm_h=pp_elm.height();
505
+ var cr_elm_pos=cr_elm.offset();
506
+ var cr_elm_pos_t=cr_elm_pos.top-((pp_elm_h-cr_elm_h)/4);
507
+ var cr_elm_pos_l=cr_elm_pos.left+cr_elm_w;
508
+
509
+ cr_elm_pos_t=cr_elm_pos_t+10; /* 10 px buffer for input span element padding */
510
+
511
+ pp_elm.find('.wt_iew_popover-title-text').html(ttle);
512
+ var target_elm_label=cr_elm.parents('tr').find('.wt_iew_mapping_column_label').html();
513
+ jQuery('.wt_iew_target_column').html(target_elm_label);
514
+ jQuery('.wt_iew_popover-content').find('.wt_iew_mapping_field_editor_expression').val(cr_elm.siblings('.columns_val').val());
515
+
516
+ wt_iew_popover.set_active_row(cr_elm);
517
+ pp_elm.css({'display':'block','opacity':0, 'top':cr_elm_pos_t,'left':cr_elm_pos_l}).stop(true,true).animate({'left':cr_elm_pos_l+20,'opacity':1}, 500, function(){
518
+ jQuery('.wt_iew_mapping_field_editor_expression').focus();
519
+ });
520
+
521
+ jQuery('[name="wt_iew_popover_do_action"]').data('click-elm', cr_elm);
522
+ wt_iew_popover.do_action();
523
+ if(wt_iew_popover.action_module=='import')
524
+ {
525
+ wt_iew_basic_import.mapping_field_editor();
526
+ wt_iew_basic_import.mapping_field_editor_output_preview();
527
+ }
528
+
529
+ });
530
+ },
531
+ do_action:function()
532
+ {
533
+ jQuery('[name="wt_iew_popover_do_action"]').unbind('click').click(function(){
534
+ var click_elm=jQuery(this).data('click-elm');
535
+ var vl=jQuery.trim(jQuery('.wt_iew_popover-content').find('.wt_iew_mapping_field_editor_expression').val());
536
+
537
+ var html_vl=vl;
538
+ if(wt_iew_popover.action_module=='import')
539
+ {
540
+ var html_vl=wt_iew_basic_import.mapping_field_editor_validate_column_val(vl);
541
+ }
542
+ click_elm.html(html_vl);
543
+ click_elm.siblings('.columns_val').val(vl);
544
+ wt_iew_popover.closePop();
545
+
546
+ if(wt_iew_popover.action_module=='import')
547
+ {
548
+ if(vl=="")
549
+ {
550
+ click_elm.parents('tr').find('.wt_iew_mapping_checkbox_sub').prop('checked', false);
551
+ }else
552
+ {
553
+ click_elm.parents('tr').find('.wt_iew_mapping_checkbox_sub').prop('checked', true);
554
+ }
555
+ wt_iew_basic_import.mapping_fields_selected_count(click_elm.parents('table'));
556
+ }
557
+ });
558
+ },
559
+ regclosePop:function()
560
+ {
561
+ jQuery('.meta_mapping_box_toggle').click(function(){
562
+ wt_iew_popover.closePop();
563
+ });
564
+ jQuery('.popover_close').unbind('click').click(function(){
565
+ wt_iew_popover.closePop();
566
+ });
567
+ },
568
+ set_active_row:function(cr_elm)
569
+ {
570
+ cr_elm.parents('tr').find('td').css({'background':'#f6f6f6'});
571
+ },
572
+ remove_active_row:function()
573
+ {
574
+ var click_elm=jQuery('[name="wt_iew_popover_do_action"]').data('click-elm');
575
+ click_elm.parents('tr').find('td').css({'background':'#fff'});
576
+ },
577
+ closePop:function()
578
+ {
579
+ var pp_elm=jQuery('.wt_iew_popover');
580
+ if(pp_elm.length>0)
581
+ {
582
+ var pp_lft=pp_elm.offset().left-50;
583
+ jQuery('[data-wt_iew_popover="1"]').attr('data-popup-opened',0);
584
+ pp_elm.stop(true,true).animate({'opacity':0, 'left':pp_lft},300,function(){
585
+ jQuery(this).css({'display':'none'});
586
+ });
587
+ this.remove_active_row();
588
+ }
589
+ }
590
+ };
591
+
592
+ var wt_iew_custom_and_preset=
593
+ {
594
+ toggler:function(preset_elm, custom_elm, custom_val) /* Toggle between custom and preset value */
595
+ {
596
+ this.do_toggle(preset_elm, custom_elm, custom_val);
597
+ preset_elm.unbind('change').change(function(){
598
+ wt_iew_custom_and_preset.do_toggle(preset_elm, custom_elm, custom_val);
599
+ });
600
+ },
601
+ do_toggle:function(preset_elm, custom_elm, custom_val)
602
+ {
603
+ if(preset_elm.val()==custom_val)
604
+ {
605
+ custom_elm.prop('readonly', false).css({'background':'#ffffff'}).focus().val('');
606
+ }else
607
+ {
608
+ custom_elm.prop('readonly', true).css({'background':'#efefef'}).val(preset_elm.find('option:selected').attr('data-val'));
609
+ }
610
+ },
611
+ delimiter_toggler:function() /* function for delimiter toggle */
612
+ {
613
+ this.toggler(jQuery('.wt_iew_delimiter_preset'), jQuery('.wt_iew_custom_delimiter'), 'other');
614
+ },
615
+ date_format_toggler:function() /* function for date format toggle */
616
+ {
617
+ this.toggler(jQuery('.wt_iew_date_format_preset'), jQuery('.wt_iew_custom_date_format'), 'other');
618
+ }
619
+ }
620
+ var wt_iew_conditional_help_text=
621
+ {
622
+ Set:function(prnt)
623
+ {
624
+ prnt=prnt ? prnt : jQuery('body');
625
+ const regex = /\[(.*?)\]/gm;
626
+ let m;
627
+ prnt.find('.wt-iew_conditional_help_text').each(function()
628
+ {
629
+ var help_text_elm=jQuery(this);
630
+ var this_condition=jQuery(this).attr('data-iew-help-condition');
631
+ if(this_condition!='')
632
+ {
633
+ var condition_conf=new Array();
634
+ var field_arr=new Array();
635
+ while ((m = regex.exec(this_condition)) !== null)
636
+ {
637
+ /* This is necessary to avoid infinite loops with zero-width matches */
638
+ if(m.index === regex.lastIndex)
639
+ {
640
+ regex.lastIndex++;
641
+ }
642
+ condition_conf.push(m[1]);
643
+ condition_arr=m[1].split('=');
644
+ if(condition_arr.length>1) /* field value pair */
645
+ {
646
+ field_arr.push(condition_arr[0]);
647
+ }
648
+ }
649
+ if(field_arr.length>0)
650
+ {
651
+ var callback_fn=function()
652
+ {
653
+ var is_hide=true;
654
+ var previous_type='';
655
+ for(var c_i=0; c_i<condition_conf.length; c_i++)
656
+ {
657
+ var cr_conf=condition_conf[c_i]; /* conf */
658
+ var conf_arr=cr_conf.split('=');
659
+ if(conf_arr.length>1) /* field value pair */
660
+ {
661
+ if(previous_type!='field')
662
+ {
663
+ previous_type='field';
664
+ var elm=jQuery('[name="'+conf_arr[0]+'"]');
665
+ var vl='';
666
+ if(elm.prop('nodeName').toLowerCase()=='input' && elm.attr('type')=='radio')
667
+ {
668
+ vl=jQuery('[name="'+conf_arr[0]+'"]:checked').val();
669
+ }
670
+ else if(elm.prop('nodeName').toLowerCase()=='input' && elm.attr('type')=='checkbox')
671
+ {
672
+ if(elm.is(':checked'))
673
+ {
674
+ vl=elm.val();
675
+ }
676
+ }else
677
+ {
678
+ vl=elm.val();
679
+ }
680
+ is_hide=(vl==conf_arr[1] ? false : true);
681
+ }
682
+ }else /* glue */
683
+ {
684
+ if(previous_type!='glue')
685
+ {
686
+ previous_type='glue';
687
+ if(conf_arr[0]=='OR')
688
+ {
689
+ if(is_hide===false) /* one previous condition is okay, then stop the loop */
690
+ {
691
+ break;
692
+ }
693
+
694
+ }else if(conf_arr[0]=='AND')
695
+ {
696
+ if(is_hide===true && c_i>0) /* one previous condition is not okay, then stop the loop */
697
+ {
698
+ break;
699
+ }
700
+ }
701
+ }
702
+ }
703
+ }
704
+ if(is_hide)
705
+ {
706
+ help_text_elm.hide();
707
+ }else
708
+ {
709
+ help_text_elm.css({'display':'inline-block'});
710
+ }
711
+ }
712
+ callback_fn();
713
+ for(var f_i=0; f_i<field_arr.length; f_i++)
714
+ {
715
+ var elm=jQuery('[name="'+field_arr[f_i]+'"]');
716
+ if(elm.prop('nodeName')=='radio' || elm.prop('nodeName')=='checkbox')
717
+ {
718
+ elm.on('click', callback_fn);
719
+ }else
720
+ {
721
+ elm.on('change', callback_fn);
722
+ }
723
+ }
724
+ }
725
+ }
726
+ });
727
+ }
728
+ }
729
+
730
+
731
+ jQuery(document).ready(function(){
732
+ wt_iew_popup.Set();
733
+ wt_iew_settings_form_basic.Set('#'+wt_iew_basic_params.plugin_id);
734
+ wt_drp_menu.Set();
735
+ wt_iew_file_attacher.Set();
736
+ wt_iew_form_toggler.Set();
737
+ wt_field_group.Set();
738
+ });
admin/modules/export/assets/js/main.js ADDED
@@ -0,0 +1,906 @@
 
 
 
 
 
 
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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ var wt_iew_basic_export=(function( $ ) {
2
+ //'use strict';
3
+ var wt_iew_basic_export=
4
+ {
5
+ ajax_data:{},
6
+ selected_template:0,
7
+ selected_template_name:'',
8
+ to_export:'',
9
+ to_export_title:'',
10
+ export_method:'',
11
+ current_step:'',
12
+ loaded_status_arr:{'loaded':1, 'loading':2, 'not_loaded':0},
13
+ page_overlay:false,
14
+ step_keys:[],
15
+ form_data:{},
16
+ only_enabled_data:false,
17
+ on_rerun:false,
18
+ rerun_id:0,
19
+ Set:function()
20
+ {
21
+ this.step_keys=Object.keys(wt_iew_export_basic_params.steps);
22
+ if(this.on_rerun)
23
+ {
24
+ this.rerun();
25
+ }else
26
+ {
27
+ var first_step=this.step_keys[0];
28
+ this.load_steps([first_step], first_step);
29
+ this.show_step_page(first_step, false); /* just to show a loading */
30
+ }
31
+ },
32
+ rerun:function()
33
+ {
34
+ var last_step=this.step_keys[this.step_keys.length-1];
35
+ this.load_steps(this.step_keys, last_step);
36
+ this.show_step_page(last_step, false); /* just to show a loading */
37
+ },
38
+ load_steps:function(steps, step_to_show)
39
+ {
40
+ this.prepare_ajax_data('get_steps', 'json');
41
+ this.ajax_data.steps=steps;
42
+ if(this.on_rerun)
43
+ {
44
+ this.ajax_data.rerun_id=this.rerun_id;
45
+ }
46
+ this.set_step_loading_status(steps, 'loading');
47
+ this.set_ajax_page_loader(steps, 'loading');
48
+ $.ajax({
49
+ type: 'POST',
50
+ url:wt_iew_basic_params.ajax_url,
51
+ data:this.ajax_data,
52
+ dataType:'json',
53
+ success:function(data)
54
+ {
55
+ if(data.status==1)
56
+ {
57
+ wt_iew_basic_export.set_step_page(data);
58
+ wt_iew_basic_export.set_step_loading_status(steps, 'loaded');
59
+ if(step_to_show)
60
+ {
61
+ wt_iew_basic_export.show_step_page(step_to_show, true);
62
+ }
63
+ if(wt_iew_basic_export.on_rerun)
64
+ {
65
+ wt_iew_basic_export.load_meta_mapping_fields();
66
+ wt_iew_basic_export.on_rerun=false;
67
+ wt_iew_basic_export.rerun_id=0;
68
+ }
69
+ }else
70
+ {
71
+ // wt_iew_basic_import.set_step_loading_status(steps, 'not_loaded');
72
+ wt_iew_basic_export.set_step_loading_status(steps, 'not_loaded');
73
+ wt_iew_basic_export.set_ajax_page_loader(steps, 'error');
74
+ }
75
+ wt_iew_basic_export.remove_ajax_page_loader();
76
+ },
77
+ error:function()
78
+ {
79
+ // wt_iew_basic_import.set_step_loading_status(steps, 'not_loaded');
80
+ wt_iew_basic_export.set_step_loading_status(steps, 'not_loaded');
81
+ wt_iew_basic_export.remove_ajax_page_loader();
82
+ wt_iew_basic_export.set_ajax_page_loader(steps, 'error');
83
+ }
84
+ });
85
+ },
86
+ load_meta_mapping_fields:function()
87
+ {
88
+ if($('.meta_mapping_box_con').length>0)
89
+ {
90
+ if($('.meta_mapping_box_con[data-loaded="0"]').length==0)
91
+ {
92
+ return false;
93
+ }
94
+ }else
95
+ {
96
+ return false;
97
+ }
98
+
99
+ this.prepare_ajax_data('get_meta_mapping_fields', 'json');
100
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_export_step_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
101
+ $.ajax({
102
+ type: 'POST',
103
+ url:wt_iew_basic_params.ajax_url,
104
+ data:this.ajax_data,
105
+ dataType:'json',
106
+ success:function(data)
107
+ {
108
+ if(data.status==1)
109
+ {
110
+ $.each(data.meta_html, function(meta_id, meta_content){
111
+ $('.meta_mapping_box_con[data-key="'+meta_id+'"]').html(meta_content).attr('data-loaded', 1);
112
+ });
113
+ wt_iew_basic_export.enable_sortable();
114
+ wt_iew_basic_export.reg_mapping_field_bulk_action();
115
+ }else
116
+ {
117
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_export_step_loader">'+wt_iew_basic_params.msgs.error+'</div>');
118
+ }
119
+ },
120
+ error:function()
121
+ {
122
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_export_step_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
123
+ }
124
+ });
125
+ },
126
+ console_formdata:function()
127
+ {
128
+ console.log(this.form_data);
129
+ },
130
+ refresh_step:function(no_overlay)
131
+ {
132
+ if(!no_overlay){
133
+ this.page_overlay=true;
134
+ }
135
+ this.load_steps([this.current_step], this.current_step);
136
+ },
137
+ load_pending_steps:function(no_overlay)
138
+ {
139
+ if(!no_overlay){
140
+ this.page_overlay=true;
141
+ }
142
+ var rest_steps=this.step_keys.slice(0);
143
+ rest_steps.shift(); /* remove first step. no need to load it agian */
144
+ this.load_steps(rest_steps, this.current_step);
145
+ },
146
+ get_page_dom_object:function(step)
147
+ {
148
+ return $('.wt_iew_export_step_'+step);
149
+ },
150
+ remove_ajax_page_loader:function()
151
+ {
152
+ $('.wt_iew_loader_info_box').hide();
153
+ $('.wt_iew_overlayed_loader').hide();
154
+ $('.spinner').css({'visibility':'hidden'});
155
+ this.page_overlay=false;
156
+ },
157
+ set_ajax_page_loader:function(steps, msg_type)
158
+ {
159
+ if(this.page_overlay)
160
+ {
161
+ var h=parseInt($('.wt_iew_export_step_main').outerHeight());
162
+ var w=parseInt($('.wt_iew_export_step_main').outerWidth());
163
+ $('.wt_iew_overlayed_loader').show().css({'height':h,'width':w,'margin-top':'30px','margin-left':'30px'});
164
+ $('.spinner').css({'visibility':'visible'});
165
+ }else
166
+ {
167
+ var msg='';
168
+ if(msg_type=='loading')
169
+ {
170
+ msg=wt_iew_basic_params.msgs.loading;
171
+ }else if(msg_type=='error')
172
+ {
173
+ msg=wt_iew_basic_params.msgs.error;
174
+ }
175
+ $.each(steps, function(step_ind, step){
176
+ wt_iew_basic_export.get_page_dom_object(step).html('<div class="wt_iew_export_step_loader">'+msg+'</div>');
177
+ });
178
+ }
179
+ },
180
+ hide_export_info_box:function()
181
+ {
182
+ $('.wt_iew_loader_info_box').hide();
183
+ },
184
+ set_export_progress_info:function(msg)
185
+ {
186
+ $('.wt_iew_loader_info_box').show().html(msg);
187
+ },
188
+ nonstep_actions:function(action)
189
+ {
190
+ if(this.export_method=='template' && this.selected_template==0)
191
+ {
192
+ $('.wt_iew_warn').hide();
193
+ $('.wt_iew_export_template_wrn').show();
194
+ return false;
195
+ }
196
+
197
+ this.prepare_ajax_data(action, 'json');
198
+
199
+ if(action=='save_template' || action=='save_template_as' || action=='update_template')
200
+ {
201
+ $('.wt_iew_template_name_wrn').hide();
202
+ var pop_elm=$('.wt_iew_template_name');
203
+ var popup_label=pop_elm.attr('data-save-label');
204
+ if(action=='save_template_as')
205
+ {
206
+ var popup_label=pop_elm.attr('data-saveas-label');
207
+ }
208
+ pop_elm.find('.wt_iew_popup_hd_label, .wt_iew_template_create_btn').text(popup_label);
209
+ wt_iew_popup.showPopup(pop_elm);
210
+ $('[name="wt_iew_template_name_field"]').val(this.selected_template_name).focus();
211
+
212
+ $('.wt_iew_template_create_btn').unbind('click').click(function(){
213
+ var name=$.trim($('.wt_iew_template_name_field').val());
214
+ if(name=='')
215
+ {
216
+ $('.wt_iew_template_name_wrn').show();
217
+ $('.wt_iew_template_name_field').focus();
218
+ }else
219
+ {
220
+ $('.wt_iew_template_name_wrn').hide();
221
+ wt_iew_popup.hidePopup();
222
+
223
+ wt_iew_basic_export.prepare_form_data();
224
+ wt_iew_basic_export.ajax_data['template_name']=name;
225
+ wt_iew_basic_export.ajax_data['form_data']=wt_iew_basic_export.form_data;
226
+ wt_iew_basic_export.do_nonstep_action(action);
227
+ }
228
+ });
229
+ }else if(action=='export' || action=='upload' || action=='export_image')
230
+ {
231
+ if(action=='export' || action=='export_image')
232
+ {
233
+ this.ajax_data['offset']=0;
234
+ this.prepare_form_data();
235
+ this.ajax_data['form_data']=this.form_data;
236
+ }
237
+ wt_iew_basic_export.do_nonstep_action(action);
238
+ }else
239
+ {
240
+ /* custom action section for other modules */
241
+ this.prepare_form_data();
242
+ this.ajax_data['form_data']=this.form_data;
243
+ wt_iew_custom_action_basic(this.ajax_data, action, this.selected_template);
244
+ }
245
+ },
246
+ do_nonstep_action:function(action)
247
+ {
248
+ this.page_overlay=true;
249
+ this.set_ajax_page_loader();
250
+ $.ajax({
251
+ type: 'POST',
252
+ url:wt_iew_basic_params.ajax_url,
253
+ data:this.ajax_data,
254
+ dataType:'json',
255
+ success:function(data)
256
+ {
257
+ wt_iew_basic_export.remove_ajax_page_loader();
258
+ if(data.status==1)
259
+ {
260
+ if(action=='save_template' || action=='save_template_as' || action=='update_template')
261
+ {
262
+ wt_iew_basic_export.selected_template=data.id;
263
+ wt_iew_basic_export.selected_template_name=data.name;
264
+ wt_iew_notify_msg.success(data.msg);
265
+ //wt_iew_notify_msg.success(wt_iew_basic_params.msgs.success);
266
+
267
+ }else if(action=='export' || action=='upload' || action=='export_image')
268
+ {
269
+ if(data.finished==1)
270
+ {
271
+ wt_iew_basic_export.set_export_progress_info(data.msg);
272
+ wt_iew_notify_msg.success(wt_iew_basic_params.msgs.success);
273
+
274
+ }
275
+ else if(data.finished==2) /* Remote export */
276
+ {
277
+ wt_iew_basic_export.set_export_progress_info(data.msg);
278
+ wt_iew_basic_export.ajax_data['export_id']=data.export_id;
279
+ wt_iew_basic_export.ajax_data['total_records']=data.total_records;
280
+ wt_iew_basic_export.ajax_data['export_action']='upload';
281
+ wt_iew_basic_export.ajax_data['form_data']={};
282
+ wt_iew_basic_export.do_nonstep_action('upload');
283
+ }
284
+ else
285
+ {
286
+ wt_iew_basic_export.set_export_progress_info(data.msg);
287
+ wt_iew_basic_export.ajax_data['offset']=data.new_offset;
288
+ wt_iew_basic_export.ajax_data['export_id']=data.export_id;
289
+ wt_iew_basic_export.ajax_data['total_records']=data.total_records;
290
+ wt_iew_basic_export.do_nonstep_action(action);
291
+ }
292
+ }else
293
+ {
294
+
295
+ }
296
+ }else
297
+ {
298
+ if(data.msg!="")
299
+ {
300
+ wt_iew_notify_msg.error(data.msg);
301
+ }else
302
+ {
303
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
304
+ }
305
+ }
306
+ },
307
+ error:function()
308
+ {
309
+ wt_iew_basic_export.remove_ajax_page_loader();
310
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
311
+ }
312
+ });
313
+ },
314
+ reg_button_actions:function()
315
+ {
316
+ $('.wt_iew_export_action_btn').unbind('click').click(function(e){
317
+ e.preventDefault();
318
+ var action=$(this).attr('data-action');
319
+ var action_type=$(this).attr('data-action-type');
320
+ var is_previous_step=wt_iew_basic_export.is_previous_step(action);
321
+ // if(!wt_iew_exporter_validate(action, action_type, is_previous_step))
322
+ // {
323
+ // return false;
324
+ // }
325
+
326
+ if(action_type=='step')
327
+ {
328
+ wt_iew_basic_export.change_step(action);
329
+ }else
330
+ {
331
+ wt_iew_basic_export.nonstep_actions(action);
332
+ }
333
+ });
334
+ },
335
+ change_step:function(step_to_go)
336
+ {
337
+ /* validation section */
338
+ if(this.current_step=='post_type')
339
+ {
340
+ if(this.to_export=='')
341
+ {
342
+ $('.wt_iew_post_type_wrn').show();
343
+ return false;
344
+ }
345
+ }else if(this.current_step=='method_export') /* method export page */
346
+ {
347
+ if(this.export_method=='template' && this.selected_template==0 && !this.is_previous_step(step_to_go))
348
+ {
349
+ $('.wt_iew_warn').hide();
350
+ $('.wt_iew_export_template_wrn').show();
351
+ return false;
352
+ }
353
+ }
354
+
355
+ /* setting fromdata */
356
+ this.prepare_form_data();
357
+
358
+ /* step changing section */
359
+ this.show_step_page(step_to_go, true);
360
+ },
361
+ reset_form_data:function()
362
+ {
363
+ this.form_data={};
364
+ this.selected_template=0;
365
+ this.selected_template_name='';
366
+ this.export_method='';
367
+ },
368
+ prepare_form_data:function()
369
+ {
370
+ if(this.current_step=='post_type')
371
+ {
372
+ this.form_data['post_type_form_data']=JSON.stringify({'item_type':wt_iew_basic_export.to_export});
373
+ }
374
+ else if(this.current_step=='method_export')
375
+ {
376
+ var mapping_enabled_fields=new Array();
377
+ $('.wt_iew_export_step_method_export [name="wt_iew_include_these_fields[]"]').each(function(){
378
+ if($(this).is(':checked'))
379
+ {
380
+ mapping_enabled_fields.push($(this).val());
381
+ }
382
+ });
383
+ this.form_data['method_export_form_data']=JSON.stringify({'method_export':wt_iew_basic_export.export_method, 'mapping_enabled_fields':mapping_enabled_fields, 'selected_template':this.selected_template});
384
+ }
385
+ else if(this.current_step=='filter')
386
+ {
387
+ if($('.wt_iew_export_filter_form').length>0)
388
+ {
389
+ var form_data=$('.wt_iew_export_filter_form').serializeArray();
390
+ var filter_form_data={};
391
+ $.each(form_data, function(){
392
+ if(filter_form_data[this.name])
393
+ {
394
+ if(!filter_form_data[this.name].push)
395
+ {
396
+ filter_form_data[this.name] = [filter_form_data[this.name]];
397
+ }
398
+ filter_form_data[this.name].push(this.value || '');
399
+ }else
400
+ {
401
+ if(wt_iew_basic_export.is_multi_select(this.name))
402
+ {
403
+ filter_form_data[this.name] = [(this.value || '')];
404
+ }else
405
+ {
406
+ filter_form_data[this.name] = this.value || '';
407
+ }
408
+ }
409
+ });
410
+ this.form_data['filter_form_data']=JSON.stringify(filter_form_data);
411
+ }
412
+ }
413
+ else if(this.current_step=='mapping')
414
+ {
415
+
416
+ /**
417
+ * Default mapping fields //===============================================
418
+ */
419
+
420
+ var mapping_form_data={};
421
+ var mapping_fields={};
422
+ var mapping_selected_fields={}; /* this value is only for backend processing */
423
+
424
+ $('.wt-iew-exporter-default-mapping-tb tbody tr').each(function(){
425
+
426
+ var columns_key=$(this).find('.columns_key').val();
427
+ var columns_val=$(this).find('.columns_val').val();
428
+
429
+ if(wt_iew_basic_export.only_enabled_data===false) /* get whole keys instead of enabled/disabled */
430
+ {
431
+ var enabled=($(this).find('.columns_key').is(':checked') ? 1 : 0);
432
+ mapping_fields[columns_key]=[columns_val,enabled];
433
+
434
+ if(enabled==1)
435
+ {
436
+ mapping_selected_fields[columns_key]=columns_val;
437
+ }
438
+
439
+ }else
440
+ {
441
+ if($(this).find('.columns_key').is(':checked'))
442
+ {
443
+ mapping_fields[columns_key]=columns_val;
444
+ mapping_selected_fields[columns_key]=columns_val;
445
+ }
446
+ }
447
+ });
448
+
449
+ var mapping_enabled_fields=new Array();
450
+ /*
451
+ $('.wt_iew_export_step_mapping [name="wt_iew_include_these_fields[]"]').each(function(){
452
+
453
+ if($(this).is(':checked'))
454
+ {
455
+ mapping_enabled_fields.push($(this).val());
456
+ }
457
+
458
+ });
459
+ */
460
+
461
+ mapping_form_data={'mapping_fields':mapping_fields,'mapping_enabled_fields':mapping_enabled_fields, 'mapping_selected_fields':mapping_selected_fields};
462
+ this.form_data['mapping_form_data']=JSON.stringify(mapping_form_data);
463
+
464
+
465
+
466
+ /**
467
+ * meta mapping fields //===============================================
468
+ */
469
+
470
+ var meta_step_form_data={};
471
+ var mapping_fields={};
472
+ var mapping_selected_fields={}; /* this value is only for backend processing */
473
+
474
+ $('.wt-iew-exporter-meta-mapping-tb').each(function(){
475
+ var mapping_key=$(this).attr('data-field-type');
476
+ mapping_fields[mapping_key]={};
477
+ mapping_selected_fields[mapping_key]={};
478
+
479
+ $(this).find('tbody tr').each(function(){
480
+ if($(this).find('.columns_key').length>0 && $(this).find('.columns_val').length>0)
481
+ {
482
+ var columns_key=$(this).find('.columns_key').val();
483
+ var columns_val=$(this).find('.columns_val').val();
484
+
485
+ if(wt_iew_basic_export.only_enabled_data===false) /* get whole keys instead of enabled/disabled */
486
+ {
487
+ var enabled=($(this).find('.columns_key').is(':checked') ? 1 : 0);
488
+ mapping_fields[mapping_key][columns_key]=[columns_val,enabled];
489
+
490
+ if(enabled==1)
491
+ {
492
+ mapping_selected_fields[mapping_key][columns_key]=columns_val;
493
+ }
494
+
495
+ }else
496
+ {
497
+ if($(this).find('.columns_key').is(':checked'))
498
+ {
499
+ mapping_fields[mapping_key][columns_key]=columns_val;
500
+ mapping_selected_fields[mapping_key][columns_key]=columns_val;
501
+ }
502
+ }
503
+ }
504
+ });
505
+ });
506
+
507
+ meta_step_form_data={'mapping_fields':mapping_fields, 'mapping_selected_fields':mapping_selected_fields};
508
+ this.form_data['meta_step_form_data']=JSON.stringify(meta_step_form_data);
509
+
510
+ }
511
+ else
512
+ {
513
+ var current_form_data={};
514
+ if($('.wt_iew_export_'+this.current_step+'_form').length>0) /* may be user hit the back button */
515
+ {
516
+ var form_data=$('.wt_iew_export_'+this.current_step+'_form').serializeArray();
517
+ $.each(form_data, function(){
518
+
519
+ if(current_form_data[this.name])
520
+ {
521
+ if(!current_form_data[this.name].push)
522
+ {
523
+ current_form_data[this.name] = [current_form_data[this.name]];
524
+ }
525
+ current_form_data[this.name].push(this.value || '');
526
+ }else
527
+ {
528
+ current_form_data[this.name] = this.value || '';
529
+ }
530
+
531
+ });
532
+
533
+ this.form_data[this.current_step+'_form_data']=JSON.stringify(current_form_data);
534
+ }
535
+ }
536
+
537
+ /* we are resetting formdata on second step. If user not going to first step then post type formdata will be empty. */
538
+ if(this.current_step!='post_type')
539
+ {
540
+ this.form_data['post_type_form_data']=JSON.stringify({'item_type':wt_iew_basic_export.to_export});
541
+ }
542
+
543
+ },
544
+ is_multi_select:function(name)
545
+ {
546
+ var elm=$('[name="'+name+'"]');
547
+ if(elm.prop("tagName").toLowerCase()=='select' && this.has_attr(elm,'multiple'))
548
+ {
549
+ return true;
550
+ }else
551
+ {
552
+ return false;
553
+ }
554
+ },
555
+ has_attr:function(elm,attr_name)
556
+ {
557
+ var attr = elm.attr(attr_name);
558
+ if(typeof attr!==typeof undefined && attr!==false)
559
+ {
560
+ return true;
561
+ }else
562
+ {
563
+ return false;
564
+ }
565
+ },
566
+ is_previous_step:function(step_key)
567
+ {
568
+ if(wt_iew_export_basic_params.steps.hasOwnProperty(step_key))
569
+ {
570
+ if(this.step_keys.indexOf(step_key)<this.step_keys.indexOf(this.current_step))
571
+ {
572
+ return true;
573
+ }
574
+ }
575
+ return false;
576
+ },
577
+ is_step_loaded:function(step)
578
+ {
579
+ if(this.get_page_dom_object(step).length==0){ return true; } /* block infinite loop, if element is not available */
580
+ return (this.get_page_dom_object(step).attr('data-loaded')==this.loaded_status_arr['loaded']);
581
+ },
582
+ set_step_loading_status:function(steps, status)
583
+ {
584
+ $.each(steps, function(step_ind, step){
585
+ wt_iew_basic_export.get_page_dom_object(step).attr('data-loaded', wt_iew_basic_export.loaded_status_arr[status]);
586
+ });
587
+ },
588
+ show_step_page:function(step, force_check_loaded)
589
+ {
590
+ $('.wt_iew_export_step').hide();
591
+ this.get_page_dom_object(step).show();
592
+ this.current_step=step;
593
+ if(force_check_loaded)
594
+ {
595
+ if(this.is_step_loaded(step))
596
+ {
597
+ this.current_step_actions();
598
+ }else
599
+ {
600
+ this.refresh_step(true);
601
+ }
602
+ }else
603
+ {
604
+ this.current_step_actions();
605
+ }
606
+ wt_iew_form_toggler.runToggler();
607
+ },
608
+ current_step_actions:function() /* current page actions after page is visible */
609
+ {
610
+ if(this.current_step=='filter')
611
+ {
612
+ this.load_meta_mapping_fields();
613
+ }else if(this.current_step=='advanced')
614
+ {
615
+ wt_field_group.Set();
616
+ }
617
+ },
618
+ show_post_type_name:function()
619
+ {
620
+ if(this.to_export!="" && this.to_export_title=='')
621
+ {
622
+ $('[name="wt_iew_export_post_type"]').val(this.to_export);
623
+ this.to_export_title=$('[name="wt_iew_export_post_type"] option:selected').text();
624
+ }
625
+ $('.wt_iew_step_head_post_type_name').html(this.to_export_title);
626
+ },
627
+ page_actions:function(step)
628
+ {
629
+ if(step=='post_type') /* post type page */
630
+ {
631
+ $('[name="wt_iew_export_post_type"]').unbind('change').change(function(){
632
+ wt_iew_basic_export.to_export=$(this).val();
633
+ wt_iew_basic_export.to_export_title='';
634
+ wt_iew_basic_export.reset_form_data();
635
+ $('.wt_iew_post_type_name').html('');
636
+ if(wt_iew_basic_export.to_export=='')
637
+ {
638
+ $('.wt_iew_post_type_wrn').show();
639
+ }else
640
+ {
641
+ $('.wt_iew_post_type_wrn').hide();
642
+ var post_type_name=$('[name="wt_iew_export_post_type"] option:selected').text();
643
+ /* $('.wt_iew_post_type_name').html(': '+post_type_name); */
644
+ wt_iew_basic_export.to_export_title=post_type_name;
645
+ wt_iew_basic_export.load_pending_steps(true);
646
+ }
647
+ });
648
+ }
649
+ else if(step=='method_export') /* method export page */
650
+ {
651
+ this.export_method=$('[name="wt_iew_export_method_export"]:checked').val();
652
+ this.toggle_export_method_options();
653
+
654
+ $('[name="wt_iew_export_method_export"]').unbind('click').click(function(){
655
+ var vl=$(this).val();
656
+ if(wt_iew_basic_export.export_method==vl)
657
+ {
658
+ return false;
659
+ }
660
+ wt_iew_basic_export.reset_form_data();
661
+ wt_iew_basic_export.export_method=vl;
662
+ if(wt_iew_basic_export.export_method=='template')
663
+ {
664
+ if($('.wt-iew-export-template-sele').val()==0)
665
+ {
666
+ wt_iew_basic_export.refresh_step();
667
+ }else
668
+ {
669
+ wt_iew_basic_export.selected_template=$('.wt-iew-export-template-sele').val();
670
+ wt_iew_basic_export.selected_template_name=$.trim($('.wt-iew-export-template-sele option:selected').text());
671
+ wt_iew_basic_export.load_pending_steps();
672
+ }
673
+ }else
674
+ {
675
+ wt_iew_basic_export.load_pending_steps();
676
+ }
677
+ });
678
+
679
+ $('.wt-iew-export-template-sele').unbind('change').change(function(){
680
+ wt_iew_basic_export.selected_template=$(this).val();
681
+ $('.wt_iew_warn').hide();
682
+ if(wt_iew_basic_export.selected_template==0)
683
+ {
684
+ $('.wt_iew_export_template_wrn').show();
685
+ }else
686
+ {
687
+ wt_iew_basic_export.selected_template_name=$.trim($('.wt-iew-export-template-sele option:selected').text());
688
+ wt_iew_basic_export.load_pending_steps();
689
+ }
690
+ });
691
+ }
692
+ else if(step=='filter') /* filter page */
693
+ {
694
+ $('.wc-enhanced-select').select2();
695
+ $( document.body ).trigger( 'wc-enhanced-select-init' );
696
+ }
697
+ else if(step=='mapping') /* mapping page */
698
+ {
699
+ this.enable_sortable();
700
+ this.mapping_box_accordian();
701
+ this.reg_mapping_field_bulk_action();
702
+ }
703
+ else if(step=='advanced')
704
+ {
705
+ /* callback for external adapters */
706
+ if($('select[name="wt_iew_file_into"]').length>0) /* multiple adapter exists so select box */
707
+ {
708
+ var file_into=$('[name="wt_iew_file_into"]').val();
709
+ $('[name="wt_iew_file_into"]').unbind('change').on('change',function(){
710
+ var file_into=$(this).val();
711
+ wt_iew_set_file_into_fields(file_into);
712
+ });
713
+ }else /* radio button */
714
+ {
715
+ var file_into=$('[name="wt_iew_file_into"]:checked').val();
716
+ $('[name="wt_iew_file_into"]').on('click',function(){
717
+ var file_into=$('[name="wt_iew_file_into"]:checked').val();
718
+ wt_iew_set_file_into_fields(file_into);
719
+ });
720
+ }
721
+ wt_iew_set_file_into_fields(file_into);
722
+
723
+ /* separate image export option */
724
+ if($('.wt_iew_separate_image_export').length>0) /* separate image export option available */
725
+ {
726
+ if($('.wt_iew_separate_image_export:checked').val()=='Yes')
727
+ {
728
+ $('.iew_export_image_btn').show();
729
+ }else
730
+ {
731
+ $('.iew_export_image_btn').hide();
732
+ }
733
+ }else
734
+ {
735
+ $('.iew_export_image_btn').hide();
736
+ }
737
+ $('.wt_iew_separate_image_export').unbind('click').click(function(){
738
+ if($(this).val()=='Yes')
739
+ {
740
+ $('.iew_export_image_btn').show();
741
+ }else
742
+ {
743
+ $('.iew_export_image_btn').hide();
744
+ }
745
+ });
746
+
747
+ /* CSV delimiter form toggler. Custom and preset delimiter */
748
+ wt_iew_custom_and_preset.delimiter_toggler();
749
+
750
+ /* file extension info box */
751
+ $('.wt_iew_file_ext_info').html('.'+$('[name="wt_iew_file_as"]').val());
752
+ $('[name="wt_iew_file_as"]').unbind('change').change(function(){
753
+ $('.wt_iew_file_ext_info').html('.'+$(this).val());
754
+ });
755
+ }
756
+
757
+ /* common events */
758
+ if($('.wt_iew_datepicker').length>0)
759
+ {
760
+ $('.wt_iew_datepicker').datepicker({dateFormat: 'yy-mm-dd'});
761
+ }
762
+ wt_field_group.Set();
763
+ wt_iew_form_toggler.Set();
764
+ wt_iew_conditional_help_text.Set(this.get_page_dom_object(step));
765
+
766
+ },
767
+ enable_sortable:function()
768
+ {
769
+ $('.meta_mapping_box_con[data-sortable="0"]').each(function(){
770
+ var tb=$(this).find(".wt-iew-mapping-tb tbody");
771
+ if(tb.length>0)
772
+ {
773
+ tb.sortable({
774
+ handle: ".wt_iew_sort_handle",
775
+ placeholder: "wt-iew-sortable-placeholder",
776
+ forcePlaceholderSize: true,
777
+ revert:true
778
+ });
779
+ $(this).attr('data-sortable', 1);
780
+ }
781
+ });
782
+ },
783
+ toggle_export_method_options:function()
784
+ {
785
+ $('.wt-iew-export-method-options').hide();
786
+ $('.wt-iew-export-method-options-'+this.export_method).show();
787
+ },
788
+ mapping_box_accordian:function()
789
+ {
790
+ $('.meta_mapping_box_hd').unbind('click').click(function()
791
+ {
792
+ var c_dv=$(this).parents('.meta_mapping_box').find('.meta_mapping_box_con');
793
+ if(c_dv.is(':visible'))
794
+ {
795
+ c_dv.hide();
796
+ $(this).find('.dashicons').removeClass('dashicons-arrow-down').addClass('dashicons-arrow-right');
797
+ }else
798
+ {
799
+ c_dv.show();
800
+ c_dv.find(".wt-iew-mapping-tb tbody tr td").each(function(){
801
+ $(this).css({'width':$(this).width()});
802
+ });
803
+ $(this).find('.dashicons').removeClass('dashicons-arrow-right').addClass('dashicons-arrow-down');
804
+ }
805
+ });
806
+ },
807
+ mapping_fields_selected_count:function(tb_elm)
808
+ {
809
+ tb_elm.parents('.meta_mapping_box').find('.meta_mapping_box_selected_count_box_num').text(tb_elm.find('.wt_iew_mapping_checkbox_sub:checked').length);
810
+ },
811
+ reg_mapping_field_bulk_action:function()
812
+ {
813
+ $('.wt_iew_mapping_checkbox_main').each(function()
814
+ {
815
+ var tb=$(this).parents('.wt-iew-mapping-tb');
816
+ if(tb.find('.wt_iew_mapping_checkbox_sub:checked').length==tb.find('.wt_iew_mapping_checkbox_sub').length)
817
+ {
818
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',true);
819
+ }else
820
+ {
821
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',false);
822
+ }
823
+ wt_iew_basic_export.mapping_fields_selected_count(tb);
824
+ });
825
+
826
+ $('.wt_iew_mapping_checkbox_main').unbind('click').click(function()
827
+ {
828
+ var tb=$(this).parents('.wt-iew-mapping-tb');
829
+ if($(this).is(':checked'))
830
+ {
831
+ tb.find('.wt_iew_mapping_checkbox_sub').prop('checked',true);
832
+ }else
833
+ {
834
+ tb.find('.wt_iew_mapping_checkbox_sub').prop('checked',false);
835
+ }
836
+ wt_iew_basic_export.mapping_fields_selected_count(tb);
837
+ });
838
+ $('.wt_iew_mapping_checkbox_sub').unbind('click').click(function()
839
+ {
840
+ var tb=$(this).parents('.wt-iew-mapping-tb');
841
+ if($(this).is(':checked') && tb.find('.wt_iew_mapping_checkbox_sub:checked').length==tb.find('.wt_iew_mapping_checkbox_sub').length)
842
+ {
843
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',true);
844
+ }else
845
+ {
846
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',false);
847
+ }
848
+ wt_iew_basic_export.mapping_fields_selected_count(tb);
849
+ });
850
+ },
851
+ set_step_page:function(data)
852
+ {
853
+ page_html=data.page_html;
854
+ $.each(page_html, function(step_id, page_content){
855
+ wt_iew_basic_export.get_page_dom_object(step_id).html(page_content);
856
+ wt_iew_basic_export.page_actions(step_id);
857
+
858
+ if(step_id=='method_export' && (wt_iew_basic_export.selected_template>0 || wt_iew_basic_export.on_rerun))
859
+ {
860
+ wt_iew_basic_export.form_data=data.template_data;
861
+
862
+ if(wt_iew_basic_export.on_rerun)
863
+ {
864
+ if($('.wt-iew-export-template-sele').val()==0)
865
+ {
866
+ wt_iew_basic_export.selected_template=0;
867
+ wt_iew_basic_export.selected_template_name='';
868
+ }else
869
+ {
870
+ wt_iew_basic_export.selected_template=$('.wt-iew-export-template-sele').val();
871
+ wt_iew_basic_export.selected_template_name=$.trim($('.wt-iew-export-template-sele option:selected').text());
872
+ }
873
+ }
874
+ }
875
+ wt_iew_basic_export.show_post_type_name();
876
+ });
877
+ this.reg_button_actions();
878
+ },
879
+ prepare_ajax_data:function(action, data_type)
880
+ {
881
+ this.ajax_data = {
882
+ '_wpnonce': wt_iew_basic_params.nonces.main,
883
+ 'action': "iew_export_ajax_basic",
884
+ 'export_action': action,
885
+ 'selected_template': this.selected_template,
886
+ 'to_export': this.to_export,
887
+ 'data_type': data_type,
888
+ 'export_method': this.export_method,
889
+ };
890
+ }
891
+ }
892
+ return wt_iew_basic_export;
893
+
894
+ })( jQuery );
895
+
896
+ jQuery(function() {
897
+
898
+ if(wt_iew_export_basic_params.rerun_id>0)
899
+ {
900
+ wt_iew_basic_export.to_export=wt_iew_export_basic_params.to_export;
901
+ wt_iew_basic_export.export_method=wt_iew_export_basic_params.export_method;
902
+ wt_iew_basic_export.rerun_id=wt_iew_export_basic_params.rerun_id;
903
+ wt_iew_basic_export.on_rerun=true;
904
+ }
905
+ wt_iew_basic_export.Set();
906
+ });
admin/modules/export/classes/class-export-ajax.php ADDED
@@ -0,0 +1,707 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Ajax section of the Export module
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+
13
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Export_Ajax')){
14
+ class Wt_Import_Export_For_Woo_Basic_Export_Ajax
15
+ {
16
+ public $step='';
17
+ public $steps=array();
18
+ public $step_btns=array();
19
+ public $export_method='';
20
+ public $to_export='';
21
+
22
+ protected $step_title='';
23
+ protected $step_keys=array();
24
+ protected $current_step_index=0;
25
+ protected $current_step_number=1;
26
+ protected $last_page=false;
27
+ protected $total_steps=0;
28
+ protected $step_summary='';
29
+ protected $mapping_enabled_fields=array();
30
+ protected $mapping_templates=array();
31
+ protected $selected_template=0;
32
+ protected $selected_template_form_data=array(); /* this variable is using to store form_data of selected template or selected history entry */
33
+ protected $export_obj=null;
34
+ protected $rerun_id=0;
35
+
36
+ public function __construct($export_obj, $to_export, $steps, $export_method, $selected_template, $rerun_id)
37
+ {
38
+ $this->export_obj=$export_obj;
39
+ $this->to_export=$to_export;
40
+ $this->steps=$steps;
41
+ $this->export_method=$export_method;
42
+ $this->selected_template=$selected_template;
43
+ $this->rerun_id=$rerun_id;
44
+ }
45
+
46
+ /**
47
+ * Ajax main function to retrive steps HTML
48
+ */
49
+ public function get_steps($out)
50
+ {
51
+ //sleep(3);
52
+ $steps=(is_array($_POST['steps']) ? $_POST['steps'] : array($_POST['steps']));
53
+ $steps=Wt_Iew_Sh::sanitize_item($steps, 'text_arr');
54
+ $page_html=array();
55
+
56
+ if($this->selected_template>0) /* taking selected tamplate form_data */
57
+ {
58
+ $this->get_template_form_data($this->selected_template);
59
+
60
+ }elseif($this->rerun_id>0)
61
+ {
62
+ $this->selected_template_form_data=$this->export_obj->form_data;
63
+ }
64
+
65
+ foreach($steps as $step)
66
+ {
67
+ $method_name=$step.'_page';
68
+ if(method_exists($this, $method_name))
69
+ {
70
+ $page_html[$step]=$this->{$method_name}();
71
+
72
+ if($step=='method_export' && ($this->selected_template>0 || $this->rerun_id>0))
73
+ {
74
+ $out['template_data']=$this->selected_template_form_data;
75
+ }
76
+ }
77
+ }
78
+ $out['status']=1;
79
+ $out['page_html']=$page_html;
80
+ return $out;
81
+ }
82
+
83
+ /**
84
+ * Ajax function to retrive meta step data
85
+ */
86
+ public function get_meta_mapping_fields($out)
87
+ {
88
+ if($this->selected_template>0) /* taking selected tamplate form_data */
89
+ {
90
+ $this->get_template_form_data($this->selected_template);
91
+
92
+ }elseif($this->rerun_id>0)
93
+ {
94
+ $this->selected_template_form_data=$this->export_obj->form_data;
95
+ }
96
+
97
+ $this->get_mapping_enabled_fields();
98
+
99
+ $meta_mapping_screen_fields=array();
100
+ foreach($this->mapping_enabled_fields as $field_key=>$field_vl)
101
+ {
102
+ $field_vl=(!is_array($field_vl) ? array($field_vl, 0) : $field_vl);
103
+ $meta_mapping_screen_fields[$field_key]=array(
104
+ 'title'=>'',
105
+ 'checked'=>$field_vl[1],
106
+ 'fields'=>array(),
107
+ );
108
+ }
109
+
110
+ //taking current page form data
111
+ $meta_step_form_data=(isset($this->selected_template_form_data['meta_step_form_data']) ? $this->selected_template_form_data['meta_step_form_data'] : array());
112
+
113
+ /* form_data/template data of fields in mapping page */
114
+ $form_data_meta_mapping_fields=isset($meta_step_form_data['mapping_fields']) ? $meta_step_form_data['mapping_fields'] : array();
115
+
116
+
117
+ $meta_mapping_screen_fields=apply_filters('wt_iew_exporter_alter_meta_mapping_fields_basic', $meta_mapping_screen_fields, $this->to_export, $form_data_meta_mapping_fields);
118
+
119
+ $draggable_tooltip=__("Drag to rearrange the columns");
120
+ $module_url=plugin_dir_url(dirname(__FILE__));
121
+
122
+ $meta_html=array();
123
+ if($meta_mapping_screen_fields && is_array($meta_mapping_screen_fields))
124
+ {
125
+ /* loop through mapping fields */
126
+ foreach($meta_mapping_screen_fields as $meta_mapping_screen_field_key=>$meta_mapping_screen_field_val)
127
+ {
128
+ $current_meta_step_form_data=(isset($form_data_meta_mapping_fields[$meta_mapping_screen_field_key]) ? $form_data_meta_mapping_fields[$meta_mapping_screen_field_key] : array());
129
+ ob_start();
130
+ include dirname(plugin_dir_path(__FILE__)).'/views/_export_meta_step_page.php';
131
+ $meta_html[$meta_mapping_screen_field_key]=ob_get_clean();
132
+ }
133
+ }
134
+
135
+ $out['status']=1;
136
+ $out['meta_html']=$meta_html;
137
+ return $out;
138
+ }
139
+
140
+ public function save_template($out)
141
+ {
142
+ return $this->do_save_template('save', $out);
143
+ }
144
+
145
+ public function save_template_as($out)
146
+ {
147
+ return $this->do_save_template('save_as', $out);
148
+ }
149
+
150
+ public function update_template($out)
151
+ {
152
+ return $this->do_save_template('update', $out);
153
+ }
154
+
155
+ /**
156
+ * Ajax hook to upload the exported file.
157
+ *
158
+ */
159
+ public function upload($out)
160
+ {
161
+ $export_id=(isset($_POST['export_id']) ? intval($_POST['export_id']) : 0);
162
+ $out=$this->export_obj->process_upload('upload', $export_id, $this->to_export);
163
+ if($out['response']===true)
164
+ {
165
+ $out['status']=1;
166
+ }else
167
+ {
168
+ $out['status']=0;
169
+ }
170
+ return $out;
171
+ }
172
+
173
+
174
+ /**
175
+ * Process the export data
176
+ *
177
+ * @return array
178
+ */
179
+ public function export($out)
180
+ {
181
+ $offset=(isset($_POST['offset']) ? intval($_POST['offset']) : 0);
182
+ $export_id=(isset($_POST['export_id']) ? intval($_POST['export_id']) : 0);
183
+ $file_name='';
184
+
185
+ if($export_id==0) /* first batch */
186
+ {
187
+ /* process form data */
188
+ $form_data=(isset($_POST['form_data']) ? Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize(($_POST['form_data']))) : array());
189
+
190
+ //sanitize form data
191
+ $form_data=Wt_Iew_IE_Basic_Helper::sanitize_formdata($form_data, $this->export_obj);
192
+
193
+ /* taking file name from user input. (If given) */
194
+ if(isset($form_data['advanced_form_data']) && isset($form_data['advanced_form_data']['wt_iew_file_name']) && $form_data['advanced_form_data']['wt_iew_file_name']!="")
195
+ {
196
+ $file_name=$form_data['advanced_form_data']['wt_iew_file_name'];
197
+ }
198
+
199
+ }else
200
+ {
201
+ /* no need to send form_data. It will take from history table by `process_action` method */
202
+ $form_data=array();
203
+ }
204
+
205
+ /* do the export process */
206
+ $out=$this->export_obj->process_action($form_data, 'export', $this->to_export, $file_name, $export_id, $offset);
207
+ if($out['response']===true)
208
+ {
209
+ $out['status']=1;
210
+ }else
211
+ {
212
+ $out['status']=0;
213
+ }
214
+ return $out;
215
+ }
216
+
217
+ /**
218
+ * Save/Update template (Ajax sub function)
219
+ * @param boolean $is_update is update existing template or save as new
220
+ * @return array response status, name, id
221
+ */
222
+ public function do_save_template($step, $out)
223
+ {
224
+ $is_update=($step=='update' ? true : false);
225
+
226
+ /* take template name from post data, if not then create from time stamp */
227
+ $template_name=(isset($_POST['template_name']) ? sanitize_text_field($_POST['template_name']) : date('d-M-Y h:i:s A'));
228
+
229
+ $template_name = stripslashes($template_name);
230
+ $out['name']= $template_name;
231
+ $out['id']=0;
232
+ $out['status']=1;
233
+
234
+ if($this->to_export!='')
235
+ {
236
+ global $wpdb;
237
+
238
+ /* checking: just saved and again click the button so shift the action as update */
239
+ if($step=='save' && $this->selected_template>0)
240
+ {
241
+ $is_update=true;
242
+ }
243
+
244
+ /* checking template with same name exists */
245
+ $template_data=$this->get_mapping_template_by_name($template_name);
246
+ if($template_data)
247
+ {
248
+ $is_throw_warn=false;
249
+ if($is_update)
250
+ {
251
+ if($template_data['id']!=$this->selected_template)
252
+ {
253
+ $is_throw_warn=true;
254
+ }
255
+ }else
256
+ {
257
+ $is_throw_warn=true;
258
+ }
259
+
260
+ if($is_throw_warn)
261
+ {
262
+ $out['status']=0;
263
+ if($step=='save_as')
264
+ {
265
+ $out['msg']=__('Please enter a different name');
266
+ }else
267
+ {
268
+ $out['msg']=__('Template with same name already exists');
269
+ }
270
+ return $out;
271
+ }
272
+ }
273
+
274
+ $tb=$wpdb->prefix. Wt_Import_Export_For_Woo_Basic::$template_tb;
275
+
276
+ /* process form data */
277
+ $form_data=(isset($_POST['form_data']) ? Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize(($_POST['form_data']))) : array());
278
+
279
+ //sanitize form data
280
+ $form_data=Wt_Iew_IE_Basic_Helper::sanitize_formdata($form_data, $this->export_obj);
281
+
282
+ /* upadte the template */
283
+ if($is_update)
284
+ {
285
+
286
+ $update_data=array(
287
+ 'data'=>maybe_serialize($form_data),
288
+ 'name'=>$template_name, //may be a rename
289
+ );
290
+ $update_data_type=array(
291
+ '%s',
292
+ '%s'
293
+ );
294
+ $update_where=array(
295
+ 'id'=>$this->selected_template
296
+ );
297
+ $update_where_type=array(
298
+ '%d'
299
+ );
300
+ if($wpdb->update($tb, $update_data, $update_where, $update_data_type, $update_where_type)!==false)
301
+ {
302
+ $out['id']=$this->selected_template;
303
+ $out['msg']=__('Template updated successfully');
304
+ $out['name']=$template_name;
305
+ return $out;
306
+ }
307
+ }else
308
+ {
309
+ $insert_data=array(
310
+ 'template_type'=>'export',
311
+ 'item_type'=>$this->to_export,
312
+ 'name'=>$template_name,
313
+ 'data'=>maybe_serialize($form_data),
314
+ );
315
+ $insert_data_type=array(
316
+ '%s','%s','%s','%s'
317
+ );
318
+ if($wpdb->insert($tb, $insert_data, $insert_data_type)) //success
319
+ {
320
+ $out['id']=$wpdb->insert_id;
321
+ $out['msg']=__('Template saved successfully');
322
+ return $out;
323
+ }
324
+ }
325
+ }
326
+ $out['status']=0;
327
+ return $out;
328
+ }
329
+
330
+ /**
331
+ * Step 1 (Ajax sub function)
332
+ * Built in steps, post type choosing page
333
+ */
334
+ public function post_type_page()
335
+ {
336
+ $post_types=apply_filters('wt_iew_exporter_post_types_basic', array());
337
+ $post_types=(!is_array($post_types) ? array() : $post_types);
338
+ $this->step='post_type';
339
+ $step_info=$this->steps[$this->step];
340
+ $item_type=$this->to_export;
341
+
342
+ $this->prepare_step_summary();
343
+ $this->prepare_footer_button_list();
344
+
345
+ ob_start();
346
+ $this->prepare_step_header_html();
347
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_export_post_type_page.php';
348
+ $this->prepare_step_footer_html();
349
+ return ob_get_clean();
350
+ }
351
+
352
+ /**
353
+ * Step 2 (Ajax sub function)
354
+ * Built in steps, export method choosing page
355
+ */
356
+ public function method_export_page()
357
+ {
358
+ $this->step='method_export';
359
+ $step_info=$this->steps[$this->step];
360
+ if($this->to_export!="")
361
+ {
362
+ /* setting a default export method */
363
+ $this->export_method=($this->export_method=='' ? $this->export_obj->default_export_method : $this->export_method);
364
+ $this->export_obj->export_method=$this->export_method;
365
+ $this->steps=$this->export_obj->get_steps();
366
+
367
+ $form_data_export_template=$this->selected_template;
368
+ $form_data_mapping_enabled=array();
369
+ if($this->rerun_id>0)
370
+ {
371
+ if(isset($this->selected_template_form_data['method_export_form_data']))
372
+ {
373
+ if(isset($this->selected_template_form_data['method_export_form_data']['selected_template']))
374
+ {
375
+ /* do not set this value to `$this->selected_template` */
376
+ $form_data_export_template=$this->selected_template_form_data['method_export_form_data']['selected_template'];
377
+ }
378
+ if(isset($this->selected_template_form_data['method_export_form_data']['mapping_enabled_fields']))
379
+ {
380
+ $form_data_mapping_enabled=$this->selected_template_form_data['method_export_form_data']['mapping_enabled_fields'];
381
+ $form_data_mapping_enabled=(is_array($form_data_mapping_enabled) ? $form_data_mapping_enabled : array());
382
+ }
383
+ }
384
+ }
385
+
386
+ $this->prepare_step_summary();
387
+ $this->prepare_footer_button_list();
388
+
389
+ /* meta field list for quick export */
390
+ $this->get_mapping_enabled_fields();
391
+
392
+ /* template list for template export */
393
+ $this->get_mapping_templates();
394
+
395
+ ob_start();
396
+ $this->prepare_step_header_html();
397
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_export_method_export_page.php';
398
+ $this->prepare_step_footer_html();
399
+ return ob_get_clean();
400
+ }else
401
+ {
402
+ return '';
403
+ }
404
+ }
405
+
406
+ /*
407
+ * Get step information
408
+ * @param string $step
409
+ */
410
+
411
+ public function get_step_info( $step ) {
412
+ return isset( $this->steps[ $step ] ) ? $this->steps[ $step ] : array( 'title' => ' ', 'description' => ' ' );
413
+ }
414
+
415
+ /**
416
+ * Step 3 (Ajax sub function)
417
+ * Built in steps, filter page
418
+ */
419
+ public function filter_page()
420
+ {
421
+ $this->step='filter';
422
+ $step_info= $this->get_step_info($this->step);
423
+ if($this->to_export!='')
424
+ {
425
+
426
+ $this->prepare_step_summary();
427
+ $this->prepare_footer_button_list();
428
+
429
+ //taking current page form data
430
+ $filter_form_data=(isset($this->selected_template_form_data['filter_form_data']) ? $this->selected_template_form_data['filter_form_data'] : array());
431
+
432
+ $filter_screen_fields=$this->export_obj->get_filter_screen_fields($filter_form_data);
433
+
434
+ ob_start();
435
+ $this->prepare_step_header_html();
436
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_export_filter_page.php';
437
+ $this->prepare_step_footer_html();
438
+ return ob_get_clean();
439
+
440
+ }else
441
+ {
442
+ return '';
443
+ }
444
+ }
445
+
446
+
447
+ /**
448
+ * Step 4 (Ajax sub function)
449
+ * Built in steps, mapping page
450
+ */
451
+ public function mapping_page()
452
+ {
453
+ $this->step='mapping';
454
+ $step_info= $this->get_step_info($this->step);
455
+ if($this->to_export!='')
456
+ {
457
+
458
+ $this->prepare_step_summary();
459
+ $this->prepare_footer_button_list();
460
+
461
+ //taking current page form data
462
+ $mapping_form_data=(isset($this->selected_template_form_data['mapping_form_data']) ? $this->selected_template_form_data['mapping_form_data'] : array());
463
+
464
+
465
+ /* form_data/template data of fields in mapping page */
466
+ $form_data_mapping_fields=isset($mapping_form_data['mapping_fields']) ? $mapping_form_data['mapping_fields'] : array();
467
+
468
+ /* default mapping page fields */
469
+ $mapping_fields=array();
470
+ $mapping_fields=apply_filters('wt_iew_exporter_alter_mapping_fields_basic', $mapping_fields, $this->to_export, $form_data_mapping_fields);
471
+
472
+
473
+ /* meta fields list */
474
+ $this->get_mapping_enabled_fields();
475
+
476
+ /* mapping enabled meta fields */
477
+ $form_data_mapping_enabled_fields=(isset($mapping_form_data['mapping_enabled_fields']) ? $mapping_form_data['mapping_enabled_fields'] : array());
478
+
479
+ ob_start();
480
+ $this->prepare_step_header_html();
481
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_export_mapping_page.php';
482
+ $this->prepare_step_footer_html();
483
+ return ob_get_clean();
484
+ }else
485
+ {
486
+ return '';
487
+ }
488
+ }
489
+
490
+ /**
491
+ * Step 5 (Ajax sub function)
492
+ * Built in steps, advanced page
493
+ */
494
+ public function advanced_page()
495
+ {
496
+ $this->step='advanced';
497
+ $step_info=$this->steps[$this->step];
498
+ if($this->to_export!='')
499
+ {
500
+
501
+ $this->prepare_step_summary();
502
+ $this->prepare_footer_button_list();
503
+
504
+ //taking current page form data
505
+ $advanced_form_data=(isset($this->selected_template_form_data['advanced_form_data']) ? $this->selected_template_form_data['advanced_form_data'] : array());
506
+
507
+ $advanced_screen_fields=$this->export_obj->get_advanced_screen_fields($advanced_form_data);
508
+
509
+ ob_start();
510
+ $this->prepare_step_header_html();
511
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_export_advanced_page.php';
512
+ $this->prepare_step_footer_html();
513
+ return ob_get_clean();
514
+
515
+ }else
516
+ {
517
+ return '';
518
+ }
519
+ }
520
+
521
+ /**
522
+ * Get template form data
523
+ */
524
+ protected function get_template_form_data($id)
525
+ {
526
+ $template_data=$this->get_mapping_template_by_id($id);
527
+ if($template_data)
528
+ {
529
+ $decoded_form_data=Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize($template_data['data']));
530
+ $this->selected_template_form_data=(!is_array($decoded_form_data) ? array() : $decoded_form_data);
531
+ }
532
+ }
533
+
534
+ /**
535
+ * Taking mapping template by Name
536
+ */
537
+ protected function get_mapping_template_by_name($name)
538
+ {
539
+ global $wpdb;
540
+ $tb=$wpdb->prefix. Wt_Import_Export_For_Woo_Basic::$template_tb;
541
+ $qry=$wpdb->prepare("SELECT * FROM $tb WHERE template_type=%s AND item_type=%s AND name=%s",array('export', $this->to_export, $name));
542
+ return $wpdb->get_row($qry, ARRAY_A);
543
+ }
544
+
545
+ /**
546
+ * Taking mapping template by ID
547
+ */
548
+ protected function get_mapping_template_by_id($id)
549
+ {
550
+ global $wpdb;
551
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
552
+ $qry=$wpdb->prepare("SELECT * FROM $tb WHERE template_type=%s AND item_type=%s AND id=%d",array('export', $this->to_export, $id));
553
+ return $wpdb->get_row($qry, ARRAY_A);
554
+ }
555
+
556
+ /**
557
+ * Taking all mapping templates
558
+ */
559
+ protected function get_mapping_templates()
560
+ {
561
+ if($this->to_export=='')
562
+ {
563
+ return;
564
+ }
565
+ global $wpdb;
566
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
567
+ $val=$wpdb->get_results("SELECT * FROM $tb WHERE template_type='export' AND item_type='".$this->to_export."' ORDER BY id DESC", ARRAY_A);
568
+
569
+ //add a filter here for modules to alter the data
570
+ $this->mapping_templates=($val ? $val : array());
571
+ }
572
+
573
+ /**
574
+ * Get meta field list for mapping page
575
+ *
576
+ */
577
+ protected function get_mapping_enabled_fields()
578
+ {
579
+ $mapping_enabled_fields=array(
580
+ // 'hidden_meta'=>array(__('Hidden meta'),0),
581
+ // 'meta'=>array(__('Meta'),1),
582
+ );
583
+ $this->mapping_enabled_fields=apply_filters('wt_iew_exporter_alter_mapping_enabled_fields_basic', $mapping_enabled_fields, $this->to_export, array());
584
+ }
585
+
586
+ protected function prepare_step_footer_html()
587
+ {
588
+ include dirname(plugin_dir_path(__FILE__)).'/views/_export_footer.php';
589
+ }
590
+
591
+ protected function prepare_step_summary()
592
+ {
593
+ $step_info= $this->get_step_info($this->step);
594
+ $this->step_title=$step_info['title'];
595
+ $this->step_keys=array_keys($this->steps);
596
+ $this->current_step_index=array_search($this->step, $this->step_keys);
597
+ $this->current_step_number=$this->current_step_index+1;
598
+ $this->last_page=(!isset($this->step_keys[$this->current_step_index+1]) ? true : false);
599
+ $this->total_steps=count($this->step_keys);
600
+ $this->step_summary=__(sprintf("Step %d of %d", $this->current_step_number, $this->total_steps));
601
+ }
602
+
603
+ protected function prepare_step_header_html()
604
+ {
605
+ include dirname(plugin_dir_path(__FILE__)).'/views/_export_header.php';
606
+ }
607
+
608
+ protected function prepare_footer_button_list()
609
+ {
610
+ $out=array();
611
+ $step_keys=$this->step_keys;
612
+ $current_index=$this->current_step_index;
613
+ $last_page=$this->last_page;
614
+ if($current_index!==false) /* step exists */
615
+ {
616
+ if($current_index>0) //add back button
617
+ {
618
+ $out['back']=array(
619
+ 'type'=>'button',
620
+ 'action_type'=>'step',
621
+ 'key'=>$step_keys[$current_index-1],
622
+ 'text'=>'<span class="dashicons dashicons-arrow-left-alt2" style="line-height:27px;"></span> '.__('Back'),
623
+ );
624
+ }
625
+
626
+ if(isset($step_keys[$current_index+1])) /* not last step */
627
+ {
628
+ $next_number=$current_index+2;
629
+ $next_key=$step_keys[$current_index+1];
630
+ $next_title=$this->steps[$next_key]['title'];
631
+ $out['next']=array(
632
+ 'type'=>'button',
633
+ 'action_type'=>'step',
634
+ 'key'=>$next_key,
635
+ 'text'=>__('Step').' '.$next_number.': '.$next_title.' <span class="dashicons dashicons-arrow-right-alt2" style="line-height:27px;"></span>',
636
+ );
637
+
638
+ if($this->export_method=='quick' || $this->export_method=='template') //Quick Or Template method
639
+ {
640
+ $out['or']=array(
641
+ 'type'=>'text',
642
+ 'text'=>__('Or'),
643
+ );
644
+ }
645
+
646
+ }else
647
+ {
648
+ $last_page=true;
649
+ }
650
+
651
+ if($this->export_method=='quick' || $this->export_method=='template' || $last_page) //template method, or last page, or quick export
652
+ {
653
+ if($last_page && $this->export_method!='quick') //last page and not quick export
654
+ {
655
+ if($this->export_method=='template')
656
+ {
657
+ $out['save']=array(
658
+ 'key'=>'save',
659
+ 'icon'=>'',
660
+ 'type'=>'dropdown_button',
661
+ 'text'=>__('Save template'),
662
+ 'items'=>array(
663
+ 'update'=>array(
664
+ 'key'=>'update_template',
665
+ 'text'=>__('Save'), //no prompt
666
+ ),
667
+ 'save'=>array(
668
+ 'key'=>'save_template_as',
669
+ 'text'=>__('Save As'), //prompt for name
670
+ )
671
+ )
672
+ );
673
+ }else
674
+ {
675
+ $out['save']=array(
676
+ 'key'=>'save_template',
677
+ 'icon'=>'',
678
+ 'type'=>'button',
679
+ 'text'=>__('Save template'), //prompt for name
680
+ );
681
+ }
682
+ }
683
+
684
+ if($last_page)
685
+ {
686
+ $out['export_image']=array(
687
+ 'key'=>'export_image',
688
+ 'class'=>'iew_export_image_btn',
689
+ 'icon'=>'',
690
+ 'type'=>'button',
691
+ 'text'=>__('Export images'),
692
+ );
693
+ }
694
+
695
+ $out['export']=array(
696
+ 'key'=>'export',
697
+ 'class'=>'iew_export_btn',
698
+ 'icon'=>'',
699
+ 'type'=>'button',
700
+ 'text'=>__('Export'),
701
+ );
702
+ }
703
+ }
704
+ $this->step_btns=apply_filters('wt_iew_exporter_alter_footer_btns_basic', $out, $this->step, $this->steps);
705
+ }
706
+ }
707
+ }
admin/modules/export/export.php ADDED
@@ -0,0 +1,816 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Export section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Export')){
13
+ class Wt_Import_Export_For_Woo_Basic_Export
14
+ {
15
+ public $module_id='';
16
+ public static $module_id_static='';
17
+ public $module_base='export';
18
+
19
+ public static $export_dir=WP_CONTENT_DIR.'/webtoffee_export';
20
+ public static $export_dir_name='/webtoffee_export';
21
+ public $steps=array();
22
+ public $allowed_export_file_type=array();
23
+
24
+ private $to_export='';
25
+ private $to_export_id='';
26
+ private $rerun_id=0;
27
+ public $export_method='';
28
+ public $export_methods=array();
29
+ public $selected_template=0;
30
+ public $default_batch_count=0; /* configure this value in `advanced_setting_fields` method */
31
+ public $selected_template_data=array();
32
+ public $default_export_method=''; /* configure this value in `advanced_setting_fields` method */
33
+ public $form_data=array();
34
+
35
+ public function __construct()
36
+ {
37
+ $this->module_id=Wt_Import_Export_For_Woo_Basic::get_module_id($this->module_base);
38
+ self::$module_id_static=$this->module_id;
39
+
40
+ /* allowed file types */
41
+ $this->allowed_export_file_type=array(
42
+ 'csv'=>__('CSV'),
43
+ 'xml'=>__('XML')
44
+ );
45
+
46
+ /* default step list */
47
+ $this->steps=array
48
+ (
49
+ 'post_type'=>array(
50
+ 'title'=>__('Select a post type'),
51
+ 'description'=>__('Export and download the respective post type into a CSV. This file can also be used to import data related to the specific post type back into your WordPress/WooCommerce site. As a first step you need to choose the post type to start the export.'),
52
+ ),
53
+ 'method_export'=>array(
54
+ 'title'=>__('Select an export method'),
55
+ 'description'=>__('Choose from the options below to continue with your export: quick export from DB, based on a pre-saved template or a new export with advanced options.'),
56
+ ),
57
+ 'filter'=>array(
58
+ 'title'=>__('Filter data'),
59
+ 'description'=>__('Filter data that needs to be exported as per the below criteria.'),
60
+ ),
61
+ 'mapping'=>array(
62
+ 'title'=>__('Map and reorder export columns'),
63
+ 'description'=>__('The default export column names can be edited from the screen below, if required. If you have chosen a pre-saved template you can see the preferred names and choices that were last saved. You may also drag the columns accordingly to reorder them within the output file.'),
64
+ ),
65
+ 'advanced'=>array(
66
+ 'title'=>__('Advanced options/Batch export'),
67
+ 'description'=>__('You can save the template file for future exports or proceed with the export.'),
68
+ ),
69
+ );
70
+
71
+
72
+ $this->validation_rule=array(
73
+ 'post_type'=>array(), /* no validation rule. So default sanitization text */
74
+ 'method_export'=>array(
75
+ 'mapping_enabled_fields' => array('type'=>'text_arr') //in case of quick export
76
+ )
77
+ );
78
+
79
+ $this->step_need_validation_filter=array('filter', 'advanced');
80
+
81
+
82
+ $this->export_methods=array(
83
+ 'quick'=>array('title'=>__('Quick export'), 'description'=> __('Exports all the basic fields.')),
84
+ 'template'=>array('title'=>__('Pre-saved template'), 'description'=> __('Exports data as per the specifications(filters,selective column,mapping etc) from the previously saved file.')),
85
+ 'new'=>array('title'=>__('Advanced export'), 'description'=> __('Exports data after a detailed process of data filtering/column selection/advanced options that may be required for your export. You can also save this selection for future use.')),
86
+ );
87
+
88
+ /* advanced plugin settings */
89
+ add_filter('wt_iew_advanced_setting_fields_basic', array($this, 'advanced_setting_fields'));
90
+
91
+ /* setting default values, this method must be below of advanced setting filter */
92
+ $this->get_defaults();
93
+
94
+ /* main ajax hook. The callback function will decide which is to execute. */
95
+ add_action('wp_ajax_iew_export_ajax_basic', array($this, 'ajax_main'), 11);
96
+
97
+ /* Admin menu for export */
98
+ add_filter('wt_iew_admin_menu_basic', array($this, 'add_admin_pages'), 10, 1);
99
+
100
+ /* Download export file via nonce URL */
101
+ add_action('admin_init', array($this, 'download_file'), 11);
102
+ }
103
+
104
+ public function get_defaults()
105
+ {
106
+ $this->default_export_method= Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('default_export_method');
107
+ $this->default_batch_count=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('default_export_batch');
108
+ }
109
+
110
+ /**
111
+ * Fields for advanced settings
112
+ *
113
+ */
114
+ public function advanced_setting_fields($fields)
115
+ {
116
+ $export_methods=array_map(function($vl){ return $vl['title']; }, $this->export_methods);
117
+ $fields['default_export_method']=array(
118
+ 'label'=>__("Default Export method"),
119
+ 'type'=>'select',
120
+ 'sele_vals'=>$export_methods,
121
+ 'value' =>'quick',
122
+ 'field_name'=>'default_export_method',
123
+ 'field_group'=>'advanced_field',
124
+ 'help_text'=>__('Select the default method of export.'),
125
+ );
126
+ $fields['default_export_batch']=array(
127
+ 'label'=>__("Default Export batch count"),
128
+ 'type'=>'number',
129
+ 'value' =>10,
130
+ 'field_name'=>'default_export_batch',
131
+ 'help_text'=>__('Provide the default count for the records to be exported in a batch.'),
132
+ 'validation_rule'=>array('type'=>'absint'),
133
+ );
134
+ return $fields;
135
+ }
136
+
137
+ /**
138
+ * Adding admin menus
139
+ */
140
+ public function add_admin_pages($menus)
141
+ {
142
+ $menu_temp=array(
143
+ $this->module_base=>array(
144
+ 'menu',
145
+ __('Export'),
146
+ __('WebToffee Import Export (Basic)'),
147
+ apply_filters('wt_import_export_allowed_capability', 'import'),
148
+ $this->module_id,
149
+ array($this,'admin_settings_page'),
150
+ 'dashicons-controls-repeat',
151
+ 56
152
+ ),
153
+ $this->module_base.'-sub'=>array(
154
+ 'submenu',
155
+ $this->module_id,
156
+ __('Export'),
157
+ __('Export'),
158
+ apply_filters('wt_import_export_allowed_capability', 'import'),
159
+ $this->module_id,
160
+ array($this, 'admin_settings_page')
161
+ ),
162
+ );
163
+ unset($menus['general-settings']);
164
+ $menus=array_merge($menu_temp, $menus);
165
+ return $menus;
166
+ }
167
+
168
+ /**
169
+ * Export page
170
+ */
171
+ public function admin_settings_page()
172
+ {
173
+ /**
174
+ * Check it is a rerun call
175
+ */
176
+ $requested_rerun_id=(isset($_GET['wt_iew_rerun']) ? absint($_GET['wt_iew_rerun']) : 0);
177
+ $this->_process_rerun($requested_rerun_id);
178
+
179
+ $this->enqueue_assets();
180
+ include plugin_dir_path(__FILE__).'views/main.php';
181
+ }
182
+
183
+ /**
184
+ * Main ajax hook to handle all export related requests
185
+ */
186
+ public function ajax_main()
187
+ {
188
+
189
+ include_once plugin_dir_path(__FILE__).'classes/class-export-ajax.php';
190
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
191
+ {
192
+ /**
193
+ * Check it is a rerun call
194
+ */
195
+ if(!$this->_process_rerun((isset($_POST['rerun_id']) ? absint($_POST['rerun_id']) : 0)))
196
+ {
197
+ $this->export_method=(isset($_POST['export_method']) ? Wt_Iew_Sh::sanitize_item($_POST['export_method'], 'text') : '');
198
+ $this->to_export=(isset($_POST['to_export']) ? Wt_Iew_Sh::sanitize_item($_POST['to_export'], 'text') : '');
199
+ $this->selected_template=(isset($_POST['selected_template']) ? Wt_Iew_Sh::sanitize_item($_POST['selected_template'], 'int') : 0);
200
+ }
201
+
202
+ $this->get_steps();
203
+
204
+ $ajax_obj=new Wt_Import_Export_For_Woo_Basic_Export_Ajax($this, $this->to_export, $this->steps, $this->export_method, $this->selected_template, $this->rerun_id);
205
+
206
+ $export_action=Wt_Iew_Sh::sanitize_item($_POST['export_action'], 'text');
207
+ $data_type=Wt_Iew_Sh::sanitize_item($_POST['data_type'], 'text');
208
+
209
+ $allowed_ajax_actions=array('get_steps', 'get_meta_mapping_fields', 'save_template', 'save_template_as', 'update_template', 'upload', 'export', 'export_image');
210
+
211
+ $out=array(
212
+ 'status'=>0,
213
+ 'msg'=>__('Error'),
214
+ );
215
+
216
+ if(method_exists($ajax_obj, $export_action) && in_array($export_action, $allowed_ajax_actions))
217
+ {
218
+ $out=$ajax_obj->{$export_action}($out);
219
+ }
220
+
221
+ if($data_type=='json')
222
+ {
223
+ echo json_encode($out);
224
+ }
225
+ }
226
+ exit();
227
+ }
228
+
229
+ public function get_filter_screen_fields($filter_form_data) {
230
+ $filter_screen_fields = array(
231
+ 'limit' => array(
232
+ 'label' => __("Limit"),
233
+ 'value' => '',
234
+ 'type' => 'number',
235
+ 'field_name' => 'limit',
236
+ 'placeholder' => 'Unlimited',
237
+ 'help_text' => __('The actual number of records you want to export. e.g. A limit of 500 with an offset 10 will export records from 11th to 510th position.'),
238
+ 'attr' => array('step' => 1, 'min' => 0),
239
+ 'validation_rule' => array('type' => 'absint')
240
+ ),
241
+ 'offset' => array(
242
+ 'label' => __("Offset"),
243
+ 'value' => '',
244
+ 'field_name' => 'offset',
245
+ 'placeholder' => __('0'),
246
+ 'help_text' => __('Specify the number of records that should be skipped from the beginning. e.g. An offset of 10 skips the first 10 records.'),
247
+ 'type' => 'number',
248
+ 'attr' => array('step' => 1, 'min' => 0),
249
+ 'validation_rule' => array('type' => 'absint')
250
+ ),
251
+ );
252
+ $filter_screen_fields = apply_filters('wt_iew_exporter_alter_filter_fields_basic', $filter_screen_fields, $this->to_export, $filter_form_data);
253
+ return $filter_screen_fields;
254
+ }
255
+
256
+ public function get_advanced_screen_fields($advanced_form_data)
257
+ {
258
+ $file_into_arr=array('local'=>__('Local'));
259
+
260
+ /* taking available remote adapters */
261
+ $remote_adapter_names=array();
262
+ $remote_adapter_names=apply_filters('wt_iew_exporter_remote_adapter_names_basic', $remote_adapter_names);
263
+ if($remote_adapter_names && is_array($remote_adapter_names))
264
+ {
265
+ foreach($remote_adapter_names as $remote_adapter_key => $remote_adapter_vl)
266
+ {
267
+ $file_into_arr[$remote_adapter_key]=$remote_adapter_vl;
268
+ }
269
+ }
270
+
271
+
272
+ $advanced_screen_fields=array(
273
+
274
+ 'batch_count'=>array(
275
+ 'label'=>__("Export in batches of"),
276
+ 'type'=>'text',
277
+ 'value'=>$this->default_batch_count,
278
+ 'field_name'=>'batch_count',
279
+ 'help_text'=>sprintf(__('The number of records that the server will process for every iteration within the configured timeout interval. If the export fails due to timeout you can lower this number accordingly and try again. Defaulted to %d records.'), 10),
280
+ 'validation_rule'=>array('type'=>'absint'),
281
+ )
282
+ );
283
+
284
+ /* taking advanced fields from post type modules */
285
+ $advanced_screen_fields=apply_filters('wt_iew_exporter_alter_advanced_fields_basic', $advanced_screen_fields, $this->to_export, $advanced_form_data);
286
+ return $advanced_screen_fields;
287
+ }
288
+
289
+ /**
290
+ * Get steps
291
+ *
292
+ */
293
+ public function get_steps()
294
+ {
295
+ if($this->export_method=='quick') /* if quick export then remove some steps */
296
+ {
297
+ $out=array(
298
+ 'post_type'=>$this->steps['post_type'],
299
+ 'method_export'=>$this->steps['method_export'],
300
+ 'advanced'=>$this->steps['advanced'],
301
+ );
302
+ $this->steps=$out;
303
+ }
304
+ $this->steps=apply_filters('wt_iew_exporter_steps_basic', $this->steps, $this->to_export);
305
+ return $this->steps;
306
+ }
307
+
308
+
309
+ /**
310
+ * Validating and Processing rerun action
311
+ */
312
+ protected function _process_rerun($rerun_id)
313
+ {
314
+ if($rerun_id>0)
315
+ {
316
+ /* check the history module is available */
317
+ $history_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules('history');
318
+ if(!is_null($history_module_obj))
319
+ {
320
+ /* check the history entry is for export and also has form_data */
321
+ $history_data=$history_module_obj->get_history_entry_by_id($rerun_id);
322
+ if($history_data && $history_data['template_type']==$this->module_base)
323
+ {
324
+ $form_data=maybe_unserialize($history_data['data']);
325
+ if($form_data && is_array($form_data))
326
+ {
327
+ $this->to_export=(isset($form_data['post_type_form_data']) && isset($form_data['post_type_form_data']['item_type']) ? $form_data['post_type_form_data']['item_type'] : '');
328
+ if($this->to_export!="")
329
+ {
330
+ $this->export_method=(isset($form_data['method_export_form_data']) && isset($form_data['method_export_form_data']['method_export']) && $form_data['method_export_form_data']['method_export']!="" ? $form_data['method_export_form_data']['method_export'] : $this->default_export_method);
331
+ $this->rerun_id=$rerun_id;
332
+ $this->form_data=$form_data;
333
+ //process steps based on the export method in the history entry
334
+ $this->get_steps();
335
+
336
+ return true;
337
+ }
338
+ }
339
+ }
340
+ }
341
+ }
342
+ return false;
343
+ }
344
+
345
+ protected function enqueue_assets()
346
+ {
347
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_is_screen_allowed()){
348
+ wp_enqueue_script($this->module_id, plugin_dir_url(__FILE__).'assets/js/main.js', array('jquery', 'jquery-ui-sortable', 'jquery-ui-datepicker'), WT_P_IEW_VERSION);
349
+ wp_enqueue_style('jquery-ui-datepicker');
350
+ wp_enqueue_style(WT_IEW_PLUGIN_ID_BASIC.'-jquery-ui', WT_P_IEW_PLUGIN_URL.'admin/css/jquery-ui.css', array(), WT_P_IEW_VERSION, 'all');
351
+ $params=array(
352
+ 'item_type'=>'',
353
+ 'steps'=>$this->steps,
354
+ 'rerun_id'=>$this->rerun_id,
355
+ 'to_export'=>$this->to_export,
356
+ 'export_method'=>$this->export_method,
357
+ 'msgs'=>array(
358
+ 'choosed_template'=>__('Choosed template: '),
359
+ 'choose_export_method'=>__('Please select an export method.'),
360
+ 'choose_template'=>__('Please select an export template.'),
361
+ 'step'=>__('Step'),
362
+ 'choose_ftp_profile'=>__('Please select an FTP profile.'),
363
+ ),
364
+ );
365
+ wp_localize_script($this->module_id, 'wt_iew_export_basic_params', $params);
366
+
367
+ $this->add_select2_lib(); //adding select2 JS, It checks the availibility of woocommerce
368
+ }
369
+ }
370
+
371
+ /**
372
+ *
373
+ * Enqueue select2 library, if woocommerce available use that
374
+ */
375
+ protected function add_select2_lib()
376
+ {
377
+ /* enqueue scripts */
378
+ if(!function_exists('is_plugin_active'))
379
+ {
380
+ include_once(ABSPATH.'wp-admin/includes/plugin.php');
381
+ }
382
+ if(is_plugin_active('woocommerce/woocommerce.php'))
383
+ {
384
+ wp_enqueue_script('wc-enhanced-select');
385
+ wp_enqueue_style('woocommerce_admin_styles', WC()->plugin_url().'/assets/css/admin.css');
386
+ }else
387
+ {
388
+ wp_enqueue_style(WT_IEW_PLUGIN_ID_BASIC.'-select2', WT_P_IEW_PLUGIN_URL. 'admin/css/select2.css', array(), WT_P_IEW_VERSION, 'all' );
389
+ wp_enqueue_script(WT_IEW_PLUGIN_ID_BASIC.'-select2', WT_P_IEW_PLUGIN_URL.'admin/js/select2.js', array('jquery'), WT_P_IEW_VERSION, false );
390
+ }
391
+ }
392
+
393
+
394
+ /**
395
+ * Upload data to the user choosed remote method (Eg: FTP)
396
+ * @param string $step the action to perform, here 'upload'
397
+ *
398
+ * @return array
399
+ */
400
+ public function process_upload($step, $export_id, $to_export)
401
+ {
402
+ $out=array(
403
+ 'response'=>false,
404
+ 'export_id'=>0,
405
+ 'history_id'=>0, //same as that of export id
406
+ 'finished'=>0,
407
+ 'file_url'=>'',
408
+ 'msg'=>'',
409
+ );
410
+
411
+ if($export_id==0) //it may be an error
412
+ {
413
+ return $out;
414
+ }
415
+
416
+ //take history data by export_id
417
+ $export_data=Wt_Import_Export_For_Woo_Basic_History::get_history_entry_by_id($export_id);
418
+ if(is_null($export_data)) //no record found so it may be an error
419
+ {
420
+ return $out;
421
+ }
422
+
423
+ $form_data=maybe_unserialize($export_data['data']);
424
+
425
+ //taking file name
426
+ $file_name=(isset($export_data['file_name']) ? $export_data['file_name'] : '');
427
+
428
+ $file_path=$this->get_file_path($file_name);
429
+ if($file_path===false)
430
+ {
431
+ $update_data=array(
432
+ 'status'=>Wt_Import_Export_For_Woo_Basic_History::$status_arr['failed'],
433
+ 'status_text'=>'File not found.' //no need to add translation function
434
+ );
435
+ $update_data_type=array(
436
+ '%d',
437
+ '%s',
438
+ );
439
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($export_id, $update_data, $update_data_type);
440
+
441
+ return $out;
442
+ }
443
+
444
+ /* updating output parameters */
445
+ $out['export_id']=$export_id;
446
+ $out['history_id']=$export_id;
447
+ $out['file_url']='';
448
+
449
+ //check where to copy the files
450
+ $file_into='local';
451
+ if(isset($form_data['advanced_form_data']))
452
+ {
453
+ $file_into=(isset($form_data['advanced_form_data']['wt_iew_file_into']) ? $form_data['advanced_form_data']['wt_iew_file_into'] : 'local');
454
+ }
455
+
456
+ if('local' != $file_into) /* file not save to local. Initiate the choosed remote profile */
457
+ {
458
+ $remote_adapter=Wt_Import_Export_For_Woo_Basic::get_remote_adapters('export', $file_into);
459
+ if(is_null($remote_adapter)) /* adapter object not found */
460
+ {
461
+ $msg=sprintf('Unable to initailize %s', $file_into);
462
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($export_id, $msg);
463
+ $out['msg']=__($msg);
464
+ return $out;
465
+ }
466
+
467
+ /* upload the file */
468
+ $upload_out_format = array('response'=>true, 'msg'=>'');
469
+
470
+ $advanced_form_data=(isset($form_data['advanced_form_data']) ? $form_data['advanced_form_data'] : array());
471
+
472
+ $upload_data = $remote_adapter->upload($file_path, $file_name, $advanced_form_data, $upload_out_format);
473
+ $out['response'] = (isset($upload_data['response']) ? $upload_data['response'] : false);
474
+ $out['msg'] = (isset($upload_data['msg']) ? $upload_data['msg'] : __('Error'));
475
+
476
+ //unlink the local file
477
+ @unlink($file_path);
478
+ }else
479
+ {
480
+ $out['response']=true;
481
+ $out['file_url']=html_entity_decode($this->get_file_url($file_name));
482
+ }
483
+
484
+ $out['finished']=1; //if any error then also its finished, but with errors
485
+ if($out['response'] === true) //success
486
+ {
487
+ $out['msg']=__('Finished');
488
+
489
+ /* updating finished status */
490
+ $update_data=array(
491
+ 'status'=>1 //success
492
+ );
493
+ $update_data_type=array(
494
+ '%d'
495
+ );
496
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($export_id, $update_data, $update_data_type);
497
+
498
+ }else //failed
499
+ {
500
+ //no need to add translation function in message
501
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($export_id, 'Failed while uploading');
502
+ }
503
+ return $out;
504
+ }
505
+
506
+
507
+ /**
508
+ * Do the export process
509
+ */
510
+ public function process_action($form_data, $step, $to_process, $file_name='', $export_id=0, $offset=0)
511
+ {
512
+ $out=array(
513
+ 'response'=>false,
514
+ 'new_offset'=>0,
515
+ 'export_id'=>0,
516
+ 'history_id'=>0, //same as that of export id
517
+ 'total_records'=>0,
518
+ 'finished'=>0,
519
+ 'file_url'=>'',
520
+ 'msg'=>'',
521
+ );
522
+
523
+ /* prepare form_data, If this was not first batch */
524
+ if($export_id>0)
525
+ {
526
+ //take history data by export_id
527
+ $export_data=Wt_Import_Export_For_Woo_Basic_History::get_history_entry_by_id($export_id);
528
+ if(is_null($export_data)) //no record found so it may be an error
529
+ {
530
+ return $out;
531
+ }
532
+
533
+ //processing form data
534
+ $form_data=(isset($export_data['data']) ? maybe_unserialize($export_data['data']) : array());
535
+ }
536
+ $this->to_export=$to_process;
537
+ $default_batch_count=$this->_get_default_batch_count($form_data);
538
+ $batch_count=$default_batch_count;
539
+ $file_as='csv';
540
+ $csv_delimiter=',';
541
+ $total_records=0;
542
+ if(isset($form_data['advanced_form_data']))
543
+ {
544
+ $batch_count=(isset($form_data['advanced_form_data']['wt_iew_batch_count']) ? $form_data['advanced_form_data']['wt_iew_batch_count'] : $batch_count);
545
+ $file_as=(isset($form_data['advanced_form_data']['wt_iew_file_as']) ? $form_data['advanced_form_data']['wt_iew_file_as'] : 'csv');
546
+ $csv_delimiter=(isset($form_data['advanced_form_data']['wt_iew_delimiter']) ? $form_data['advanced_form_data']['wt_iew_delimiter'] : ',');
547
+ $csv_delimiter=($csv_delimiter=="" ? ',' : $csv_delimiter);
548
+ }
549
+ $file_as=(isset($this->allowed_export_file_type[$file_as]) ? $file_as : 'csv');
550
+
551
+
552
+ $generated_file_name=$this->to_export.'_export_'.date('Y-m-d-h-i-s').'.'.$file_as;
553
+
554
+ if($export_id==0) //first batch then create a history entry
555
+ {
556
+ $file_name=($file_name=="" ? $generated_file_name : sanitize_file_name($file_name.'.'.$file_as));
557
+ $export_id=Wt_Import_Export_For_Woo_Basic_History::create_history_entry($file_name, $form_data, $this->to_export, $step);
558
+ $offset=0;
559
+ }else
560
+ {
561
+ //taking file name from export data
562
+ $file_name=(isset($export_data['file_name']) ? $export_data['file_name'] : $generated_file_name);
563
+ $total_records=(isset($export_data['total']) ? $export_data['total'] : 0);
564
+ }
565
+
566
+ /* setting history_id in Log section */
567
+ Wt_Import_Export_For_Woo_Basic_Log::$history_id=$export_id;
568
+
569
+
570
+ $file_path=$this->get_file_path($file_name);
571
+ if($file_path===false)
572
+ {
573
+ $msg='Unable to create backup directory. Please grant write permission for `wp-content` folder.';
574
+
575
+ //no need to add translation function in message
576
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($export_id, $msg);
577
+
578
+ $out['msg']=__($msg);
579
+ return $out;
580
+ }
581
+
582
+ /* giving full data */
583
+ $form_data=apply_filters('wt_iew_export_full_form_data_basic', $form_data, $to_process, $step, $this->selected_template_data);
584
+
585
+ /* hook to get data from corresponding module. Eg: product, order */
586
+ $export_data=array(
587
+ 'total'=>100,
588
+ 'head_data'=>array("abc"=>"hd1", "bcd"=>"hd2", "cde"=>"hd3", "def"=>"hd4"),
589
+ 'body_data'=>array(
590
+ array("abc"=>"Abc1", "bcd"=>"Bcd1", "cde"=>"Cde1", "def"=>"Def1"),
591
+ array("abc"=>"Abc2", "bcd"=>"Bcd2", "cde"=>"Cde2", "def"=>"Def2")
592
+ ),
593
+ );
594
+
595
+ /* in scheduled export. The export method will not available so we need to take it from form_data */
596
+ $form_data_export_method=(isset($form_data['method_export_form_data']) && isset($form_data['method_export_form_data']['method_export']) ? $form_data['method_export_form_data']['method_export'] : $this->default_export_method);
597
+ $this->export_method=($this->export_method=="" ? $form_data_export_method : $this->export_method);
598
+
599
+ $export_data=apply_filters('wt_iew_exporter_do_export_basic', $export_data, $to_process, $step, $form_data, $this->selected_template_data, $this->export_method, $offset);
600
+ if($offset==0)
601
+ {
602
+ $total_records=intval(isset($export_data['total']) ? $export_data['total'] : 0);
603
+ }
604
+ $this->_update_history_after_export($export_id, $offset, $total_records, $export_data);
605
+
606
+ /* checking action is finshed */
607
+ $is_last_offset=false;
608
+ $new_offset=$offset+$batch_count; //increase the offset
609
+ if($new_offset>=$total_records) //finished
610
+ {
611
+ $is_last_offset=true;
612
+ }
613
+
614
+
615
+ /* no data from corresponding module */
616
+ if(!$export_data) //error !!!
617
+ {
618
+ //return $out;
619
+ }else
620
+ {
621
+
622
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-csvwriter.php';
623
+ $writer=new Wt_Import_Export_For_Woo_Basic_Csvwriter($file_path, $offset, $csv_delimiter);
624
+
625
+
626
+ /**
627
+ * Alter export data before writing to file.
628
+ * @param array $export_data data to export
629
+ * @param int $offset current offset
630
+ * @param boolean $is_last_offset is current offset is last one
631
+ * @param string $file_as file type to write Eg: XML, CSV
632
+ * @param string $to_export Post type
633
+ * @param string $csv_delimiter CSV delimiter. In case of CSV export
634
+ * @return array $export_data Altered export data
635
+ */
636
+ $export_data=apply_filters('wt_iew_alter_export_data_basic', $export_data, $offset, $is_last_offset, $file_as, $this->to_export, $csv_delimiter);
637
+
638
+ $writer->write_to_file($export_data, $offset, $is_last_offset, $this->to_export);
639
+ }
640
+
641
+ /* updating output parameters */
642
+ $out['total_records']=$total_records;
643
+ $out['export_id']=$export_id;
644
+ $out['history_id']=$export_id;
645
+ $out['file_url']='';
646
+ $out['response']=true;
647
+
648
+ /* updating action is finshed */
649
+ if($is_last_offset) //finished
650
+ {
651
+ //check where to copy the files
652
+ $file_into='local';
653
+ if(isset($form_data['advanced_form_data']))
654
+ {
655
+ $file_into=(isset($form_data['advanced_form_data']['wt_iew_file_into']) ? $form_data['advanced_form_data']['wt_iew_file_into'] : 'local');
656
+ }
657
+ if('local' != $file_into) /* file not save to local. Initiate the choosed remote profile */
658
+ {
659
+ $out['finished']=2; //file created, next upload it
660
+
661
+ $out['msg']=sprintf(__('Uploading to %s'), $file_into);
662
+ }else
663
+ {
664
+ $out['file_url']=html_entity_decode($this->get_file_url($file_name));
665
+ $out['finished']=1; //finished
666
+
667
+ $msg = __('Export file processing completed');
668
+ $msg.='<span class="wt_iew_popup_close" style="line-height:10px;width:auto" onclick="wt_iew_basic_export.hide_export_info_box();">X</span>';
669
+
670
+ $msg.='<span class="wt_iew_info_box_finished_text" style="font-size: 10px; display:block">';
671
+ if(Wt_Import_Export_For_Woo_Admin_Basic::module_exists('history'))
672
+ {
673
+ $history_module_id= Wt_Import_Export_For_Woo_Basic::get_module_id('history');
674
+ $history_page_url=admin_url('admin.php?page='.$history_module_id);
675
+ $msg.=__('You can manage exports from History section.');
676
+ }
677
+
678
+ $msg.='<a class="button button-secondary" style="margin-top:10px;" onclick="wt_iew_basic_export.hide_export_info_box();" target="_blank" href="'.$out['file_url'].'" >'.__('Download file').'</a></span>';
679
+
680
+ $out['msg']=$msg;
681
+
682
+ /* updating finished status */
683
+ $update_data=array(
684
+ 'status'=>Wt_Import_Export_For_Woo_Basic_History::$status_arr['finished'],
685
+ 'status_text'=>'Finished' //translation function not needed
686
+ );
687
+ $update_data_type=array(
688
+ '%d',
689
+ '%s',
690
+ );
691
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($export_id,$update_data,$update_data_type);
692
+ }
693
+
694
+ }else
695
+ {
696
+ $out['new_offset']=$new_offset;
697
+ $out['msg']=sprintf(__('Exporting...(%d out of %d)'), $new_offset, $total_records);
698
+ }
699
+ return $out;
700
+ }
701
+
702
+
703
+ public static function get_file_path($file_name)
704
+ {
705
+ if(!is_dir(self::$export_dir))
706
+ {
707
+ if(!mkdir(self::$export_dir, 0700))
708
+ {
709
+ return false;
710
+ }else
711
+ {
712
+ $files_to_create=array('.htaccess' => 'deny from all', 'index.php'=>'<?php // Silence is golden');
713
+ foreach($files_to_create as $file=>$file_content)
714
+ {
715
+ if(!file_exists(self::$export_dir.'/'.$file))
716
+ {
717
+ $fh=@fopen(self::$export_dir.'/'.$file, "w");
718
+ if(is_resource($fh))
719
+ {
720
+ fwrite($fh, $file_content);
721
+ fclose($fh);
722
+ }
723
+ }
724
+ }
725
+ }
726
+ }
727
+ return self::$export_dir.'/'.$file_name;
728
+ }
729
+
730
+ /**
731
+ * Download file via a nonce URL
732
+ */
733
+ public function download_file()
734
+ {
735
+ if(isset($_GET['wt_iew_export_download']))
736
+ {
737
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC)) /* check nonce and role */
738
+ {
739
+ $file_name=(isset($_GET['file']) ? sanitize_file_name($_GET['file']) : '');
740
+ if($file_name!="")
741
+ {
742
+ $file_arr=explode(".", $file_name);
743
+ $file_ext=end($file_arr);
744
+ if(isset($this->allowed_export_file_type[$file_ext]) || $file_ext=='zip') /* Only allowed files. Zip file in image export */
745
+ {
746
+ $file_path=self::$export_dir.'/'.$file_name;
747
+ if(file_exists($file_path) && is_file($file_path)) /* check existence of file */
748
+ {
749
+ header('Pragma: public');
750
+ header('Expires: 0');
751
+ header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
752
+ header('Cache-Control: private', false);
753
+ header('Content-Transfer-Encoding: binary');
754
+ header('Content-Disposition: attachment; filename="'.$file_name.'";');
755
+ header('Content-Description: File Transfer');
756
+ header('Content-Type: application/octet-stream');
757
+ //header('Content-Length: '.filesize($file_path));
758
+
759
+ $chunk_size=1024 * 1024;
760
+ $handle=@fopen($file_path, 'rb');
761
+ while(!feof($handle))
762
+ {
763
+ $buffer = fread($handle, $chunk_size);
764
+ echo $buffer;
765
+ ob_flush();
766
+ flush();
767
+ }
768
+ fclose($handle);
769
+ exit();
770
+
771
+ }
772
+ }
773
+ }
774
+ }
775
+ }
776
+ }
777
+
778
+ private function _update_history_after_export($export_id, $offset, $total_records, $export_data)
779
+ {
780
+ /* we need to update total record count on first batch */
781
+ if($offset==0)
782
+ {
783
+ $update_data=array(
784
+ 'total'=>$total_records
785
+ );
786
+ }else
787
+ {
788
+ /* updating completed offset */
789
+ $update_data=array(
790
+ 'offset'=>$offset
791
+ );
792
+ }
793
+ $update_data_type=array(
794
+ '%d'
795
+ );
796
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($export_id, $update_data, $update_data_type);
797
+ }
798
+
799
+ private function _get_default_batch_count($form_data)
800
+ {
801
+ $default_batch_count=absint(apply_filters('wt_iew_exporter_alter_default_batch_count_basic', $this->default_batch_count, $this->to_export, $form_data));
802
+ $form_data=null;
803
+ unset($form_data);
804
+ return ($default_batch_count==0 ? $this->default_batch_count : $default_batch_count);
805
+ }
806
+
807
+ /**
808
+ * Generating downloadable URL for a file
809
+ */
810
+ private function get_file_url($file_name)
811
+ {
812
+ return wp_nonce_url(admin_url('admin.php?wt_iew_export_download=true&file='.$file_name), WT_IEW_PLUGIN_ID_BASIC);
813
+ }
814
+ }
815
+ }
816
+ Wt_Import_Export_For_Woo_Basic::$loaded_modules['export']=new Wt_Import_Export_For_Woo_Basic_Export();
admin/modules/export/views/_export_advanced_page.php ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_export_main">
7
+ <p><?php echo $step_info['description']; ?></p>
8
+ <form class="wt_iew_export_advanced_form">
9
+ <table class="form-table wt-iew-form-table wt-iew-export-filter-table">
10
+ <?php
11
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::field_generator($advanced_screen_fields, $advanced_form_data);
12
+ ?>
13
+ </table>
14
+ </form>
15
+ </div>
16
+ <?php
17
+
18
+ $file_int_field_tr_arr=array();
19
+ $file_int_field_tr_arr=apply_filters('wt_iew_exporter_file_into_fields_row_id_basic', $file_int_field_tr_arr);
20
+ ?>
21
+ <script type="text/javascript">
22
+ var file_int_field_tr_arr=<?php echo json_encode($file_int_field_tr_arr); ?>;
23
+ /* remote file modules can hook */
24
+ function wt_iew_set_file_into_fields(file_into)
25
+ {
26
+ /* first hide all */
27
+ if(file_int_field_tr_arr.length>0)
28
+ {
29
+ jQuery(file_int_field_tr_arr.join(', ')).hide();
30
+ }
31
+ // wt_iew_toggle_schedule_btn(0); //hide scheduler btn if exists
32
+ <?php
33
+ do_action('wt_iew_exporter_file_into_js_fn');
34
+ ?>
35
+ }
36
+ <?php /*
37
+ function wt_iew_toggle_schedule_btn(state) /* show/hide cron button
38
+ {
39
+ <?php
40
+ do_action('wt_iew_toggle_schedule_btn');
41
+ ?>
42
+ } */ ?>
43
+
44
+ /* custom action: other than export, save, update. Eg: schedule */
45
+ function wt_iew_custom_action_basic(ajx_dta, action, id)
46
+ {
47
+ ajx_dta['item_type']=ajx_dta['to_export'];
48
+ <?php
49
+ do_action('wt_iew_custom_action_basic');
50
+ ?>
51
+ }
52
+ </script>
admin/modules/export/views/_export_filter_page.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_export_main">
7
+ <p><?php echo $step_info['description']; ?></p>
8
+ <form class="wt_iew_export_filter_form">
9
+ <table class="form-table wt-iew-form-table wt-iew-export-filter-table">
10
+ <?php
11
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::field_generator($filter_screen_fields, $filter_form_data);
12
+ ?>
13
+ </table>
14
+ </form>
15
+ </div>
admin/modules/export/views/_export_footer.php ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-plugin-toolbar bottom">
7
+ <div style="float:left; padding-top:10px;" class="wt_iew_export_template_name"> </div>
8
+ <div style="float:right;">
9
+ <div style="float:right;">
10
+ <?php
11
+ $button_types = array_column(array_values($this->step_btns), 'type');
12
+ $last_button_key = array_search('button', array_reverse($button_types, true));
13
+ $count = 0;
14
+ $button_standard_class = 'media-button';
15
+ foreach($this->step_btns as $btnk=>$btnv)
16
+ {
17
+ $css_class=(isset($btnv['class']) ? $btnv['class'] : '');
18
+ $action_type=(isset($btnv['action_type']) ? $btnv['action_type'] : 'non-step');
19
+ if($count == $last_button_key){
20
+ $button_standard_class = 'button-primary';
21
+ }
22
+ if($btnv['type']=='button')
23
+ {
24
+ ?>
25
+ <button class="button <?php echo $button_standard_class; ?> wt_iew_export_action_btn <?php echo $css_class; ?>" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnv['key'];?>" type="submit">
26
+ <?php echo $btnv['text'];?>
27
+ </button>
28
+ <?php
29
+
30
+ }
31
+ elseif($btnv['type']=='dropdown_button')
32
+ {
33
+ $btn_arr=(isset($btnv['items']) && is_array($btnv['items']) ? $btnv['items'] : array());
34
+ ?>
35
+ <button type="button" class="button button-primary wt_iew_drp_menu <?php echo $css_class; ?>" data-target="wt_iew_<?php echo $btnk; ?>_drp">
36
+ <?php echo $btnv['text'];?> <span class="dashicons dashicons-arrow-down" style="line-height: 28px;"></span>
37
+ </button>
38
+ <ul class="wt_iew_dropdown <?php echo $css_class; ?>" data-id="wt_iew_<?php echo $btnk; ?>_drp">
39
+ <?php
40
+ foreach($btn_arr as $btnkk => $btnvv)
41
+ {
42
+ $field_attr=(isset($btnvv['field_attr']) ? $btnvv['field_attr'] : '');
43
+ $action_type=(isset($btnvv['action_type']) ? $btnvv['action_type'] : 'non-step');
44
+ ?>
45
+ <li class="wt_iew_export_action_btn" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnvv['key'];?>" <?php echo $field_attr;?> ><?php echo $btnvv['text'];?></li>
46
+ <?php
47
+ }
48
+ ?>
49
+ </ul>
50
+ <?php
51
+ }
52
+ elseif($btnv['type']=='hidden_button')
53
+ {
54
+ ?>
55
+ <button style="display:none;" class="button button-primary wt_iew_export_action_btn <?php echo $css_class; ?>" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnv['key'];?>" type="submit">
56
+ <?php echo $btnv['text'];?>
57
+ </button>
58
+ <?php
59
+
60
+ }
61
+ elseif($btnv['type']=='text')
62
+ {
63
+ ?>
64
+ <span style="line-height:40px; font-weight:bold;" class="<?php echo $css_class; ?>"><?php echo $btnv['text'];?></span>
65
+ <?php
66
+ }
67
+ $count++;
68
+ }
69
+ ?>
70
+ </div>
71
+ </div>
72
+ <span class="spinner" style="margin-top:11px;"></span>
73
+ </div>
admin/modules/export/views/_export_header.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-settings-header">
7
+ <h3>
8
+ <?php _e('Export'); ?><?php if($this->step!='post_type'){ ?> <span class="wt_iew_step_head_post_type_name"></span><?php } ?>: <?php echo $this->step_title; ?>
9
+ </h3>
10
+ <span class="wt_iew_step_info" title="<?php echo $this->step_summary; ?>">
11
+ <?php
12
+ echo $this->step_summary;
13
+ ?>
14
+ </span>
15
+ </div>
admin/modules/export/views/_export_mapping_page.php ADDED
@@ -0,0 +1,97 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_export_main">
7
+ <p><?php echo $step_info['description']; ?></p>
8
+ <div class="meta_mapping_box">
9
+ <div class="meta_mapping_box_hd wt_iew_noselect">
10
+ <span class="dashicons dashicons-arrow-down"></span>
11
+ <?php _e('Default fields');?>
12
+ <span class="meta_mapping_box_selected_count_box"><span class="meta_mapping_box_selected_count_box_num">0</span> <?php _e(' columns(s) selected'); ?></span>
13
+ </div>
14
+ <div style="clear:both;"></div>
15
+ <div class="meta_mapping_box_con" data-sortable="0" data-loaded="1" data-field-validated="0" data-key="" style="display:inline-block;">
16
+ <table class="wt-iew-mapping-tb wt-iew-exporter-default-mapping-tb">
17
+ <thead>
18
+ <tr>
19
+ <th>
20
+ <input type="checkbox" name="" class="wt_iew_mapping_checkbox_main">
21
+ </th>
22
+ <th width="35%"><?php _e('Column');?></th>
23
+ <th><?php _e('Column name');?></th>
24
+ </tr>
25
+ </thead>
26
+ <tbody>
27
+ <?php
28
+ $draggable_tooltip=__("Drag to rearrange the columns");
29
+ $tr_count=0;
30
+ foreach($form_data_mapping_fields as $key=>$val)
31
+ {
32
+ if(isset($mapping_fields[$key]))
33
+ {
34
+ $label=$mapping_fields[$key];
35
+ include "_export_mapping_tr_html.php";
36
+ unset($mapping_fields[$key]); //remove the field from default list
37
+ $tr_count++;
38
+ }
39
+ }
40
+ if(count($mapping_fields)>0)
41
+ {
42
+ foreach($mapping_fields as $key=>$label)
43
+ {
44
+ $val=array($key, 1); //enable the field
45
+ include "_export_mapping_tr_html.php";
46
+ $tr_count++;
47
+ }
48
+ }
49
+ if($tr_count==0)
50
+ {
51
+ ?>
52
+ <tr>
53
+ <td colspan="3" style="text-align:center;">
54
+ <?php _e('No fields found.'); ?>
55
+ </td>
56
+ </tr>
57
+ <?php
58
+ }
59
+ ?>
60
+ </tbody>
61
+ </table>
62
+ </div>
63
+ </div>
64
+ <div style="clear:both;"></div>
65
+ <?php
66
+ if($this->mapping_enabled_fields)
67
+ {
68
+ foreach($this->mapping_enabled_fields as $mapping_enabled_field_key=>$mapping_enabled_field)
69
+ {
70
+ $mapping_enabled_field=(!is_array($mapping_enabled_field) ? array($mapping_enabled_field, 0) : $mapping_enabled_field);
71
+
72
+ if(count($form_data_mapping_enabled_fields)>0)
73
+ {
74
+ if(in_array($mapping_enabled_field_key, $form_data_mapping_enabled_fields))
75
+ {
76
+ $mapping_enabled_field[1]=1;
77
+ }else
78
+ {
79
+ $mapping_enabled_field[1]=0;
80
+ }
81
+ }
82
+ ?>
83
+ <div class="meta_mapping_box">
84
+ <div class="meta_mapping_box_hd wt_iew_noselect">
85
+ <span class="dashicons dashicons-arrow-right"></span>
86
+ <?php echo $mapping_enabled_field[0];?>
87
+ <span class="meta_mapping_box_selected_count_box"><span class="meta_mapping_box_selected_count_box_num">0</span> <?php _e(' columns(s) selected'); ?></span>
88
+ </div>
89
+ <div style="clear:both;"></div>
90
+ <div class="meta_mapping_box_con" data-sortable="0" data-loaded="0" data-field-validated="0" data-key="<?php echo $mapping_enabled_field_key;?>"></div>
91
+ </div>
92
+ <div style="clear:both;"></div>
93
+ <?php
94
+ }
95
+ }
96
+ ?>
97
+ </div>
admin/modules/export/views/_export_mapping_tr_html.php ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ $checked=is_array($val) ? $val[1] : 0;
6
+ $val=(is_array($val) ? $val[0] : $val);
7
+ ?>
8
+ <tr id="columns_<?php echo $key;?>">
9
+ <td>
10
+ <div class="wt_iew_sort_handle"><span class="dashicons dashicons-move"></span></div>
11
+ <input type="checkbox" name="columns_key[]" class="columns_key wt_iew_mapping_checkbox_sub" value="<?php echo $key;?>" <?php echo ($checked==1 ? 'checked' : ''); ?>></td>
12
+ <td>
13
+ <label class="wt_iew_mapping_column_label"><?php echo $label;?></label>
14
+ </td>
15
+ <td>
16
+ <input type="text" name="columns_val[]" class="columns_val" value="<?php echo $val;?>">
17
+ </td>
18
+ </tr>
admin/modules/export/views/_export_meta_step_page.php ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <table class="wt-iew-mapping-tb wt-iew-exporter-meta-mapping-tb" data-field-type="<?php echo $meta_mapping_screen_field_key; ?>">
7
+ <thead>
8
+ <tr>
9
+ <th>
10
+ <?php
11
+ $is_checked=(isset($meta_mapping_screen_field_val['checked']) && $meta_mapping_screen_field_val['checked']==1 ? 1 : 0);
12
+ $checked_attr=($is_checked==1 ? ' checked="checked"' : '');
13
+ ?>
14
+ <input type="checkbox" name="" class="wt_iew_mapping_checkbox_main" <?php echo $checked_attr; ?>>
15
+ </th>
16
+ <th width="35%"><?php _e('Column');?></th>
17
+ <th><?php _e('Column name');?></th>
18
+ </tr>
19
+ </thead>
20
+ <tbody>
21
+ <?php
22
+ $tr_count=0;
23
+
24
+ if(isset($meta_mapping_screen_field_val['fields']) && is_array($meta_mapping_screen_field_val['fields']) && count($meta_mapping_screen_field_val['fields'])>0)
25
+ {
26
+ foreach($meta_mapping_screen_field_val['fields'] as $key=>$val)
27
+ {
28
+ $val=is_array($val) ? $val : array($val, 0);
29
+ $label=$val[0];
30
+
31
+ if(isset($current_meta_step_form_data[$key])) /* forma data/template data available */
32
+ {
33
+ $val=(is_array($current_meta_step_form_data[$key]) ? $current_meta_step_form_data[$key] : array($current_meta_step_form_data[$key], 1));
34
+ }else
35
+ {
36
+ $val[1]=$is_checked; //parent is checked
37
+ }
38
+
39
+ include "_export_mapping_tr_html.php";
40
+ $tr_count++;
41
+ }
42
+ }
43
+
44
+ if($tr_count==0)
45
+ {
46
+ ?>
47
+ <tr>
48
+ <td colspan="3" style="text-align:center;">
49
+ <?php _e('No fields found.'); ?>
50
+ </td>
51
+ </tr>
52
+ <?php
53
+ }
54
+ ?>
55
+ </tbody>
56
+ </table>
admin/modules/export/views/_export_method_export_page.php ADDED
@@ -0,0 +1,90 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_export_main">
7
+ <p><?php echo $step_info['description']; ?></p>
8
+
9
+ <div class="wt_iew_warn wt_iew_method_export_wrn" style="display:none;">
10
+ <?php _e('Please select an export method');?>
11
+ </div>
12
+
13
+ <div class="wt_iew_warn wt_iew_export_template_wrn" style="display:none;">
14
+ <?php _e('Please select an export template.');?>
15
+ </div>
16
+
17
+ <table class="form-table wt-iew-form-table">
18
+ <tr>
19
+ <th><label><?php _e('Select an export method');?></label></th>
20
+ <td colspan="2" style="width:75%;">
21
+ <div class="wt_iew_radio_block">
22
+ <?php
23
+ foreach($this->export_obj->export_methods as $key => $value)
24
+ {
25
+ ?>
26
+ <p>
27
+ <input type="radio" value="<?php echo $key;?>" id="wt_iew_export_<?php echo $key;?>_export" name="wt_iew_export_method_export" <?php echo ($this->export_method==$key ? 'checked="checked"' : '');?>><b><label for="wt_iew_export_<?php echo $key;?>_export"><?php echo $value['title']; ?></label></b> <br />
28
+ <span><label for="wt_iew_export_<?php echo $key;?>_export"><?php echo $value['description']; ?></label></span>
29
+ </p>
30
+ <?php
31
+ }
32
+ ?>
33
+ </div>
34
+
35
+ </td>
36
+ </tr>
37
+
38
+ <!-- <tr class="wt-iew-export-method-options wt-iew-export-method-options-quick">
39
+ <th style="width:150px; text-align:left; vertical-align:top;"><label><?php _e('Include fields from the respective groups');?></label></th>
40
+ <td colspan="2" style="width:75%;">
41
+ <?php
42
+ foreach($this->mapping_enabled_fields as $mapping_enabled_field_key=>$mapping_enabled_field)
43
+ {
44
+ $mapping_enabled_field=(!is_array($mapping_enabled_field) ? array($mapping_enabled_field, 0) : $mapping_enabled_field);
45
+
46
+ if($this->rerun_id>0) /* check this is a rerun request */
47
+ {
48
+ if(in_array($mapping_enabled_field_key, $form_data_mapping_enabled))
49
+ {
50
+ $mapping_enabled_field[1]=1; //mark it as checked
51
+ }else
52
+ {
53
+ $mapping_enabled_field[1]=0; //mark it as unchecked
54
+ }
55
+ }
56
+ ?>
57
+ <div class="wt_iew_checkbox" style="padding-left:0px;">
58
+ <input type="checkbox" id="wt_iew_<?php echo $mapping_enabled_field_key;?>" name="wt_iew_include_these_fields[]" value="<?php echo $mapping_enabled_field_key;?>" <?php echo ($mapping_enabled_field[1]==1 ? 'checked="checked"' : '');?> />
59
+ <label for="wt_iew_<?php echo $mapping_enabled_field_key;?>"><?php echo $mapping_enabled_field[0];?></label>
60
+ </div>
61
+ <?php
62
+ }
63
+ ?>
64
+ <span class="wt-iew_form_help"><?php _e('Enabling any of these ensures that all the fields from the respective groups are included in your export.');?></span>
65
+ </td>
66
+ </tr>-->
67
+
68
+
69
+ <tr class="wt-iew-export-method-options wt-iew-export-method-options-template" style="display:none;">
70
+ <th><label><?php _e('Export template');?></label></th>
71
+ <td>
72
+ <select class="wt-iew-export-template-sele">
73
+ <option value="0">-- <?php _e('Select a template'); ?> --</option>
74
+ <?php
75
+ foreach($this->mapping_templates as $mapping_template)
76
+ {
77
+ ?>
78
+ <option value="<?php echo $mapping_template['id'];?>" <?php echo ($form_data_export_template==$mapping_template['id'] ? ' selected="selected"' : ''); ?>>
79
+ <?php echo $mapping_template['name'];?>
80
+ </option>
81
+ <?php
82
+ }
83
+ ?>
84
+ </select>
85
+ </td>
86
+ <td>
87
+ </td>
88
+ </tr>
89
+ </table>
90
+ </div>
admin/modules/export/views/_export_post_type_page.php ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_export_main">
7
+ <p><?php echo $step_info['description']; ?></p>
8
+ <div class="wt_iew_warn wt_iew_post_type_wrn" style="display:none;">
9
+ <?php _e('Please select a post type');?>
10
+ </div>
11
+ <table class="form-table wt-iew-form-table">
12
+ <tr>
13
+ <th><label><?php _e('Select a post type to export'); ?></label></th>
14
+ <td>
15
+ <select name="wt_iew_export_post_type">
16
+ <option value="">-- <?php _e('Select post type'); ?> --</option>
17
+ <?php
18
+ foreach($post_types as $key=>$value)
19
+ {
20
+ ?>
21
+ <option value="<?php echo $key;?>" <?php echo ($item_type==$key ? 'selected' : '');?>><?php echo $value;?></option>
22
+ <?php
23
+ }
24
+ ?>
25
+ </select>
26
+ </td>
27
+ <td></td>
28
+ </tr>
29
+ </table>
30
+ </div>
admin/modules/export/views/main.php ADDED
@@ -0,0 +1,67 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Main view file of export section
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ ?>
13
+ <?php
14
+ do_action('wt_iew_exporter_before_head');
15
+ $wf_admin_view_path=plugin_dir_path(WT_P_IEW_PLUGIN_FILENAME).'admin/views/';
16
+ ?>
17
+ <style type="text/css">
18
+ .wt_iew_export_step{ display:none; }
19
+ .wt_iew_export_step_loader{ width:100%; height:400px; text-align:center; line-height:400px; font-size:14px; }
20
+ .wt_iew_export_step_main{ float:left; box-sizing:border-box; padding:15px; padding-bottom:0px; width:95%; margin:30px 2.5%; background:#fff; box-shadow:0px 2px 2px #ccc; border:solid 1px #efefef; }
21
+ .wt_iew_export_main{ padding:20px 0px; }
22
+ .wt_iew_file_ext_info_td{ vertical-align:top !important; }
23
+ .wt_iew_file_ext_info{ display:inline-block; margin-top:3px; }
24
+ </style>
25
+ <?php
26
+ Wt_Iew_IE_Basic_Helper::debug_panel($this->module_base);
27
+ ?>
28
+ <?php include WT_P_IEW_PLUGIN_PATH."/admin/views/_save_template_popup.php"; ?>
29
+ <h2 class="wt_iew_page_hd"><?php _e('Export'); ?><span class="wt_iew_post_type_name"></span></h2>
30
+
31
+ <?php
32
+ if($requested_rerun_id>0 && $this->rerun_id==0)
33
+ {
34
+ ?>
35
+ <div class="wt_iew_warn wt_iew_rerun_warn">
36
+ <?php _e('Unable to handle Re-Run request.');?>
37
+ </div>
38
+ <?php
39
+ }
40
+ ?>
41
+
42
+ <div class="wt_iew_loader_info_box"></div>
43
+ <div class="wt_iew_overlayed_loader"></div>
44
+ <div class="wt_iew_export_step_main" style = "width:68%">
45
+ <?php
46
+ foreach($this->steps as $stepk=>$stepv)
47
+ {
48
+ ?>
49
+ <div class="wt_iew_export_step wt_iew_export_step_<?php echo $stepk;?>" data-loaded="0"></div>
50
+ <?php
51
+ }
52
+ ?>
53
+ </div>
54
+ <?php
55
+ include $wf_admin_view_path."market.php";
56
+ /*
57
+ <script type="text/javascript">
58
+ /* external modules can hook
59
+ function wt_iew_exporter_validate(action, action_type, is_previous_step)
60
+ {
61
+ var is_continue=true;
62
+ <?php
63
+ do_action('wt_iew_exporter_validate');
64
+ ?>
65
+ return is_continue;
66
+ }
67
+ </script> */ ?>
admin/modules/history/assets/js/main.js ADDED
@@ -0,0 +1,196 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ var wt_iew_basic_history=(function( $ ) {
2
+ //'use strict';
3
+ var wt_iew_basic_history=
4
+ {
5
+ log_offset:0,
6
+ Set:function()
7
+ {
8
+ this.reg_delete();
9
+ this.reg_view_log();
10
+ this.reg_bulk_action();
11
+ },
12
+ reg_view_log:function()
13
+ {
14
+ jQuery(document).on('click', ".wt_iew_view_log_btn", function(){
15
+ wt_iew_basic_history.show_log_popup();
16
+ var history_id=$(this).attr('data-history-id');
17
+ if(history_id>0)
18
+ {
19
+ wt_iew_basic_history.log_offset=0;
20
+ wt_iew_basic_history.load_page(history_id);
21
+ }else
22
+ {
23
+ var log_file=$(this).attr('data-log-file');
24
+ if(log_file!="")
25
+ {
26
+ wt_iew_basic_history.view_raw_log(log_file);
27
+ }
28
+ }
29
+ });
30
+ },
31
+ view_raw_log:function(log_file)
32
+ {
33
+ $('.wt_iew_log_container').html('<div class="wt_iew_log_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
34
+ $.ajax({
35
+ url:wt_iew_basic_params.ajax_url,
36
+ data:{'action':'iew_history_ajax_basic', _wpnonce:wt_iew_basic_params.nonces.main, 'history_action':'view_log', 'log_file':log_file, 'data_type':'json'},
37
+ type:'post',
38
+ dataType:"json",
39
+ success:function(data)
40
+ {
41
+ if(data.status==1)
42
+ {
43
+ $('.wt_iew_log_container').html(data.html);
44
+ }else
45
+ {
46
+ $('.wt_iew_log_loader').html(wt_iew_basic_params.msgs.error);
47
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
48
+ }
49
+ },
50
+ error:function()
51
+ {
52
+ $('.wt_iew_log_loader').html(wt_iew_basic_params.msgs.error);
53
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
54
+ }
55
+ });
56
+ },
57
+ show_log_popup:function()
58
+ {
59
+ var pop_elm=$('.wt_iew_view_log');
60
+ var ww=$(window).width();
61
+ pop_w=(ww<1300 ? ww : 1300)-200;
62
+ pop_w=(pop_w<200 ? 200 : pop_w);
63
+ pop_elm.width(pop_w);
64
+
65
+ wh=$(window).height();
66
+ pop_h=(wh>=400 ? (wh-200) : wh);
67
+ $('.wt_iew_log_container').css({'max-height':pop_h+'px','overflow':'auto'});
68
+ wt_iew_popup.showPopup(pop_elm);
69
+ },
70
+ load_page:function(history_id)
71
+ {
72
+ var offset=wt_iew_basic_history.log_offset;
73
+ if(offset==0)
74
+ {
75
+ $('.wt_iew_log_container').html('<div class="wt_iew_log_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
76
+ }else
77
+ {
78
+ $('.wt_iew_history_loadmore_btn').hide();
79
+ $('.wt_iew_history_loadmore_loading').show();
80
+ }
81
+ $.ajax({
82
+ url:wt_iew_basic_params.ajax_url,
83
+ data:{'action':'iew_history_ajax_basic', _wpnonce:wt_iew_basic_params.nonces.main, 'history_action':'view_log', 'offset': offset, 'history_id':history_id, 'data_type':'json'},
84
+ type:'post',
85
+ dataType:"json",
86
+ success:function(data)
87
+ {
88
+ $('.wt_iew_history_loadmore_btn').show();
89
+ $('.wt_iew_history_loadmore_loading').hide();
90
+ if(data.status==1)
91
+ {
92
+ wt_iew_basic_history.log_offset=data.offset;
93
+ if(offset==0)
94
+ {
95
+ $('.wt_iew_log_container').html(data.html);
96
+ }else
97
+ {
98
+ $('.log_view_tb_tbody').append(data.html);
99
+ }
100
+ if(data.finished)
101
+ {
102
+ $('.wt_iew_history_loadmore_btn').hide();
103
+ }else
104
+ {
105
+ if(offset==0)
106
+ {
107
+ $('.wt_iew_history_loadmore_btn').unbind('click').click(function(){
108
+ wt_iew_basic_history.load_page(history_id);
109
+ });
110
+ }
111
+ }
112
+ }else
113
+ {
114
+ $('.wt_iew_log_loader').html(wt_iew_basic_params.msgs.error);
115
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
116
+ }
117
+ },
118
+ error:function()
119
+ {
120
+ $('.wt_iew_log_loader').html(wt_iew_basic_params.msgs.error);
121
+ $('.wt_iew_history_loadmore_btn').show();
122
+ $('.wt_iew_history_loadmore_loading').hide();
123
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
124
+ }
125
+ });
126
+ },
127
+ reg_delete:function()
128
+ {
129
+ jQuery('.wt_iew_delete_history, .wt_iew_delete_log').click(function(){
130
+ if(confirm(wt_iew_history_basic_params.msgs.sure))
131
+ {
132
+ window.location.href=jQuery(this).attr('data-href');
133
+ }
134
+ });
135
+ },
136
+ reg_bulk_action:function()
137
+ {
138
+ var checkbox_main=$('.wt_iew_history_checkbox_main');
139
+ var checkbox_sub=$('.wt_iew_history_checkbox_sub');
140
+ var tb=$('.history_list_tb');
141
+ if(tb.find('.wt_iew_history_checkbox_sub:checked').length==tb.find('.wt_iew_history_checkbox_sub').length)
142
+ {
143
+ checkbox_main.prop('checked',true);
144
+ }else
145
+ {
146
+ checkbox_main.prop('checked',false);
147
+ }
148
+
149
+ checkbox_main.unbind('click').click(function()
150
+ {
151
+ if($(this).is(':checked'))
152
+ {
153
+ checkbox_sub.prop('checked',true);
154
+ }else
155
+ {
156
+ checkbox_sub.prop('checked',false);
157
+ }
158
+ });
159
+ checkbox_sub.unbind('click').click(function()
160
+ {
161
+ if($(this).is(':checked') && $('.wt_iew_history_checkbox_sub:checked').length==checkbox_sub.length)
162
+ {
163
+ checkbox_main.prop('checked',true);
164
+ }else
165
+ {
166
+ checkbox_main.prop('checked',false);
167
+ }
168
+ });
169
+
170
+ $('.wt_iew_bulk_action_btn').click(function(){
171
+ if($('.wt_iew_history_checkbox_sub:checked').length>0 && $('.wt_iew_bulk_action option:selected').val()!="")
172
+ {
173
+ var cr_action=$('.wt_iew_bulk_action option:selected').val();
174
+ if(cr_action=='delete')
175
+ {
176
+ if(confirm(wt_iew_history_basic_params.msgs.sure))
177
+ {
178
+ var id_arr=new Array();
179
+ $('.wt_iew_history_checkbox_sub:checked').each(function(){
180
+ id_arr.push($(this).val());
181
+ });
182
+ var delete_url=wt_iew_history_basic_params.delete_url.replace('_history_id_', id_arr.join(','));
183
+ window.location.href=delete_url;
184
+ }
185
+ }
186
+ }
187
+ });
188
+ }
189
+ }
190
+ return wt_iew_basic_history;
191
+
192
+ })( jQuery );
193
+
194
+ jQuery(function() {
195
+ wt_iew_basic_history.Set();
196
+ });
admin/modules/history/history.php ADDED
@@ -0,0 +1,857 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * History of import/Export
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_History')){
13
+ class Wt_Import_Export_For_Woo_Basic_History
14
+ {
15
+ public $module_id='';
16
+ public static $module_id_static='';
17
+ public $module_base='history';
18
+ public static $status_arr=array();
19
+ public static $status_label_arr=array();
20
+ public static $action_label_arr=array();
21
+ public $max_records=50;
22
+
23
+ public function __construct()
24
+ {
25
+ $this->module_id=Wt_Import_Export_For_Woo_Basic::get_module_id($this->module_base);
26
+ self::$module_id_static=$this->module_id;
27
+
28
+ self::$status_arr=array(
29
+ 'pending'=>0, //running...
30
+ 'finished'=>1, //completed
31
+ 'failed'=>2, //failed
32
+ );
33
+
34
+ self::$status_label_arr=array(
35
+ 0=>__('Running/Incomplete'),
36
+ 1=>__('Finished'),
37
+ 2=>__('Failed'),
38
+ );
39
+
40
+ self::$action_label_arr=array(
41
+ 'export'=>__('Export'),
42
+ 'import'=>__('Import'),
43
+ 'export_image'=>__('Image Export'),
44
+ );
45
+
46
+ /* Admin menu for hostory listing */
47
+ add_filter('wt_iew_admin_menu_basic', array($this, 'add_admin_pages'), 10, 1);
48
+
49
+ /* advanced plugin settings */
50
+ add_filter('wt_iew_advanced_setting_fields_basic', array($this, 'advanced_setting_fields'), 11);
51
+
52
+ /* main ajax hook. The callback function will decide which action is to execute. */
53
+ add_action('wp_ajax_iew_history_ajax_basic', array($this, 'ajax_main'), 11);
54
+
55
+ /* Hook to perform actions after advanced settings was updated */
56
+ add_action('wt_iew_after_advanced_setting_update_basic', array($this, 'after_advanced_setting_update'), 11);
57
+
58
+ /* Download log file via nonce URL */
59
+ add_action('admin_init', array($this, 'download_file'), 11);
60
+
61
+ }
62
+
63
+ /**
64
+ * Adding admin menus
65
+ */
66
+ public function add_admin_pages($menus)
67
+ {
68
+ $menus[$this->module_base]=array(
69
+ 'submenu',
70
+ WT_IEW_PLUGIN_ID_BASIC,
71
+ __('History'),
72
+ __('History'),
73
+ apply_filters('wt_import_export_allowed_capability', 'import'),
74
+ $this->module_id,
75
+ array($this, 'admin_settings_page')
76
+ );
77
+ $menus[$this->module_base.'_log']=array(
78
+ 'submenu',
79
+ WT_IEW_PLUGIN_ID_BASIC,
80
+ __('Logs'),
81
+ __('Logs'),
82
+ apply_filters('wt_import_export_allowed_capability', 'import'),
83
+ $this->module_id.'_log',
84
+ array($this, 'admin_log_page')
85
+ );
86
+ return $menus;
87
+ }
88
+
89
+ public function ajax_main()
90
+ {
91
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
92
+ {
93
+ $allowed_ajax_actions=array('view_log');
94
+
95
+ $out=array(
96
+ 'status'=>0,
97
+ 'msg'=>__('Error'),
98
+ );
99
+
100
+ $history_action=Wt_Iew_Sh::sanitize_item($_POST['history_action'], 'text');
101
+ $data_type=Wt_Iew_Sh::sanitize_item($_POST['data_type'], 'text');
102
+
103
+ if(method_exists($this, $history_action) && in_array($history_action, $allowed_ajax_actions))
104
+ {
105
+ $out=$this->{$history_action}($out);
106
+ }
107
+
108
+ if($data_type=='json')
109
+ {
110
+ echo json_encode($out);
111
+ }
112
+ }
113
+ exit();
114
+ }
115
+
116
+ /**
117
+ * Ajax sub function to display logs
118
+ *
119
+ */
120
+ private function view_log($out)
121
+ {
122
+ $history_id=(isset($_POST['history_id']) ? absint($_POST['history_id']) : 0);
123
+ $out['html']='';
124
+
125
+ if($history_id>0)
126
+ {
127
+ $offset=(isset($_POST['offset']) ? absint($_POST['offset']) : 0);
128
+ $out['offset']=$offset;
129
+ $out['history_id']=$history_id;
130
+
131
+ $history_item=$this->get_history_entry_by_id($history_id);
132
+ if($history_item) //history item exists
133
+ {
134
+ $action_type=$history_item['template_type'];
135
+ if($action_type=='import' && Wt_Import_Export_For_Woo_Admin_Basic::module_exists($action_type))
136
+ {
137
+ $action_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules($action_type);
138
+ $log_file_name=$action_module_obj->get_log_file_name($history_item['id']);
139
+ $log_file_path=$action_module_obj->get_file_path($log_file_name);
140
+ if(file_exists($log_file_path))
141
+ {
142
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-logreader.php';
143
+ $reader=new Wt_Import_Export_For_Woo_Basic_Logreader();
144
+ $response=$reader->get_data_as_batch($log_file_path, $offset);
145
+ if($response['response'])
146
+ {
147
+ $log_list=$response['data_arr'];
148
+ $out['offset']=$response['offset'];
149
+ $out['status']=1;
150
+ $out['finished']=$response['finished'];
151
+
152
+ $is_finished=$response['finished'];
153
+ $new_offset=$response['offset'];
154
+
155
+ $show_item_details=false;
156
+ $item_type_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules($history_item['item_type']);
157
+ if(!is_null($item_type_module_obj) && method_exists($item_type_module_obj, 'get_item_by_id'))
158
+ {
159
+ $show_item_details=true;
160
+ }
161
+ ob_start();
162
+ include plugin_dir_path(__FILE__).'views/_log_table.php';
163
+ $out['html']=ob_get_clean();
164
+ }
165
+ }
166
+ }
167
+ }
168
+ }else /* raw log viewing */
169
+ {
170
+ $log_file_name=(isset($_POST['log_file']) ? sanitize_text_field($_POST['log_file']) : '');
171
+ if($log_file_name!="")
172
+ {
173
+ $ext_arr=explode(".", $log_file_name);
174
+ $ext=end($ext_arr);
175
+ if($ext=='log')
176
+ {
177
+ $log_file_path=Wt_Import_Export_For_Woo_Basic_Log::get_file_path($log_file_name);
178
+ if(file_exists($log_file_path))
179
+ {
180
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-logreader.php';
181
+ $reader=new Wt_Import_Export_For_Woo_Basic_Logreader();
182
+ $response=$reader->get_full_data($log_file_path);
183
+
184
+ $out['status']=1;
185
+ $out['html']='<div class="wt_iew_raw_log">'.nl2br(esc_html__($response['data_str'])).'</div>';
186
+ }
187
+ }
188
+ }
189
+
190
+ }
191
+ return $out;
192
+ }
193
+
194
+ /**
195
+ * Fields for advanced settings
196
+ *
197
+ */
198
+ public function advanced_setting_fields($fields)
199
+ {
200
+ $fields['advanced_field_head'] =array(
201
+ 'type'=>'field_group_head', //field type
202
+ 'head'=>__('Advanced options'),
203
+ 'group_id'=>'advanced_field', //field group id
204
+ 'show_on_default'=>0,
205
+ );
206
+ $fields['enable_history_auto_delete']=array(
207
+ 'label'=>__("Auto delete history"),
208
+ 'type'=>'radio',
209
+ 'radio_fields'=>array(
210
+ 1=>__('Yes'),
211
+ 0=>__('No')
212
+ ),
213
+ 'value' =>1,
214
+ 'field_name'=>'enable_history_auto_delete',
215
+ 'field_group'=>'advanced_field',
216
+ 'help_text'=>__('Enable auto delete for records within the history section.'),
217
+ 'validation_rule'=>array('type'=>'absint'),
218
+ 'form_toggler'=>array(
219
+ 'type'=>'parent',
220
+ 'target'=>'wt_iew_enable_history_auto_delete',
221
+ ),
222
+ );
223
+
224
+ $fields['auto_delete_history_count']=array(
225
+ 'label'=>__("Maximum entries"),
226
+ 'type'=>'number',
227
+ 'value' =>100,
228
+ 'attr' =>array(
229
+ 'style'=>'width:30%;',
230
+ ),
231
+ 'field_name'=>'auto_delete_history_count',
232
+ 'field_group'=>'advanced_field',
233
+ 'help_text'=>__('Indicates the maximum records to retain in history. Limit the number of records with status ‘Finished’. E.g On giving an input of 50, the system will retain(not delete) the latest 50 records with status ‘Finished’. Any other record with a different status will not be retained.'),
234
+ 'validation_rule'=>array('type'=>'absint'),
235
+ 'form_toggler'=>array(
236
+ 'type'=>'child',
237
+ 'id'=>'wt_iew_enable_history_auto_delete',
238
+ 'val'=>1,
239
+ ),
240
+ );
241
+
242
+ return $fields;
243
+ }
244
+
245
+ public function admin_log_page($args)
246
+ {
247
+ /* delete action */
248
+ if(isset($_GET['wt_iew_delete_log']))
249
+ {
250
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
251
+ {
252
+ $log_file_name=(isset($_GET['wt_iew_log_file']) ? sanitize_text_field($_GET['wt_iew_log_file']) : '');
253
+ if($log_file_name!="")
254
+ {
255
+ $ext_arr=explode(".", $log_file_name);
256
+ $ext=end($ext_arr);
257
+ if($ext=='log')
258
+ {
259
+ $log_file_path=Wt_Import_Export_For_Woo_Basic_Log::get_file_path($log_file_name);
260
+ if(file_exists($log_file_path) && is_file($log_file_path))
261
+ {
262
+ @unlink($log_file_path);
263
+ }
264
+ }
265
+ }
266
+ }
267
+ }
268
+
269
+ $delete_url_params['wt_iew_delete_log']=1;
270
+ $delete_url_params['wt_iew_log_file']='_log_file_';
271
+ $delete_url_params['page']=$this->module_id.'_log';
272
+ $delete_url=wp_nonce_url(admin_url('admin.php?'.http_build_query($delete_url_params)), WT_IEW_PLUGIN_ID_BASIC);
273
+
274
+ $download_url=wp_nonce_url(admin_url('admin.php?wt_iew_log_download=1&file=_log_file_'), WT_IEW_PLUGIN_ID_BASIC);
275
+
276
+ //enqueue script
277
+ if(isset($_GET['page']) && $_GET['page']==$this->module_id.'_log')
278
+ {
279
+ $this->enqueue_scripts($delete_url);
280
+ }
281
+
282
+ include plugin_dir_path(__FILE__).'views/settings.php';
283
+ }
284
+
285
+ /**
286
+ * History list page
287
+ */
288
+ public function admin_settings_page($args)
289
+ {
290
+ global $wpdb;
291
+
292
+ /* delete action */
293
+ if(isset($_GET['wt_iew_delete_history']))
294
+ {
295
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
296
+ {
297
+ $history_id_arr=isset($_GET['wt_iew_history_id']) ? explode(",", $_GET['wt_iew_history_id']) : array();
298
+ $history_id_arr=Wt_Iew_Sh::sanitize_item($history_id_arr, 'absint_arr');
299
+ if(count($history_id_arr)>0)
300
+ {
301
+ self::delete_history_by_id($history_id_arr);
302
+ }
303
+ }
304
+ }
305
+
306
+ /**
307
+ * Lising page section
308
+ */
309
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
310
+
311
+ $post_type_arr=self::get_disticnt_items('item_type');
312
+ $action_type_arr=self::get_disticnt_items('template_type');
313
+ $status_arr=self::get_disticnt_items('status');
314
+
315
+ $importer_post_types=apply_filters('wt_iew_importer_post_types_basic', array());
316
+ $exporter_post_types=apply_filters('wt_iew_exporter_post_types_basic', array());
317
+ $post_type_label_arr=array_merge($importer_post_types, $exporter_post_types);
318
+
319
+
320
+ /**
321
+ * Get history entries by Schedule ID
322
+ */
323
+ $cron_id=(isset($_GET['wt_iew_cron_id']) ? absint($_GET['wt_iew_cron_id']) : 0);
324
+ $history_arr=array();
325
+ $list_by_cron=false;
326
+ if($cron_id>0)
327
+ {
328
+ $cron_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules('cron');
329
+ if(!is_null($cron_module_obj))
330
+ {
331
+ $cron_data=$cron_module_obj->get_cron_by_id($cron_id);
332
+ if($cron_data)
333
+ {
334
+ $history_id_arr=($cron_data['history_id_list']!="" ? maybe_unserialize($cron_data['history_id_list']) : array());
335
+ $history_id_arr=(is_array($history_id_arr) ? $history_id_arr : array());
336
+ $list_by_cron=true;
337
+ }else
338
+ {
339
+ $cron_id=0; //invalid cron id
340
+ }
341
+ }else
342
+ {
343
+ $cron_id=0; //cron module not enabled
344
+ }
345
+ }
346
+
347
+
348
+ /**
349
+ * Filter by form fields
350
+ */
351
+ $filter_by=array(
352
+ 'item_type'=>array(
353
+ 'label'=>__('Post type'),
354
+ 'values'=>$post_type_arr,
355
+ 'val_labels'=>$post_type_label_arr,
356
+ 'val_type'=>'%s',
357
+ 'selected_val'=>'',
358
+ ),
359
+ 'template_type'=>array(
360
+ 'label'=>__('Action type'),
361
+ 'values'=>$action_type_arr,
362
+ 'val_labels'=>self::$action_label_arr,
363
+ 'val_type'=>'%s',
364
+ 'selected_val'=>'',
365
+ ),
366
+ 'status'=>array(
367
+ 'label'=>__('Status'),
368
+ 'values'=>$status_arr,
369
+ 'val_labels'=>self::$status_label_arr,
370
+ 'validation_rule'=>array('type'=>'absint'),
371
+ 'val_type'=>'%d',
372
+ 'selected_val'=>'',
373
+ ),
374
+ );
375
+
376
+ if($list_by_cron) // no need of these filters in `cron by` listing
377
+ {
378
+ unset($filter_by['item_type']);
379
+ unset($filter_by['template_type']);
380
+ }
381
+
382
+
383
+ /**
384
+ * Order by field vals
385
+ */
386
+ $order_by=array(
387
+ 'date_desc'=>array('label'=>__('Date descending'), 'sql'=>'created_at DESC'),
388
+ 'date_asc'=>array('label'=>__('Date ascending'), 'sql'=>'created_at ASC'),
389
+ );
390
+
391
+ /* just applying a text validation */
392
+ $conf_arr=isset($_GET['wt_iew_history']) ? Wt_Iew_Sh::sanitize_item($_GET['wt_iew_history'], 'text_arr') : array();
393
+ $url_params_allowed=array(); //this array will only include the allowed $_GET params. This will use in pagination section
394
+
395
+ /**
396
+ * Filter by block
397
+ */
398
+ $where_qry_val_arr=array(); //sql query WHERE clause val array
399
+ $where_qry_format_arr=array(); //sql query WHERE clause val format array
400
+ if(isset($conf_arr['filter_by'])) /* filter by GET var exists */
401
+ {
402
+ $url_params_allowed['filter_by']=array();/* for pagination purpose */
403
+
404
+ $filter_by_conf=(is_array($conf_arr['filter_by']) ? $conf_arr['filter_by'] : array());
405
+ $filter_by_validation_rule=Wt_Import_Export_For_Woo_Basic_Common_Helper::extract_validation_rules($filter_by);
406
+ foreach ($filter_by as $filter_key => $filter_val)
407
+ {
408
+ if(isset($filter_by_conf[$filter_key]) && trim($filter_by_conf[$filter_key])!="") //current filter applied
409
+ {
410
+ $where_qry_format_arr[]=$filter_key.'='.$filter_val['val_type'];
411
+ $filter_by[$filter_key]['selected_val']=Wt_Iew_Sh::sanitize_data($filter_by_conf[$filter_key], $filter_key, $filter_by_validation_rule);
412
+ $where_qry_val_arr[]=$filter_by[$filter_key]['selected_val'];
413
+
414
+ $url_params_allowed['filter_by'][$filter_key]=$filter_by[$filter_key]['selected_val']; /* for pagination purpose */
415
+ }
416
+ }
417
+ }
418
+
419
+ /**
420
+ * Order by block
421
+ */
422
+ $default_order_by=array_keys($order_by)[0];
423
+ $order_by_val=$default_order_by;
424
+ $order_qry_val_arr=array(); //sql query ORDER clause val array
425
+ if(isset($conf_arr['order_by'])) /* order by GET var exists */
426
+ {
427
+ $order_by_val=(is_array($conf_arr['order_by']) ? $default_order_by : $conf_arr['order_by']);
428
+ }
429
+ if(isset($order_by[$order_by_val]))
430
+ {
431
+ $order_qry_val_arr[]=$order_by[$order_by_val]['sql'];
432
+ $url_params_allowed['order_by']=$order_by_val; /* for pagination purpose */
433
+ }
434
+
435
+ /**
436
+ * Pagination block
437
+ */
438
+ $max_data=(isset($conf_arr['max_data']) ? absint($conf_arr['max_data']) : $this->max_records);
439
+ $this->max_records=($max_data>0 ? $max_data : $this->max_records);
440
+
441
+ $offset=(isset($_GET['offset']) ? absint($_GET['offset']) : 0);
442
+ $url_params_allowed['max_data']=$this->max_records;
443
+ $pagination_url_params=array('wt_iew_history'=>$url_params_allowed, 'page'=>$this->module_id);
444
+ $offset_qry_str=" LIMIT $offset, ".$this->max_records;
445
+ $no_records=false;
446
+
447
+ if($list_by_cron) /* list by cron */
448
+ {
449
+ $pagination_url_params['wt_iew_cron_id']=$cron_id; /* adding cron id to URL params */
450
+
451
+ $total_history_ids=count($history_id_arr);
452
+ if($total_history_ids>0)
453
+ {
454
+ $where_qry_format_arr[]='id IN('.implode(",", array_fill(0, $total_history_ids, "%d")).")";
455
+ $where_qry_val_arr=array_merge($where_qry_val_arr, $history_id_arr);
456
+
457
+ }else //reset all where, order by queries
458
+ {
459
+ $where_qry_format_arr=array();
460
+ $where_qry_val_arr=array();
461
+ //$order_qry_val_arr=array();
462
+ $no_records=true;
463
+ }
464
+ }
465
+
466
+ $where_qry=(count($where_qry_format_arr)>0 ? ' WHERE '.implode(" AND ", $where_qry_format_arr) : '');
467
+ $orderby_qry=(count($order_qry_val_arr)>0 ? ' ORDER BY '.implode(", ", $order_qry_val_arr) : '');
468
+
469
+ /* prepare SQL */
470
+ $num_sql="SELECT COUNT(id) AS total_records FROM $tb $where_qry";
471
+ $list_sql="SELECT * FROM $tb $where_qry $orderby_qry ".$offset_qry_str;
472
+
473
+ if(count($where_qry_format_arr)>0)
474
+ {
475
+ $num_sql=$wpdb->prepare($num_sql, $where_qry_val_arr);
476
+ $list_sql=$wpdb->prepare($list_sql, $where_qry_val_arr);
477
+ }
478
+
479
+ if($no_records) /* in list_by cron, history IDs are not available */
480
+ {
481
+ $total_records=0;
482
+ $history_list=array();
483
+ }else
484
+ {
485
+ $total_records=$wpdb->get_row($num_sql, ARRAY_A);
486
+ $total_records=($total_records && isset($total_records['total_records']) ? $total_records['total_records'] : 0);
487
+
488
+ $history_list=$wpdb->get_results($list_sql, ARRAY_A);
489
+ $history_list=($history_list ? $history_list : array());
490
+ }
491
+
492
+ $delete_url_params=$pagination_url_params;
493
+ $delete_url_params['wt_iew_delete_history']=1;
494
+ $delete_url_params['wt_iew_history_id']='_history_id_';
495
+ $delete_url_params['offset']=$offset;
496
+ $delete_url=wp_nonce_url(admin_url('admin.php?'.http_build_query($delete_url_params)), WT_IEW_PLUGIN_ID_BASIC);
497
+
498
+ //enqueue script
499
+ if(isset($_GET['page']) && $_GET['page']==$this->module_id)
500
+ {
501
+ $this->enqueue_scripts($delete_url);
502
+ }
503
+
504
+
505
+ include plugin_dir_path(__FILE__).'views/settings.php';
506
+ }
507
+
508
+ private function enqueue_scripts($delete_url)
509
+ {
510
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_is_screen_allowed()){
511
+ wp_enqueue_script($this->module_id, plugin_dir_url(__FILE__).'assets/js/main.js', array('jquery'), WT_P_IEW_VERSION, false);
512
+
513
+ $params=array(
514
+ 'delete_url'=>$delete_url,
515
+ 'msgs'=>array(
516
+ 'sure'=>__('Are you sure?'),
517
+ )
518
+ );
519
+ wp_localize_script($this->module_id, 'wt_iew_history_basic_params', $params);
520
+ }
521
+ }
522
+
523
+ public static function record_failure($history_id, $msg)
524
+ {
525
+ $update_data=array(
526
+ 'status'=>self::$status_arr['failed'],
527
+ 'status_text'=>$msg //no need to add translation function
528
+ );
529
+ $update_data_type=array(
530
+ '%d',
531
+ '%s',
532
+ );
533
+ self::update_history_entry($history_id, $update_data, $update_data_type);
534
+ }
535
+
536
+ /**
537
+ * Delete history entry from DB and also associated files (Export files only)
538
+ * @param array|int $id history entry IDs
539
+ */
540
+ public static function delete_history_by_id($id)
541
+ {
542
+ global $wpdb;
543
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
544
+ if(is_array($id))
545
+ {
546
+ $where=" IN(".implode(",", array_fill(0, count($id), '%d')).")";
547
+ $where_data=$id;
548
+ }else
549
+ {
550
+ $where="=%d";
551
+ $where_data=array($id);
552
+ }
553
+
554
+ //first remove files associated with it. give argument as array then no need to check the result array type
555
+ $allowed_ext_arr=array('csv', 'xml'); //please update this array if new file types introduced
556
+ $list=self::get_history_entry_by_id($where_data);
557
+ if($list)
558
+ {
559
+ foreach($list as $listv)
560
+ {
561
+ if($listv['template_type']=='export') //history is for export action
562
+ {
563
+ if(Wt_Import_Export_For_Woo_Admin_Basic::module_exists('export'))
564
+ {
565
+ $ext_arr=explode('.', $listv['file_name']);
566
+ $ext=end($ext_arr);
567
+ if(in_array($ext, $allowed_ext_arr)) /* delete only allowed extensions */
568
+ {
569
+ $file_path=Wt_Import_Export_For_Woo_Basic_Export::get_file_path($listv['file_name']);
570
+ if($file_path && file_exists($file_path))
571
+ {
572
+ @unlink($file_path);
573
+ }
574
+ }
575
+ }
576
+ }elseif($listv['template_type']=='import')
577
+ {
578
+ $action_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules('import');
579
+
580
+ $log_file_name=$action_module_obj->get_log_file_name($listv['id']);
581
+ $log_file_path=$action_module_obj->get_file_path($log_file_name);
582
+ if(file_exists($log_file_path))
583
+ {
584
+ @unlink($log_file_path);
585
+ }
586
+ }
587
+ }
588
+ }
589
+
590
+
591
+ $wpdb->query(
592
+ $wpdb->prepare("DELETE FROM $tb WHERE id".$where, $where_data)
593
+ );
594
+ }
595
+
596
+ public static function update_history_entry($history_id, $update_data, $update_data_type)
597
+ {
598
+ global $wpdb;
599
+ //updating the data
600
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
601
+ $update_where=array(
602
+ 'id'=>$history_id
603
+ );
604
+ $update_where_type=array(
605
+ '%d'
606
+ );
607
+ if($wpdb->update($tb, $update_data, $update_where, $update_data_type, $update_where_type)!==false)
608
+ {
609
+ return true;
610
+ }
611
+ return false;
612
+ }
613
+
614
+ /**
615
+ * Mathod perform actions after advanced settings was updated
616
+ *
617
+ */
618
+ public function after_advanced_setting_update($advanced_settings)
619
+ {
620
+ /* Check auto deletion enabled */
621
+ if(isset($advanced_settings['wt_iew_enable_history_auto_delete']) && $advanced_settings['wt_iew_enable_history_auto_delete']==1)
622
+ {
623
+ $record_count=(isset($advanced_settings['wt_iew_auto_delete_history_count']) ? absint($advanced_settings['wt_iew_auto_delete_history_count']) : 0);
624
+ if($record_count>0)
625
+ {
626
+ self::auto_delete_history_entry($record_count);
627
+ }
628
+ }
629
+ }
630
+
631
+ /**
632
+ * Check and delete history entry. If auto deletion enabled
633
+ *
634
+ */
635
+ public static function auto_delete_history_entry($record_count=0)
636
+ {
637
+ if($record_count==0) /* this condition is for, some requests will come from create section or some from advanced settings section */
638
+ {
639
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('enable_history_auto_delete')==1)
640
+ {
641
+ $record_count=absint(Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('auto_delete_history_count'));
642
+ }
643
+ }
644
+ if($record_count>=1)
645
+ {
646
+ global $wpdb;
647
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
648
+
649
+ $data=$wpdb->get_results("SELECT * FROM $tb WHERE status=".self::$status_arr['finished']." AND id<(SELECT id FROM $tb ORDER BY id DESC LIMIT ".($record_count-1).",1)", ARRAY_A);
650
+
651
+ if($data && is_array($data))
652
+ {
653
+ $id_arr=array_column($data, 'id');
654
+ self::delete_history_by_id($id_arr);
655
+ }
656
+ }
657
+ }
658
+
659
+ /**
660
+ * create a history entry before starting export/import
661
+ * @param $file_name String export/import file name
662
+ * @param $form_data Array export/import formdata
663
+ * @param $action String export or import
664
+ * @return $history_id Int DB id if success otherwise zero
665
+ */
666
+ public static function create_history_entry($file_name, $form_data, $to_process, $action)
667
+ {
668
+ global $wpdb;
669
+
670
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
671
+ $insert_data=array(
672
+ 'template_type'=>$action,
673
+ 'item_type'=>$to_process, //item type Eg: product
674
+ 'file_name'=>$file_name, //export/import file name
675
+ 'created_at'=>time(), //craeted time
676
+ 'data'=>maybe_serialize($form_data), //formadata
677
+ 'status'=>self::$status_arr['pending'], //pending
678
+ 'status_text'=>'Pending', //pending, No need to add translate function. we can add this on printing page
679
+ 'offset'=>0, //current offset, its always 0 on start
680
+ 'total'=>0, //total records, not available now
681
+ );
682
+ $insert_data_type=array(
683
+ '%s','%s','%s','%d','%s','%d','%d','%d'
684
+ );
685
+
686
+ $insert_response=$wpdb->insert($tb, $insert_data, $insert_data_type);
687
+
688
+ /* check for auto delete */
689
+ self::auto_delete_history_entry();
690
+
691
+ if($insert_response) //success
692
+ {
693
+ return $wpdb->insert_id;
694
+ }
695
+ return 0;
696
+ }
697
+
698
+ /**
699
+ * Get distinct column values from history table
700
+ * @param string $column table column name
701
+ * @return array array of distinct column values
702
+ */
703
+ private static function get_disticnt_items($column)
704
+ {
705
+ global $wpdb;
706
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
707
+ $data=$wpdb->get_results("SELECT DISTINCT $column FROM $tb ORDER BY $column ASC", ARRAY_A);
708
+ $data=is_array($data) ? $data : array();
709
+ return array_column($data, $column);
710
+ }
711
+
712
+ /**
713
+ * Taking history entry by ID
714
+ */
715
+ public static function get_history_entry_by_id($id)
716
+ {
717
+ global $wpdb;
718
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$history_tb;
719
+ if(is_array($id))
720
+ {
721
+ $where=" IN(".implode(",", array_fill(0, count($id), '%d')).")";
722
+ $where_data=$id;
723
+ }else
724
+ {
725
+ $where="=%d";
726
+ $where_data=array($id);
727
+ }
728
+ $qry=$wpdb->prepare("SELECT * FROM $tb WHERE id".$where, $where_data);
729
+
730
+ if(!is_array($id))
731
+ {
732
+ return $wpdb->get_row($qry, ARRAY_A);
733
+ }else
734
+ {
735
+ return $wpdb->get_results($qry, ARRAY_A);
736
+ }
737
+ }
738
+
739
+
740
+ /**
741
+ * Download log file via a nonce URL
742
+ */
743
+ public function download_file()
744
+ {
745
+ if(isset($_GET['wt_iew_log_download']))
746
+ {
747
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC)) /* check nonce and role */
748
+ {
749
+ $file_name=(isset($_GET['file']) ? sanitize_text_field($_GET['file']) : '');
750
+ if($file_name!="")
751
+ {
752
+ $file_arr=explode(".", $file_name);
753
+ $file_ext=end($file_arr);
754
+ if($file_ext=='log') /* Only allowed files. */
755
+ {
756
+ $file_path=Wt_Import_Export_For_Woo_Basic_Log::get_file_path($file_name);
757
+ if(file_exists($file_path) && is_file($file_path))
758
+ {
759
+ header('Pragma: public');
760
+ header('Expires: 0');
761
+ header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
762
+ header('Cache-Control: private', false);
763
+ header('Content-Transfer-Encoding: binary');
764
+ header('Content-Disposition: attachment; filename="'.$file_name.'";');
765
+ header('Content-Description: File Transfer');
766
+ header('Content-Type: application/octet-stream');
767
+ //header('Content-Length: '.filesize($file_path));
768
+
769
+ $chunk_size=1024 * 1024;
770
+ $handle=@fopen($file_path, 'rb');
771
+ while(!feof($handle))
772
+ {
773
+ $buffer = fread($handle, $chunk_size);
774
+ echo $buffer;
775
+ ob_flush();
776
+ flush();
777
+ }
778
+ fclose($handle);
779
+ exit();
780
+
781
+ }
782
+ }
783
+ }
784
+ }
785
+ }
786
+ }
787
+
788
+
789
+ /**
790
+ *
791
+ * Generate pagination HTML
792
+ */
793
+ public static function gen_pagination_html($total, $limit, $offset, $url, $url_params=array(), $mxnav=6)
794
+ {
795
+ if($total<=0){
796
+ return '';
797
+ }
798
+ /* taking current page */
799
+ $crpage=($offset+$limit)/$limit;
800
+
801
+ $limit=$limit<=0 ? 1 : $limit;
802
+ $ttpg=ceil($total/$limit);
803
+ if($ttpg<$crpage){
804
+ //return '';
805
+ }
806
+
807
+ //calculations
808
+ $mxnav=$ttpg<$mxnav ? $ttpg : $mxnav;
809
+
810
+ $mxnav_mid=floor($mxnav/2);
811
+ $pgstart=$mxnav_mid>=$crpage ? 1 : $crpage-$mxnav_mid;
812
+ $mxnav_mid+=$mxnav_mid>=$crpage ? ($mxnav_mid-$crpage) : 0; //adjusting other half with first half balance
813
+ $pgend=$crpage+$mxnav_mid;
814
+ if($pgend>$ttpg)
815
+ {
816
+ $pgend=$ttpg;
817
+ }
818
+
819
+ $html='<span class="wt_iew_pagination_total_info">'.$total.__(' record(s)').'</span>';
820
+ $url_params_string=http_build_query($url_params);
821
+ $url_params_string=$url_params_string!="" ? '&'.$url_params_string : '';
822
+ $url=(strpos($url, '?')!==false ? $url.'&' : $url.'?');
823
+ $href_attr=' href="'.$url.'offset={offset}'.$url_params_string.'"';
824
+
825
+ $prev_onclick='';
826
+ if($crpage>1)
827
+ {
828
+ $offset=(($crpage-2)*$limit);
829
+ $prev_onclick=str_replace('{offset}', $offset, $href_attr);
830
+ }
831
+
832
+ $html.='<a class="'.($crpage>1 ? 'wt_iew_page' : 'wt_iew_pagedisabled').'"'.$prev_onclick.'>‹</a>';
833
+ for($i=$pgstart; $i<=$pgend; $i++)
834
+ {
835
+ $page_offset='';
836
+ $onclick='';
837
+ $offset=($i*$limit)-$limit;
838
+ if($i!=$crpage)
839
+ {
840
+ $onclick=str_replace('{offset}', $offset, $href_attr);
841
+ }
842
+ $html.='<a class="'.($i==$crpage ? 'wt_iew_pageactive' : 'wt_iew_page').'" '.$onclick.'>'.$i.'</a>';
843
+ }
844
+
845
+ $next_onclick='';
846
+ if($crpage<$ttpg)
847
+ {
848
+ $offset=($crpage*$limit);
849
+ $next_onclick=str_replace('{offset}', $offset, $href_attr);
850
+ }
851
+
852
+ $html.='<a class="'.($crpage<$ttpg ? 'wt_iew_page' : 'wt_iew_pagedisabled').'"'.$next_onclick.'>›</a>';
853
+ return '<div class="wt_iew_pagination"><span>'.$html.'</div>';
854
+ }
855
+ }
856
+ }
857
+ Wt_Import_Export_For_Woo_Basic::$loaded_modules['history']=new Wt_Import_Export_For_Woo_Basic_History();
admin/modules/history/views/_history_list.php ADDED
@@ -0,0 +1,198 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_history_page">
7
+ <h2 class="wp-heading-inline"><?php _e('Import/Export history');?></h2>
8
+
9
+ <div style="margin-bottom:25px;">
10
+ <?php _e('Lists the runs and the status corresponding to every import/export with options to re-run, view detailed log or delete entry.');?>
11
+ </div>
12
+
13
+
14
+ <div class="wt_iew_history_settings">
15
+ <form action="admin.php">
16
+ <input type="hidden" name="page" value="<?php echo $this->module_id;?>">
17
+ <?php
18
+ if(array_filter(array_column($filter_by, 'values')))
19
+ {
20
+ ?>
21
+ <div class="wt_iew_history_settings_hd"><?php _e('Filter'); ?></div>
22
+ <div class="wt_iew_history_settings_form_group_box">
23
+ <?php
24
+ foreach ($filter_by as $filter_by_key => $filter_by_value)
25
+ {
26
+ if(count($filter_by_value['values'])>0)
27
+ {
28
+ ?>
29
+ <div class="wt_iew_history_settings_form_group">
30
+ <label><?php echo $filter_by_value['label']; ?></label>
31
+ <select name="wt_iew_history[filter_by][<?php echo $filter_by_key;?>]" class="wt_iew_select">
32
+ <option value=""><?php _e('All'); ?></option>
33
+ <?php
34
+ $val_labels=$filter_by_value['val_labels'];
35
+ foreach($filter_by_value['values'] as $val)
36
+ {
37
+ ?>
38
+ <option value="<?php echo $val;?>" <?php echo ($filter_by_value['selected_val']==$val ? 'selected="selected"' : '');?>><?php echo (isset($val_labels[$val]) ? $val_labels[$val] : $val);?></option>
39
+ <?php
40
+ }
41
+ ?>
42
+ </select>
43
+ </div>
44
+ <?php
45
+ }
46
+ }
47
+ ?>
48
+ </div>
49
+ <?php
50
+ }
51
+ ?>
52
+
53
+ <div class="wt_iew_history_settings_form_group_box">
54
+ <div class="wt_iew_history_settings_form_group">
55
+ <label><?php _e('Sort by'); ?></label>
56
+ <select name="wt_iew_history[order_by]" class="wt_iew_select">
57
+ <?php
58
+ foreach ($order_by as $key => $value)
59
+ {
60
+ ?>
61
+ <option value="<?php echo $key;?>" <?php echo ($order_by_val==$key ? 'selected="selected"' : '');?>><?php echo $value['label'];?></option>
62
+ <?php
63
+ }
64
+ ?>
65
+ </select>
66
+ </div>
67
+ <div class="wt_iew_history_settings_form_group">
68
+ <label><?php _e('Max record/page'); ?></label>
69
+ <input type="text" name="wt_iew_history[max_data]" value="<?php echo $this->max_records;?>" class="wt_iew_text" style="width:50px;">
70
+ </div>
71
+ </div>
72
+ <div class="wt_iew_history_settings_form_group_box">
73
+ <input type="hidden" name="offset" value="0">
74
+ <?php
75
+ if($list_by_cron) /* list by cron */
76
+ {
77
+ ?>
78
+ <input type="hidden" name="wt_iew_cron_id" value="<?php echo $cron_id;?>">
79
+ <?php
80
+ }
81
+ ?>
82
+ <button class="button button-primary" type="submit" style="float:left;"><?php _e('Apply'); ?></button>
83
+ </div>
84
+ </form>
85
+ </div>
86
+
87
+ <div class="wt_iew_bulk_action_box">
88
+ <select class="wt_iew_bulk_action wt_iew_select">
89
+ <option value=""><?php _e('Bulk Actions'); ?></option>
90
+ <option value="delete"><?php _e('Delete'); ?></option>
91
+ </select>
92
+ <button class="button button-primary wt_iew_bulk_action_btn" type="button" style="float:left;"><?php _e('Apply'); ?></button>
93
+ </div>
94
+ <?php
95
+ echo self::gen_pagination_html($total_records, $this->max_records, $offset, 'admin.php', $pagination_url_params);
96
+ ?>
97
+ <?php
98
+ if(isset($history_list) && is_array($history_list) && count($history_list)>0)
99
+ {
100
+ ?>
101
+ <table class="wp-list-table widefat fixed striped history_list_tb">
102
+ <thead>
103
+ <tr>
104
+ <th width="100">
105
+ <input type="checkbox" name="" class="wt_iew_history_checkbox_main">
106
+ <?php _e("No."); ?>
107
+ </th>
108
+ <th><?php _e("Id"); ?></th>
109
+ <th><?php _e("Action type"); ?></th>
110
+ <th><?php _e("Post type"); ?></th>
111
+ <th><?php _e("Started at"); ?></th>
112
+ <th>
113
+ <?php _e("Status"); ?>
114
+ <span class="dashicons dashicons-editor-help wt-iew-tips"
115
+ data-wt-iew-tip="
116
+ <span class='wt_iew_tooltip_span'><?php echo sprintf(__('%sSuccess%s - Process completed successfully'), '<b>', '</b>');?></span><br />
117
+ <span class='wt_iew_tooltip_span'><?php echo sprintf(__('%sFailed%s - Failed process triggered due to connection/permission or similar issues(unable to establish FTP/DB connection, write permission issues etc.)'), '<b>', '</b>');?> </span><br />
118
+ <span class='wt_iew_tooltip_span'><?php echo sprintf(__('%sRunning/Incomplete%s - Process that are running currently or that may have been terminated unknowingly(e.g, closing a browser tab while in progress etc)'), '<b>', '</b>');?> </span>">
119
+ </span>
120
+ </th>
121
+ <th>
122
+ <?php _e("Actions"); ?>
123
+ <span class="dashicons dashicons-editor-help wt-iew-tips"
124
+ data-wt-iew-tip=" <span class='wt_iew_tooltip_span'><?php _e('Re-run will take the user to the respective screen depending on the corresponding action type and the user can initiate the process accordingly.');?></span>"></span>
125
+ </th>
126
+ </tr>
127
+ </thead>
128
+ <tbody>
129
+ <?php
130
+ $i=$offset;
131
+ foreach($history_list as $key =>$history_item)
132
+ {
133
+ $i++;
134
+ ?>
135
+ <tr>
136
+ <th>
137
+ <input type="checkbox" value="<?php echo $history_item['id'];?>" name="history_id[]" class="wt_iew_history_checkbox_sub">
138
+ <?php echo $i;?>
139
+ </td>
140
+ <td><?php echo $history_item['id']; ?></td>
141
+ <td><?php echo ucfirst($history_item['template_type']); ?></td>
142
+ <td><?php echo ucfirst($history_item['item_type']); ?></td>
143
+ <td><?php echo date_i18n('Y-m-d h:i:s A', $history_item['created_at']); ?></td>
144
+ <td>
145
+ <?php
146
+ echo (isset(self::$status_label_arr[$history_item['status']]) ? self::$status_label_arr[$history_item['status']] : __('Unknown'));
147
+ ?>
148
+ </td>
149
+ <td>
150
+ <a class="wt_iew_delete_history" data-href="<?php echo str_replace('_history_id_', $history_item['id'], $delete_url);?>"><?php _e('Delete'); ?></a>
151
+ <?php
152
+ $form_data=maybe_unserialize($history_item['data']);
153
+ $action_type=$history_item['template_type'];
154
+ if($form_data && is_array($form_data))
155
+ {
156
+ $to_process=(isset($form_data['post_type_form_data']) && isset($form_data['post_type_form_data']['item_type']) ? $form_data['post_type_form_data']['item_type'] : '');
157
+ if($to_process!="")
158
+ {
159
+ if(Wt_Import_Export_For_Woo_Admin_Basic::module_exists($action_type))
160
+ {
161
+ $action_module_id=Wt_Import_Export_For_Woo_Basic::get_module_id($action_type);
162
+ $url=admin_url('admin.php?page='.$action_module_id.'&wt_iew_rerun='.$history_item['id']);
163
+ ?>
164
+ | <a href="<?php echo $url;?>" target="_blank"><?php _e("Re-Run");?></a>
165
+ <?php
166
+ }
167
+ }
168
+ }
169
+ if($action_type=='import' && Wt_Import_Export_For_Woo_Admin_Basic::module_exists($action_type))
170
+ {
171
+ $action_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules($action_type);
172
+ $log_file_name=$action_module_obj->get_log_file_name($history_item['id']);
173
+ $log_file_path=$action_module_obj->get_file_path($log_file_name);
174
+ if(file_exists($log_file_path))
175
+ {
176
+ ?>
177
+ | <a class="wt_iew_view_log_btn" data-history-id="<?php echo $history_item['id'];?>"><?php _e("View log");?></a>
178
+ <?php
179
+ }
180
+ }
181
+ ?>
182
+ </td>
183
+ </tr>
184
+ <?php
185
+ }
186
+ ?>
187
+ </tbody>
188
+ </table>
189
+ <?php
190
+ echo self::gen_pagination_html($total_records, $this->max_records, $offset, 'admin.php', $pagination_url_params);
191
+ }else
192
+ {
193
+ ?>
194
+ <h4 class="wt_iew_history_no_records"><?php _e("No records found."); ?></h4>
195
+ <?php
196
+ }
197
+ ?>
198
+ </div>
admin/modules/history/views/_log_list.php ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ /* delete after redirect */
6
+ if(isset($_GET['wt_iew_delete_log']))
7
+ {
8
+ ?>
9
+ <script type="text/javascript">
10
+ window.location.href='<?php echo admin_url('admin.php?page='.$this->module_id.'_log'); ?>';
11
+ </script>
12
+ <?php
13
+ }
14
+ ?>
15
+ <div class="wt_iew_history_page">
16
+ <h2 class="wp-heading-inline"><?php _e('Logs');?></h2>
17
+ <p>
18
+ <?php _e('Lists developer logs mostly required for debugging purposes. Options to view detailed logs are available along with delete and download(that can be shared with the support team in case of issues).');?>
19
+ </p>
20
+
21
+ <?php
22
+ $log_path=Wt_Import_Export_For_Woo_Basic_Log::$log_dir;
23
+ $log_files = glob($log_path.'/*'.'.log');
24
+ if(is_array($log_files) && count($log_files)>0)
25
+ {
26
+ foreach ($log_files as $key => $value) {
27
+ $date_time = str_replace('.log','',substr($value, strrpos($value, '_') + 1));
28
+ $d = DateTime::createFromFormat('Y-m-d H i s A', $date_time);
29
+ if ($d == false) {
30
+ $index = $date_time;
31
+ } else {
32
+ $index = $d->getTimestamp();
33
+ }
34
+ $indexed_log_files[$index] = $value;
35
+ }
36
+ krsort($indexed_log_files);
37
+ $log_files = $indexed_log_files;
38
+ ?>
39
+ <table class="wp-list-table widefat fixed striped history_list_tb log_list_tb">
40
+ <thead>
41
+ <tr>
42
+ <th class="log_file_name_col"><?php _e("File"); ?></th>
43
+ <th><?php _e("Actions"); ?></th>
44
+ </tr>
45
+ </thead>
46
+ <tbody>
47
+ <?php
48
+ foreach($log_files as $log_file)
49
+ {
50
+ $file_name=basename($log_file);
51
+ ?>
52
+ <tr>
53
+ <td class="log_file_name_col"><a class="wt_iew_view_log_btn" data-log-file="<?php echo $file_name;?>"><?php echo $file_name; ?></a></td>
54
+ <td>
55
+ <a class="wt_iew_delete_log" data-href="<?php echo str_replace('_log_file_', $file_name, $delete_url);?>"><?php _e('Delete'); ?></a>
56
+ | <a class="wt_iew_view_log_btn" data-log-file="<?php echo $file_name;?>"><?php _e("View");?></a>
57
+ | <a class="wt_iew_download_log_btn" href="<?php echo str_replace('_log_file_', $file_name, $download_url);?>"><?php _e("Download");?></a>
58
+ </td>
59
+ </tr>
60
+ <?php
61
+ }
62
+ ?>
63
+ </tbody>
64
+ </table>
65
+ <?php
66
+ }else
67
+ {
68
+ ?>
69
+ <h4 class="wt_iew_history_no_records"><?php _e("No logs found."); ?></h4>
70
+ <?php
71
+ }
72
+ ?>
73
+ </div>
admin/modules/history/views/_log_table.php ADDED
@@ -0,0 +1,130 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Log table view file
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+
13
+ $summary = array(
14
+ 'type' => array(
15
+ 0 => array(
16
+ 'count' => 0,
17
+ 'description' => __('Item with same ID already exists.'),
18
+ 'help_link' => 'https://www.webtoffee.com/how-to-resolve-id-conflict-during-import-in-woocommerce/',
19
+ 'error_code' => 'already exists'
20
+ ),
21
+ 1 => array(
22
+ 'count' => 0,
23
+ 'description' => __('Importing item conflicts with an existing post.'),
24
+ 'help_link' => 'https://www.webtoffee.com/how-to-resolve-id-conflict-during-import-in-woocommerce/',
25
+ 'error_code' => 'conflicts with an existing post'
26
+ ),
27
+ 2 => array(
28
+ 'count' => 0,
29
+ 'description' => __('Invalid product type.'),
30
+ 'help_link' => 'https://www.webtoffee.com/setting-up-product-import-export-plugin-for-woocommerce/',
31
+ 'error_code' => 'Invalid product type'
32
+ )
33
+ )
34
+ );
35
+ if(isset($log_list) && is_array($log_list) && count($log_list)>0)
36
+ {
37
+ if($offset==0)
38
+ {
39
+ ?>
40
+ <table class="wp-list-table widefat fixed striped log_view_tb" style="margin-bottom:25px;">
41
+ <thead>
42
+ <tr>
43
+ <th style="width:100px;"><?php _e("Row No."); ?></th>
44
+ <th><?php _e("Status"); ?></th>
45
+ <th><?php _e("Message"); ?></th>
46
+ <th><?php _e("Item"); ?></th>
47
+ </tr>
48
+ </thead>
49
+ <tbody class="log_view_tb_tbody">
50
+ <?php
51
+ }
52
+ foreach($log_list as $key =>$log_item)
53
+ {
54
+ if(!$log_item['status']){
55
+ if(strpos($log_item['message'], 'already exists')!==false){
56
+ $summary['type'][0]['count'] = $summary['type'][0]['count']+1;
57
+ }
58
+ if(strpos($log_item['message'], 'conflicts with an existing post')!==false){
59
+ $summary['type'][1]['count'] = $summary['type'][1]['count']+1;
60
+ }
61
+ if(strpos($log_item['message'], 'Invalid product type')!==false){
62
+ $summary['type'][2]['count'] = $summary['type'][2]['count']+1;
63
+ }
64
+ }
65
+ ?>
66
+ <tr>
67
+ <td><?php echo absint($log_item['row']); ?></td>
68
+ <td><?php echo ($log_item['status'] ? __('Success') : __('Failed/Skipped') ); ?></td>
69
+ <td><?php esc_html_e($log_item['message']); ?></td>
70
+ <td>
71
+ <?php
72
+ if($show_item_details)
73
+ {
74
+ $item_data=$item_type_module_obj->get_item_by_id($log_item['post_id']);
75
+ if($item_data && isset($item_data['title']))
76
+ {
77
+ if(isset($item_data['edit_url']))
78
+ {
79
+ echo '<a href="'.$item_data['edit_url'].'" target="_blank">'.$item_data['title'].'</a>';
80
+ }else
81
+ {
82
+ echo $item_data['title'];
83
+ }
84
+ }else
85
+ {
86
+ echo $log_item['post_id'];
87
+ }
88
+ }else
89
+ {
90
+ echo $log_item['post_id'];
91
+ }
92
+ ?>
93
+ </td>
94
+ </tr>
95
+ <?php
96
+ }?>
97
+ <div style="background-color: #f6f7f7;padding: 10px;">
98
+ <?php
99
+
100
+ foreach ($summary['type'] as $summary_row) {
101
+ $summary_row_count = $summary_row['count'];
102
+ $summary_row_help_link = $summary_row['help_link'];
103
+ if($summary_row_count):
104
+ ?>
105
+ <p><?php echo $summary_row['description']."($summary_row_count)";?> - <?php _e('Please refer')?> <a href="<?php echo $summary_row_help_link; ?>" target="_blank"><?php _e('this article');?></a> <?php _e('for troubleshoot.');?></p>
106
+ <?php
107
+ endif;
108
+
109
+ }
110
+ ?>
111
+ </div>
112
+ <?php
113
+ if($offset==0)
114
+ {
115
+ ?>
116
+ </tbody>
117
+ </table>
118
+ <h4 style="margin-top:0px;">
119
+ <a class="wt_iew_history_loadmore_btn button button-primary"> <?php _e("Load more."); ?></a>
120
+ <span class="wt_iew_history_loadmore_loading" style="display:none;"><?php _e("Loading...."); ?></span>
121
+ </h4>
122
+ <?php
123
+ }
124
+ }else
125
+ {
126
+ ?>
127
+ <h4 style="margin-bottom:55px;"><?php _e("No records found."); ?> </h4>
128
+ <?php
129
+ }
130
+ ?>
admin/modules/history/views/settings.php ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <style type="text/css">
7
+ .wt_iew_history_page{ padding:15px; }
8
+ .history_list_tb td, .history_list_tb th{ text-align:center; }
9
+ .history_list_tb tr th:first-child{ text-align:left; }
10
+ .wt_iew_delete_history, .wt_iew_delete_log{ cursor:pointer; }
11
+ .wt_iew_history_settings{ float:left; width:100%; padding:15px; background:#fff; border:solid 1px #ccd0d4; box-sizing:border-box; margin-bottom:15px; }
12
+ .wt_iew_history_settings_hd{ float:left; width:100%; font-weight:bold; font-size:13px; }
13
+ .wt_iew_history_settings_form_group_box{ float:left; width:100%; box-sizing:border-box; padding:10px; padding-bottom:0px; height:auto; font-size:12px; }
14
+ .wt_iew_history_settings_form_group{ float:left; width:auto; margin-right:3%; min-width:200px;}
15
+ .wt_iew_history_settings_form_group label{ font-size:12px; font-weight:bold; }
16
+ .wt_iew_history_settings_form_group select, .wt_iew_history_settings_form_group input[type="text"]{ height:20px; }
17
+ .wt_iew_history_no_records{float:left; width:100%; margin-bottom:55px; margin-top:20px; text-align:center; background:#fff; padding:15px 0px; border:solid 1px #ccd0d4;}
18
+ .wt_iew_bulk_action_box{ float:left; width:auto; margin:10px 0px; }
19
+ select.wt_iew_bulk_action{ float:left; width:auto; height:20px; margin-right:10px; }
20
+ .wt_iew_view_log_btn{ cursor:pointer; }
21
+ .wt_iew_view_log{ }
22
+ .wt_iew_log_loader{ width:100%; height:200px; text-align:center; line-height:150px; font-size:14px; font-style:italic; }
23
+ .wt_iew_log_container{ padding:25px; }
24
+ .wt_iew_raw_log{ text-align:left; font-size:14px; }
25
+ .log_view_tb th, .log_view_tb td{ text-align:center; }
26
+ .log_list_tb .log_file_name_col{ text-align:left; }
27
+ </style>
28
+ <div class="wt_iew_view_log wt_iew_popup">
29
+ <div class="wt_iew_popup_hd">
30
+ <span style="line-height:40px;" class="dashicons dashicons-media-text"></span>
31
+ <span class="wt_iew_popup_hd_label"><?php _e('View log');?></span>
32
+ <div class="wt_iew_popup_close">X</div>
33
+ </div>
34
+ <div class="wt_iew_log_container">
35
+
36
+ </div>
37
+ </div>
38
+ <?php
39
+ if(isset($_GET['page']) && $_GET['page']==$this->module_id.'_log')
40
+ {
41
+ include plugin_dir_path(__FILE__)."/_log_list.php";
42
+ }else
43
+ {
44
+ include plugin_dir_path(__FILE__)."/_history_list.php";
45
+ }
46
+ ?>
admin/modules/import/assets/js/main.js ADDED
@@ -0,0 +1,1482 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ var wt_iew_basic_import=(function( $ ) {
2
+ //'use strict';
3
+ var wt_iew_basic_import=
4
+ {
5
+ ajax_data:{},
6
+ selected_template:0,
7
+ selected_template_name:'',
8
+ to_import:'',
9
+ to_import_title:'',
10
+ import_method:'',
11
+ current_step:'',
12
+ loaded_status_arr:{'loaded':1, 'loading':2, 'not_loaded':0},
13
+ page_overlay:false,
14
+ step_keys:[],
15
+ form_data:{},
16
+ is_valid_file:false,
17
+ temp_import_file:'',
18
+ file_from:'',
19
+ blocked_action:'', /* the current action will be blocked if file validation is not done. After the successful validation the blocked action will be executed */
20
+ local_import_file:'',
21
+ url_import_file:'',
22
+ on_rerun:false,
23
+ rerun_id:0,
24
+ import_delimiter:',',
25
+ Set:function()
26
+ {
27
+ this.step_keys=Object.keys(wt_iew_import_basic_params.steps);
28
+ if(this.on_rerun)
29
+ {
30
+ this.rerun();
31
+ }else
32
+ {
33
+ var first_step=this.step_keys[0];
34
+ this.load_steps([first_step], first_step);
35
+ this.show_step_page(first_step, false); /* just to show a loading */
36
+ }
37
+ },
38
+ rerun:function()
39
+ {
40
+ var last_step=this.step_keys[this.step_keys.length-1];
41
+ this.load_steps(this.step_keys, last_step);
42
+ this.show_step_page(last_step, false); /* just to show a loading */
43
+ },
44
+ filter_loaded_steps:function(steps)
45
+ {
46
+ var filtered_steps=new Array();
47
+ $.each(steps, function(step_ind, step){
48
+ if(wt_iew_basic_import.get_page_dom_object(step).attr('data-loaded')!=wt_iew_basic_import.loaded_status_arr['loaded'])
49
+ {
50
+ filtered_steps.push(step);
51
+ }
52
+ });
53
+ return filtered_steps;
54
+ },
55
+ load_steps:function(steps, step_to_show)
56
+ {
57
+ steps=this.filter_loaded_steps(steps);
58
+ if(steps.length==0){ return; }
59
+ this.prepare_ajax_data('get_steps', 'json');
60
+ this.ajax_data.steps=steps;
61
+ if(this.on_rerun)
62
+ {
63
+ this.ajax_data.rerun_id=this.rerun_id;
64
+ }
65
+ this.set_step_loading_status(steps, 'loading');
66
+ this.set_ajax_page_loader(steps, 'loading');
67
+ $.ajax({
68
+ type: 'POST',
69
+ url:wt_iew_basic_params.ajax_url,
70
+ data:this.ajax_data,
71
+ dataType:'json',
72
+ success:function(data)
73
+ {
74
+ if(data!=null && data.status==1)
75
+ {
76
+ wt_iew_basic_import.set_step_page(data);
77
+ wt_iew_basic_import.set_step_loading_status(steps, 'loaded');
78
+ if(step_to_show)
79
+ {
80
+ wt_iew_basic_import.show_step_page(step_to_show, true);
81
+ }
82
+ if(wt_iew_basic_import.on_rerun)
83
+ {
84
+ wt_iew_basic_import.load_meta_mapping_fields();
85
+ wt_iew_basic_import.set_validate_file_info(); /* this will prevent revalidation of files */
86
+ wt_iew_basic_import.on_rerun=false;
87
+ wt_iew_basic_import.rerun_id=0;
88
+ }
89
+ }else
90
+ {
91
+ wt_iew_basic_import.set_step_loading_status(steps, 'not_loaded');
92
+ wt_iew_basic_import.set_ajax_page_loader(steps, 'error');
93
+ }
94
+ wt_iew_basic_import.remove_ajax_page_loader();
95
+ },
96
+ error:function()
97
+ {
98
+ wt_iew_basic_import.set_step_loading_status(steps, 'not_loaded');
99
+ wt_iew_basic_import.remove_ajax_page_loader();
100
+ wt_iew_basic_import.set_ajax_page_loader(steps, 'error');
101
+ }
102
+ });
103
+ },
104
+ load_meta_mapping_fields:function()
105
+ {
106
+ this.prepare_ajax_data('get_meta_mapping_fields', 'json');
107
+ this.ajax_data['file_head_meta']=JSON.stringify(wt_iew_file_head_remaining_meta);
108
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_import_step_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
109
+ $.ajax({
110
+ type: 'POST',
111
+ url:wt_iew_basic_params.ajax_url,
112
+ data:this.ajax_data,
113
+ dataType:'json',
114
+ success:function(data)
115
+ {
116
+ if(data.status==1)
117
+ {
118
+ $.each(data.meta_html, function(meta_id, meta_content){
119
+ $('.meta_mapping_box_con[data-key="'+meta_id+'"]').html(meta_content).attr('data-loaded', 1);
120
+ });
121
+ wt_iew_basic_import.enable_sortable();
122
+ wt_iew_basic_import.reg_mapping_field_bulk_action();
123
+ wt_iew_popover.Set();
124
+ }else
125
+ {
126
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_import_step_loader">'+wt_iew_basic_params.msgs.error+'</div>');
127
+ }
128
+ },
129
+ error:function()
130
+ {
131
+ $('.meta_mapping_box_con[data-loaded="0"]').html('<div class="wt_iew_import_step_loader">'+wt_iew_basic_params.msgs.loading+'</div>');
132
+ }
133
+ });
134
+ },
135
+ console_formdata:function()
136
+ {
137
+ console.log(this.form_data);
138
+ },
139
+ refresh_step:function(no_overlay)
140
+ {
141
+ /* if popover is opened */
142
+ wt_iew_popover.closePop();
143
+
144
+ if(!no_overlay){
145
+ this.page_overlay=true;
146
+ }
147
+ this.reset_step_loaded_state([this.current_step]);
148
+ this.load_steps([this.current_step], this.current_step);
149
+ },
150
+ get_need_to_reload_steps:function()
151
+ {
152
+ var rest_steps=this.step_keys.slice(0);
153
+ /* remove first and second steps */
154
+ rest_steps.shift();
155
+ rest_steps.shift();
156
+ return rest_steps;
157
+ },
158
+ load_pending_steps:function(no_overlay, show_step)
159
+ {
160
+ if(!no_overlay){
161
+ this.page_overlay=true;
162
+ }
163
+ if(!show_step)
164
+ {
165
+ show_step=this.current_step;
166
+ }
167
+ this.load_steps(this.get_need_to_reload_steps(), show_step);
168
+ },
169
+ get_page_dom_object:function(step)
170
+ {
171
+ return $('.wt_iew_import_step_'+step);
172
+ },
173
+ remove_ajax_page_loader:function()
174
+ {
175
+ this.hide_import_info_box();
176
+ $('.wt_iew_overlayed_loader').hide();
177
+ $('.spinner').css({'visibility':'hidden'});
178
+ this.page_overlay=false;
179
+ },
180
+ set_ajax_page_loader:function(steps, msg_type)
181
+ {
182
+ if(this.page_overlay)
183
+ {
184
+ var h=parseInt($('.wt_iew_import_step_main').outerHeight());
185
+ var w=parseInt($('.wt_iew_import_step_main').outerWidth());
186
+ $('.wt_iew_overlayed_loader').show().css({'height':h,'width':w,'margin-top':'30px','margin-left':'30px'});
187
+ $('.spinner').css({'visibility':'visible'});
188
+ }else
189
+ {
190
+ var msg='';
191
+ if(msg_type=='loading')
192
+ {
193
+ msg=wt_iew_basic_params.msgs.loading;
194
+ }else if(msg_type=='error')
195
+ {
196
+ msg=wt_iew_basic_params.msgs.error;
197
+ }
198
+ $.each(steps, function(step_ind, step){
199
+ wt_iew_basic_import.get_page_dom_object(step).html('<div class="wt_iew_import_step_loader">'+msg+'</div>');
200
+ });
201
+ }
202
+ },
203
+ hide_import_info_box:function()
204
+ {
205
+ $('.wt_iew_loader_info_box').hide();
206
+ },
207
+ set_import_progress_info:function(msg)
208
+ {
209
+ $('.wt_iew_loader_info_box').show().html(msg);
210
+ },
211
+ nonstep_actions:function(action)
212
+ {
213
+ this.prepare_ajax_data(action, 'json');
214
+ if(action=='save_template' || action=='save_template_as' || action=='update_template')
215
+ {
216
+ $('.wt_iew_template_name_wrn').hide();
217
+ var pop_elm=$('.wt_iew_template_name');
218
+ var popup_label=pop_elm.attr('data-save-label');
219
+ if(action=='save_template_as')
220
+ {
221
+ var popup_label=pop_elm.attr('data-saveas-label');
222
+ }
223
+ pop_elm.find('.wt_iew_popup_hd_label, .wt_iew_template_create_btn').text(popup_label);
224
+ wt_iew_popup.showPopup(pop_elm);
225
+ $('[name="wt_iew_template_name_field"]').val(this.selected_template_name).focus();
226
+
227
+ $('.wt_iew_template_create_btn').unbind('click').click(function(){
228
+ var name=$.trim($('.wt_iew_template_name_field').val());
229
+ if(name=='')
230
+ {
231
+ $('.wt_iew_template_name_wrn').show();
232
+ $('.wt_iew_template_name_field').focus();
233
+ }else
234
+ {
235
+ $('.wt_iew_template_name_wrn').hide();
236
+ wt_iew_popup.hidePopup();
237
+
238
+ wt_iew_basic_import.prepare_form_data();
239
+ wt_iew_basic_import.ajax_data['template_name']=name;
240
+ wt_iew_basic_import.ajax_data['form_data']=wt_iew_basic_import.form_data;
241
+ wt_iew_basic_import.do_nonstep_action(action);
242
+ }
243
+ });
244
+ }else if(action=='validate_file' || action=='download')
245
+ {
246
+ this.prepare_form_data();
247
+ this.ajax_data['form_data']=this.form_data;
248
+ this.do_nonstep_action(action);
249
+ }else
250
+ {
251
+ /* custom action section for other modules */
252
+ this.prepare_form_data();
253
+ this.ajax_data['form_data']=this.form_data;
254
+ wt_iew_custom_action_basic(this.ajax_data, action, this.selected_template);
255
+ }
256
+ },
257
+ do_nonstep_action:function(action)
258
+ {
259
+ this.page_overlay=true;
260
+ this.set_ajax_page_loader();
261
+
262
+ if(action=='download')
263
+ {
264
+ wt_iew_basic_import.set_import_progress_info(wt_iew_import_basic_params.msgs.processing_file);
265
+ }
266
+ $.ajax({
267
+ type: 'POST',
268
+ url:wt_iew_basic_params.ajax_url,
269
+ data:this.ajax_data,
270
+ dataType:'json',
271
+ success:function(data)
272
+ {
273
+ wt_iew_basic_import.remove_ajax_page_loader();
274
+ if(wt_iew_basic_import.is_object(data) && data.hasOwnProperty('status'))
275
+ {
276
+ if(data.status==1)
277
+ {
278
+ if(action=='save_template' || action=='save_template_as' || action=='update_template')
279
+ {
280
+ wt_iew_basic_import.selected_template=data.id;
281
+ wt_iew_basic_import.selected_template_name=data.name;
282
+ wt_iew_notify_msg.success(data.msg);
283
+ //wt_iew_notify_msg.success(wt_iew_basic_params.msgs.success);
284
+
285
+ }else if(action=='import')
286
+ {
287
+ if(data.finished==1)
288
+ {
289
+ wt_iew_basic_import.temp_import_file='';
290
+ wt_iew_notify_msg.success(wt_iew_basic_params.msgs.success);
291
+ wt_iew_basic_import.set_import_progress_info(data.msg);
292
+ }
293
+ else
294
+ {
295
+ wt_iew_basic_import.set_import_progress_info(data.msg);
296
+ wt_iew_basic_import.ajax_data['offset']=data.new_offset;
297
+ wt_iew_basic_import.ajax_data['import_id']=data.import_id;
298
+ wt_iew_basic_import.ajax_data['total_records']=data.total_records;
299
+ wt_iew_basic_import.ajax_data['offset_count']=data.offset_count;
300
+
301
+ wt_iew_basic_import.ajax_data['total_success']=data.total_success;
302
+ wt_iew_basic_import.ajax_data['total_failed']=data.total_failed;
303
+ wt_iew_basic_import.do_nonstep_action(action);
304
+ }
305
+ }else if(action=='download')
306
+ {
307
+ wt_iew_basic_import.set_import_progress_info(data.msg);
308
+ wt_iew_basic_import.ajax_data['import_id']=data.import_id;
309
+ wt_iew_basic_import.ajax_data['total_records']=data.total_records;
310
+ if(data.finished==3)/* finished file processing */
311
+ {
312
+ wt_iew_basic_import.ajax_data['offset']=0;
313
+ wt_iew_basic_import.ajax_data['offset_count']=0;
314
+ wt_iew_basic_import.ajax_data['import_action']='import';
315
+ wt_iew_basic_import.ajax_data['temp_import_file']=data.temp_import_file;
316
+ wt_iew_basic_import.temp_import_file=data.temp_import_file;
317
+ wt_iew_basic_import.do_nonstep_action('import');
318
+ }else
319
+ {
320
+ wt_iew_basic_import.ajax_data['offset']=data.new_offset;
321
+ wt_iew_basic_import.ajax_data['import_action']='download';
322
+ wt_iew_basic_import.do_nonstep_action('download');
323
+ }
324
+ }
325
+ else if(action=='validate_file')
326
+ {
327
+ wt_iew_basic_import.is_valid_file=true;
328
+
329
+ /* set meta step status to not loaded */
330
+ wt_iew_basic_import.reset_meta_step_loaded_state();
331
+
332
+ wt_iew_basic_import.temp_import_file=data.file_name;
333
+ wt_iew_basic_import.set_validate_file_info();
334
+ if(wt_iew_basic_import.blocked_action!='') /* pending action exists */
335
+ {
336
+ if(wt_iew_basic_import.is_step(wt_iew_basic_import.blocked_action))
337
+ {
338
+ /* load all pending steps, and show the next step (Blocked action) */
339
+ wt_iew_basic_import.load_pending_steps(false, wt_iew_basic_import.blocked_action);
340
+
341
+ }else /* may be import(download) */
342
+ {
343
+ wt_iew_basic_import.nonstep_actions(wt_iew_basic_import.blocked_action);
344
+ }
345
+
346
+ /* clear the blocked action */
347
+ wt_iew_basic_import.blocked_action='';
348
+ }
349
+ }else
350
+ {
351
+
352
+ }
353
+ }else
354
+ {
355
+ if(data.msg!="")
356
+ {
357
+ wt_iew_notify_msg.error(data.msg);
358
+ }else
359
+ {
360
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
361
+ }
362
+ }
363
+ }else
364
+ {
365
+ wt_iew_basic_import.temp_import_file='';
366
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
367
+ }
368
+ },
369
+ error:function()
370
+ {
371
+ wt_iew_basic_import.temp_import_file='';
372
+ wt_iew_basic_import.remove_ajax_page_loader();
373
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
374
+ }
375
+ });
376
+ },
377
+ reg_button_actions:function()
378
+ {
379
+ $('.wt_iew_import_action_btn').unbind('click').click(function(e){
380
+ e.preventDefault();
381
+
382
+ wt_iew_basic_import.remove_ajax_page_loader(); /* remove any loader that are open */
383
+
384
+ var action=$(this).attr('data-action');
385
+ var action_type=$(this).attr('data-action-type');
386
+ var is_previous_step=wt_iew_basic_import.is_previous_step(action);
387
+ if(!wt_iew_importer_validate_basic(action, action_type, is_previous_step))
388
+ {
389
+ return false;
390
+ }
391
+
392
+ /* validation section */
393
+ if(!wt_iew_basic_import.form_validation(action))
394
+ {
395
+ return false;
396
+ }
397
+
398
+ /* if popover is opened */
399
+ wt_iew_popover.closePop();
400
+
401
+ /* this method will check current step is import method step and file is validated */
402
+ if(!wt_iew_basic_import.validate_file(action, action_type))
403
+ {
404
+ return false;
405
+ }
406
+
407
+ if(action_type=='step')
408
+ {
409
+ wt_iew_basic_import.change_step(action);
410
+ }else
411
+ {
412
+ wt_iew_basic_import.nonstep_actions(action);
413
+ }
414
+ });
415
+ },
416
+ get_file_from:function()
417
+ {
418
+ if(jQuery('select[name="wt_iew_file_from"]').length>0) /* select box */
419
+ {
420
+ var file_from=jQuery('[name="wt_iew_file_from"]').val();
421
+ }else
422
+ {
423
+ var file_from=jQuery('[name="wt_iew_file_from"]:checked').val();
424
+ }
425
+ return file_from;
426
+ },
427
+ set_validate_file_info:function()
428
+ {
429
+ var file_from=this.get_file_from();
430
+
431
+ if(file_from=='local')
432
+ {
433
+ this.local_import_file=$('[name="wt_iew_local_file"]').val();
434
+
435
+ }else if(file_from=='url')
436
+ {
437
+ this.url_import_file=$('[name="wt_iew_url_file"]').val();
438
+
439
+ }else
440
+ {
441
+ wt_iew_set_validate_file_info(file_from);
442
+ }
443
+ },
444
+ validate_file:function(action, action_type)
445
+ {
446
+ if(this.current_step=='method_import')
447
+ {
448
+ /* check any revalidation needed for input file */
449
+ var file_from=this.get_file_from();
450
+ if(file_from=='local')
451
+ {
452
+ if(this.local_import_file!=$('[name="wt_iew_local_file"]').val())
453
+ {
454
+ this.is_valid_file=false;
455
+ }else
456
+ {
457
+ this.is_valid_file=true;
458
+ }
459
+ }else if(file_from=='url')
460
+ {
461
+ if(this.url_import_file!=$('[name="wt_iew_url_file"]').val())
462
+ {
463
+ this.is_valid_file=false;
464
+ }else
465
+ {
466
+ this.is_valid_file=true;
467
+ }
468
+ }else
469
+ {
470
+ /* revalidation check of other remote adapters will done on form validation hook */
471
+ }
472
+ }
473
+
474
+ if(this.current_step=='method_import' && !this.is_valid_file) /* method import page, then check file validation is done. */
475
+ {
476
+ if(action_type=='step' && this.is_previous_step(action)) /* step action and previous step */
477
+ {
478
+ return true;
479
+ }
480
+
481
+ /* store the current action to a variable. After successful validation of the file the stopped action will resumed */
482
+ this.blocked_action=action;
483
+
484
+ this.set_import_progress_info(wt_iew_import_basic_params.msgs.validating_file);
485
+ this.nonstep_actions('validate_file'); /* download/upload the file and validate it. */
486
+ return false;
487
+ }else
488
+ {
489
+ return true;
490
+ }
491
+ },
492
+ form_validation:function(step_to_go)
493
+ {
494
+ if(this.current_step=='post_type')
495
+ {
496
+ if(this.to_import=='')
497
+ {
498
+ $('.wt_iew_post_type_wrn').show();
499
+ return false;
500
+ }
501
+ }else if(this.current_step=='method_import') /* method import page */
502
+ {
503
+ if(this.import_method=='template' && this.selected_template==0 && !this.is_previous_step(step_to_go))
504
+ {
505
+ wt_iew_notify_msg.error(wt_iew_import_basic_params.msgs.select_an_import_template);
506
+ return false;
507
+ }
508
+ if((this.import_method=='new' || this.import_method=='quick') && !this.is_previous_step(step_to_go))
509
+ {
510
+ if(this.file_from=='')
511
+ {
512
+ wt_iew_notify_msg.error(wt_iew_import_basic_params.msgs.choose_import_from);
513
+ return false;
514
+ }else
515
+ {
516
+ if(this.file_from=='local' && $.trim($('[name="wt_iew_local_file"]').val())=='')
517
+ {
518
+ wt_iew_notify_msg.error(wt_iew_import_basic_params.msgs.choose_a_file);
519
+ return false;
520
+ }
521
+ else if(this.file_from=='url' && $.trim($('[name="wt_iew_url_file"]').val())=='')
522
+ {
523
+ wt_iew_notify_msg.error(wt_iew_import_basic_params.msgs.choose_a_file);
524
+ return false;
525
+ }
526
+ }
527
+ }
528
+ }else if(this.current_step=='advanced')
529
+ {
530
+
531
+ }
532
+ return true;
533
+ },
534
+ change_step:function(step_to_go)
535
+ {
536
+ /* setting fromdata */
537
+ this.prepare_form_data();
538
+
539
+ /* step changing section */
540
+ this.show_step_page(step_to_go, true);
541
+ },
542
+ reset_form_data:function()
543
+ {
544
+ this.form_data={};
545
+ this.selected_template=0;
546
+ this.selected_template_name='';
547
+ this.import_method='';
548
+ this.is_valid_file=false;
549
+ this.local_import_file='';
550
+ this.url_import_file='';
551
+ wt_iew_importer_reset_form_data_basic();
552
+
553
+ /* reset loaded state */
554
+ this.reset_step_loaded_state(this.get_need_to_reload_steps());
555
+ },
556
+ reset_step_loaded_state:function(steps)
557
+ {
558
+ this.set_step_loading_status(steps, 'not_loaded');
559
+ },
560
+ reset_meta_step_loaded_state:function()
561
+ {
562
+ var rest_steps=this.get_need_to_reload_steps();
563
+ var meta_step=rest_steps.shift();
564
+ this.reset_step_loaded_state([meta_step]);
565
+ },
566
+ prepare_form_data:function()
567
+ {
568
+ if(this.current_step=='post_type')
569
+ {
570
+ this.form_data['post_type_form_data']=JSON.stringify({'item_type':wt_iew_basic_import.to_import});
571
+ }
572
+ else if(this.current_step=='mapping')
573
+ {
574
+
575
+ /**
576
+ * Default mapping fields
577
+ */
578
+ var mapping_form_data={};
579
+ var mapping_fields={};
580
+ var mapping_selected_fields={}; /* this value is only for backend processing */
581
+
582
+ $('.wt-iew-importer-default-mapping-tb tbody tr').each(function(){
583
+
584
+ var columns_key=$(this).find('.columns_key').val();
585
+ var columns_val=$(this).find('.columns_val').val();
586
+
587
+ var enabled=($(this).find('.columns_key').is(':checked') ? 1 : 0);
588
+ var type=$(this).find('.columns_val').attr('data-type');
589
+ mapping_fields[columns_key]=[columns_val, enabled, type];
590
+ if(enabled==1)
591
+ {
592
+ mapping_selected_fields[columns_key]=columns_val;
593
+ }
594
+
595
+ });
596
+
597
+ mapping_form_data={'mapping_fields':mapping_fields, 'mapping_selected_fields':mapping_selected_fields};
598
+ this.form_data['mapping_form_data']=JSON.stringify(mapping_form_data);
599
+
600
+
601
+
602
+ /**
603
+ * meta mapping fields
604
+ */
605
+ var meta_step_form_data={};
606
+ var mapping_fields={};
607
+ var mapping_selected_fields={}; /* this value is only for backend processing */
608
+
609
+ $('.wt-iew-importer-meta-mapping-tb').each(function(){
610
+ var mapping_key=$(this).attr('data-field-type');
611
+ mapping_fields[mapping_key]={};
612
+ mapping_selected_fields[mapping_key]={};
613
+
614
+ $(this).find('tbody tr').each(function(){
615
+ if($(this).find('.columns_key').length>0 && $(this).find('.columns_val').length>0)
616
+ {
617
+ var columns_key=$(this).find('.columns_key').val();
618
+ var columns_val=$(this).find('.columns_val').val();
619
+
620
+ var enabled=($(this).find('.columns_key').is(':checked') ? 1 : 0);
621
+ var type=$(this).find('.columns_val').attr('data-type');
622
+ mapping_fields[mapping_key][columns_key]=[columns_val, enabled, type];
623
+ if(enabled==1)
624
+ {
625
+ mapping_selected_fields[mapping_key][columns_key]=columns_val;
626
+ }
627
+ }
628
+ });
629
+ });
630
+
631
+ meta_step_form_data={'mapping_fields':mapping_fields, 'mapping_selected_fields':mapping_selected_fields};
632
+ this.form_data['meta_step_form_data']=JSON.stringify(meta_step_form_data);
633
+
634
+ }
635
+ else
636
+ {
637
+ var current_form_data={};
638
+ if(this.current_step=='method_import')
639
+ {
640
+ current_form_data={'method_import' : wt_iew_basic_import.import_method, 'selected_template':this.selected_template};
641
+ }
642
+ if($('.wt_iew_import_'+this.current_step+'_form').length>0) /* may be user hit the back button */
643
+ {
644
+ var form_data=$('.wt_iew_import_'+this.current_step+'_form').serializeArray();
645
+ $.each(form_data, function(){
646
+
647
+ if(current_form_data[this.name])
648
+ {
649
+ if(!current_form_data[this.name].push)
650
+ {
651
+ current_form_data[this.name] = [current_form_data[this.name]];
652
+ }
653
+ current_form_data[this.name].push(this.value || '');
654
+ }else
655
+ {
656
+ current_form_data[this.name] = this.value || '';
657
+ }
658
+
659
+ });
660
+
661
+ this.form_data[this.current_step+'_form_data']=JSON.stringify(current_form_data);
662
+ }
663
+ }
664
+
665
+ /* we are resetting formdata on second step. If user not going to first step then post type formdata will be empty. */
666
+ if(this.current_step!='post_type')
667
+ {
668
+ this.form_data['post_type_form_data']=JSON.stringify({'item_type':wt_iew_basic_import.to_import});
669
+ }
670
+
671
+ },
672
+ is_multi_select:function(name)
673
+ {
674
+ var elm=$('[name="'+name+'"]');
675
+ if(elm.prop("tagName").toLowerCase()=='select' && this.has_attr(elm,'multiple'))
676
+ {
677
+ return true;
678
+ }else
679
+ {
680
+ return false;
681
+ }
682
+ },
683
+ has_attr:function(elm,attr_name)
684
+ {
685
+ var attr = elm.attr(attr_name);
686
+ if(typeof attr!==typeof undefined && attr!==false)
687
+ {
688
+ return true;
689
+ }else
690
+ {
691
+ return false;
692
+ }
693
+ },
694
+ is_step:function(step_key)
695
+ {
696
+ return wt_iew_import_basic_params.steps.hasOwnProperty(step_key) ? true : false;
697
+ },
698
+ is_previous_step:function(step_key)
699
+ {
700
+ if(this.is_step(step_key))
701
+ {
702
+ if(this.step_keys.indexOf(step_key)<this.step_keys.indexOf(this.current_step))
703
+ {
704
+ return true;
705
+ }
706
+ }
707
+ return false;
708
+ },
709
+ is_step_loaded:function(step)
710
+ {
711
+ if(this.get_page_dom_object(step).length==0){ return true; } /* block infinite loop, if element is not available */
712
+ return (this.get_page_dom_object(step).attr('data-loaded')==this.loaded_status_arr['loaded']);
713
+ },
714
+ set_step_loading_status:function(steps, status)
715
+ {
716
+ $.each(steps, function(step_ind, step){
717
+ wt_iew_basic_import.get_page_dom_object(step).attr('data-loaded', wt_iew_basic_import.loaded_status_arr[status]);
718
+ });
719
+ },
720
+ show_step_page:function(step, force_check_loaded)
721
+ {
722
+ $('.wt_iew_import_step').hide();
723
+ this.get_page_dom_object(step).show();
724
+ this.current_step=step;
725
+ if(force_check_loaded)
726
+ {
727
+ if(this.is_step_loaded(step))
728
+ {
729
+ this.current_step_actions();
730
+ }else
731
+ {
732
+ this.refresh_step(true);
733
+ }
734
+ }else
735
+ {
736
+ this.current_step_actions();
737
+ }
738
+ wt_iew_form_toggler.runToggler();
739
+ },
740
+ current_step_actions:function() /* current page actions after page is visible */
741
+ {
742
+ if(this.current_step=='method_import')
743
+ {
744
+ wt_iew_file_attacher.Set();
745
+ wt_iew_form_toggler.runToggler();
746
+
747
+ if(this.import_method == 'template'){
748
+ if( this.selected_template == 0){
749
+ $('.wt-iew-import-method-options-template').not('.wt-iew-import-template-sele-tr').hide();
750
+ }else{
751
+ $('.wt-iew-import-method-options-template').show();
752
+ }
753
+
754
+ }
755
+ }
756
+ else if(this.current_step=='advanced')
757
+ {
758
+ wt_iew_form_toggler.runToggler();
759
+ wt_field_group.Set();
760
+ }
761
+ else if(this.current_step=='mapping')
762
+ {
763
+ wt_iew_popover.Set();
764
+
765
+ if($('.meta_mapping_box_con').length>0)
766
+ {
767
+ if($('.meta_mapping_box_con[data-loaded="0"]').length>0)
768
+ {
769
+ this.load_meta_mapping_fields();
770
+ }
771
+ }
772
+ }
773
+ },
774
+ show_post_type_name:function()
775
+ {
776
+ if(this.to_import!="" && this.to_import_title=='')
777
+ {
778
+ $('[name="wt_iew_import_post_type"]').val(this.to_import);
779
+ this.to_import_title=$('[name="wt_iew_import_post_type"] option:selected').text();
780
+ }
781
+ $('.wt_iew_step_head_post_type_name').html(this.to_import_title);
782
+ if(this.to_import_title.includes('User'))
783
+ $('#user-required-field-message').show();
784
+ },
785
+ page_actions:function(step)
786
+ {
787
+ if(step=='post_type') /* post type page */
788
+ {
789
+ $('[name="wt_iew_import_post_type"]').unbind('change').change(function(){
790
+ wt_iew_basic_import.to_import=$(this).val();
791
+ wt_iew_basic_import.to_import_title='';
792
+ wt_iew_basic_import.reset_form_data();
793
+ $('.wt_iew_post_type_name').html('');
794
+ if(wt_iew_basic_import.to_import=='')
795
+ {
796
+ $('.wt_iew_post_type_wrn').show();
797
+ }else
798
+ {
799
+ $('.wt_iew_post_type_wrn').hide();
800
+ var post_type_name=$('[name="wt_iew_import_post_type"] option:selected').text();
801
+ /* $('.wt_iew_post_type_name').html(': '+post_type_name); */
802
+ wt_iew_basic_import.to_import_title=post_type_name;
803
+
804
+ /* load second step */
805
+ wt_iew_basic_import.set_step_loading_status([wt_iew_basic_import.step_keys[1]], 'not_loaded'); /* resetting status for force refresh */
806
+ wt_iew_basic_import.load_steps([wt_iew_basic_import.step_keys[1]]);
807
+ }
808
+ });
809
+ }
810
+ else if(step=='method_import') /* method import page */
811
+ {
812
+ this.import_method=$('[name="wt_iew_import_method_import"]:checked').val();
813
+ this.toggle_import_method_options();
814
+
815
+ $('[name="wt_iew_import_method_import"]').unbind('click').click(function(){
816
+ var vl=$(this).val();
817
+ if(wt_iew_basic_import.import_method==vl)
818
+ {
819
+ return false;
820
+ }
821
+ wt_iew_basic_import.reset_form_data();
822
+ wt_iew_basic_import.import_method=vl;
823
+ wt_iew_basic_import.refresh_step();
824
+ });
825
+
826
+ $('.wt-iew-import-template-sele').unbind('change').change(function(){
827
+ wt_iew_basic_import.selected_template=$(this).val();
828
+ wt_iew_basic_import.is_valid_file=false;
829
+ if(wt_iew_basic_import.selected_template==0)
830
+ {
831
+ wt_iew_notify_msg.error(wt_iew_import_basic_params.msgs.select_an_import_template);
832
+ }else
833
+ {
834
+ /* reset step loaded sataus */
835
+ wt_iew_basic_import.reset_step_loaded_state(wt_iew_basic_import.get_need_to_reload_steps());
836
+
837
+ wt_iew_basic_import.selected_template_name=$.trim($('.wt-iew-import-template-sele option:selected').text());
838
+ wt_iew_basic_import.refresh_step();
839
+ }
840
+ });
841
+
842
+
843
+ /* callback for external adapters */
844
+ if($('select[name="wt_iew_file_from"]').length>0) /* multiple adapter exists so select box */
845
+ {
846
+ this.file_from=$('[name="wt_iew_file_from"]').val();
847
+ $('[name="wt_iew_file_from"]').unbind('change').on('change',function(){
848
+ wt_iew_basic_import.file_from=$(this).val();
849
+ wt_iew_basic_import.is_valid_file=false;
850
+ wt_iew_set_file_from_fields(wt_iew_basic_import.file_from);
851
+ });
852
+ }else /* radio button */
853
+ {
854
+ this.file_from=$('[name="wt_iew_file_from"]:checked').val();
855
+ $('[name="wt_iew_file_from"]').on('click',function(){
856
+ wt_iew_basic_import.file_from=$('[name="wt_iew_file_from"]:checked').val();
857
+ wt_iew_basic_import.is_valid_file=false;
858
+ wt_iew_set_file_from_fields(wt_iew_basic_import.file_from);
859
+ });
860
+ }
861
+ wt_iew_set_file_from_fields(wt_iew_basic_import.file_from);
862
+
863
+ /* CSV delimiter form toggler. Custom and preset delimiter */
864
+ wt_iew_custom_and_preset.delimiter_toggler();
865
+
866
+ /* Input date format form toggler. Custom and preset date format */
867
+ wt_iew_custom_and_preset.date_format_toggler();
868
+
869
+ wt_iew_dropzone.init('wt_iew_local_file_dropzone');
870
+ /* Auto populate template file. */
871
+ wt_iew_dropzone.auto_populate();
872
+ }
873
+ else if(step=='mapping') /* mapping page */
874
+ {
875
+ this.enable_sortable();
876
+ this.mapping_box_accordian();
877
+ this.reg_mapping_field_bulk_action();
878
+ wt_iew_popover.Set();
879
+ }
880
+ else if(step=='advanced')
881
+ {
882
+
883
+ }
884
+
885
+ /* common events */
886
+ if($('.wt_iew_datepicker').length>0)
887
+ {
888
+ $('.wt_iew_datepicker').datepicker();
889
+ }
890
+ wt_field_group.Set();
891
+ wt_iew_form_toggler.Set();
892
+ wt_iew_conditional_help_text.Set(this.get_page_dom_object(step));
893
+ },
894
+ enable_sortable:function()
895
+ {
896
+ $('.meta_mapping_box_con[data-sortable="0"]').each(function(){
897
+ var tb=$(this).find(".wt-iew-mapping-tb tbody");
898
+ if(tb.length>0)
899
+ {
900
+ tb.sortable({
901
+ handle: ".wt_iew_sort_handle",
902
+ placeholder: "wt-iew-sortable-placeholder",
903
+ forcePlaceholderSize: true,
904
+ revert:true
905
+ });
906
+ $(this).attr('data-sortable', 1);
907
+ }
908
+ });
909
+ },
910
+ toggle_import_method_options:function()
911
+ {
912
+ $('.wt-iew-import-method-options').hide();
913
+ $('.wt-iew-import-method-options-'+this.import_method).show();
914
+ },
915
+ mapping_box_accordian:function()
916
+ {
917
+ $('.meta_mapping_box_hd').unbind('click').click(function()
918
+ {
919
+ /* if popover is opened */
920
+ wt_iew_popover.closePop();
921
+
922
+ var c_dv=$(this).parents('.meta_mapping_box').find('.meta_mapping_box_con');
923
+ if(c_dv.is(':visible'))
924
+ {
925
+ c_dv.hide();
926
+ $(this).find('.dashicons').removeClass('dashicons-arrow-down').addClass('dashicons-arrow-right');
927
+ }else
928
+ {
929
+ c_dv.show();
930
+ c_dv.find(".wt-iew-mapping-tb tbody tr td").each(function(){
931
+ $(this).css({'width':$(this).width()});
932
+ });
933
+ $(this).find('.dashicons').removeClass('dashicons-arrow-right').addClass('dashicons-arrow-down');
934
+ }
935
+ });
936
+ },
937
+ mapping_fields_selected_count:function(tb_elm)
938
+ {
939
+ tb_elm.parents('.meta_mapping_box').find('.meta_mapping_box_selected_count_box_num').text(tb_elm.find('.wt_iew_mapping_checkbox_sub:checked').length);
940
+ },
941
+ reg_mapping_field_bulk_action:function()
942
+ {
943
+ $('.wt_iew_mapping_checkbox_main').each(function()
944
+ {
945
+ var tb=$(this).parents('.wt-iew-mapping-tb');
946
+ if(tb.find('.wt_iew_mapping_checkbox_sub:checked').length==tb.find('.wt_iew_mapping_checkbox_sub').length)
947
+ {
948
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',true);
949
+ }else
950
+ {
951
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',false);
952
+ }
953
+ wt_iew_basic_import.mapping_fields_selected_count(tb);
954
+ });
955
+
956
+ $('.wt_iew_mapping_checkbox_main').unbind('click').click(function()
957
+ {
958
+ var tb=$(this).parents('.wt-iew-mapping-tb');
959
+ if($(this).is(':checked'))
960
+ {
961
+ tb.find('.wt_iew_mapping_checkbox_sub').prop('checked',true);
962
+ }else
963
+ {
964
+ tb.find('.wt_iew_mapping_checkbox_sub').prop('checked',false);
965
+ }
966
+ wt_iew_basic_import.mapping_fields_selected_count(tb);
967
+ });
968
+ $('.wt_iew_mapping_checkbox_sub').unbind('click').click(function()
969
+ {
970
+ var tb=$(this).parents('.wt-iew-mapping-tb');
971
+ if($(this).is(':checked') && tb.find('.wt_iew_mapping_checkbox_sub:checked').length==tb.find('.wt_iew_mapping_checkbox_sub').length)
972
+ {
973
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',true);
974
+ }else
975
+ {
976
+ tb.find('.wt_iew_mapping_checkbox_main').prop('checked',false);
977
+ }
978
+ wt_iew_basic_import.mapping_fields_selected_count(tb);
979
+ });
980
+ },
981
+ set_step_page:function(data)
982
+ {
983
+ page_html=data.page_html;
984
+ $.each(page_html, function(step_id, page_content){
985
+ wt_iew_basic_import.get_page_dom_object(step_id).html(page_content);
986
+ wt_iew_basic_import.page_actions(step_id);
987
+
988
+ if(step_id=='method_import' && (wt_iew_basic_import.selected_template>0 || wt_iew_basic_import.on_rerun))
989
+ {
990
+ wt_iew_basic_import.form_data=data.template_data;
991
+
992
+ if(wt_iew_basic_import.on_rerun)
993
+ {
994
+ if($('.wt-iew-import-template-sele').val()==0)
995
+ {
996
+ wt_iew_basic_import.selected_template=0;
997
+ wt_iew_basic_import.selected_template_name='';
998
+ }else
999
+ {
1000
+ wt_iew_basic_import.selected_template=$('.wt-iew-import-template-sele').val();
1001
+ wt_iew_basic_import.selected_template_name=$.trim($('.wt-iew-import-template-sele option:selected').text());
1002
+ }
1003
+ }
1004
+ }
1005
+ wt_iew_basic_import.show_post_type_name();
1006
+ });
1007
+ this.reg_button_actions();
1008
+ },
1009
+ prepare_ajax_data:function(action, data_type)
1010
+ {
1011
+ this.ajax_data = {
1012
+ '_wpnonce': wt_iew_basic_params.nonces.main,
1013
+ 'action': "iew_import_ajax_basic",
1014
+ 'import_action': action,
1015
+ 'selected_template': this.selected_template,
1016
+ 'to_import': this.to_import,
1017
+ 'data_type': data_type,
1018
+ 'import_method': this.import_method,
1019
+ 'temp_import_file': this.temp_import_file,
1020
+ };
1021
+
1022
+ if($('[name="wt_iew_delimiter"]').length>0){
1023
+ this.import_delimiter = $('[name="wt_iew_delimiter"]').val();
1024
+ this.ajax_data['delimiter'] = this.import_delimiter;
1025
+ }
1026
+
1027
+ },
1028
+ mapping_field_editor:function()
1029
+ {
1030
+ mapping_field_editor.Set();
1031
+ },
1032
+ mapping_field_editor_validate_column_val:function(vl)
1033
+ {
1034
+ return mapping_field_editor.validate_column_val(vl);
1035
+ },
1036
+ mapping_field_editor_output_preview:function()
1037
+ {
1038
+ mapping_field_editor.output_preview();
1039
+ },
1040
+ is_object:function(obj)
1041
+ {
1042
+ return obj !== undefined && obj !== null && obj.constructor == Object;
1043
+ }
1044
+ }
1045
+
1046
+ var mapping_field_editor=
1047
+ {
1048
+ text_area_pos:null,
1049
+ popover:null,
1050
+ Set:function()
1051
+ {
1052
+ this.popover=$('.wt_iew_popover-content');
1053
+ this.add_fields();
1054
+
1055
+ this.popover.find('.wt_iew_mapping_field_editor_expression').unbind('keyup').on('keyup', function(){
1056
+ mapping_field_editor.text_area_pos=$(this).getCursorPosition();
1057
+ mapping_field_editor.output_preview();
1058
+ });
1059
+
1060
+ this.search_column();
1061
+ },
1062
+ validate_columns:function()
1063
+ {
1064
+ $('.meta_mapping_box_con[data-field-validated="0"]').each(function(){
1065
+ var tb=$(this).find('.wt-iew-mapping-tb');
1066
+ if($(this).find('.wt-iew-mapping-tb').length>0)
1067
+ {
1068
+ $(this).attr({'data-field-validated':1});
1069
+ tb.find('.columns_val').each(function(){
1070
+ var vl=$.trim($(this).val());
1071
+ if(vl!="")
1072
+ {
1073
+ var html_vl=mapping_field_editor.validate_column_val(vl);
1074
+ $(this).siblings('[data-wt_iew_popover="1"]').html(html_vl);
1075
+ }
1076
+ });
1077
+ }
1078
+ });
1079
+ },
1080
+ validate_column_val:function(str)
1081
+ {
1082
+ const regex = /\{([^}]+)\}/g;
1083
+ let m;
1084
+ var out=str;
1085
+ while ((m = regex.exec(str)) !== null)
1086
+ {
1087
+ /* This is necessary to avoid infinite loops with zero-width matches */
1088
+ if (m.index === regex.lastIndex) {
1089
+ regex.lastIndex++;
1090
+ }
1091
+ /* The result can be accessed through the `m`-variable. */
1092
+ m.forEach((match, groupIndex) => {
1093
+
1094
+ /* check date format matching */
1095
+ var match_arr=match.split(wt_iew_import_basic_params.wt_iew_prefix+'@');
1096
+ if(match_arr.length==2)/* date format matched */
1097
+ {
1098
+ match=match_arr[0];
1099
+ }
1100
+
1101
+ if(!wt_iew_file_head_default.hasOwnProperty(match) && !wt_iew_file_head_meta.hasOwnProperty(match))
1102
+ {
1103
+ out=out.replace('{'+match+'}', '<span class="wt_iew_invalid_mapping_field">{'+match+'}</span>');
1104
+ }
1105
+ });
1106
+ }
1107
+ return out;
1108
+ },
1109
+ add_fields:function()
1110
+ {
1111
+ this.popover.find('.wt_iew_mapping_field_selector li').unbind('click').click(function(){
1112
+ var vl=' {'+$(this).attr('data-val')+'} ';
1113
+ var exp_vl=mapping_field_editor.popover.find('.wt_iew_mapping_field_editor_expression').val();
1114
+ if(mapping_field_editor.text_area_pos!==null)
1115
+ {
1116
+ var new_vl=exp_vl.substr(0, mapping_field_editor.text_area_pos)+vl+exp_vl.substr(mapping_field_editor.text_area_pos);
1117
+ }else
1118
+ {
1119
+ var new_vl=exp_vl+vl;
1120
+ }
1121
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_editor_expression').val(new_vl);
1122
+ mapping_field_editor.output_preview();
1123
+ })
1124
+ },
1125
+ search_column:function()
1126
+ {
1127
+ /* my template search */
1128
+ this.popover.find('.wt_iew_mapping_field_editor_column_search').unbind('keyup').on('keyup',function(){
1129
+ var vl=$.trim($(this).val());
1130
+ if(vl!="")
1131
+ {
1132
+ vl=vl.toLowerCase();
1133
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_selector li').hide();
1134
+ var kk=mapping_field_editor.popover.find('.wt_iew_mapping_field_selector li').filter(function(){
1135
+ var name=$(this).attr('data-val');
1136
+ name=name.toLowerCase();
1137
+ if(name.search(vl)!=-1)
1138
+ {
1139
+ return true;
1140
+ }else
1141
+ {
1142
+ return false;
1143
+ }
1144
+ });
1145
+ kk.show();
1146
+ if(mapping_field_editor.popover.find('.wt_iew_mapping_field_selector li:visible').length==0)
1147
+ {
1148
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_selector_no_column').show();
1149
+ }else
1150
+ {
1151
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_selector_no_column').hide();
1152
+ }
1153
+ }else
1154
+ {
1155
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_selector li').show();
1156
+ }
1157
+ });
1158
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_selector_no_column').hide();
1159
+ },
1160
+ output_preview:function()
1161
+ {
1162
+ this.popover.find('.wt_iew_mapping_field_editor_er').html('');
1163
+ const str = this.popover.find('.wt_iew_mapping_field_editor_expression').val();
1164
+ var out='';
1165
+ out=this.add_sample_data(str);
1166
+ out=this.do_arithmetic(out);
1167
+ this.popover.find('.wt_iew_mapping_field_editor_sample').html(out);
1168
+ },
1169
+ add_sample_data:function(str)
1170
+ {
1171
+ const regex = /\{([^}]+)\}/g;
1172
+
1173
+ let m;
1174
+ var out=str;
1175
+
1176
+ while ((m = regex.exec(str)) !== null) {
1177
+ /* This is necessary to avoid infinite loops with zero-width matches */
1178
+ if (m.index === regex.lastIndex) {
1179
+ regex.lastIndex++;
1180
+ }
1181
+ /* The result can be accessed through the `m`-variable. */
1182
+ m.forEach((match, groupIndex) => {
1183
+
1184
+ /* check date format matching */
1185
+ var match_arr=match.split(wt_iew_import_basic_params.wt_iew_prefix+'@');
1186
+ if(match_arr.length==2)/* date format matched */
1187
+ {
1188
+ match=match_arr[0];
1189
+ }
1190
+
1191
+ var sample_vl=' '; /* do not set default value as empty string */
1192
+ if(wt_iew_file_head_default.hasOwnProperty(match))
1193
+ {
1194
+ var sample_vl=$.trim(wt_iew_file_head_default[match]);
1195
+ }
1196
+ else if(wt_iew_file_head_meta.hasOwnProperty(match))
1197
+ {
1198
+ var sample_vl=$.trim(wt_iew_file_head_meta[match]);
1199
+ }
1200
+
1201
+ if(match_arr.length==2)/* date format matched */
1202
+ {
1203
+ match=match_arr.join(wt_iew_import_basic_params.wt_iew_prefix+'@');
1204
+ if(sample_vl!="")
1205
+ {
1206
+ sample_vl=mapping_field_editor.format_date(sample_vl);
1207
+ }
1208
+ }
1209
+
1210
+ sample_vl=(sample_vl!="" ? sample_vl : '<span class="wt_iew_no_sample_mapping_data">'+match+'</span>');
1211
+ out=out.replace('{'+match+'}', sample_vl);
1212
+ });
1213
+ }
1214
+ return out;
1215
+ },
1216
+ add_zero:function(i)
1217
+ {
1218
+ if(i<10)
1219
+ {
1220
+ i="0"+i;
1221
+ }
1222
+ return i;
1223
+ },
1224
+ format_date:function(date_string)
1225
+ {
1226
+ var d = new Date(date_string);
1227
+ if(d instanceof Date && !isNaN(d))
1228
+ {
1229
+ date_string=d.getFullYear()+'-'+this.add_zero(d.getMonth()+1)+'-'+this.add_zero(d.getDate())+' '+this.add_zero(d.getHours())+':'+this.add_zero(d.getMinutes())+':'+this.add_zero(d.getSeconds());
1230
+ }
1231
+ return date_string;
1232
+ },
1233
+ do_arithmetic:function(str)
1234
+ {
1235
+ const regex_arith = /\[([0-9()+\-*/. ]+)\]/g;
1236
+ let m;
1237
+ var out=str;
1238
+ while ((m = regex_arith.exec(str)) !== null) {
1239
+ /* This is necessary to avoid infinite loops with zero-width matches */
1240
+ if (m.index === regex_arith.lastIndex) {
1241
+ regex_arith.lastIndex++;
1242
+ }
1243
+ try{
1244
+ eqn='('+m[1]+')';
1245
+ eval("var eqn_eval = " + eqn.toLowerCase());
1246
+ out=out.replace(m[0], eqn_eval);
1247
+ } catch(e) {
1248
+ mapping_field_editor.popover.find('.wt_iew_mapping_field_editor_er').html(e);
1249
+ return false;
1250
+ }
1251
+ }
1252
+ return out;
1253
+ }
1254
+ }
1255
+
1256
+ return wt_iew_basic_import;
1257
+ })( jQuery );
1258
+
1259
+ (function ($, undefined) {
1260
+ $.fn.getCursorPosition = function() {
1261
+ var el = $(this).get(0);
1262
+ var pos = 0;
1263
+ if('selectionStart' in el) {
1264
+ pos = el.selectionStart;
1265
+ } else if('selection' in document) {
1266
+ el.focus();
1267
+ var Sel = document.selection.createRange();
1268
+ var SelLength = document.selection.createRange().text.length;
1269
+ Sel.moveStart('character', -el.value.length);
1270
+ pos = Sel.text.length - SelLength;
1271
+ }
1272
+ return pos;
1273
+ }
1274
+ })(jQuery);
1275
+
1276
+ /**
1277
+ * Dropzone initaiting section
1278
+ * More info at [www.dropzonejs.com](http://www.dropzonejs.com)
1279
+ */
1280
+ var wt_iew_dropzone=
1281
+ {
1282
+ elm:null,
1283
+ old_file:false,
1284
+ Set:function()
1285
+ {
1286
+ if(typeof Dropzone==='undefined'){
1287
+ return false;
1288
+ }
1289
+ Dropzone.autoDiscover = false;
1290
+ this.auto_populate();
1291
+ },
1292
+ auto_populate:function()
1293
+ {
1294
+ var template_val=jQuery.trim(jQuery('#local_file').val());
1295
+ if(template_val!="")
1296
+ {
1297
+ var file_name=template_val.split('/').pop();
1298
+ this.set_success(file_name);
1299
+ }
1300
+ },
1301
+ set_success:function(file_name)
1302
+ {
1303
+ jQuery(".wt_iew_dz_file_success").html(wt_iew_import_basic_params.msgs.upload_done);
1304
+ jQuery(".wt_iew_dz_remove_link").html(wt_iew_import_basic_params.msgs.remove);
1305
+ jQuery(".wt_iew_dz_file_name").html(file_name);
1306
+ jQuery(".dz-message").css({'margin-top':'60px'});
1307
+
1308
+ /* register file deleting event */
1309
+ wt_iew_dropzone.remove_file();
1310
+ },
1311
+ init:function(elm_id)
1312
+ {
1313
+ if(typeof Dropzone==='undefined'){
1314
+ return false;
1315
+ }
1316
+ this.elm=jQuery("#"+elm_id);
1317
+ var map_profile =jQuery('.wt-iew-import-template-sele').val();
1318
+ var ajax_data={
1319
+ '_wpnonce': wt_iew_basic_params.nonces.main,
1320
+ 'action': "iew_import_ajax_basic",
1321
+ 'import_action': 'upload_import_file',
1322
+ 'map_profile_id':map_profile,
1323
+ 'data_type': 'json',
1324
+ 'file_url': '',
1325
+ };
1326
+ var drop_zone_obj = new Dropzone(
1327
+ "#"+elm_id, {
1328
+ url:wt_iew_basic_params.ajax_url,
1329
+ createImageThumbnails:false,
1330
+ acceptedFiles:wt_iew_import_basic_params.allowed_import_file_type_mime.join(", "),
1331
+ paramName:'wt_iew_import_file',
1332
+ dictDefaultMessage:wt_iew_import_basic_params.msgs.drop_upload,
1333
+ dictInvalidFileType:wt_iew_import_basic_params.msgs.invalid_file,
1334
+ dictResponseError:wt_iew_import_basic_params.msgs.server_error,
1335
+ params:ajax_data,
1336
+ uploadMultiple:false,
1337
+ parallelUploads:1,
1338
+ maxFiles:1,
1339
+ maxFilesize:wt_iew_import_basic_params.max_import_file_size,
1340
+ previewTemplate:"<div class=\"dz-preview dz-file-preview\">\n <div class=\"dz-upload-info\"></div> \n <div class=\"dz-details\">\n <div class=\"dz-filename\"><span data-dz-name></span></div>\n </div>\n <div class=\"dz-progress\"><span class=\"dz-upload\" data-dz-uploadprogress></span></div>\n </div>",
1341
+ }
1342
+ );
1343
+
1344
+ drop_zone_obj.on("addedfile", function(file) {
1345
+ jQuery(".dz-upload-info").html(wt_iew_import_basic_params.msgs.uploading);
1346
+ jQuery(".dz-message").css({'margin-top':'85px'});
1347
+
1348
+ var dropzone_target=wt_iew_dropzone.elm.attr('wt_iew_dropzone_target');
1349
+ var dropzone_target_elm=jQuery(dropzone_target);
1350
+ if(dropzone_target_elm.length>0)
1351
+ {
1352
+ var file_url=dropzone_target_elm.val();
1353
+ if(file_url!="")
1354
+ {
1355
+ drop_zone_obj.options.params['file_url']=file_url; /* this is to remove the already uploaded file */
1356
+ }
1357
+ }
1358
+
1359
+ });
1360
+
1361
+ drop_zone_obj.on("dragstart", function(file) {
1362
+ wt_iew_dropzone.elm.addClass('wt_drag_start');
1363
+ });
1364
+
1365
+ drop_zone_obj.on("dragover", function(file) {
1366
+ wt_iew_dropzone.elm.addClass('wt_drag_start');
1367
+ });
1368
+
1369
+ drop_zone_obj.on("dragleave", function(file) {
1370
+ wt_iew_dropzone.elm.removeClass('wt_drag_start');
1371
+ });
1372
+
1373
+ drop_zone_obj.on("drop", function(file) {
1374
+ wt_iew_dropzone.elm.removeClass('wt_drag_start');
1375
+ });
1376
+
1377
+ drop_zone_obj.on("dragend", function(file) {
1378
+ wt_iew_dropzone.elm.removeClass('wt_drag_start');
1379
+ });
1380
+
1381
+ drop_zone_obj.on("fallback", function(file) {
1382
+ wt_iew_dropzone.elm.html(wt_iew_import_basic_params.msgs.outdated);
1383
+ return null;
1384
+ });
1385
+ drop_zone_obj.on("error", function(file, message) {
1386
+ drop_zone_obj.removeFile(file);
1387
+ wt_iew_notify_msg.error(message);
1388
+ });
1389
+
1390
+ drop_zone_obj.on("success", function(file, response) {
1391
+
1392
+ var file_name=file.name;
1393
+
1394
+ /* remove file obj */
1395
+ drop_zone_obj.removeFile(file);
1396
+
1397
+
1398
+ if(wt_iew_dropzone.isJson(response))
1399
+ {
1400
+ response=JSON.parse(response);
1401
+ if(response.status==1)
1402
+ {
1403
+ wt_iew_dropzone.set_success(file_name);
1404
+
1405
+ var dropzone_target=wt_iew_dropzone.elm.attr('wt_iew_dropzone_target');
1406
+ var dropzone_target_elm=jQuery(dropzone_target);
1407
+ if(dropzone_target_elm.length>0)
1408
+ {
1409
+ dropzone_target_elm.val(response.url);
1410
+
1411
+ }
1412
+ }else
1413
+ {
1414
+ wt_iew_notify_msg.error(response.msg);
1415
+ }
1416
+ }else
1417
+ {
1418
+ wt_iew_notify_msg.error(wt_iew_basic_params.msgs.error);
1419
+ }
1420
+ });
1421
+ },
1422
+ remove_file:function()
1423
+ {
1424
+ jQuery('.wt_iew_dz_remove_link').unbind('click').click(function(e){
1425
+ e.stopPropagation();
1426
+
1427
+ var dropzone_target=wt_iew_dropzone.elm.attr('wt_iew_dropzone_target');
1428
+ var mapping_profile =jQuery('.wt-iew-import-template-sele').val();
1429
+ var dropzone_target_elm=jQuery(dropzone_target);
1430
+ if(dropzone_target_elm.length>0)
1431
+ {
1432
+ var file_url=dropzone_target_elm.val();
1433
+ if(file_url!="")
1434
+ {
1435
+ dropzone_target_elm.val('');
1436
+ jQuery(".wt_iew_dz_file_success, .wt_iew_dz_remove_link, .wt_iew_dz_file_name").html('');
1437
+ jQuery(".dz-message").css({'margin-top':'85px'});
1438
+
1439
+ jQuery.ajax({
1440
+ type: 'POST',
1441
+ url:wt_iew_basic_params.ajax_url,
1442
+ data:{
1443
+ '_wpnonce': wt_iew_basic_params.nonces.main,
1444
+ 'action': "iew_import_ajax_basic",
1445
+ 'import_action': 'delete_import_file',
1446
+ 'mapping_profile': mapping_profile,
1447
+ 'data_type': 'json',
1448
+ 'file_url':file_url,
1449
+ },
1450
+ dataType:'json'
1451
+
1452
+ });
1453
+ }
1454
+ }
1455
+ });
1456
+ },
1457
+ isJson:function(str)
1458
+ {
1459
+ try {
1460
+ JSON.parse(str);
1461
+ } catch (e) {
1462
+ return false;
1463
+ }
1464
+ return true;
1465
+ }
1466
+ }
1467
+ wt_iew_dropzone.Set();
1468
+
1469
+
1470
+ jQuery(function() {
1471
+
1472
+ if(wt_iew_import_basic_params.rerun_id>0)
1473
+ {
1474
+ wt_iew_basic_import.to_import=wt_iew_import_basic_params.to_import;
1475
+ wt_iew_basic_import.import_method=wt_iew_import_basic_params.import_method;
1476
+ wt_iew_basic_import.rerun_id=wt_iew_import_basic_params.rerun_id;
1477
+ wt_iew_basic_import.on_rerun=true;
1478
+ wt_iew_basic_import.is_valid_file=true;
1479
+ wt_iew_basic_import.temp_import_file=wt_iew_import_basic_params.temp_import_file;
1480
+ }
1481
+ wt_iew_basic_import.Set();
1482
+ });
admin/modules/import/classes/class-import-ajax.php ADDED
@@ -0,0 +1,1209 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Ajax section of the Import module
4
+ *
5
+ *
6
+ * @package Wt_Import_Export_For_Woo
7
+ */
8
+ if (!defined('ABSPATH')) {
9
+ exit;
10
+ }
11
+
12
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Import_Ajax')){
13
+ class Wt_Import_Export_For_Woo_Basic_Import_Ajax
14
+ {
15
+ public $step='';
16
+ public $steps=array();
17
+ public $step_btns=array();
18
+ public $import_method='';
19
+ public $to_import='';
20
+
21
+ protected $step_title='';
22
+ protected $step_keys=array();
23
+ protected $current_step_index=0;
24
+ protected $current_step_number=1;
25
+ protected $last_page=false;
26
+ protected $total_steps=0;
27
+ protected $step_summary='';
28
+ protected $step_description='';
29
+ protected $mapping_enabled_fields=array();
30
+ protected $mapping_templates=array();
31
+ protected $selected_template=0;
32
+ protected $selected_template_form_data=array();
33
+ protected $import_obj=null;
34
+ protected $field_group_prefixes=array();
35
+ protected $rerun_id=0;
36
+
37
+ public function __construct($import_obj, $to_import, $steps, $import_method, $selected_template, $rerun_id)
38
+ {
39
+ $this->import_obj=$import_obj;
40
+ $this->to_import=$to_import;
41
+ $this->steps=$steps;
42
+ $this->import_method=$import_method;
43
+ $this->selected_template=$selected_template;
44
+ $this->rerun_id=$rerun_id;
45
+
46
+ /**
47
+ * This array is to group the fields in the input file that are not in the default list.
48
+ */
49
+ $this->field_group_prefixes=array(
50
+ 'taxonomies'=>array('tax'),
51
+ 'meta'=>array('meta'),
52
+ 'attributes'=>array('attribute', 'attribute_data', 'attribute_default', 'meta:attribute'),
53
+ 'hidden_meta'=>array('meta:_'),
54
+ );
55
+ }
56
+
57
+ /**
58
+ * Ajax main function to retrive steps HTML
59
+ */
60
+ public function get_steps($out)
61
+ {
62
+ //sleep(3);
63
+ $steps=(is_array($_POST['steps']) ? $_POST['steps'] : array($_POST['steps']));
64
+ $steps=Wt_Iew_Sh::sanitize_item($steps, 'text_arr');
65
+ $page_html=array();
66
+
67
+ if($this->selected_template>0) /* taking selected tamplate formdata */
68
+ {
69
+ $this->get_template_form_data($this->selected_template);
70
+
71
+ }elseif($this->rerun_id>0)
72
+ {
73
+ $this->selected_template_form_data=$this->import_obj->form_data;
74
+ }
75
+
76
+ foreach($steps as $step)
77
+ {
78
+ $method_name=$step.'_page';
79
+ if(method_exists($this, $method_name))
80
+ {
81
+ $page_html[$step]=$this->{$method_name}();
82
+
83
+ if($step=='method_import' && ($this->selected_template>0 || $this->rerun_id>0))
84
+ {
85
+ $out['template_data']=$this->selected_template_form_data;
86
+ }
87
+ }
88
+ }
89
+ $out['status']=1;
90
+ $out['page_html']=$page_html;
91
+ return $out;
92
+ }
93
+
94
+ /**
95
+ * Delete uploaded import file
96
+ *
97
+ */
98
+ public function delete_import_file($out)
99
+ {
100
+ $file_url=(isset($_POST['file_url']) ? esc_url_raw($_POST['file_url']) : '');
101
+ $mapping_profile=(isset($_POST['mapping_profile']) ? ($_POST['mapping_profile']) : '');
102
+ $out['file_url']=$file_url;
103
+ if($file_url!="")
104
+ {
105
+ if(!$mapping_profile){
106
+ $this->import_obj->delete_import_file($file_url);
107
+ }
108
+ $out['status']=1;
109
+ $out['msg']='';
110
+ }
111
+ return $out;
112
+ }
113
+
114
+ /**
115
+ * Upload import file (Drag and drop upload)
116
+ *
117
+ */
118
+ public function upload_import_file($out)
119
+ {
120
+ if(isset($_FILES['wt_iew_import_file']))
121
+ {
122
+
123
+ $is_file_type_allowed=false;
124
+ if(!in_array($_FILES['wt_iew_import_file']['type'], $this->import_obj->allowed_import_file_type_mime)) /* Not allowed file type. [Bug fix for Windows OS]Then verify it again with file extension */
125
+ {
126
+ $ext=pathinfo($_FILES['wt_iew_import_file']['name'], PATHINFO_EXTENSION);
127
+ if(isset($this->import_obj->allowed_import_file_type_mime[$ext])) /* extension exists. */
128
+ {
129
+ $is_file_type_allowed=true;
130
+ }
131
+ }else
132
+ {
133
+ $is_file_type_allowed=true;
134
+ }
135
+
136
+ if($is_file_type_allowed) /* Allowed file type */
137
+ {
138
+
139
+ @set_time_limit(3600); // 1 hour
140
+
141
+ $max_bytes=($this->import_obj->max_import_file_size*1000000); //convert to bytes
142
+ if($max_bytes>=$_FILES['wt_iew_import_file']['size'])
143
+ {
144
+ $file_name='local_file_'.time().'_'.sanitize_file_name($_FILES['wt_iew_import_file']['name']); //sanitize the file name, add a timestamp prefix to avoid conflict
145
+ $file_path=$this->import_obj->get_file_path($file_name);
146
+ // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged
147
+ if(@move_uploaded_file($_FILES['wt_iew_import_file']['tmp_name'], $file_path))
148
+ {
149
+ $out['msg']='';
150
+ $out['status']=1;
151
+ $out['url']=$this->import_obj->get_file_url($file_name);
152
+
153
+ /**
154
+ * Check old file exists, and delete it
155
+ */
156
+ $file_url=(isset($_POST['file_url']) ? esc_url_raw($_POST['file_url']) : '');
157
+ $map_profile_id=(isset($_POST['map_profile_id']) ? ($_POST['map_profile_id']) : '');
158
+ if($file_url!="" && !$map_profile_id)
159
+ {
160
+ $this->import_obj->delete_import_file($file_url);
161
+ }
162
+ }else
163
+ {
164
+ $out['msg']=__('Unable to upload file. Please check write permission of your `wp-content` folder.');
165
+ }
166
+ }else
167
+ {
168
+ $out['msg']=sprintf(__('File size exceeds the limit. %dMB max'), $this->import_obj->max_import_file_size);
169
+ }
170
+ }else
171
+ {
172
+ $out['msg']=sprintf(__('Invalid file type. Only %s are allowed.'), implode(", ", array_values($this->import_obj->allowed_import_file_type)));
173
+ }
174
+ }
175
+
176
+ return $out;
177
+ }
178
+
179
+ /**
180
+ * Ajax hook to download the input file as temp file and validate its extension.
181
+ */
182
+ public function validate_file($out)
183
+ {
184
+ /* process form data */
185
+ $form_data=(isset($_POST['form_data']) ? Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize(($_POST['form_data']))) : array());
186
+ $response=$this->import_obj->download_remote_file($form_data);
187
+
188
+ if($response['response']) /* temp file created. Then delete old temp file if exists */
189
+ {
190
+ $temp_import_file=(isset($_POST['temp_import_file']) ? sanitize_file_name($_POST['temp_import_file']) : '');
191
+ if($temp_import_file!="")
192
+ {
193
+ $file_path=$this->import_obj->get_file_path($temp_import_file);
194
+ if(file_exists($file_path))
195
+ {
196
+ @unlink($file_path);
197
+ }
198
+ }
199
+ }
200
+
201
+ $out['status']=($response['response'] ? 1 : 0);
202
+ $out['msg']=($response['msg']!="" ? $response['msg'] : $out['msg']);
203
+ $out['file_name']=(isset($response['file_name']) ? $response['file_name'] : '');
204
+
205
+ return $out;
206
+ }
207
+
208
+ /**
209
+ * Ajax function to retrive meta step data
210
+ */
211
+ public function get_meta_mapping_fields($out)
212
+ {
213
+ if($this->selected_template>0) /* taking selected tamplate formdata */
214
+ {
215
+ $this->get_template_form_data($this->selected_template);
216
+
217
+ }elseif($this->rerun_id>0)
218
+ {
219
+ $this->selected_template_form_data=$this->import_obj->form_data;
220
+ }
221
+
222
+ /* This is the sample data from input file */
223
+ $file_heading_meta_fields=(isset($_POST['file_head_meta']) ? json_decode(stripslashes($_POST['file_head_meta']), true) : array());
224
+
225
+ //taking current page form data
226
+ $meta_step_form_data=(isset($this->selected_template_form_data['meta_step_form_data']) ? $this->selected_template_form_data['meta_step_form_data'] : array());
227
+
228
+ /* formdata/template data of fields in mapping page */
229
+ $form_data_meta_mapping_fields=isset($meta_step_form_data['mapping_fields']) ? $meta_step_form_data['mapping_fields'] : array();
230
+
231
+
232
+ $meta_mapping_screen_fields=$this->_get_meta_mapping_screen_fields($form_data_meta_mapping_fields);
233
+
234
+ $draggable_tooltip=__("Drag to rearrange the columns");
235
+ $module_url=plugin_dir_url(dirname(__FILE__));
236
+
237
+
238
+ /* preparing meta fields. */
239
+ $prepared_meta_fields=array();
240
+ if($meta_mapping_screen_fields && is_array($meta_mapping_screen_fields))
241
+ {
242
+ /* loop through mapping fields */
243
+ foreach($meta_mapping_screen_fields as $meta_mapping_screen_field_key=>$meta_mapping_screen_field_val)
244
+ {
245
+ /* decalaring an empty array*/
246
+ $temp_arr=array();
247
+
248
+ /* current field group(tax, meta) formdata */
249
+ $current_meta_step_form_data=(isset($form_data_meta_mapping_fields[$meta_mapping_screen_field_key]) ? $form_data_meta_mapping_fields[$meta_mapping_screen_field_key] : array());
250
+
251
+ /* default field list from post type module */
252
+ $mapping_fields=((isset($meta_mapping_screen_field_val['fields']) && is_array($meta_mapping_screen_field_val['fields'])) ? $meta_mapping_screen_field_val['fields'] : array());
253
+
254
+ /* loop through form data */
255
+ foreach($current_meta_step_form_data as $key=>$val_arr) /* looping the template form data */
256
+ {
257
+ $val=$val_arr[0]; /* normal column val */
258
+ $checked=$val_arr[1]; /* import this column? */
259
+
260
+ if(isset($mapping_fields[$key])) /* found in default field list */
261
+ {
262
+ $label=(isset($mapping_fields[$key]['title']) ? $mapping_fields[$key]['title'] : '');
263
+ $description=(isset($mapping_fields[$key]['description']) ? $mapping_fields[$key]['title'] : '');
264
+ $type=(isset($mapping_fields[$key]['type']) ? $mapping_fields[$key]['type'] : '');
265
+ unset($mapping_fields[$key]); //remove the field from default list
266
+
267
+ if(isset($file_heading_meta_fields[$key])) /* also found in file heading list */
268
+ {
269
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
270
+ }
271
+ $temp_arr[$key]=array('label'=>$label, 'description'=>$description, 'val'=>$val, 'checked'=>$checked, 'type'=>$type);
272
+ }
273
+ elseif(isset($file_heading_meta_fields[$key])) /* found in file heading list */
274
+ {
275
+ $label=$key;
276
+ $description=$this->prepare_field_description($key);
277
+ $type='';
278
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
279
+ $temp_arr[$key]=array('label'=>$label, 'description'=>$description, 'val'=>$val, 'checked'=>$checked, 'type'=>$type);
280
+ }
281
+ }
282
+
283
+ /* loop through mapping fields */
284
+ if(count($mapping_fields)>0)
285
+ {
286
+ foreach($mapping_fields as $key=>$val_arr)
287
+ {
288
+ $label=(isset($val_arr['title']) ? $val_arr['title'] : '');
289
+ $description=(isset($val_arr['description']) ? $val_arr['description'] : '');
290
+ $type=(isset($val_arr['type']) ? $val_arr['type'] : '');
291
+ $val='';
292
+ $checked=0; /* import this column? */
293
+ if(isset($file_heading_meta_fields[$key]))
294
+ {
295
+ $checked=1; /* import this column? */
296
+ $val='{'.$key.'}';
297
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
298
+ }
299
+ $temp_arr[$key]=array('label'=>$label, 'description'=>$description, 'val'=>$val, 'checked'=>$checked, 'type'=>$type);
300
+ }
301
+ }
302
+
303
+ if(count($file_heading_meta_fields)>0)
304
+ {
305
+ $current_field_group_prefix_arr=(isset($this->field_group_prefixes[$meta_mapping_screen_field_key]) ? $this->field_group_prefixes[$meta_mapping_screen_field_key] : array());
306
+ foreach($file_heading_meta_fields as $key=>$sample_val)
307
+ {
308
+ $is_include=$this->_is_include_meta_in_this_group($current_field_group_prefix_arr, $key);
309
+ if($is_include==1)
310
+ {
311
+ $label=Wt_Iew_Sh::sanitize_item($key);
312
+ $description=$this->prepare_field_description($key);
313
+ $type='';
314
+ $val='{'.$key.'}';
315
+ $checked=1; /* import this column? */
316
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
317
+ $temp_arr[$key]=array('label'=>$label, 'description'=>$description, 'val'=>$val, 'checked'=>$checked, 'type'=>$type);
318
+ }
319
+ }
320
+ }
321
+
322
+ /* adding value to main array */
323
+ $prepared_meta_fields[$meta_mapping_screen_field_key]=array('fields'=>$temp_arr, 'checked'=>(isset($meta_mapping_screen_field_val['checked']) && $meta_mapping_screen_field_val['checked']==1 ? 1 : 0) );
324
+ }
325
+
326
+ /* if any columns that not in the above list */
327
+ if(count($file_heading_meta_fields)>0)
328
+ {
329
+ //do something
330
+ }
331
+ }
332
+
333
+ /* prepare HTML for meta mapping step */
334
+ $meta_html=array();
335
+
336
+ /* loop through prepared meta fields */
337
+ foreach($prepared_meta_fields as $meta_mapping_screen_field_key=>$meta_mapping_screen_field_val)
338
+ {
339
+ ob_start();
340
+ include dirname(plugin_dir_path(__FILE__)).'/views/_import_meta_step_page.php';
341
+ $meta_html[$meta_mapping_screen_field_key]=ob_get_clean();
342
+ }
343
+
344
+ $out['status']=1;
345
+ $out['meta_html']=$meta_html;
346
+ return $out;
347
+ }
348
+
349
+ public function save_template($out)
350
+ {
351
+ return $this->do_save_template('save', $out);
352
+ }
353
+
354
+ public function save_template_as($out)
355
+ {
356
+ return $this->do_save_template('save_as', $out);
357
+ }
358
+
359
+ public function update_template($out)
360
+ {
361
+ return $this->do_save_template('update', $out);
362
+ }
363
+
364
+ /**
365
+ * Download the input file and create history entry.
366
+ * This is the primary step before Import
367
+ * On XML import the file will be converted to CSV (Batch processing)
368
+ */
369
+ public function download($out)
370
+ {
371
+ $this->import_obj->temp_import_file=(isset($_POST['temp_import_file']) ? sanitize_file_name($_POST['temp_import_file']) : '');
372
+
373
+ $offset=(isset($_POST['offset']) ? floatval($_POST['offset']) : 0);
374
+ $import_id=(isset($_POST['import_id']) ? intval($_POST['import_id']) : 0);
375
+ $import_method=(isset($_POST['import_method']) ? sanitize_text_field($_POST['import_method']) : $this->import_obj->default_import_method);
376
+
377
+ if($offset==0)
378
+ {
379
+ /* process form data */
380
+ $form_data=(isset($_POST['form_data']) ? Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize(($_POST['form_data']))) : array());
381
+
382
+ //sanitize form data
383
+ $form_data=Wt_Iew_IE_Basic_Helper::sanitize_formdata($form_data, $this->import_obj);
384
+ }else
385
+ {
386
+ /* no need to process the formdata steps other than first */
387
+ $form_data=array();
388
+ }
389
+
390
+ $out=$this->import_obj->process_download($form_data, 'download', $this->to_import, $import_id, $offset);
391
+ if($out['response']===true)
392
+ {
393
+ $import_id=$out['import_id'];
394
+
395
+ /**
396
+ * Prepare default mapping data for quick import
397
+ * After preparing update the Formdata in history table
398
+ */
399
+ if($import_method=='quick' && $import_id>0 && $out['finished']==3)
400
+ {
401
+ $this->_prepare_for_quick($import_id);
402
+ }
403
+
404
+
405
+ $out['status']=1;
406
+ }else
407
+ {
408
+ $out['status']=0;
409
+ }
410
+ return $out;
411
+ }
412
+
413
+ /**
414
+ * Process the import
415
+ *
416
+ * @return array
417
+ */
418
+ public function import($out)
419
+ {
420
+ $offset=(isset($_POST['offset']) ? floatval($_POST['offset']) : 0);
421
+ $import_id=(isset($_POST['import_id']) ? intval($_POST['import_id']) : 0);
422
+
423
+ /* no need to send formdata. It will take from history table by `process_action` method */
424
+ $form_data=array();
425
+
426
+ /* do the export process */
427
+ $out=$this->import_obj->process_action($form_data, 'import', $this->to_import, '', $import_id, $offset);
428
+ if($out['response']===true)
429
+ {
430
+ $out['status']=1;
431
+ }else
432
+ {
433
+ $out['status']=0;
434
+ }
435
+ return $out;
436
+ }
437
+
438
+ /**
439
+ * Save/Update template (Ajax sub function)
440
+ * @param boolean $is_update is update existing template or save as new
441
+ * @return array response status, name, id
442
+ */
443
+ public function do_save_template($step, $out)
444
+ {
445
+ $is_update=($step=='update' ? true : false);
446
+
447
+ /* take template name from post data, if not then create from time stamp */
448
+ $template_name=(isset($_POST['template_name']) ? sanitize_text_field($_POST['template_name']) : date('d-M-Y h:i:s A'));
449
+
450
+ $template_name = stripslashes($template_name);
451
+ $out['name']= $template_name;
452
+ $out['id']=0;
453
+ $out['status']=1;
454
+
455
+ if($this->to_import!='')
456
+ {
457
+ global $wpdb;
458
+
459
+ /* checking: just saved and again click the button so shift the action as update */
460
+ if($step=='save' && $this->selected_template>0)
461
+ {
462
+ $is_update=true;
463
+ }
464
+
465
+ /* checking template with same name exists */
466
+ $template_data=$this->get_mapping_template_by_name($template_name);
467
+ if($template_data)
468
+ {
469
+ $is_throw_warn=false;
470
+ if($is_update)
471
+ {
472
+ if($template_data['id']!=$this->selected_template)
473
+ {
474
+ $is_throw_warn=true;
475
+ }
476
+ }else
477
+ {
478
+ $is_throw_warn=true;
479
+ }
480
+
481
+ if($is_throw_warn)
482
+ {
483
+ $out['status']=0;
484
+ if($step=='save_as')
485
+ {
486
+ $out['msg']=__('Please enter a different name');
487
+ }else
488
+ {
489
+ $out['msg']=__('Template with same name already exists');
490
+ }
491
+ return $out;
492
+ }
493
+ }
494
+
495
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
496
+
497
+ /* process form data */
498
+ $form_data=(isset($_POST['form_data']) ? Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize(($_POST['form_data']))) : array());
499
+
500
+ //sanitize form data
501
+ $form_data=Wt_Iew_IE_Basic_Helper::sanitize_formdata($form_data, $this->import_obj);
502
+
503
+ /* upadte the template */
504
+ if($is_update)
505
+ {
506
+
507
+ $update_data=array(
508
+ 'data'=>maybe_serialize($form_data),
509
+ 'name'=>$template_name, //may be a rename
510
+ );
511
+ $update_data_type=array(
512
+ '%s',
513
+ '%s'
514
+ );
515
+ $update_where=array(
516
+ 'id'=>$this->selected_template
517
+ );
518
+ $update_where_type=array(
519
+ '%d'
520
+ );
521
+ if($wpdb->update($tb, $update_data, $update_where, $update_data_type, $update_where_type)!==false)
522
+ {
523
+ $out['id']=$this->selected_template;
524
+ $out['name']=$template_name;
525
+ $out['msg']=__('Template updated successfully');
526
+ return $out;
527
+ }
528
+ }else
529
+ {
530
+ $insert_data=array(
531
+ 'template_type'=>'import',
532
+ 'item_type'=>$this->to_import,
533
+ 'name'=>$template_name,
534
+ 'data'=>maybe_serialize($form_data),
535
+ );
536
+ $insert_data_type=array(
537
+ '%s','%s','%s','%s'
538
+ );
539
+ if($wpdb->insert($tb, $insert_data, $insert_data_type)) //success
540
+ {
541
+ $out['id']=$wpdb->insert_id;
542
+ $out['msg']=__('Template saved successfully');
543
+ return $out;
544
+ }
545
+ }
546
+ }
547
+ $out['status']=0;
548
+ return $out;
549
+ }
550
+
551
+
552
+ /*
553
+ * Get step information
554
+ * @param string $step
555
+ */
556
+
557
+ public function get_step_info( $step ) {
558
+ return isset( $this->steps[ $step ] ) ? $this->steps[ $step ] : array( 'title' => ' ', 'description' => ' ' );
559
+ }
560
+ /**
561
+ * Step 1 (Ajax sub function)
562
+ * Built in steps, post type choosing page
563
+ */
564
+ public function post_type_page()
565
+ {
566
+ $post_types=apply_filters('wt_iew_importer_post_types_basic', array());
567
+ $post_types=(!is_array($post_types) ? array() : $post_types);
568
+ $this->step='post_type';
569
+
570
+ $this->prepare_step_summary();
571
+ $this->prepare_footer_button_list();
572
+
573
+ ob_start();
574
+ $this->prepare_step_header_html();
575
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_import_post_type_page.php';
576
+ $this->prepare_step_footer_html();
577
+ return ob_get_clean();
578
+ }
579
+
580
+ /**
581
+ * Step 2 (Ajax sub function)
582
+ * Built in steps, import method choosing page
583
+ */
584
+ public function method_import_page()
585
+ {
586
+ $this->step='method_import';
587
+ if($this->to_import!="")
588
+ {
589
+ /* setting a default import method */
590
+ $this->import_method=($this->import_method=='' ? $this->import_obj->default_import_method : $this->import_method);
591
+ $this->import_obj->import_method=$this->import_method;
592
+ $this->steps=$this->import_obj->get_steps();
593
+
594
+ $this->prepare_step_summary();
595
+ $this->prepare_footer_button_list();
596
+
597
+ //taking current page form data
598
+ $method_import_form_data=(isset($this->selected_template_form_data['method_import_form_data']) ? $this->selected_template_form_data['method_import_form_data'] : array());
599
+
600
+ $method_import_screen_fields=$this->import_obj->get_method_import_screen_fields($method_import_form_data);
601
+
602
+
603
+ $form_data_import_template=$this->selected_template;
604
+ if($this->rerun_id>0)
605
+ {
606
+ if(isset($method_import_form_data['selected_template']))
607
+ {
608
+ /* do not set this value to `$this->selected_template` */
609
+ $form_data_import_template=$method_import_form_data['selected_template'];
610
+ }
611
+ }
612
+
613
+ /* meta field list for quick import */
614
+ $this->get_mapping_templates();
615
+
616
+ ob_start();
617
+ $this->prepare_step_header_html();
618
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_import_method_import_page.php';
619
+ $this->prepare_step_footer_html();
620
+ return ob_get_clean();
621
+ }else
622
+ {
623
+ return '';
624
+ }
625
+ }
626
+
627
+ /**
628
+ * Step 3 (Ajax sub function)
629
+ * Built in steps, Import mapping page
630
+ */
631
+ public function mapping_page()
632
+ {
633
+ $this->step='mapping';
634
+ if($this->to_import!="")
635
+ {
636
+ $this->prepare_step_summary();
637
+ $this->prepare_footer_button_list();
638
+
639
+
640
+ $temp_import_file=(isset($_POST['temp_import_file']) ? sanitize_file_name($_POST['temp_import_file']) : '');
641
+ $file_path=$this->import_obj->get_file_path($temp_import_file);
642
+ if($temp_import_file!="" && file_exists($file_path))
643
+ {
644
+ $ext_arr=explode('.', $temp_import_file);
645
+ $ext= strtolower(end($ext_arr));
646
+ if(isset($this->import_obj->allowed_import_file_type[$ext])) /* file type is in allowed list */
647
+ {
648
+
649
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-csvreader.php';
650
+ $delimiter=(isset($_POST['delimiter']) ? ($_POST['delimiter']) : ','); //no sanitization
651
+ $reader=new Wt_Import_Export_For_Woo_Basic_Csvreader($delimiter);
652
+
653
+
654
+ /* take first two rows in csv and in xml takes column keys and a sample data */
655
+ $sample_data=$reader->get_sample_data($file_path, true);
656
+
657
+ $file_heading_data=$this->process_file_heading_data($sample_data);
658
+ $file_heading_default_fields=$file_heading_data['default'];
659
+ $file_heading_meta_fields=$file_heading_data['meta'];
660
+
661
+
662
+ //taking current page form data
663
+ $mapping_form_data=(isset($this->selected_template_form_data['mapping_form_data']) ? $this->selected_template_form_data['mapping_form_data'] : array());
664
+
665
+ /* formdata/template data of fields in mapping page */
666
+ $form_data_mapping_fields=isset($mapping_form_data['mapping_fields']) ? $mapping_form_data['mapping_fields'] : array();
667
+
668
+ /**
669
+ * default mapping page fields
670
+ * Format: 'field_key'=>array('title'=>'', 'description'=>'')
671
+ */
672
+ $mapping_fields=array();
673
+ $mapping_fields=apply_filters('wt_iew_importer_alter_mapping_fields_basic', $mapping_fields, $this->to_import, $form_data_mapping_fields);
674
+
675
+ /* meta fields list */
676
+ $this->get_mapping_enabled_fields();
677
+
678
+ /* mapping enabled meta fields */
679
+ $form_data_mapping_enabled_fields=(isset($mapping_form_data['mapping_enabled_fields']) ? $mapping_form_data['mapping_enabled_fields'] : array());
680
+ }
681
+ }
682
+
683
+ ob_start();
684
+ $this->prepare_step_header_html();
685
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_import_mapping_page.php';
686
+ $this->prepare_step_footer_html();
687
+ return ob_get_clean();
688
+
689
+ }else
690
+ {
691
+ return '';
692
+ }
693
+ }
694
+
695
+ /**
696
+ * Step 4 (Ajax sub function)
697
+ * Built in steps, Advanced settings page
698
+ */
699
+ public function advanced_page()
700
+ {
701
+ $this->step='advanced';
702
+ if($this->to_import!="")
703
+ {
704
+ $this->prepare_step_summary();
705
+ $this->prepare_footer_button_list();
706
+
707
+ //taking current page form data
708
+ $advanced_form_data=(isset($this->selected_template_form_data['advanced_form_data']) ? $this->selected_template_form_data['advanced_form_data'] : array());
709
+
710
+ $advanced_screen_fields=$this->import_obj->get_advanced_screen_fields($advanced_form_data);
711
+
712
+ ob_start();
713
+ $this->prepare_step_header_html();
714
+ include_once dirname(plugin_dir_path(__FILE__)).'/views/_import_advanced_page.php';
715
+ $this->prepare_step_footer_html();
716
+ return ob_get_clean();
717
+
718
+ }else
719
+ {
720
+ return '';
721
+ }
722
+ }
723
+
724
+ /**
725
+ * Prepare description for mapping step fields
726
+ */
727
+ protected function prepare_field_description($key)
728
+ {
729
+ $out='';
730
+ if(strpos($key, 'tax:')!==false) /* taxonomy */
731
+ {
732
+ $column=trim(str_replace('tax:', '', $key));
733
+ if(substr($column, 0, 3)!== 'pa_')
734
+ {
735
+ $out=__('Product taxonomies');
736
+ }else
737
+ {
738
+ $out=__('New taxonomy: ').$column;
739
+ }
740
+ }
741
+ elseif(strpos($key, 'meta:')!==false) /* meta */
742
+ {
743
+ $column=trim(str_replace('meta:', '', $key));
744
+ $out=__('Custom Field: ').$column;
745
+ }
746
+ elseif(strpos($key, 'attribute:')!==false) /* attribute */
747
+ {
748
+ $column=trim(str_replace('attribute:', '', $key));
749
+ if(substr($column, 0, 3)== 'pa_')
750
+ {
751
+ $out=__('Taxonomy attributes');
752
+ }else
753
+ {
754
+ $out=__('New attribute: ').$column;
755
+ }
756
+ }
757
+ elseif(strpos($key, 'attribute_data:')!==false) /* attribute data */
758
+ {
759
+ $column=trim(str_replace('attribute_data:', '', $key));
760
+ $out=__('Attribute data: ').$column;
761
+ }
762
+ elseif(strpos($key, 'attribute_default:')!==false) /* attribute default */
763
+ {
764
+ $column=trim(str_replace('attribute_default:', '', $key));
765
+ $out=__('Attribute default value: ').$column;
766
+ }
767
+ return $out;
768
+ }
769
+
770
+ /**
771
+ * split default mapping fields and meta mapping fields
772
+ */
773
+ protected function process_file_heading_data($arr)
774
+ {
775
+ $default=array();
776
+ $meta=array();
777
+ foreach($arr as $key=>$v)
778
+ {
779
+ if(is_array($v))
780
+ {
781
+ $meta=array_merge($meta, $v);
782
+ }else
783
+ {
784
+ $default[$key]=$v;
785
+ }
786
+ }
787
+ return array('default'=>$default, 'meta'=>$meta);
788
+ }
789
+
790
+ /**
791
+ * Get template form data
792
+ */
793
+ protected function get_template_form_data($id)
794
+ {
795
+ $template_data=$this->get_mapping_template_by_id($id);
796
+ if($template_data)
797
+ {
798
+ $decoded_form_data=Wt_Import_Export_For_Woo_Basic_Common_Helper::process_formdata(maybe_unserialize($template_data['data']));
799
+ $this->selected_template_form_data=(!is_array($decoded_form_data) ? array() : $decoded_form_data);
800
+ }
801
+ }
802
+
803
+
804
+ /**
805
+ * Taking mapping template by Name
806
+ */
807
+ protected function get_mapping_template_by_name($name)
808
+ {
809
+ global $wpdb;
810
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
811
+ $qry=$wpdb->prepare("SELECT * FROM $tb WHERE template_type=%s AND item_type=%s AND name=%s",array('import', $this->to_import, $name));
812
+ return $wpdb->get_row($qry, ARRAY_A);
813
+ }
814
+
815
+
816
+ /**
817
+ * Taking mapping template by ID
818
+ */
819
+ protected function get_mapping_template_by_id($id)
820
+ {
821
+ global $wpdb;
822
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
823
+ $qry=$wpdb->prepare("SELECT * FROM $tb WHERE template_type=%s AND item_type=%s AND id=%d",array('import', $this->to_import, $id));
824
+ return $wpdb->get_row($qry, ARRAY_A);
825
+ }
826
+
827
+ /**
828
+ * Taking all mapping templates
829
+ */
830
+ protected function get_mapping_templates()
831
+ {
832
+ if($this->to_import=='')
833
+ {
834
+ return;
835
+ }
836
+ global $wpdb;
837
+ $tb=$wpdb->prefix.Wt_Import_Export_For_Woo_Basic::$template_tb;
838
+ $val=$wpdb->get_results("SELECT * FROM $tb WHERE template_type='import' AND item_type='".$this->to_import."' ORDER BY id DESC", ARRAY_A);
839
+
840
+ //add a filter here for modules to alter the data
841
+ $this->mapping_templates=($val ? $val : array());
842
+ }
843
+
844
+
845
+ /**
846
+ * Get meta field list for mapping page
847
+ *
848
+ */
849
+ protected function get_mapping_enabled_fields()
850
+ {
851
+ $mapping_enabled_fields=array(
852
+
853
+ );
854
+ $this->mapping_enabled_fields=apply_filters('wt_iew_importer_alter_mapping_enabled_fields_basic', $mapping_enabled_fields, $this->to_import, array());
855
+ }
856
+
857
+ protected function prepare_step_summary()
858
+ {
859
+ $step_info= $this->get_step_info($this->step);
860
+ $this->step_title=$step_info['title'];
861
+ $this->step_keys=array_keys($this->steps);
862
+ $this->current_step_index=array_search($this->step, $this->step_keys);
863
+ $this->current_step_number=$this->current_step_index+1;
864
+ $this->last_page=(!isset($this->step_keys[$this->current_step_index+1]) ? true : false);
865
+ $this->total_steps=count($this->step_keys);
866
+ $this->step_summary=__(sprintf("Step %d of %d", $this->current_step_number, $this->total_steps));
867
+ $this->step_description=$step_info['description'];
868
+ }
869
+
870
+ protected function prepare_step_header_html()
871
+ {
872
+ include dirname(plugin_dir_path(__FILE__)).'/views/_import_header.php';
873
+ }
874
+
875
+ protected function prepare_step_footer_html()
876
+ {
877
+ include dirname(plugin_dir_path(__FILE__)).'/views/_import_footer.php';
878
+ }
879
+
880
+ protected function prepare_footer_button_list()
881
+ {
882
+ $out=array();
883
+ $step_keys=$this->step_keys;
884
+ $current_index=$this->current_step_index;
885
+ $last_page=$this->last_page;
886
+ if($current_index!==false) /* step exists */
887
+ {
888
+ if($current_index>0) //add back button
889
+ {
890
+ $out['back']=array(
891
+ 'type'=>'button',
892
+ 'action_type'=>'step',
893
+ 'key'=>$step_keys[$current_index-1],
894
+ 'text'=>'<span class="dashicons dashicons-arrow-left-alt2" style="line-height:27px;"></span> '.__('Back'),
895
+ );
896
+ }
897
+
898
+ if(isset($step_keys[$current_index+1])) /* not last step */
899
+ {
900
+ $next_number=$current_index+2;
901
+ $next_key=$step_keys[$current_index+1];
902
+ $next_title=$this->steps[$next_key]['title'];
903
+ $out['next']=array(
904
+ 'type'=>'button',
905
+ 'action_type'=>'step',
906
+ 'key'=>$next_key,
907
+ 'text'=>__('Step').' '.$next_number.': '.$next_title.' <span class="dashicons dashicons-arrow-right-alt2" style="line-height:27px;"></span>',
908
+ );
909
+
910
+ if($this->import_method=='quick' || $this->import_method=='template') //Quick Or Template method
911
+ {
912
+ $out['or']=array(
913
+ 'type'=>'text',
914
+ 'text'=>__('Or'),
915
+ );
916
+ }
917
+
918
+ }else
919
+ {
920
+ $last_page=true;
921
+ }
922
+
923
+ if($this->import_method=='quick' || $this->import_method=='template' || $last_page) //template method, or last page, or quick import
924
+ {
925
+ if($last_page && $this->import_method!='quick') //last page and not quick import
926
+ {
927
+ if($this->import_method=='template')
928
+ {
929
+ $out['save']=array(
930
+ 'key'=>'save',
931
+ 'icon'=>'',
932
+ 'type'=>'dropdown_button',
933
+ 'text'=>__('Save template'),
934
+ 'items'=>array(
935
+ 'update'=>array(
936
+ 'key'=>'update_template',
937
+ 'text'=>__('Save'), //no prompt
938
+ ),
939
+ 'save'=>array(
940
+ 'key'=>'save_template_as',
941
+ 'text'=>__('Save As'), //prompt for name
942
+ )
943
+ )
944
+ );
945
+ }else
946
+ {
947
+ $out['save']=array(
948
+ 'key'=>'save_template',
949
+ 'icon'=>'',
950
+ 'type'=>'button',
951
+ 'text'=>__('Save template'), //prompt for name
952
+ );
953
+ }
954
+ }
955
+ $out['download']=array(
956
+ 'key'=>'download', /* first step of import must be download the input file */
957
+ 'class'=>'iew_import_btn',
958
+ 'icon'=>'',
959
+ 'type'=>'button',
960
+ 'text'=>__('Import'),
961
+ );
962
+ }
963
+ }
964
+ $this->step_btns=apply_filters('wt_iew_importer_alter_footer_btns_basic', $out, $this->step, $this->steps);
965
+ }
966
+
967
+ /**
968
+ * Prepare default mapping data for quick import
969
+ * After preparing update the Formdata in history table
970
+ */
971
+ protected function _prepare_for_quick($import_id)
972
+ {
973
+ //take history data by import_id
974
+ $import_data=Wt_Import_Export_For_Woo_Basic_History::get_history_entry_by_id($import_id);
975
+
976
+ //processing form data
977
+ $form_data=(isset($import_data['data']) ? maybe_unserialize($import_data['data']) : array());
978
+
979
+
980
+ $ext_arr=explode('.', $this->import_obj->temp_import_file);
981
+
982
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-csvreader.php';
983
+ $delimiter=(isset($form_data['method_import_form_data']['wt_iew_delimiter']) ? ($form_data['method_import_form_data']['wt_iew_delimiter']) : ',');
984
+ $reader=new Wt_Import_Export_For_Woo_Basic_Csvreader($delimiter);
985
+
986
+
987
+ $file_path=$this->import_obj->get_file_path($this->import_obj->temp_import_file);
988
+
989
+ /* take first two rows in csv and in xml takes column keys and a sample data */
990
+ $sample_data=$reader->get_sample_data($file_path, true);
991
+
992
+ $file_heading_data=$this->process_file_heading_data($sample_data);
993
+ $file_heading_default_fields=$file_heading_data['default'];
994
+ $file_heading_meta_fields=$file_heading_data['meta'];
995
+
996
+
997
+ /**
998
+ * Default mapping fields
999
+ * Format: 'field_key'=>array('title'=>'', 'description'=>'')
1000
+ */
1001
+ $mapping_fields=array();
1002
+ $mapping_fields=apply_filters('wt_iew_importer_alter_mapping_fields_basic', $mapping_fields, $this->to_import, array());
1003
+
1004
+ $array_keys_file_heading_default_fields = array_keys($file_heading_default_fields);
1005
+ $mapping_form_data=array('mapping_fields'=>array(), 'mapping_selected_fields'=>array());
1006
+ $allowed_field_types=array('start_with', 'end_with', 'contain');
1007
+
1008
+ foreach($mapping_fields as $key=>$val_arr)
1009
+ {
1010
+ $val='';
1011
+ $checked=0; /* import this column? */
1012
+ $type=(isset($val_arr['type']) ? $val_arr['type'] : '');
1013
+ // if(isset($file_heading_default_fields[$key]))
1014
+ if($case_key = preg_grep("/^$key$/i", $array_keys_file_heading_default_fields)) //preg_grep used escape from case sensitive check.
1015
+ {
1016
+ $checked=1; /* import this column? */
1017
+ // $val='{'.$key.'}';
1018
+ $val='{'.array_shift($case_key).'}'; // preg_grep give an array with actual index and value
1019
+ unset($file_heading_default_fields[$key]); //remove the field from file heading list
1020
+ }
1021
+ elseif(isset($file_heading_meta_fields[$key])) /* some meta items will show inside default field list, Eg: yoast */
1022
+ {
1023
+ $checked=1; /* import this column? */
1024
+ $val='{'.$key.'}';
1025
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
1026
+ }else
1027
+ {
1028
+ $field_type=(isset($val_arr['field_type']) ? $val_arr['field_type'] : '');
1029
+ if($field_type!="" && in_array($field_type, $allowed_field_types)) // it may be a different field type
1030
+ {
1031
+ foreach ($file_heading_default_fields as $def_key => $def_val)
1032
+ {
1033
+ $matched=false;
1034
+ if($field_type=='start_with' && strpos($def_key, $key)===0)
1035
+ {
1036
+ $matched=true;
1037
+ }
1038
+ elseif($field_type=='ends_with' && strrpos($def_key, $key)===(strlen($def_key) - strlen($key)))
1039
+ {
1040
+ $matched=true;
1041
+ }
1042
+ elseif($field_type=='contains' && strpos($def_key, $key)!==false)
1043
+ {
1044
+ $matched=true;
1045
+ }
1046
+ if($matched)
1047
+ {
1048
+ $val='{'.$def_key.'}';
1049
+ unset($file_heading_default_fields[$def_key]); //remove the field from file heading list
1050
+ $mapping_form_data['mapping_selected_fields'][$def_key]=$val;
1051
+ $mapping_form_data['mapping_fields'][$def_key]=array($val, 1, $type); //value, enabled, type
1052
+ }
1053
+ }
1054
+ }else /* unmatched keys */
1055
+ {
1056
+ $checked=0;
1057
+ $val='';
1058
+ }
1059
+ }
1060
+ if($checked==1)
1061
+ {
1062
+ $mapping_form_data['mapping_selected_fields'][$key]=$val;
1063
+ $mapping_form_data['mapping_fields'][$key]=array($val, 1, $type); //value, enabled, type
1064
+ }
1065
+ }
1066
+
1067
+ /**
1068
+ * Meta mapping fields
1069
+ *
1070
+ */
1071
+ $form_data_meta_mapping_fields = array(); // recheck the need of this variable in the below context.
1072
+ $meta_mapping_screen_fields=$this->_get_meta_mapping_screen_fields($form_data_meta_mapping_fields);
1073
+
1074
+ /* preparing meta fields. */
1075
+ $meta_mapping_form_data=array('mapping_fields'=>array(), 'mapping_selected_fields'=>array());
1076
+ if($meta_mapping_screen_fields && is_array($meta_mapping_screen_fields))
1077
+ {
1078
+ /* loop through mapping fields */
1079
+ foreach($meta_mapping_screen_fields as $meta_mapping_screen_field_key=>$meta_mapping_screen_field_val)
1080
+ {
1081
+ /* decalaring an empty array*/
1082
+ $temp_arr=array();
1083
+ $temp_fields_arr=array(); /* this is to store mapping field other details */
1084
+
1085
+ /* default field list from post type module */
1086
+ $mapping_fields=((isset($meta_mapping_screen_field_val['fields']) && is_array($meta_mapping_screen_field_val['fields'])) ? $meta_mapping_screen_field_val['fields'] : array());
1087
+
1088
+ /* loop through mapping fields */
1089
+ if(count($mapping_fields)>0)
1090
+ {
1091
+ foreach($mapping_fields as $key=>$val_arr)
1092
+ {
1093
+ $val='';
1094
+ $checked=0; /* import this column? */
1095
+ $type=(isset($val_arr['type']) ? $val_arr['type'] : '');
1096
+
1097
+ if(isset($file_heading_meta_fields[$key]))
1098
+ {
1099
+ $checked=1; /* import this column? */
1100
+ $val='{'.$key.'}';
1101
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
1102
+ }
1103
+ if($checked==1)
1104
+ {
1105
+ $temp_arr[$key]=$val;
1106
+ $temp_fields_arr[$key]=array($val, 1, $type);
1107
+ }
1108
+ }
1109
+ }
1110
+ if(count($file_heading_meta_fields)>0)
1111
+ {
1112
+ $current_field_group_prefix_arr=(isset($this->field_group_prefixes[$meta_mapping_screen_field_key]) ? $this->field_group_prefixes[$meta_mapping_screen_field_key] : array());
1113
+ foreach($file_heading_meta_fields as $key=>$sample_val)
1114
+ {
1115
+ $is_include=$this->_is_include_meta_in_this_group($current_field_group_prefix_arr, $key);
1116
+ if($is_include==1)
1117
+ {
1118
+ $val='{'.$key.'}';
1119
+ $checked=1; /* import this column? */
1120
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
1121
+ $temp_arr[$key]=$val;
1122
+ $temp_fields_arr[$key]=array($val, 1, '');
1123
+ }
1124
+ }
1125
+ }
1126
+
1127
+ /* adding value to main array */
1128
+ $meta_mapping_form_data['mapping_selected_fields'][$meta_mapping_screen_field_key]=$temp_arr;
1129
+ $meta_mapping_form_data['mapping_fields'][$meta_mapping_screen_field_key]=$temp_fields_arr;
1130
+ $mapping_fields=$temp_arr=$temp_fields_arr=null;
1131
+ unset($temp_arr, $temp_fields_arr, $mapping_fields);
1132
+ }
1133
+
1134
+ /* if any columns that not in the above list */
1135
+ if(count($file_heading_meta_fields)>0)
1136
+ {
1137
+ //do something
1138
+ }
1139
+ }
1140
+
1141
+ /**
1142
+ * update form data with prepared mapping form data
1143
+ */
1144
+ $form_data['mapping_form_data']=$mapping_form_data;
1145
+ $form_data['meta_step_form_data']=$meta_mapping_form_data;
1146
+
1147
+
1148
+ $update_data=array(
1149
+ 'data'=>maybe_serialize($form_data), //formadata
1150
+ );
1151
+ $update_data_type=array(
1152
+ '%s',
1153
+ );
1154
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($import_id, $update_data, $update_data_type);
1155
+
1156
+ $mapping_form_data=$meta_mapping_form_data=$form_data=null;
1157
+ unset($mapping_form_data, $meta_mapping_form_data, $form_data);
1158
+ }
1159
+
1160
+ protected function _get_meta_mapping_screen_fields($form_data_meta_mapping_fields)
1161
+ {
1162
+ $this->get_mapping_enabled_fields();
1163
+ $meta_mapping_screen_fields=array();
1164
+ foreach($this->mapping_enabled_fields as $field_key=>$field_vl)
1165
+ {
1166
+ $field_vl=(!is_array($field_vl) ? array($field_vl, 0) : $field_vl);
1167
+ $meta_mapping_screen_fields[$field_key]=array(
1168
+ 'title'=>'',
1169
+ 'checked'=>$field_vl[1],
1170
+ 'fields'=>array(),
1171
+ );
1172
+ }
1173
+
1174
+ /**
1175
+ * default mapping page fields
1176
+ * Format: 'field_key'=>array('title'=>'', 'description'=>'')
1177
+ */
1178
+ return apply_filters('wt_iew_importer_alter_meta_mapping_fields_basic', $meta_mapping_screen_fields, $this->to_import, $form_data_meta_mapping_fields);
1179
+ }
1180
+
1181
+ protected function _is_include_meta_in_this_group($current_field_group_prefix_arr, $key)
1182
+ {
1183
+ $is_include=0;
1184
+ foreach ($current_field_group_prefix_arr as $_prefix)
1185
+ {
1186
+ if(strpos($key, $_prefix)===0) /* find as first occurrence */
1187
+ {
1188
+ if($_prefix=='meta') /* avoid conflict with hidden meta */
1189
+ {
1190
+ $name=str_replace('meta:', '', $key);
1191
+ if(substr($name, 0, 1)!='_') /* not hidden meta */
1192
+ {
1193
+ if(strpos($name, 'attribute')!==0) /* its not meta attribute */
1194
+ {
1195
+ $is_include=1;
1196
+ break;
1197
+ }
1198
+ }
1199
+ }else
1200
+ {
1201
+ $is_include=1;
1202
+ break;
1203
+ }
1204
+ }
1205
+ }
1206
+ return $is_include;
1207
+ }
1208
+ }
1209
+ }
admin/modules/import/import.php ADDED
@@ -0,0 +1,1287 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Import section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+
13
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Import')){
14
+ class Wt_Import_Export_For_Woo_Basic_Import
15
+ {
16
+ public $module_id='';
17
+ public static $module_id_static='';
18
+ public $module_base='import';
19
+
20
+ public static $import_dir=WP_CONTENT_DIR.'/webtoffee_import';
21
+ public static $import_dir_name='/webtoffee_import';
22
+ public $steps=array();
23
+ public $allowed_import_file_type=array();
24
+ public $max_import_file_size=10; //in MB
25
+
26
+ private $to_import_id='';
27
+ private $to_import='';
28
+ private $rerun_id=0;
29
+ public $import_method='';
30
+ public $import_methods=array();
31
+ public $selected_template=0;
32
+ public $default_batch_count=0; /* configure this value in `advanced_setting_fields` method */
33
+ public $selected_template_data=array();
34
+ public $default_import_method=''; /* configure this value in `advanced_setting_fields` method */
35
+ public $form_data=array();
36
+ public $temp_import_file='';
37
+ private $to_process='';
38
+
39
+ public function __construct()
40
+ {
41
+ $this->module_id=Wt_Import_Export_For_Woo_Basic::get_module_id($this->module_base);
42
+ self::$module_id_static=$this->module_id;
43
+
44
+ $this->max_import_file_size=wp_max_upload_size()/1000000; //in MB
45
+
46
+ /* allowed file types */
47
+ $this->allowed_import_file_type=array(
48
+ 'csv'=>__('CSV'),
49
+ );
50
+ $this->allowed_import_file_type_mime=array(
51
+ 'csv'=>'text/csv',
52
+ );
53
+
54
+ /* default step list */
55
+ $this->steps=array(
56
+ 'post_type'=>array(
57
+ 'title'=>__('Select a post type'),
58
+ 'description'=>__('Import the respective post type from a CSV. As a first step you need to choose the post type to start the import.'),
59
+ ),
60
+ 'method_import'=>array(
61
+ 'title'=>__('Select import method'),
62
+ 'description'=>__('Choose from the options below to continue with your import: quick import, based on a pre-saved template or a new import with advanced options.'),
63
+ ),
64
+ 'mapping'=>array(
65
+ 'title'=>__('Map import columns'),
66
+ 'description'=>__('Map the standard columns with your CSV column names.'),
67
+ ),
68
+ 'advanced'=>array(
69
+ 'title'=>__('Advanced options/Batch import'),
70
+ 'description'=>__('Use advanced options from below to decide on the delimiter options, updates to existing products, batch import count or schedule an import. You can also save the template file for future imports.'),
71
+ ),
72
+ );
73
+
74
+ $this->import_methods=array(
75
+ 'quick'=>array('title'=>__('Quick import'), 'description'=> __('Use this option primarily when your input file was exported using the same plugin.')),
76
+ 'template'=>array('title'=>__('Pre-saved template'), 'description'=> __('Using a pre-saved template retains the previous filter criteria and other column specifications as per the chosen file and imports data accordingly.')),
77
+ 'new'=>array('title'=>__('Advanced Import'), 'description'=> __('This option will take you through the entire process of filtering/column selection/advanced options that may be required for your import. You can also save your selections as a template for future use.')),
78
+ );
79
+
80
+ $this->step_need_validation_filter=array('method_import', 'mapping', 'advanced');
81
+
82
+ /* advanced plugin settings */
83
+ add_filter('wt_iew_advanced_setting_fields_basic', array($this, 'advanced_setting_fields'));
84
+
85
+ /* setting default values this method must be below of advanced setting filter */
86
+ $this->get_defaults();
87
+
88
+ /* main ajax hook. The callback function will decide which is to execute. */
89
+ add_action('wp_ajax_iew_import_ajax_basic', array($this, 'ajax_main'), 11);
90
+
91
+ /* Admin menu for import */
92
+ add_filter('wt_iew_admin_menu_basic', array($this, 'add_admin_pages'), 10, 1);
93
+
94
+ }
95
+
96
+ public function get_defaults()
97
+ {
98
+ $this->default_import_method= Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('default_import_method');
99
+ $this->default_batch_count=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('default_import_batch');
100
+ }
101
+
102
+ /**
103
+ * Fields for advanced settings
104
+ *
105
+ */
106
+ public function advanced_setting_fields($fields)
107
+ {
108
+ $fields['enable_import_log']=array(
109
+ 'label'=>__("Save Import log"),
110
+ 'type'=>'radio',
111
+ 'radio_fields'=>array(
112
+ 1=>__('Yes'),
113
+ 0=>__('No')
114
+ ),
115
+ 'value' =>1,
116
+ 'field_name'=>'enable_import_log',
117
+ 'field_group'=>'advanced_field',
118
+ 'help_text'=>__('Save import log as text file and make it available in the history section.'),
119
+ 'validation_rule'=>array('type'=>'absint'),
120
+ );
121
+ $import_methods=array_map(function($vl){ return $vl['title']; }, $this->import_methods);
122
+ $fields['default_import_method']=array(
123
+ 'label'=>__("Default Import method"),
124
+ 'type'=>'select',
125
+ 'sele_vals'=>$import_methods,
126
+ 'value' =>'quick',
127
+ 'field_name'=>'default_import_method',
128
+ 'field_group'=>'advanced_field',
129
+ 'help_text'=>__('Select the default method of import.'),
130
+ );
131
+ $fields['default_import_batch']=array(
132
+ 'label'=>__("Default Import batch count"),
133
+ 'type'=>'number',
134
+ 'value' =>10, /* If altering then please also change batch count field help text section */
135
+ 'field_name'=>'default_import_batch',
136
+ 'help_text'=>__('Provide the default count for the records to be imported in a batch.'),
137
+ 'validation_rule'=>array('type'=>'absint'),
138
+ );
139
+ return $fields;
140
+ }
141
+
142
+ /**
143
+ * Fields for Import advanced step
144
+ */
145
+ public function get_advanced_screen_fields($advanced_form_data)
146
+ {
147
+ $advanced_screen_fields=array(
148
+
149
+ 'batch_count'=>array(
150
+ 'label'=>__("Import in batches of"),
151
+ 'type'=>'text',
152
+ 'value'=>$this->default_batch_count,
153
+ 'field_name'=>'batch_count',
154
+ 'help_text'=>sprintf(__('The number of records that the server will process for every iteration within the configured timeout interval. If the import fails you can lower this number accordingly and try again. Defaulted to %d records.'), 10),
155
+ 'validation_rule'=>array('type'=>'absint'),
156
+ )
157
+ );
158
+
159
+ /* taking advanced fields from post type modules */
160
+ $advanced_screen_fields=apply_filters('wt_iew_importer_alter_advanced_fields_basic', $advanced_screen_fields, $this->to_import, $advanced_form_data);
161
+ return $advanced_screen_fields;
162
+ }
163
+
164
+ /**
165
+ * Fields for Import method step
166
+ */
167
+ public function get_method_import_screen_fields($method_import_form_data)
168
+ {
169
+ $file_from_arr=array(
170
+ 'local'=>__('Local'),
171
+ );
172
+
173
+ /* taking available remote adapters */
174
+ $remote_adapter_names=array();
175
+ $remote_adapter_names=apply_filters('wt_iew_importer_remote_adapter_names_basic', $remote_adapter_names);
176
+ if($remote_adapter_names && is_array($remote_adapter_names))
177
+ {
178
+ foreach($remote_adapter_names as $remote_adapter_key => $remote_adapter_vl)
179
+ {
180
+ $file_from_arr[$remote_adapter_key]=$remote_adapter_vl;
181
+ }
182
+ }
183
+
184
+ //prepare file from field type based on remote type adapters
185
+ $file_from_field_arr=array(
186
+ 'label'=>__("Choose file for Import"),
187
+ 'type'=>'select',
188
+ 'tr_class'=>'wt-iew-import-method-options wt-iew-import-method-options-quick wt-iew-import-method-options-new wt-iew-import-method-options-template',
189
+ 'sele_vals'=>$file_from_arr,
190
+ 'field_name'=>'file_from',
191
+ 'default_value'=>'local',
192
+ 'form_toggler'=>array(
193
+ 'type'=>'parent',
194
+ 'target'=>'wt_iew_file_from'
195
+ )
196
+ );
197
+
198
+
199
+ $method_import_screen_fields=array(
200
+ 'file_from'=>$file_from_field_arr,
201
+ 'local_file'=>array(
202
+ 'label'=>__("Select a file"),
203
+ 'type'=>'dropzone',
204
+ 'merge_left'=>true,
205
+ 'merge_right'=>true,
206
+ 'tr_id'=>'local_file_tr',
207
+ 'tr_class'=>$file_from_field_arr['tr_class'], //add tr class from parent.Because we need to toggle the tr when parent tr toggles.
208
+ 'field_name'=>'local_file',
209
+ 'html_id'=>'local_file',
210
+ 'form_toggler'=>array(
211
+ 'type'=>'child',
212
+ 'id'=>'wt_iew_file_from',
213
+ 'val'=>'local',
214
+ ),
215
+ ),
216
+
217
+ );
218
+
219
+ /* taking import_method fields from other modules */
220
+ $method_import_screen_fields=apply_filters('wt_iew_importer_alter_method_import_fields_basic', $method_import_screen_fields, $this->to_import, $method_import_form_data);
221
+
222
+
223
+ $method_import_screen_fields['delimiter']=array(
224
+ 'label'=>__("Delimiter"),
225
+ 'type'=>'select',
226
+ 'value'=>",",
227
+ 'css_class'=>"wt_iew_delimiter_preset",
228
+ 'tr_id'=>'delimiter_tr',
229
+ 'tr_class'=>$file_from_field_arr['tr_class'], //add tr class from parent.Because we need to toggle the tr when parent tr toggles.
230
+ 'field_name'=>'delimiter_preset',
231
+ 'sele_vals'=>Wt_Iew_IE_Basic_Helper::_get_csv_delimiters(),
232
+ 'help_text'=>__('Only applicable for CSV imports in order to separate the columns in the CSV file. Takes comma(,) by default.'),
233
+ 'validation_rule'=>array('type'=>'skip'),
234
+ 'after_form_field'=>'<input type="text" class="wt_iew_custom_delimiter" name="wt_iew_delimiter" value="," />',
235
+ );
236
+
237
+
238
+
239
+ return $method_import_screen_fields;
240
+ }
241
+
242
+ /**
243
+ * Adding admin menus
244
+ */
245
+ public function add_admin_pages($menus)
246
+ {
247
+ $first = array_slice($menus, 0, 3, true);
248
+ $last=array_slice($menus, 3, (count($menus)-1), true);
249
+
250
+ $menu=array(
251
+ $this->module_base=>array(
252
+ 'submenu',
253
+ WT_IEW_PLUGIN_ID_BASIC,
254
+ __('Import'),
255
+ __('Import'),
256
+ apply_filters('wt_import_export_allowed_capability', 'import'),
257
+ $this->module_id,
258
+ array($this, 'admin_settings_page')
259
+ )
260
+ );
261
+
262
+ $menus=array_merge($first, $menu, $last);
263
+ return $menus;
264
+ }
265
+
266
+ /**
267
+ * Import page
268
+ */
269
+ public function admin_settings_page()
270
+ {
271
+ /**
272
+ * Check it is a rerun call
273
+ */
274
+ $requested_rerun_id=(isset($_GET['wt_iew_rerun']) ? absint($_GET['wt_iew_rerun']) : 0);
275
+ $this->_process_rerun($requested_rerun_id);
276
+
277
+ if($this->rerun_id>0) /* this is a rerun request. Then validate the file */
278
+ {
279
+ $response=$this->download_remote_file($this->form_data);
280
+ if($response['response']) /* temp file created. */
281
+ {
282
+ $this->temp_import_file=$response['file_name'];
283
+
284
+ /* delete temp files other than the current temp file of same rerun id, if exists */
285
+ $file_path=$this->get_file_path();
286
+ $temp_files = glob($file_path.'/rerun_'.$this->rerun_id.'_*');
287
+ if(count($temp_files)>1) /* Other than the current temp file */
288
+ {
289
+ foreach($temp_files as $key => $temp_file)
290
+ {
291
+ if(basename($temp_file)!=$this->temp_import_file)
292
+ {
293
+ @unlink($temp_file); //delete it
294
+ }
295
+ }
296
+ }
297
+
298
+ }else /* unable to create temp file, then abort the rerun request */
299
+ {
300
+ $this->rerun_id=0;
301
+ $this->form_data=array();
302
+ }
303
+ }
304
+ $this->enqueue_assets();
305
+ include plugin_dir_path(__FILE__).'views/main.php';
306
+ }
307
+
308
+
309
+ /**
310
+ * Validating and Processing rerun action
311
+ */
312
+ protected function _process_rerun($rerun_id)
313
+ {
314
+ if($rerun_id>0)
315
+ {
316
+ /* check the history module is available */
317
+ $history_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules('history');
318
+ if(!is_null($history_module_obj))
319
+ {
320
+ /* check the history entry is for import and also has form_data */
321
+ $history_data=$history_module_obj->get_history_entry_by_id($rerun_id);
322
+ if($history_data && $history_data['template_type']==$this->module_base)
323
+ {
324
+ $form_data=maybe_unserialize($history_data['data']);
325
+ if($form_data && is_array($form_data))
326
+ {
327
+ $this->to_import=(isset($form_data['post_type_form_data']) && isset($form_data['post_type_form_data']['item_type']) ? $form_data['post_type_form_data']['item_type'] : '');
328
+ if($this->to_import!="")
329
+ {
330
+ $this->import_method=(isset($form_data['method_import_form_data']) && isset($form_data['method_import_form_data']['method_import']) && $form_data['method_import_form_data']['method_import']!="" ? $form_data['method_import_form_data']['method_import'] : $this->default_import_method);
331
+ $this->rerun_id=$rerun_id;
332
+ $this->form_data=$form_data;
333
+ //process steps based on the import method in the history entry
334
+ $this->get_steps();
335
+
336
+ return true;
337
+ }
338
+ }
339
+ }
340
+ }
341
+ }
342
+ return false;
343
+ }
344
+
345
+ protected function enqueue_assets()
346
+ {
347
+ if(Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_is_screen_allowed()){
348
+ /* adding dropzone JS */
349
+ wp_enqueue_script(WT_IEW_PLUGIN_ID_BASIC.'-dropzone', WT_P_IEW_PLUGIN_URL.'admin/js/dropzone.min.js', array('jquery'), WT_P_IEW_VERSION);
350
+
351
+ wp_enqueue_script($this->module_id, plugin_dir_url(__FILE__).'assets/js/main.js', array('jquery', 'jquery-ui-sortable', 'jquery-ui-datepicker'), WT_P_IEW_VERSION);
352
+ wp_enqueue_style('jquery-ui-datepicker');
353
+ //wp_enqueue_media();
354
+
355
+ wp_enqueue_style(WT_IEW_PLUGIN_ID_BASIC.'-jquery-ui', WT_P_IEW_PLUGIN_URL.'admin/css/jquery-ui.css', array(), WT_P_IEW_VERSION, 'all');
356
+
357
+ /* check the history module is available */
358
+ $history_module_obj=Wt_Import_Export_For_Woo_Basic::load_modules('history');
359
+ if(!is_null($history_module_obj))
360
+ {
361
+ wp_enqueue_script(Wt_Import_Export_For_Woo_Basic::get_module_id('history'),WT_P_IEW_PLUGIN_URL.'admin/modules/history/assets/js/main.js', array('jquery'), WT_P_IEW_VERSION, false);
362
+ }
363
+
364
+ $file_extensions=array_keys($this->allowed_import_file_type_mime);
365
+ $file_extensions=array_map(function($vl){
366
+ return '.'.$vl;
367
+ }, $file_extensions);
368
+
369
+ $params=array(
370
+ 'item_type'=>'',
371
+ 'steps'=>$this->steps,
372
+ 'rerun_id'=>$this->rerun_id,
373
+ 'to_import'=>$this->to_import,
374
+ 'import_method'=>$this->import_method,
375
+ 'temp_import_file'=>$this->temp_import_file,
376
+ 'allowed_import_file_type_mime'=>$file_extensions,
377
+ 'max_import_file_size'=>$this->max_import_file_size,
378
+ 'msgs'=>array(
379
+ 'choosed_template'=>__('Choosed template: '),
380
+ 'choose_import_method'=>__('Please select an import method.'),
381
+ 'choose_template'=>__('Please select an import template.'),
382
+ 'step'=>__('Step'),
383
+ 'choose_ftp_profile'=>__('Please select an FTP profile.'),
384
+ 'choose_import_from'=>__('Please choose import from.'),
385
+ 'choose_a_file'=>__('Please choose an import file.'),
386
+ 'select_an_import_template'=>__('Please select an import template.'),
387
+ 'validating_file'=>__('Creating temp file and validating.'),
388
+ 'processing_file'=>__('Processing input file...'),
389
+ 'column_not_in_the_list'=>__('This column is not present in the import list. Please tick the checkbox to include.'),
390
+ 'uploading'=>__('Uploading...'),
391
+ 'outdated'=>__('You are using an outdated browser. Please upgarde your browser.'),
392
+ 'server_error'=>__('An error occured.'),
393
+ 'invalid_file'=>sprintf(__('Invalid file type. Only %s are allowed'), implode(", ", array_values($this->allowed_import_file_type))),
394
+ 'drop_upload'=>__('Drop files here or click to upload'),
395
+ 'upload_done'=>sprintf(__('%s Done.'), '<span class="dashicons dashicons-yes-alt" style="color:#3fa847;"></span>'),
396
+ 'remove'=>__('Remove'),
397
+ ),
398
+ );
399
+ wp_localize_script($this->module_id, 'wt_iew_import_basic_params', $params);
400
+
401
+ $this->add_select2_lib(); //adding select2 JS, It checks the availibility of woocommerce
402
+ }
403
+ }
404
+
405
+ /**
406
+ *
407
+ * Enqueue select2 library, if woocommerce available use that
408
+ */
409
+ protected function add_select2_lib()
410
+ {
411
+ /* enqueue scripts */
412
+ if(!function_exists('is_plugin_active'))
413
+ {
414
+ include_once(ABSPATH.'wp-admin/includes/plugin.php');
415
+ }
416
+ if(is_plugin_active('woocommerce/woocommerce.php'))
417
+ {
418
+ wp_enqueue_script('wc-enhanced-select');
419
+ wp_enqueue_style('woocommerce_admin_styles', WC()->plugin_url().'/assets/css/admin.css');
420
+ }else
421
+ {
422
+ wp_enqueue_style(WT_IEW_PLUGIN_ID_BASIC.'-select2', WT_P_IEW_PLUGIN_URL. 'admin/css/select2.css', array(), WT_P_IEW_VERSION, 'all' );
423
+ wp_enqueue_script(WT_IEW_PLUGIN_ID_BASIC.'-select2', WT_P_IEW_PLUGIN_URL.'admin/js/select2.js', array('jquery'), WT_P_IEW_VERSION, false );
424
+ }
425
+ }
426
+
427
+ /**
428
+ * Get steps
429
+ *
430
+ */
431
+ public function get_steps()
432
+ {
433
+ if($this->import_method=='quick') /* if quick import then remove some steps */
434
+ {
435
+ $out=array(
436
+ 'post_type'=>$this->steps['post_type'],
437
+ 'method_import'=>$this->steps['method_import'],
438
+ 'advanced'=>$this->steps['advanced'],
439
+ );
440
+ $this->steps=$out;
441
+ }
442
+ $this->steps=apply_filters('wt_iew_importer_steps_basic', $this->steps, $this->to_import);
443
+ return $this->steps;
444
+ }
445
+
446
+ /**
447
+ * Download and save file into web server
448
+ *
449
+ */
450
+ public function download_remote_file($form_data)
451
+ {
452
+ $out=array(
453
+ 'response'=>false,
454
+ 'file_name'=>'',
455
+ 'msg'=>'',
456
+ );
457
+
458
+ $method_import_form_data=(isset($form_data['method_import_form_data']) ? $form_data['method_import_form_data'] : array());
459
+ $file_from=(isset($method_import_form_data['wt_iew_file_from']) ? Wt_Iew_Sh::sanitize_item($method_import_form_data['wt_iew_file_from']) : '');
460
+
461
+ if($file_from=="")
462
+ {
463
+ return $out;
464
+ }
465
+ if($file_from=='local' || $file_from=='url')
466
+ {
467
+ if($file_from=='local')
468
+ {
469
+ $file_url=(isset($method_import_form_data['wt_iew_local_file']) ? Wt_Iew_Sh::sanitize_item($method_import_form_data['wt_iew_local_file'], 'url') : '');
470
+ $local_file_path=Wt_Iew_IE_Basic_Helper::_get_local_file_path($file_url);
471
+ if(!$local_file_path) /* no local file found */
472
+ {
473
+ $file_url='';
474
+ }
475
+ }else
476
+ {
477
+ $file_url=(isset($method_import_form_data['wt_iew_url_file']) ? Wt_Iew_Sh::sanitize_item($method_import_form_data['wt_iew_url_file'], 'url') : '');
478
+ }
479
+
480
+ if($file_url!="") /* file URL not empty */
481
+ {
482
+ if($this->is_extension_allowed($file_url)) /* file type is in allowed list */
483
+ {
484
+ $ext_arr=explode('.', $file_url);
485
+ $ext=end($ext_arr);
486
+
487
+ $file_name=$this->get_temp_file_name($ext);
488
+ $file_path=$this->get_file_path($file_name);
489
+ if($file_path)
490
+ {
491
+ if($file_from=='local')
492
+ {
493
+ if(@copy($local_file_path, $file_path))
494
+ {
495
+ $out=array(
496
+ 'response'=>true,
497
+ 'file_name'=>$file_name,
498
+ 'msg'=>'',
499
+ );
500
+ }else
501
+ {
502
+ $out['msg']=__('Unable to create temp file.');
503
+ }
504
+ }else
505
+ {
506
+ $file_data=$this->remote_get($file_url);
507
+
508
+ if(!is_wp_error($file_data) && wp_remote_retrieve_response_code($file_data)==200)
509
+ {
510
+ $file_data=wp_remote_retrieve_body($file_data);
511
+ if(@file_put_contents($file_path, $file_data))
512
+ {
513
+ $out=array(
514
+ 'response'=>true,
515
+ 'file_name'=>$file_name,
516
+ 'msg'=>'',
517
+ );
518
+ }else
519
+ {
520
+ $out['msg']=__('Unable to create temp file.');
521
+ }
522
+ }else
523
+ {
524
+ $out['msg']=__('Unable to fetch file data.');
525
+ }
526
+ }
527
+ }else
528
+ {
529
+ $out['msg']=__('Unable to create temp directory.');
530
+ }
531
+ }else
532
+ {
533
+ $out['msg']=__('File type not allowed.');
534
+ }
535
+ }else
536
+ {
537
+ $out['msg']=__('File not found.');
538
+ }
539
+ }else
540
+ {
541
+ $out['response']=true;
542
+ $out=apply_filters('wt_iew_validate_file_basic', $out, $file_from, $method_import_form_data);
543
+
544
+ if(is_array($out) && isset($out['response']) && $out['response']) /* a form validation hook for remote modules */
545
+ {
546
+ $remote_adapter=Wt_Import_Export_For_Woo_Basic::get_remote_adapters('import', $file_from);
547
+
548
+ if(is_null($remote_adapter)) /* adapter object not found */
549
+ {
550
+ $msg=sprintf('Unable to initailize %s', $file_from);
551
+ $out['msg']=__($msg);
552
+ $out['response']=false;
553
+ }else
554
+ {
555
+ /* download the file */
556
+ $out = $remote_adapter->download($method_import_form_data, $out, $this);
557
+ }
558
+ }
559
+ }
560
+ if($out['response']!==false)
561
+ {
562
+ $file_path=self::get_file_path($out['file_name']);
563
+ /**
564
+ * Filter to modify the import file before processing.
565
+ * @param string $file_name name of the file
566
+ * @param string $file_path path of the file
567
+ * @return string $file_name name of the new altered file
568
+ */
569
+ $out['file_name']=apply_filters('wt_iew_alter_import_file_basic', $out['file_name'], $file_path);
570
+ }
571
+
572
+ return $out;
573
+ }
574
+
575
+ public function remote_get($target_url)
576
+ {
577
+ global $wp_version;
578
+
579
+ $def_args = array(
580
+ 'timeout' => 5,
581
+ 'redirection' => 5,
582
+ 'httpversion' => '1.0',
583
+ 'user-agent' => 'WordPress/' . $wp_version . '; ' . home_url(),
584
+ 'blocking' => true,
585
+ 'headers' => array(),
586
+ 'cookies' => array(),
587
+ 'body' => null,
588
+ 'compress' => false,
589
+ 'decompress' => true,
590
+ 'sslverify' => false,
591
+ 'stream' => false,
592
+ 'filename' => null
593
+ );
594
+ return wp_remote_get($target_url, $def_args);
595
+ }
596
+
597
+ public function get_log_file_name($history_id)
598
+ {
599
+ return 'log_'.$history_id.'.log';
600
+ }
601
+
602
+ public function get_temp_file_name($ext)
603
+ {
604
+ /* adding rerun prefix is to easily identify rerun temp files */
605
+ $rerun_prefix=($this->rerun_id>0 ? 'rerun_'.$this->rerun_id.'_' : '');
606
+ return $rerun_prefix.'temp_'.$this->to_import.'_'.time().'.'.$ext;
607
+ }
608
+
609
+ /**
610
+ * Get given file url.
611
+ * If file name is empty then URL will return
612
+ */
613
+ public static function get_file_url($file_name="")
614
+ {
615
+ return WP_CONTENT_URL.self::$import_dir_name.'/'.$file_name;
616
+ }
617
+
618
+ /**
619
+ * Checks the file extension is in allowed list
620
+ * @param string File name/ URL
621
+ * @return boolean
622
+ */
623
+ public function is_extension_allowed($file_url)
624
+ {
625
+ $ext_arr=explode('.', $file_url);
626
+ $ext=strtolower(end($ext_arr));
627
+ if(isset($this->allowed_import_file_type[$ext])) /* file type is in allowed list */
628
+ {
629
+ return true;
630
+ }
631
+ return false;
632
+ }
633
+
634
+ /**
635
+ * Delete import file
636
+ * @param string File path/ URL
637
+ * @return boolean
638
+ */
639
+ public function delete_import_file($file_url)
640
+ {
641
+ $file_path_arr=explode("/", $file_url);
642
+ $file_name=end($file_path_arr);
643
+ $file_path=$this->get_file_path($file_name);
644
+ if(file_exists($file_path))
645
+ {
646
+ if($this->is_extension_allowed($file_url))/* file type is in allowed list */
647
+ {
648
+ @unlink($file_path);
649
+ return true;
650
+ }
651
+ }
652
+ return false;
653
+ }
654
+
655
+ /**
656
+ * Get given temp file path.
657
+ * If file name is empty then file path will return
658
+ */
659
+ public static function get_file_path($file_name="")
660
+ {
661
+ if(!is_dir(self::$import_dir))
662
+ {
663
+ if(!mkdir(self::$import_dir, 0700))
664
+ {
665
+ return false;
666
+ }else
667
+ {
668
+ $files_to_create=array('.htaccess' => 'deny from all', 'index.php'=>'<?php // Silence is golden');
669
+ foreach($files_to_create as $file=>$file_content)
670
+ {
671
+ if(!file_exists(self::$import_dir.'/'.$file))
672
+ {
673
+ $fh=@fopen(self::$import_dir.'/'.$file, "w");
674
+ if(is_resource($fh))
675
+ {
676
+ fwrite($fh, $file_content);
677
+ fclose($fh);
678
+ }
679
+ }
680
+ }
681
+ }
682
+ }
683
+ return self::$import_dir.'/'.$file_name;
684
+ }
685
+
686
+ /**
687
+ * Download and create a temp file. And create a history entry
688
+ * @param string $step the action to perform, here 'download'
689
+ *
690
+ * @return array
691
+ */
692
+ public function process_download($form_data, $step, $to_process, $import_id=0, $offset=0)
693
+ {
694
+ $out=array(
695
+ 'response'=>false,
696
+ 'new_offset'=>0,
697
+ 'import_id'=>0,
698
+ 'history_id'=>0, //same as that of import id
699
+ 'total_records'=>0,
700
+ 'finished'=>0,
701
+ 'msg'=>'',
702
+ );
703
+ $this->to_import=$to_process;
704
+
705
+ if($import_id>0)
706
+ {
707
+ //take history data by import_id
708
+ $import_data=Wt_Import_Export_For_Woo_Basic_History::get_history_entry_by_id($import_id);
709
+ if(is_null($import_data)) //no record found so it may be an error
710
+ {
711
+ return $out;
712
+ }else
713
+ {
714
+ $file_name=(isset($import_data['file_name']) ? $import_data['file_name'] : '');
715
+ $file_path=$this->get_file_path($file_name);
716
+ if($file_path && file_exists($file_path))
717
+ {
718
+ $this->temp_import_file=$file_name;
719
+ }else
720
+ {
721
+ $msg='Error occurred while processing the file';
722
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($import_id, $msg);
723
+ $out['msg']=__($msg);
724
+ return $out;
725
+ }
726
+ }
727
+ }else
728
+ {
729
+ if($offset==0)
730
+ {
731
+ if($this->temp_import_file!="") /* its a non schedule import */
732
+ {
733
+ $file_path=$this->get_file_path($this->temp_import_file);
734
+ if($file_path && file_exists($file_path))
735
+ {
736
+ if($this->is_extension_allowed($this->temp_import_file)) /* file type is in allowed list */
737
+ {
738
+ $import_id=Wt_Import_Export_For_Woo_Basic_History::create_history_entry('', $form_data, $to_process, 'import');
739
+ }else
740
+ {
741
+ return $out;
742
+ }
743
+ }else
744
+ {
745
+ $out['msg']=__('Temp file missing.');
746
+ return $out;
747
+ }
748
+ }else /* in scheduled import need to prepare the temp file */
749
+ {
750
+ $import_id=Wt_Import_Export_For_Woo_Basic_History::create_history_entry('', $form_data, $to_process, 'import');
751
+ $response=$this->download_remote_file($form_data);
752
+
753
+ if(!$response['response']) /* not validated successfully */
754
+ {
755
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($import_id, $response['msg']);
756
+ $out['msg']=$response['msg'];
757
+ return $out;
758
+ }else
759
+ {
760
+ $file_path=$this->get_file_path($response['file_name']);
761
+ $this->temp_import_file=$response['file_name'];
762
+ }
763
+ }
764
+ }
765
+ }
766
+
767
+ /**
768
+ * In XML import we need to convert the file into CSV before processing
769
+ * It may be a batched processing for larger files
770
+ */
771
+ $ext_arr=explode('.', $this->temp_import_file);
772
+
773
+ $out=$this->_set_import_file_processing_finished($file_path, $import_id);
774
+ return $out;
775
+ }
776
+
777
+ /**
778
+ * If the file type is not CSV (Eg: XML) Then the delimiter must be ",".
779
+ * Because we are converting XML to CSV
780
+ *
781
+ */
782
+ protected function _set_csv_delimiter($form_data, $import_id)
783
+ {
784
+ $form_data['method_import_form_data']['wt_iew_delimiter']=",";
785
+
786
+ $update_data=array(
787
+ 'data'=>maybe_serialize($form_data), //formadata
788
+ );
789
+ $update_data_type=array(
790
+ '%s',
791
+ );
792
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($import_id, $update_data, $update_data_type);
793
+
794
+ return $form_data;
795
+ }
796
+
797
+ protected function _set_import_file_processing_finished($file_path, $import_id)
798
+ {
799
+ /* update total records, temp file name in history table */
800
+ $total_records=filesize($file_path); /* in this case we cannot count number of rows */
801
+ $update_data=array(
802
+ 'total'=>$total_records,
803
+ 'file_name'=>$this->temp_import_file,
804
+ );
805
+ $update_data_type=array(
806
+ '%d',
807
+ '%s',
808
+ );
809
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($import_id, $update_data, $update_data_type);
810
+
811
+ return array(
812
+ 'response'=>true,
813
+ 'finished'=>3,
814
+ 'import_id'=>$import_id,
815
+ 'history_id'=>$import_id, //same as that of import id
816
+ 'total_records'=>$total_records,
817
+ 'temp_import_file'=>$this->temp_import_file,
818
+ 'msg'=>sprintf(__('Importing...(%d processed)'), 0),
819
+ );
820
+ }
821
+
822
+
823
+ /**
824
+ * Do the import process
825
+ */
826
+ public function process_action($form_data, $step, $to_process, $file_name='', $import_id=0, $offset=0)
827
+ {
828
+ $out=array(
829
+ 'response'=>false,
830
+ 'new_offset'=>0,
831
+ 'import_id'=>0,
832
+ 'history_id'=>0, //same as that of import id
833
+ 'total_records'=>0,
834
+ 'offset_count'=>0,
835
+ 'finished'=>0,
836
+ 'msg'=>'',
837
+ 'total_success'=>0,
838
+ 'total_failed'=>0,
839
+ );
840
+
841
+ $this->to_import=$to_process;
842
+ $this->to_process=$to_process;
843
+
844
+ /* prepare formdata, If this was not first batch */
845
+ if($import_id>0)
846
+ {
847
+ //take history data by import_id
848
+ $import_data=Wt_Import_Export_For_Woo_Basic_History::get_history_entry_by_id($import_id);
849
+ if(is_null($import_data)) //no record found so it may be an error
850
+ {
851
+ return $out;
852
+ }
853
+
854
+ //processing form data
855
+ $form_data=(isset($import_data['data']) ? maybe_unserialize($import_data['data']) : array());
856
+
857
+ }
858
+ else // No import id so it may be an error
859
+ {
860
+ return $out;
861
+ }
862
+
863
+ /* setting history_id in Log section */
864
+ Wt_Import_Export_For_Woo_Basic_Log::$history_id=$import_id;
865
+
866
+ $file_name=(isset($import_data['file_name']) ? $import_data['file_name'] : '');
867
+ $file_path=$this->get_file_path($file_name);
868
+ if($file_path)
869
+ {
870
+ if(!file_exists($file_path))
871
+ {
872
+ $msg='Temp file missing';
873
+ //no need to add translation function in message
874
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($import_id, $msg);
875
+ $out['msg']=__($msg);
876
+ return $out;
877
+ }
878
+ }else
879
+ {
880
+ $msg='Temp file missing';
881
+ //no need to add translation function in message
882
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($import_id, $msg);
883
+ $out['msg']=__($msg);
884
+ return $out;
885
+ }
886
+
887
+ $default_batch_count=absint(apply_filters('wt_iew_importer_alter_default_batch_count_basic', $this->default_batch_count, $to_process, $form_data));
888
+ $default_batch_count=($default_batch_count==0 ? $this->default_batch_count : $default_batch_count);
889
+
890
+ $batch_count=$default_batch_count;
891
+ $csv_delimiter=',';
892
+ $total_records=(isset($import_data['total']) ? $import_data['total'] : 0);
893
+ $file_ext_arr=explode('.', $file_name);
894
+ $file_type= strtolower(end($file_ext_arr));
895
+ $file_type=(isset($this->allowed_import_file_type[$file_type]) ? $file_type : 'csv');
896
+
897
+ if(isset($form_data['advanced_form_data']))
898
+ {
899
+ $batch_count=(isset($form_data['advanced_form_data']['wt_iew_batch_count']) ? $form_data['advanced_form_data']['wt_iew_batch_count'] : $batch_count);
900
+ }
901
+ if(isset($form_data['method_import_form_data']) && $file_type=='csv')
902
+ {
903
+ $csv_delimiter=(isset($form_data['method_import_form_data']['wt_iew_delimiter']) ? $form_data['method_import_form_data']['wt_iew_delimiter'] : $csv_delimiter);
904
+ $csv_delimiter=($csv_delimiter=="" ? ',' : $csv_delimiter);
905
+ }
906
+
907
+
908
+
909
+ include_once WT_P_IEW_PLUGIN_PATH.'admin/classes/class-csvreader.php';
910
+ $reader=new Wt_Import_Export_For_Woo_Basic_Csvreader($csv_delimiter);
911
+
912
+
913
+ /* important: prepare deafult mapping formdata for quick import */
914
+ $input_data=$reader->get_data_as_batch($file_path, $offset, $batch_count, $this, $form_data);
915
+
916
+ if(empty($input_data['data_arr'])){
917
+ $out['msg']=__('CSV is empty');
918
+ return $out;
919
+ }
920
+
921
+ if(!$input_data || !is_array($input_data))
922
+ {
923
+ $msg='Unable to process the file';
924
+ //no need to add translation function in message
925
+ Wt_Import_Export_For_Woo_Basic_History::record_failure($import_id, $msg);
926
+ $out['msg']=__($msg);
927
+ return $out;
928
+ }
929
+
930
+ /* checking action is finshed */
931
+ $is_last_offset=false;
932
+ $new_offset=$input_data['offset']; //increase the offset
933
+ if($new_offset>=$total_records) //finished
934
+ {
935
+ $is_last_offset=true;
936
+ }
937
+
938
+ /**
939
+ * In case of non schedule import. Offset row count.
940
+ * The real internal offset is in bytes, This offset is total row processed.
941
+ */
942
+ $offset_count=(isset($_POST['offset_count']) ? absint($_POST['offset_count']) : 0);
943
+
944
+ /* giving full data */
945
+ $form_data=apply_filters('wt_iew_import_full_form_data_basic', $form_data, $to_process, $step, $this->selected_template_data);
946
+
947
+ /* in scheduled import. The import method will not available so we need to take it from formdata */
948
+ $formdata_import_method=(isset($formdata['method_import_form_data']) && isset($formdata['method_import_form_data']['method_import']) ? $formdata['method_import_form_data']['method_import'] : 'quick');
949
+ $this->import_method=($this->import_method=="" ? $formdata_import_method : $this->import_method);
950
+
951
+ /**
952
+ * Import response format
953
+ */
954
+ $import_response=array(
955
+ 'total_success'=>$batch_count,
956
+ 'total_failed'=>0,
957
+ 'log_data'=>array(
958
+ array('row'=>$offset_count, 'message'=>'', 'status'=>true, 'post_id'=>''),
959
+ ),
960
+ );
961
+
962
+ $import_response=apply_filters('wt_iew_importer_do_import_basic', $input_data['data_arr'], $to_process, $step, $form_data, $this->selected_template_data, $this->import_method, $offset_count, $is_last_offset);
963
+
964
+ /**
965
+ * Writing import log to file
966
+ */
967
+ if(!empty($import_response) && is_array($import_response) && Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('enable_import_log')==1)
968
+ {
969
+ $log_writer=new Wt_Import_Export_For_Woo_Basic_Logwriter();
970
+ $log_file_name=$this->get_log_file_name($import_id);
971
+ $log_file_path=$this->get_file_path($log_file_name);
972
+ $log_data=(isset($import_response['log_data']) && is_array($import_response['log_data']) ? $import_response['log_data'] : array());
973
+ $log_writer->write_import_log($log_data, $log_file_path);
974
+ }
975
+
976
+
977
+ /* updating completed offset */
978
+ $update_data=array(
979
+ 'offset'=>$offset
980
+ );
981
+ $update_data_type=array(
982
+ '%d'
983
+ );
984
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($import_id, $update_data, $update_data_type);
985
+
986
+
987
+ /* updating output parameters */
988
+ $out['total_records']=$total_records;
989
+ $out['import_id']=$import_id;
990
+ $out['history_id']=$import_id;
991
+ $out['response']=true;
992
+
993
+ /* In case of non schedule import. total success, totla failed count */
994
+ $total_success=(isset($_POST['total_success']) ? absint($_POST['total_success']) : 0);
995
+ $total_failed=(isset($_POST['total_failed']) ? absint($_POST['total_failed']) : 0);
996
+
997
+ $out['total_success']=(isset($import_response['total_success']) ? $import_response['total_success'] : 0)+$total_success;
998
+ $out['total_failed']=(isset($import_response['total_failed']) ? $import_response['total_failed'] : 0)+$total_failed;
999
+
1000
+ /* updating action is finshed */
1001
+ if($is_last_offset) //finished
1002
+ {
1003
+ /* delete the temp file */
1004
+ @unlink($file_path);
1005
+
1006
+ $log_summary_msg=$this->generate_log_summary($out, $is_last_offset);
1007
+
1008
+ $out['finished']=1; //finished
1009
+ $out['msg']=$log_summary_msg;
1010
+
1011
+ /* updating finished status */
1012
+ $update_data=array(
1013
+ 'status'=>Wt_Import_Export_For_Woo_Basic_History::$status_arr['finished'],
1014
+ 'status_text'=>'Finished' //translation function not needed
1015
+ );
1016
+ $update_data_type=array(
1017
+ '%d',
1018
+ '%s',
1019
+ );
1020
+ Wt_Import_Export_For_Woo_Basic_History::update_history_entry($import_id, $update_data, $update_data_type);
1021
+ }else
1022
+ {
1023
+ $rows_processed=$input_data['rows_processed'];
1024
+ $total_processed=$rows_processed+$offset_count;
1025
+
1026
+ $out['offset_count']=$total_processed;
1027
+ $out['new_offset']=$new_offset;
1028
+
1029
+ $log_summary_msg=$this->generate_log_summary($out, $is_last_offset);
1030
+
1031
+ $out['msg']=$log_summary_msg;
1032
+ }
1033
+
1034
+ return $out;
1035
+ }
1036
+
1037
+ protected function generate_log_summary($data, $is_last_offset)
1038
+ {
1039
+ if($is_last_offset)
1040
+ {
1041
+ $msg='<span class="wt_iew_info_box_title">'.__('Finished').'</span>';
1042
+ $msg.='<span class="wt_iew_popup_close" style="line-height:10px;width:auto" onclick="wt_iew_basic_import.hide_import_info_box();">X</span>';
1043
+ }else
1044
+ {
1045
+ $msg='<span class="wt_iew_info_box_title">'.sprintf(__('Importing...(%d processed)'), $data['offset_count']).'</span>';
1046
+ }
1047
+ $msg.='<br />'.__('Total success: ').$data['total_success'].'<br />'.__('Total failed: ').$data['total_failed'];
1048
+ if($is_last_offset)
1049
+ {
1050
+ $msg.='<span class="wt_iew_info_box_finished_text" style="display:block">';
1051
+ if(Wt_Import_Export_For_Woo_Admin_Basic::module_exists('history'))
1052
+ {
1053
+ $msg.='<a class="button button-secondary wt_iew_view_log_btn" style="margin-top:10px;" data-history-id="'. $data['history_id'] .'" onclick="wt_iew_basic_import.hide_import_info_box();">'.__('View Details').'</a></span>';
1054
+ }
1055
+ }
1056
+ return $msg;
1057
+ }
1058
+
1059
+ /**
1060
+ * Main ajax hook to handle all import related requests
1061
+ */
1062
+ public function ajax_main()
1063
+ {
1064
+ include_once plugin_dir_path(__FILE__).'classes/class-import-ajax.php';
1065
+ if(Wt_Iew_Sh::check_write_access(WT_IEW_PLUGIN_ID_BASIC))
1066
+ {
1067
+ /**
1068
+ * Check it is a rerun call
1069
+ */
1070
+ if(!$this->_process_rerun((isset($_POST['rerun_id']) ? absint($_POST['rerun_id']) : 0)))
1071
+ {
1072
+ $this->import_method=(isset($_POST['import_method']) ? Wt_Iew_Sh::sanitize_item($_POST['import_method'], 'text') : '');
1073
+ $this->to_import=(isset($_POST['to_import']) ? Wt_Iew_Sh::sanitize_item($_POST['to_import'], 'text') : '');
1074
+ $this->selected_template=(isset($_POST['selected_template']) ? Wt_Iew_Sh::sanitize_item($_POST['selected_template'], 'int') : 0);
1075
+ }
1076
+
1077
+ $this->get_steps();
1078
+
1079
+ $ajax_obj=new Wt_Import_Export_For_Woo_Basic_Import_Ajax($this, $this->to_import, $this->steps, $this->import_method, $this->selected_template, $this->rerun_id);
1080
+
1081
+ $import_action=Wt_Iew_Sh::sanitize_item($_POST['import_action'], 'text');
1082
+ $data_type=Wt_Iew_Sh::sanitize_item($_POST['data_type'], 'text');
1083
+
1084
+ $allowed_ajax_actions=array('get_steps', 'validate_file', 'get_meta_mapping_fields', 'save_template', 'save_template_as', 'update_template', 'download', 'import', 'upload_import_file', 'delete_import_file');
1085
+
1086
+ $out=array(
1087
+ 'status'=>0,
1088
+ 'msg'=>__('Error'),
1089
+ );
1090
+
1091
+ if(method_exists($ajax_obj, $import_action) && in_array($import_action, $allowed_ajax_actions))
1092
+ {
1093
+ $out=$ajax_obj->{$import_action}($out);
1094
+ }
1095
+
1096
+ if($data_type=='json')
1097
+ {
1098
+ echo json_encode($out);
1099
+ }
1100
+ }
1101
+ exit();
1102
+ }
1103
+
1104
+ public function process_column_val($input_file_data_row, $form_data)
1105
+ {
1106
+ $out=array(
1107
+ 'mapping_fields'=>array(),
1108
+ 'meta_mapping_fields'=>array()
1109
+ );
1110
+
1111
+ /**
1112
+ * Default columns
1113
+ */
1114
+ $mapping_form_data=(isset($form_data['mapping_form_data']) ? $form_data['mapping_form_data'] : array());
1115
+ $mapping_selected_fields=(isset($mapping_form_data['mapping_selected_fields']) ? $mapping_form_data['mapping_selected_fields'] : array());
1116
+ $mapping_fields=(isset($mapping_form_data['mapping_fields']) ? $mapping_form_data['mapping_fields'] : array());
1117
+
1118
+ /**
1119
+ * Input date format.
1120
+ * This will be taken as the global date format for all date fields in the input file.
1121
+ * If date format is specified in the evaluation section. Then this value will be overriden.
1122
+ */
1123
+ $method_import_form_data=(isset($form_data['method_import_form_data']) ? $form_data['method_import_form_data'] : array());
1124
+ $input_date_format=(isset($method_import_form_data['wt_iew_date_format']) ? $method_import_form_data['wt_iew_date_format'] : '');
1125
+
1126
+ foreach ($mapping_selected_fields as $key => $value)
1127
+ {
1128
+ $out['mapping_fields'][$key]=$this->evaluate_data($key, $value, $input_file_data_row, $mapping_fields, $input_date_format);
1129
+ }
1130
+ $mapping_form_data=$mapping_fields=$mapping_selected_fields=null;
1131
+ unset($mapping_form_data, $mapping_fields, $mapping_selected_fields);
1132
+
1133
+ /**
1134
+ * Meta columns
1135
+ */
1136
+ $meta_step_form_data=(isset($form_data['meta_step_form_data']) ? $form_data['meta_step_form_data'] : array());
1137
+ $mapping_selected_fields=(isset($meta_step_form_data['mapping_selected_fields']) ? $meta_step_form_data['mapping_selected_fields'] : array());
1138
+ $mapping_fields=(isset($meta_step_form_data['mapping_fields']) ? $meta_step_form_data['mapping_fields'] : array());
1139
+ foreach ($mapping_selected_fields as $meta_key => $meta_val_arr)
1140
+ {
1141
+ $out['meta_mapping_fields'][$meta_key]=array();
1142
+ $meta_fields_arr=(isset($mapping_fields[$meta_key]) ? $mapping_fields[$meta_key] : array());
1143
+ foreach ($meta_val_arr as $key => $value)
1144
+ {
1145
+ $out['meta_mapping_fields'][$meta_key][$key]=$this->evaluate_data($key, $value, $input_file_data_row, $meta_fields_arr, $input_date_format);
1146
+ }
1147
+ }
1148
+ $meta_step_form_data=$mapping_fields=$mapping_selected_fields=$input_file_data_row=$form_data=null;
1149
+ unset($meta_step_form_data, $mapping_fields, $mapping_selected_fields, $input_file_data_row, $form_data);
1150
+
1151
+ return $out;
1152
+ }
1153
+ protected function evaluate_data($key, $value, $data_row, $mapping_fields, $input_date_format)
1154
+ {
1155
+ $value=$this->add_input_file_data($key, $value, $data_row, $mapping_fields, $input_date_format);
1156
+ $value=$this->do_arithmetic($value);
1157
+ $data_row=null;
1158
+ unset($data_row);
1159
+ return $value;
1160
+ }
1161
+ protected function do_arithmetic($str)
1162
+ {
1163
+ $re = '/\[([0-9()+\-*\/. ]+)\]/m';
1164
+ $matches=array();
1165
+ $find=array();
1166
+ $replace=array();
1167
+ if(preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0))
1168
+ {
1169
+ foreach ($matches as $key => $value)
1170
+ {
1171
+ if(is_array($value) && count($value)>1)
1172
+ {
1173
+ $synatx=$this->validate_syntax($value[1]);
1174
+ if($synatx)
1175
+ {
1176
+ $replace[]=eval('return '.$synatx.';');
1177
+ }else
1178
+ {
1179
+ $replace[]='';
1180
+ }
1181
+ $find[]=$value[0];
1182
+ unset($synatx);
1183
+ }
1184
+ }
1185
+ }
1186
+ return str_replace($find, $replace, $str);
1187
+ }
1188
+ protected function validate_syntax($val)
1189
+ {
1190
+ $open_bracket=substr_count($val, '(');
1191
+ $close_bracket=substr_count($val, ')');
1192
+ if($close_bracket!=$open_bracket)
1193
+ {
1194
+ return false; //invalid
1195
+ }
1196
+
1197
+ //remove whitespaces
1198
+ $val=str_replace(' ', '', $val);
1199
+ $re_after='/\b[\+|*|\-|\/]([^0-9\+\-\(])/m';
1200
+ $re_before='/([^0-9\+\-\)])[\+|*|\-|\/]/m';
1201
+
1202
+ $match_after=array();
1203
+ $match_before=array();
1204
+ if(preg_match_all($re_after, $val, $match_after, PREG_SET_ORDER, 0) || preg_match_all($re_before, $val, $match_before, PREG_SET_ORDER, 0))
1205
+ {
1206
+ return false; //invalid
1207
+ }
1208
+
1209
+ unset($match_after, $match_before, $re_after, $re_before);
1210
+
1211
+ /* process + and - symbols */
1212
+ $val=preg_replace(array('/\+{2,}/m', '/\-{2,}/m'), array('+', '- -'), $val);
1213
+
1214
+ return $val;
1215
+ }
1216
+ protected function add_input_file_data($key, $str, $data_row, $mapping_fields, $input_date_format)
1217
+ {
1218
+ $re = '/\{([^}]+)\}/m';
1219
+ $matches=array();
1220
+ preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0);
1221
+ $find=array();
1222
+ $replace=array();
1223
+ foreach ($matches as $key => $value)
1224
+ {
1225
+ if(is_array($value) && count($value)>1)
1226
+ {
1227
+ $data_key=trim($value[1]);
1228
+
1229
+ /* Check for date formatting */
1230
+ $data_key_arr=explode("@", $data_key);
1231
+ $data_format='';
1232
+ if(count($data_key_arr)==2) /* date format field given while on import */
1233
+ {
1234
+ $data_key=$data_key_arr[0]; //first value is the field key
1235
+ $data_format=$data_key_arr[1]; //second value will be the format
1236
+ }
1237
+
1238
+ /* Pre-defined date field */
1239
+ if(isset($mapping_fields[$data_key]) && isset($mapping_fields[$data_key][2]) && $mapping_fields[$data_key][2]='date')
1240
+ {
1241
+ /**
1242
+ * Always give preference to evaluation section
1243
+ * If not specified in evaluation section. Use default format
1244
+ */
1245
+ if($data_format=="")
1246
+ {
1247
+ $data_format=$input_date_format;
1248
+ }
1249
+ }
1250
+
1251
+ $output_val='';
1252
+ if(isset($data_row[$data_key]))
1253
+ {
1254
+ // $output_val=sanitize_text_field($data_row[$data_key]); sanitize_text_field stripping html content
1255
+ $output_val=($data_row[$data_key]);
1256
+ }
1257
+
1258
+ /**
1259
+ * This is a date field
1260
+ */
1261
+ if(trim($data_format)!="" && trim($output_val)!="")
1262
+ {
1263
+ if(version_compare(PHP_VERSION, '5.6.0', '>='))
1264
+ {
1265
+ $date_obj=DateTime::createFromFormat($data_format, $output_val);
1266
+ if($date_obj)
1267
+ {
1268
+ $output_val=$date_obj->format('Y-m-d H:i:s');
1269
+ }
1270
+ }else
1271
+ {
1272
+ $output_val=date("Y-m-d H:i:s", strtotime(trim(str_replace('/', '-', str_replace('-', '', $output_val)))));
1273
+ }
1274
+ }
1275
+
1276
+ $replace[]=$output_val;
1277
+ $find[]=$value[0];
1278
+ unset($data_key);
1279
+ }
1280
+ }
1281
+ $data_row=null;
1282
+ unset($data_row);
1283
+ return str_replace($find, $replace, $str);
1284
+ }
1285
+ }
1286
+ }
1287
+ Wt_Import_Export_For_Woo_Basic::$loaded_modules['import']=new Wt_Import_Export_For_Woo_Basic_Import();
admin/modules/import/views/_import_advanced_page.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_import_main">
7
+ <p><?php echo $this->step_description;?></p>
8
+ <form class="wt_iew_import_advanced_form">
9
+ <table class="form-table wt-iew-form-table">
10
+ <?php
11
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::field_generator($advanced_screen_fields, $advanced_form_data);
12
+ ?>
13
+ </table>
14
+ </form>
15
+ </div>
16
+ <script type="text/javascript">
17
+ /* custom action: other than import, save, update. Eg: schedule */
18
+ function wt_iew_custom_action_basic(ajx_dta, action, id)
19
+ {
20
+ ajx_dta['item_type']=ajx_dta['to_import'];
21
+ <?php
22
+ do_action('wt_iew_custom_action_basic');
23
+ ?>
24
+ }
25
+ </script>
admin/modules/import/views/_import_footer.php ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-plugin-toolbar bottom">
7
+ <div style="float:left; padding-top:10px;" class="wt_iew_import_template_name"> </div>
8
+ <div style="float:right;">
9
+ <div style="float:right;">
10
+ <?php
11
+ $button_types = array_column(array_values($this->step_btns), 'type');
12
+ $last_button_key = array_search('button', array_reverse($button_types, true));
13
+ $count = 0;
14
+ $button_standard_class = 'media-button';
15
+ foreach($this->step_btns as $btnk=>$btnv)
16
+ {
17
+ $css_class=(isset($btnv['class']) ? $btnv['class'] : '');
18
+ $action_type=(isset($btnv['action_type']) ? $btnv['action_type'] : 'non-step');
19
+ if($count == $last_button_key){
20
+ $button_standard_class = 'button-primary';
21
+ }
22
+ if($btnv['type']=='button')
23
+ {
24
+ ?>
25
+ <button class="button <?php echo $button_standard_class; ?> wt_iew_import_action_btn <?php echo $css_class; ?>" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnv['key'];?>" type="submit">
26
+ <?php echo $btnv['text'];?>
27
+ </button>
28
+ <?php
29
+
30
+ }
31
+ elseif($btnv['type']=='dropdown_button')
32
+ {
33
+ $btn_arr=(isset($btnv['items']) && is_array($btnv['items']) ? $btnv['items'] : array());
34
+ ?>
35
+ <button type="button" class="button button-primary wt_iew_drp_menu <?php echo $css_class; ?>" data-target="wt_iew_<?php echo $btnk; ?>_drp">
36
+ <?php echo $btnv['text'];?> <span class="dashicons dashicons-arrow-down" style="line-height: 28px;"></span>
37
+ </button>
38
+ <ul class="wt_iew_dropdown <?php echo $css_class; ?>" data-id="wt_iew_<?php echo $btnk; ?>_drp">
39
+ <?php
40
+ foreach($btn_arr as $btnkk => $btnvv)
41
+ {
42
+ $field_attr=(isset($btnvv['field_attr']) ? $btnvv['field_attr'] : '');
43
+ $action_type=(isset($btnvv['action_type']) ? $btnvv['action_type'] : 'non-step');
44
+ ?>
45
+ <li class="wt_iew_import_action_btn" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnvv['key'];?>" <?php echo $field_attr;?> ><?php echo $btnvv['text'];?></li>
46
+ <?php
47
+ }
48
+ ?>
49
+ </ul>
50
+ <?php
51
+ }
52
+ elseif($btnv['type']=='hidden_button')
53
+ {
54
+ ?>
55
+ <button style="display:none;" class="button button-primary wt_iew_import_action_btn <?php echo $css_class; ?>" data-action-type="<?php echo $action_type; ?>" data-action="<?php echo $btnv['key'];?>" type="submit">
56
+ <?php echo $btnv['text'];?>
57
+ </button>
58
+ <?php
59
+
60
+ }
61
+ elseif($btnv['type']=='text')
62
+ {
63
+ ?>
64
+ <span style="line-height:40px; font-weight:bold;" class="<?php echo $css_class; ?>"><?php echo $btnv['text'];?></span>
65
+ <?php
66
+ }
67
+ $count++;
68
+ }
69
+ ?>
70
+ </div>
71
+ </div>
72
+ <span class="spinner" style="margin-top:11px;"></span>
73
+ </div>
admin/modules/import/views/_import_header.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-settings-header">
7
+ <h3>
8
+ <?php _e('Import'); ?><?php if($this->step!='post_type'){ ?> <span class="wt_iew_step_head_post_type_name"></span><?php } ?>: <?php echo $this->step_title; ?>
9
+ </h3>
10
+ <span class="wt_iew_step_info" title="<?php echo $this->step_summary; ?>">
11
+ <?php /* step count summary */
12
+ echo $this->step_summary;
13
+ ?>
14
+ </span>
15
+ </div>
admin/modules/import/views/_import_mapping_page.php ADDED
@@ -0,0 +1,282 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <?php
7
+ $click_to_use=__('Click to use');
8
+ ?>
9
+ <script type="text/javascript">
10
+ var wt_iew_file_head_default=<?php echo json_encode($file_heading_default_fields);?>;
11
+ var wt_iew_file_head_meta=<?php echo json_encode($file_heading_meta_fields);?>;
12
+ </script>
13
+
14
+ <!-- Mapping field editor popup -->
15
+ <div class="wt_iew_mapping_field_editor_container" data-title="<?php _e('Set value for column:');?> <span class='wt_iew_target_column'></span>" data-module="import">
16
+ <div class="wt_iew_mapping_field_editor">
17
+ <p class="wt_iew_mapping_field_editor_info" style="margin-bottom:5px;"><?php _e('Select and map any column from the input file or compute values with expressions.'); ?></p>
18
+
19
+ <label><?php _e('Expression');?></label>
20
+ <p class="wt_iew_mapping_field_editor_info">
21
+ <ul class="wt_evaluation_expression_points">
22
+ <li><?php _e('Append operators like + * / - () & @ or string constants along with the column names to update the values on import.'); ?></li>
23
+ <li><?php echo sprintf(__('Ensure to enclose the expressions in square brackets. E.g. To increase the stock quantity of %sall imported products%s by 5 units, input [{_stock}+5] in the stock column.'), '<b>', '</b>');?></li>
24
+ </ul>
25
+ </p>
26
+ <p class="wt_iew_mapping_field_editor_er"></p>
27
+ <div class="wt_iew_mapping_field_editor_box">
28
+ <textarea class="wt_iew_mapping_field_editor_expression"></textarea>
29
+ </div>
30
+
31
+ <label><?php _e('Input file columns');?></label>
32
+ <div class="wt_iew_mapping_field_editor_box">
33
+ <input type="text" class="wt_iew_mapping_field_editor_column_search" placeholder="<?php _e('Type here to search');?>">
34
+ <div class="wt_iew_mapping_field_selector_box">
35
+ <ul class="wt_iew_mapping_field_selector">
36
+ <?php
37
+ foreach ($file_heading_default_fields as $key => $value)
38
+ {
39
+ ?>
40
+ <li title="<?php echo $click_to_use;?>" data-val="<?php echo $key;?>"><?php echo $key;?></li>
41
+ <?php
42
+ }
43
+ foreach ($file_heading_meta_fields as $key => $value)
44
+ {
45
+ ?>
46
+ <li title="<?php echo $click_to_use;?>" data-val="<?php echo $key;?>"><?php echo $key;?></li>
47
+ <?php
48
+ }
49
+ ?>
50
+ </ul>
51
+ <div class="wt_iew_mapping_field_selector_no_column"><?php _e('No column found.');?></div>
52
+ </div>
53
+ </div>
54
+
55
+ <label><?php _e('Output');?></label>
56
+ <p class="wt_iew_mapping_field_editor_info">
57
+ <?php _e('Sample value based on first record from input file. Columns that have no values in the input file may cause syntax errors if used in an expression as above.'); ?>
58
+ </p>
59
+ <div class="wt_iew_mapping_field_editor_box" style="max-height:80px; overflow:auto; margin-bottom:0px; border:dashed 1px #ccc; padding:5px;">
60
+ <div class="wt_iew_mapping_field_editor_sample"></div>
61
+ </div>
62
+ </div>
63
+ </div>
64
+ <!-- Mapping field editor popup -->
65
+
66
+ <div class="wt_iew_import_main">
67
+ <p><?php echo $this->step_description;?></p>
68
+
69
+ <p class="wt_iew_info_box wt_iew_info">
70
+ <?php _e('Columns are mapped automatically only if a matching header name is found in the input file. If not the value is left blank.');?>
71
+ <br />
72
+ <?php _e('If your input file header does not have exact names or if you need to edit the existing mapping you can simply click on the respective value fields corresponding to each row. Furthermore you can also assign expressions based on the existing input file columns.');?>
73
+ </p>
74
+
75
+ <div class="meta_mapping_box">
76
+ <div class="meta_mapping_box_hd_nil wt_iew_noselect">
77
+ <?php _e('Default fields');?>
78
+ <span class="meta_mapping_box_selected_count_box"><span class="meta_mapping_box_selected_count_box_num">0</span> <?php _e(' columns(s) selected'); ?></span>
79
+ </div>
80
+ <div style="clear:both;"></div>
81
+ <div class="meta_mapping_box_con" data-sortable="0" data-loaded="1" data-field-validated="0" data-key="" style="display:inline-block;">
82
+ <table class="wt-iew-mapping-tb wt-iew-importer-default-mapping-tb">
83
+ <thead>
84
+ <tr>
85
+ <th>
86
+ <input type="checkbox" name="" class="wt_iew_mapping_checkbox_main">
87
+ </th>
88
+ <th width="35%"><?php _e('Column');?></th>
89
+ <th><?php _e('Column name');?></th>
90
+ </tr>
91
+ </thead>
92
+ <tbody>
93
+ <?php
94
+ $draggable_tooltip=__("Drag to rearrange the columns");
95
+ $tr_count=0;
96
+ foreach($form_data_mapping_fields as $key=>$val_arr) /* looping the template form data */
97
+ {
98
+ $val=$val_arr[0]; /* normal column val */
99
+ $checked=$val_arr[1]; /* import this column? */
100
+
101
+ if(isset($mapping_fields[$key])) /* found in default field list */
102
+ {
103
+ $label=(isset($mapping_fields[$key]['title']) ? $mapping_fields[$key]['title'] : '');
104
+ $description=(isset($mapping_fields[$key]['description']) ? $mapping_fields[$key]['description'] : '');
105
+ $type=(isset($mapping_fields[$key]['type']) ? $mapping_fields[$key]['type'] : '');
106
+ unset($mapping_fields[$key]); //remove the field from default list
107
+
108
+ if(isset($file_heading_default_fields[$key])) /* also found in file heading list */
109
+ {
110
+ unset($file_heading_default_fields[$key]); //remove the field from file heading list
111
+ }
112
+
113
+ include "_import_mapping_tr_html.php";
114
+ $tr_count++;
115
+ }
116
+ elseif(isset($file_heading_default_fields[$key])) /* found in file heading list */
117
+ {
118
+ $label=$key;
119
+ $description=$key;
120
+ $type='';
121
+ unset($file_heading_default_fields[$key]); //remove the field from file heading list
122
+ include "_import_mapping_tr_html.php";
123
+ $tr_count++;
124
+ }
125
+ elseif(isset($file_heading_meta_fields[$key])) /* some meta items will show inside default field list, Eg: yoast */
126
+ {
127
+ $label=$key;
128
+ $description=$key;
129
+ $type='';
130
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
131
+ include "_import_mapping_tr_html.php";
132
+ $tr_count++;
133
+ }
134
+ }
135
+
136
+ /**
137
+ * ####Important####
138
+ * The similar code also done in Default mapping preparation step for quick import.
139
+ * If any updates done please update there also
140
+ * Method _prepare_for_quick in import ajax class
141
+ */
142
+
143
+ if(count($mapping_fields)>0)
144
+ {
145
+ $array_keys_file_heading_default_fields = array_keys($file_heading_default_fields);
146
+ $allowed_field_types=array('start_with', 'end_with', 'contain');
147
+ foreach($mapping_fields as $key=>$val_arr)
148
+ {
149
+ $label=(isset($val_arr['title']) ? $val_arr['title'] : '');
150
+ $description=(isset($val_arr['description']) ? $val_arr['description'] : '');
151
+ $type=(isset($val_arr['type']) ? $val_arr['type'] : '');
152
+ $val='';
153
+ $checked=0; /* import this column? */
154
+ // if(isset($file_heading_default_fields[$key]))
155
+ if($case_key = preg_grep("/^$key$/i", $array_keys_file_heading_default_fields)) //preg_grep used escape from case sensitive check.
156
+ {
157
+ $checked=1; /* import this column? */
158
+ // $val='{'.$key.'}';
159
+ $val='{'.array_shift($case_key).'}'; // preg_grep give an array with actual index and value
160
+ unset($file_heading_default_fields[$key]); //remove the field from file heading list
161
+ unset($array_keys_file_heading_default_fields[$key]);
162
+ include "_import_mapping_tr_html.php";
163
+ $tr_count++;
164
+ }
165
+ elseif(isset($file_heading_meta_fields[$key])) /* some meta items will show inside default field list, Eg: yoast */
166
+ {
167
+ $checked=1; /* import this column? */
168
+ $val='{'.$key.'}';
169
+ unset($file_heading_meta_fields[$key]); //remove the field from file heading list
170
+ include "_import_mapping_tr_html.php";
171
+ $tr_count++;
172
+ }else
173
+ {
174
+
175
+ $field_type=(isset($val_arr['field_type']) ? $val_arr['field_type'] : '');
176
+ if($field_type!="" && in_array($field_type, $allowed_field_types)) // it may be a different field type
177
+ {
178
+ foreach ($file_heading_default_fields as $def_key => $def_val)
179
+ {
180
+ $matched=false;
181
+ if($field_type=='start_with' && strpos($def_key, $key)===0)
182
+ {
183
+ $matched=true;
184
+ }
185
+ elseif($field_type=='ends_with' && strrpos($def_key, $key)===(strlen($def_key) - strlen($key)))
186
+ {
187
+ $matched=true;
188
+ }
189
+ elseif($field_type=='contains' && strpos($def_key, $key)!==false)
190
+ {
191
+ $matched=true;
192
+ }
193
+ if($matched)
194
+ {
195
+ $checked=1; // import this column?
196
+ $val='{'.$def_key.'}';
197
+ $label=$def_key;
198
+ $key_backup=$key;
199
+ $key=$def_key;
200
+ unset($file_heading_default_fields[$def_key]); //remove the field from file heading list
201
+ include "_import_mapping_tr_html.php";
202
+ $tr_count++;
203
+ $key=$key_backup;
204
+ }
205
+ }
206
+ }else /* unmatched keys */
207
+ {
208
+ $checked=0; /* import this column? */
209
+ $val='';
210
+ include "_import_mapping_tr_html.php";
211
+ $tr_count++;
212
+ }
213
+ }
214
+ }
215
+ }
216
+ if(count($file_heading_default_fields)>0) /* show the remaining items */
217
+ {
218
+ /*
219
+ foreach($file_heading_default_fields as $key=>$sample_val)
220
+ {
221
+ $label=$key;
222
+ $description=$key;
223
+ $val='{'.$key.'}';
224
+ $checked=1;
225
+ include "_import_mapping_tr_html.php";
226
+ $tr_count++;
227
+ }
228
+ */
229
+ }
230
+ if($tr_count==0)
231
+ {
232
+ ?>
233
+ <tr>
234
+ <td colspan="3" style="text-align:center;">
235
+ <?php _e('No fields found.'); ?>
236
+ </td>
237
+ </tr>
238
+ <?php
239
+ }
240
+ ?>
241
+ </tbody>
242
+ </table>
243
+ </div>
244
+ </div>
245
+ <div style="clear:both;"></div>
246
+
247
+ <?php
248
+ if($this->mapping_enabled_fields)
249
+ {
250
+ foreach($this->mapping_enabled_fields as $mapping_enabled_field_key=>$mapping_enabled_field)
251
+ {
252
+ $mapping_enabled_field=(!is_array($mapping_enabled_field) ? array($mapping_enabled_field, 0) : $mapping_enabled_field);
253
+
254
+ if(count($form_data_mapping_enabled_fields)>0)
255
+ {
256
+ if(in_array($mapping_enabled_field_key, $form_data_mapping_enabled_fields))
257
+ {
258
+ $mapping_enabled_field[1]=1;
259
+ }else
260
+ {
261
+ $mapping_enabled_field[1]=0;
262
+ }
263
+ }
264
+ ?>
265
+ <div class="meta_mapping_box">
266
+ <div class="meta_mapping_box_hd wt_iew_noselect">
267
+ <span class="dashicons dashicons-arrow-right"></span>
268
+ <?php echo $mapping_enabled_field[0];?>
269
+ <span class="meta_mapping_box_selected_count_box"><span class="meta_mapping_box_selected_count_box_num">0</span> <?php _e(' columns(s) selected'); ?></span>
270
+ </div>
271
+ <div style="clear:both;"></div>
272
+ <div class="meta_mapping_box_con" data-sortable="0" data-loaded="0" data-field-validated="0" data-key="<?php echo $mapping_enabled_field_key;?>"></div>
273
+ </div>
274
+ <div style="clear:both;"></div>
275
+ <?php
276
+ }
277
+ }
278
+ ?>
279
+ </div>
280
+ <script type="text/javascript">
281
+ var wt_iew_file_head_remaining_meta=<?php echo json_encode($file_heading_meta_fields);?>;
282
+ </script>
admin/modules/import/views/_import_mapping_tr_html.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <tr id="columns_<?php echo $key;?>">
7
+ <td>
8
+ <input type="checkbox" name="columns_key[]" class="columns_key wt_iew_mapping_checkbox_sub" value="<?php echo $key;?>" <?php echo ($checked==1 ? 'checked' : ''); ?>>
9
+ </td>
10
+ <td>
11
+ <label class="wt_iew_mapping_column_label"><?php echo $label;?></label>
12
+ </td>
13
+ <td>
14
+ <input type="hidden" name="columns_val[]" class="columns_val" value="<?php echo $val;?>" data-type="<?php echo $type;?>">
15
+ <span data-wt_iew_popover="1" data-title="" data-content-container=".wt_iew_mapping_field_editor_container" class="wt_iew_mapping_field_val"><?php echo $val;?></span>
16
+ </td>
17
+ </tr>
admin/modules/import/views/_import_meta_step_page.php ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <table class="wt-iew-mapping-tb wt-iew-importer-meta-mapping-tb" data-field-type="<?php echo $meta_mapping_screen_field_key; ?>">
7
+ <thead>
8
+ <tr>
9
+ <th>
10
+ <?php
11
+ $is_checked=$meta_mapping_screen_field_val['checked'];
12
+ $checked_attr=($is_checked==1 ? ' checked="checked"' : '');
13
+ ?>
14
+ <input type="checkbox" name="" class="wt_iew_mapping_checkbox_main" <?php echo $checked_attr; ?>>
15
+ </th>
16
+ <th width="35%"><?php _e('Column');?></th>
17
+ <th><?php _e('Column name');?></th>
18
+ </tr>
19
+ </thead>
20
+ <tbody>
21
+ <?php
22
+ $tr_count=0;
23
+
24
+ foreach($meta_mapping_screen_field_val['fields'] as $key=>$val_arr)
25
+ {
26
+ extract($val_arr);
27
+ include "_import_mapping_tr_html.php";
28
+ $tr_count++;
29
+ }
30
+
31
+ if($tr_count==0)
32
+ {
33
+ ?>
34
+ <tr>
35
+ <td colspan="3" style="text-align:center;">
36
+ <?php _e('No fields found.'); ?>
37
+ </td>
38
+ </tr>
39
+ <?php
40
+ }
41
+ ?>
42
+ </tbody>
43
+ </table>
admin/modules/import/views/_import_method_import_page.php ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_import_main">
7
+ <p><?php //echo $this->step_description;?></p>
8
+ <div class="wt_iew_warn wt_iew_method_import_wrn" style="display:none;">
9
+ <?php _e('Please select an import template.');?>
10
+ </div>
11
+ <table class="form-table wt-iew-form-table">
12
+ <tr>
13
+ <th><label><?php _e('Import method');?></label></th>
14
+ <td colspan="2" style="width:75%;">
15
+ <div class="wt_iew_radio_block">
16
+ <?php
17
+ foreach($this->import_obj->import_methods as $key => $value)
18
+ {
19
+ ?>
20
+ <p>
21
+ <input type="radio" value="<?php echo $key;?>" id="wt_iew_import_<?php echo $key;?>_import" name="wt_iew_import_method_import" <?php echo ($this->import_method==$key ? 'checked="checked"' : '');?>><b><label for="wt_iew_import_<?php echo $key;?>_import"><?php echo $value['title']; ?></label></b> <br />
22
+ <span><label for="wt_iew_import_<?php echo $key;?>_import"><?php echo $value['description']; ?></label></span>
23
+ </p>
24
+ <?php
25
+ }
26
+ ?>
27
+ </div>
28
+ </td>
29
+ </tr>
30
+ <tr><div id="user-required-field-message" class="updated" style="margin-left:0px;display: none;background: #dceff4;"><p><?php _e('Ensure the import file has the user\'s email ID for a successful import. Use default column name <b>user_email</b> or map the column accordingly if you are using a custom column name.'); ?></p></div></tr>
31
+ <tr class="wt-iew-import-method-options wt-iew-import-method-options-template wt-iew-import-template-sele-tr" style="display:none;">
32
+ <th><label><?php _e('Import template');?></label></th>
33
+ <td>
34
+ <select class="wt-iew-import-template-sele">
35
+ <option value="0">-- <?php _e('Select a template'); ?> --</option>
36
+ <?php
37
+ foreach($this->mapping_templates as $mapping_template)
38
+ {
39
+ ?>
40
+ <option value="<?php echo $mapping_template['id'];?>" <?php echo ($form_data_import_template==$mapping_template['id'] ? ' selected="selected"' : ''); ?>>
41
+ <?php echo $mapping_template['name'];?>
42
+ </option>
43
+ <?php
44
+ }
45
+ ?>
46
+ </select>
47
+ </td>
48
+ <td>
49
+ </td>
50
+ </tr>
51
+ </table>
52
+ <form class="wt_iew_import_method_import_form">
53
+ <table class="form-table wt-iew-form-table">
54
+ <?php
55
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::field_generator($method_import_screen_fields, $method_import_form_data);
56
+ ?>
57
+ </table>
58
+ </form>
59
+ </div>
60
+ <script type="text/javascript">
61
+ /* remote file modules can hook */
62
+ function wt_iew_set_file_from_fields(file_from)
63
+ {
64
+ <?php
65
+ do_action('wt_iew_importer_file_from_js_fn');
66
+ ?>
67
+ }
68
+
69
+ function wt_iew_set_validate_file_info(file_from)
70
+ {
71
+ <?php
72
+ do_action('wt_iew_importer_set_validate_file_info');
73
+ ?>
74
+ }
75
+ </script>
admin/modules/import/views/_import_post_type_page.php ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+ <div class="wt_iew_import_main">
7
+ <p><?php echo $this->step_description;?></p>
8
+ <div class="wt_iew_warn wt_iew_post_type_wrn" style="display:none;">
9
+ <?php _e('Please select a post type');?>
10
+ </div>
11
+ <table class="form-table wt-iew-form-table">
12
+ <tr>
13
+ <th><label><?php _e('Select a post type to import'); ?></label></th>
14
+ <td>
15
+ <select name="wt_iew_import_post_type">
16
+ <option value="">-- <?php _e('Select post type'); ?> --</option>
17
+ <?php
18
+ $item_type = isset($item_type) ? $item_type : '';
19
+ foreach($post_types as $key=>$value)
20
+ {
21
+ ?>
22
+ <option value="<?php echo $key;?>" <?php echo ($item_type==$key ? 'selected' : '');?>><?php echo $value;?></option>
23
+ <?php
24
+ }
25
+ ?>
26
+ </select>
27
+ </td>
28
+ <td></td>
29
+ </tr>
30
+ </table>
31
+ </div>
admin/modules/import/views/main.php ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Main view file of import section
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ ?>
13
+ <?php
14
+ do_action('wt_iew_importer_before_head');
15
+ $wf_admin_view_path=plugin_dir_path(WT_P_IEW_PLUGIN_FILENAME).'admin/views/';
16
+ ?>
17
+ <style type="text/css">
18
+ .wt_iew_import_step{ display:none; }
19
+ .wt_iew_import_step_loader{ width:100%; height:400px; text-align:center; line-height:400px; font-size:14px; }
20
+ .wt_iew_import_step_main{ float:left; box-sizing:border-box; padding:15px; padding-bottom:0px; width:95%; margin:30px 2.5%; background:#fff; box-shadow:0px 2px 2px #ccc; border:solid 1px #efefef; }
21
+ .wt_iew_import_main{ padding:20px 0px; }
22
+ select[name=wt_iew_file_from]{visibility: hidden;}
23
+ </style>
24
+ <div class="wt_iew_view_log wt_iew_popup" style="text-align:left">
25
+ <div class="wt_iew_popup_hd">
26
+ <span style="line-height:40px;" class="dashicons dashicons-media-text"></span>
27
+ <span class="wt_iew_popup_hd_label"><?php _e('History Details');?></span>
28
+ <div class="wt_iew_popup_close">X</div>
29
+ </div>
30
+ <div class="wt_iew_log_container" style="padding:25px;">
31
+
32
+ </div>
33
+ </div>
34
+ <?php
35
+ Wt_Iew_IE_Basic_Helper::debug_panel($this->module_base);
36
+ ?>
37
+ <?php include WT_P_IEW_PLUGIN_PATH."/admin/views/_save_template_popup.php"; ?>
38
+
39
+ <h2 class="wt_iew_page_hd"><?php _e('Import'); ?><span class="wt_iew_post_type_name"></span></h2>
40
+
41
+ <?php
42
+ if($requested_rerun_id>0 && $this->rerun_id==0)
43
+ {
44
+ ?>
45
+ <div class="wt_iew_warn wt_iew_rerun_warn">
46
+ <?php _e('Unable to handle Re-Run request.');?>
47
+ </div>
48
+ <?php
49
+ }
50
+ ?>
51
+
52
+ <div class="wt_iew_loader_info_box"></div>
53
+ <div class="wt_iew_overlayed_loader"></div>
54
+
55
+ <div class="wt_iew_import_step_main" style = "width:68%">
56
+ <?php
57
+ foreach($this->steps as $stepk=>$stepv)
58
+ {
59
+ ?>
60
+ <div class="wt_iew_import_step wt_iew_import_step_<?php echo $stepk;?>" data-loaded="0"></div>
61
+ <?php
62
+ }
63
+ ?>
64
+ </div>
65
+ <?php include $wf_admin_view_path."market.php"; ?>
66
+ <script type="text/javascript">
67
+ /* external modules can hook */
68
+ function wt_iew_importer_validate_basic(action, action_type, is_previous_step)
69
+ {
70
+ var is_continue=true;
71
+ <?php
72
+ do_action('wt_iew_importer_validate_basic');
73
+ ?>
74
+ return is_continue;
75
+ }
76
+ function wt_iew_importer_reset_form_data_basic()
77
+ {
78
+ <?php
79
+ do_action('wt_iew_importer_reset_form_data_basic');
80
+ ?>
81
+ }
82
+ </script>
admin/modules/product/data/data-allowed-product-types.php ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('WPINC')) {
3
+ exit;
4
+ }
5
+
6
+ $allowed_product_types = array(
7
+ 'simple' => __('Simple product', 'woocommerce'),
8
+ 'grouped' => __('Grouped product', 'woocommerce'),
9
+ 'external' => __('External/Affiliate product', 'woocommerce'),
10
+ 'variable' => __('Variable product', 'woocommerce'),
11
+ );
12
+
13
+
14
+ // Subscription product types
15
+ if (class_exists('WC_Subscriptions')) {
16
+ $subscription_term = get_term_by('slug', 'subscription', 'product_type');
17
+ $variable_subscription_term = get_term_by('slug', 'variable-subscription', 'product_type');
18
+
19
+ $allowed_product_types['subscription'] = $subscription_term->name;
20
+ $allowed_product_types['variable-subscription'] = $variable_subscription_term->name;
21
+ }
22
+
23
+ // Composite product type
24
+ if (class_exists('WC_Composite_Products')) {
25
+ $composite_term = get_term_by('name', 'composite', 'product_type');
26
+
27
+ if ($composite_term) {
28
+ $allowed_product_types['composite'] = $composite_term->name;
29
+ }
30
+ }
31
+ // Simple Auction product type
32
+ if (class_exists('WooCommerce_simple_auction')) {
33
+ $auction_term = get_term_by('name', 'auction', 'product_type');
34
+
35
+ if ($auction_term) {
36
+ $allowed_product_types['auction'] = $auction_term->name;
37
+ }
38
+ }
39
+
40
+ // Bundle product type
41
+ if (class_exists('WC_Bundles')) {
42
+ $bundle_term = get_term_by('name', 'bundle', 'product_type');
43
+
44
+ if ($bundle_term) {
45
+ $allowed_product_types['bundle'] = $bundle_term->name;
46
+ }
47
+ }
48
+
49
+ // Wcpb Product Bundle
50
+ if (class_exists('WC_Product_Wcpb')) {
51
+ $wcbundle_term = get_term_by('name', 'wcpb', 'product_type');
52
+
53
+ if ($wcbundle_term) {
54
+ $allowed_product_types['wcpb'] = $wcbundle_term->name;
55
+ }
56
+ }
57
+
58
+ // Booking product types
59
+ if (class_exists('WC_Booking')) {
60
+ $booking_term = get_term_by('slug', 'booking', 'product_type');
61
+
62
+ if ($booking_term) {
63
+ $allowed_product_types['booking'] = $booking_term->name;
64
+ }
65
+ }
66
+
67
+ // Photography product types
68
+ if (class_exists('WC_Photography')) {
69
+ $photography_term = get_term_by('slug', 'photography', 'product_type');
70
+
71
+ if ($photography_term) {
72
+ $allowed_product_types['photography'] = $photography_term->name;
73
+ }
74
+ }
75
+ return apply_filters('wt_iew_allowed_product_types', $allowed_product_types);
admin/modules/product/data/data-product-post-columns.php ADDED
@@ -0,0 +1,111 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if (!defined('WPINC')) {
4
+ exit;
5
+ }
6
+
7
+ if (function_exists('wc_get_filename_from_url')) {
8
+ $file_path_header = 'downloadable_files';
9
+ } else {
10
+ $file_path_header = 'file_paths';
11
+ }
12
+
13
+
14
+ $post_columns = array(
15
+ 'post_title' => 'Product Name',
16
+ 'post_name' => 'Product Slug',
17
+ 'post_parent' => 'Parent ID',
18
+ 'ID' => 'ID',
19
+ 'post_excerpt' => 'Short Description',
20
+ 'post_content' => 'Description',
21
+ 'post_status' => 'Status',
22
+ 'post_password' => 'post_password',
23
+ 'menu_order' => 'menu_order',
24
+ 'post_date' => 'post_date',
25
+ 'post_author' => 'post_author',
26
+ 'comment_status' => 'comment_status',
27
+ // Meta
28
+
29
+ '_sku' => 'sku',
30
+ 'parent_sku' => 'parent_sku',
31
+ 'parent' => 'Parent Title',
32
+ '_children' => 'children', //For Grouped products
33
+ '_downloadable' => 'downloadable',
34
+ '_virtual' => 'virtual',
35
+ '_stock' => 'stock',
36
+ '_regular_price' => 'Regular Price',
37
+ '_sale_price' => 'Sale Price',
38
+ '_weight' => 'weight',
39
+ '_length' => 'length',
40
+ '_width' => 'width',
41
+ '_height' => 'height',
42
+ '_tax_class' => 'tax_class',
43
+ '_visibility' => 'visibility',
44
+ '_stock_status' => 'stock_status',
45
+ '_backorders' => 'backorders',
46
+ '_sold_individually' => 'sold_individually',
47
+ '_low_stock_amount' => 'low_stock_amount',
48
+ '_manage_stock' => 'manage_stock',
49
+ '_tax_status' => 'tax_status',
50
+ '_upsell_ids' => 'upsell_ids',
51
+ '_crosssell_ids' => 'crosssell_ids',
52
+ '_featured' => 'featured',
53
+ '_purchase_note' => '_purchase_note',
54
+ '_sale_price_dates_from' => 'sale_price_dates_from',
55
+ '_sale_price_dates_to' => 'sale_price_dates_to',
56
+ // Downloadable products
57
+ '_download_limit' => 'download_limit',
58
+ '_download_expiry' => 'download_expiry',
59
+ // Virtual products
60
+ '_product_url' => 'product_url',
61
+ '_button_text' => 'button_text',
62
+
63
+
64
+
65
+ 'images' => 'Images (featured and gallery)',
66
+ "$file_path_header" => 'Downloadable file paths',
67
+ 'product_page_url' => 'Product Page URL',
68
+ //'taxonomies' => 'Taxonomies (cat/tags/shipping-class)',
69
+ //'meta' => 'Meta (custom fields)',
70
+ //'attributes' => 'Attributes',
71
+ );
72
+
73
+ if(class_exists('WPSEO_Options')){
74
+ /* Yoast is active */
75
+
76
+ $post_columns['meta:_yoast_wpseo_focuskw'] = 'meta:_yoast_wpseo_focuskw';
77
+ $post_columns['meta:_yoast_wpseo_canonical'] = 'meta:_yoast_wpseo_canonical';
78
+ $post_columns['meta:_yoast_wpseo_bctitle'] = 'meta:_yoast_wpseo_bctitle';
79
+ $post_columns['meta:_yoast_wpseo_meta-robots-adv'] = 'meta:_yoast_wpseo_meta-robots-adv';
80
+ $post_columns['meta:_yoast_wpseo_is_cornerstone'] ='meta:_yoast_wpseo_is_cornerstone';
81
+ $post_columns['meta:_yoast_wpseo_metadesc'] = 'meta:_yoast_wpseo_metadesc';
82
+ $post_columns['meta:_yoast_wpseo_linkdex'] = 'meta:_yoast_wpseo_linkdex';
83
+ $post_columns['meta:_yoast_wpseo_estimated-reading-time-minutes'] = 'meta:yoast_wpseo_estimated-reading-time-minutes';
84
+ $post_columns['meta:_yoast_wpseo_content_score'] = 'meta:_yoast_wpseo_focuskw';
85
+ $post_columns['meta:_yoast_wpseo_title'] = 'meta:_yoast_wpseo_title';
86
+ $post_columns['meta:_yoast_wpseo_metadesc'] = 'meta:_yoast_wpseo_metadesc';
87
+ $post_columns['meta:_yoast_wpseo_metakeywords'] = 'meta:_yoast_wpseo_metakeywords';
88
+
89
+ }
90
+
91
+ if (function_exists( 'aioseo' )) {
92
+ /* All in One SEO is active */
93
+
94
+ $post_columns['meta:_aioseo_title'] = 'meta:_aioseo_title';
95
+ $post_columns['meta:_aioseo_description'] = 'meta:_aioseo_description';
96
+ $post_columns['meta:_aioseo_keywords'] = 'meta:_aioseo_keywords';
97
+ $post_columns['meta:_aioseo_og_title'] = 'meta:_aioseo_og_title';
98
+ $post_columns['meta:_aioseo_og_description'] = 'meta:_aioseo_og_description';
99
+ $post_columns['meta:_aioseo_twitter_title'] = 'meta:_aioseo_twitter_title';
100
+ $post_columns['meta:_aioseo_og_article_tags'] = 'meta:_aioseo_og_article_tags';
101
+ $post_columns['meta:_aioseo_twitter_description'] = 'meta:_aioseo_twitter_description';
102
+ }
103
+
104
+ if (apply_filters('wpml_setting', false, 'setup_complete')) {
105
+
106
+ $post_columns['wpml:language_code'] = 'wpml:language_code';
107
+ $post_columns['wpml:original_product_id'] = 'wpml:original_product_id';
108
+ $post_columns['wpml:original_product_sku'] = 'wpml:original_product_sku';
109
+ }
110
+
111
+ return apply_filters('wt_iew_product_post_columns',$post_columns);
{includes/exporter → admin/modules/product}/data/data-wf-hidden-meta-columns.php RENAMED
@@ -1,7 +1,7 @@
1
  <?php
2
 
3
  // Exclude columns handled specifically
4
- return array(
5
  '_product_attributes',
6
  '_file_paths',
7
  '_woocommerce_gpf_data',
@@ -17,4 +17,4 @@ return array(
17
  '_min_variation_price',
18
  '_min_variation_regular_price',
19
  '_min_variation_sale_price',
20
- );
1
  <?php
2
 
3
  // Exclude columns handled specifically
4
+ return apply_filters('wt_product_exclude_hidden_meta_columns',array(
5
  '_product_attributes',
6
  '_file_paths',
7
  '_woocommerce_gpf_data',
17
  '_min_variation_price',
18
  '_min_variation_regular_price',
19
  '_min_variation_sale_price',
20
+ ));
admin/modules/product/data/data/data-wf-reserved-fields-pair.php ADDED
@@ -0,0 +1,414 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Reserved column names
4
+ $post_columns = array(
5
+ 'post_title' => array('title'=>'Product Title','description'=>'Product Title. ie Name of the product'),
6
+ 'post_name' => array('title'=>'Product Permalink','description'=>'Unique part of the product URL'),
7
+ 'ID' => array('title'=>'Product ID','description'=>'Product ID'),
8
+ 'post_parent' => array('title'=>'Parent ID','description'=>'Parent Product ID , if you are importing variation Product'),
9
+ 'post_status' => array('title'=>'Product Status','description'=>'Product Status ( published , draft ...)'),
10
+ 'post_content' => array('title'=>'Product Description','description'=>'Description about the Product'),
11
+ 'post_excerpt' => array('title'=>'Product Short Description','description'=>'Short description about the Product'),
12
+ 'post_date' => array('title'=>'Post Date','description'=>'Product posted date', 'type' => 'date'),
13
+ 'post_password' => array('title'=>'Post Password','description'=>'To Protect a post with password'),
14
+ 'post_author' => array('title'=>'Product Author','description'=>'Product Author ( 1 - Admin )'),
15
+ 'menu_order' => array('title'=>'Menu Order','description'=>'If menu enabled , menu order'),
16
+ 'comment_status' => array('title'=>'Comment Status','description'=>'Comment Status ( Open or Closed comments for this prodcut)'),
17
+ //'post_date_gmt' => array('title'=>'Post Date GMT','description'=>'Tooltip data Status'),
18
+
19
+ 'parent' => array('title'=>'Parent Title','description'=>'Parent Product Title , if you are importing variation Product'),
20
+ 'parent_sku' => array('title'=>'Parent SKU','description'=>'Parent Product SKU , if you are importing variation Product'),
21
+ '_sku' => array('title'=>'Product SKU','description'=>'Product SKU - This will unique and Product identifier'),
22
+ '_children' => array('title'=>'Children Product ID','description'=>'Linked Products id if you are importing Grouped products'),
23
+ '_downloadable' => array('title'=>'Type: Downloadable','description'=>'Is Product is downloadable eg:- Book'),
24
+ '_virtual' => array('title'=>'Type: Virtual','description'=>'Is Product is virtual'),
25
+ '_visibility' => array('title'=>'Visibility: Visibility','description'=>'Visibility status ( hidden or visible)'),
26
+ '_featured' => array('title'=>'Visibility: Featured','description'=>'Featured Product'),
27
+ '_purchase_note' => array('title'=>'Purchase note','description'=>'Purchase note'),
28
+ '_stock' => array('title'=>'Inventory: Stock','description'=>'Stock quantity'),
29
+ '_stock_status' => array('title'=>'Inventory: Stock Status','description'=>'InStock or OutofStock'),
30
+ '_backorders' => array('title'=>'Inventory: Backorders','description'=>'Backorders'),
31
+ '_sold_individually' => array('title'=>'Inventory: Sold individually','description'=>'Sold individually'),
32
+ '_low_stock_amount' => array('title'=>'Inventory: Low stock amount','description'=>'Low stock amount'),
33
+ '_manage_stock' => array('title'=>'Inventory: Manage Stock','description'=>'yes to enable no to disable'),
34
+ '_sale_price' => array('title'=>'Price: Sale Price','description'=>'Sale Price'),
35
+ '_regular_price' => array('title'=>'Price: Regular Price','description'=>'Regular Price'),
36
+ '_sale_price_dates_from' => array('title'=>'Sale Price Dates: From','description'=>'Sale Price Dates effect from', 'type' => 'date'),
37
+ '_sale_price_dates_to' => array('title'=>'Sale Price Dates: To','description'=>'Sale Price Dates effect to', 'type' => 'date'),
38
+ '_weight' => array('title'=>'Dimensions: Weight','description'=>'Wight of product in LB , OZ , KG as of your woocommerce Unit'),
39
+ '_length' => array('title'=>'Dimensions: length','description'=>'Length'),
40
+ '_width' => array('title'=>'Dimensions: width','description'=>'Width'),
41
+ '_height' => array('title'=>'Dimensions: height','description'=>'Height'),
42
+ '_tax_status' => array('title'=>'Tax: Tax Status','description'=>'Taxable product or not'),
43
+ '_tax_class' => array('title'=>'Tax: Tax Class','description'=>'Tax class ( eg:- reduced rate)'),
44
+ '_upsell_ids' => array('title'=>'Related Products: Upsell IDs','description'=>'Upsell Product ids'),
45
+ '_crosssell_ids' => array('title'=>'Related Products: Crosssell IDs','description'=>'Crosssell Product ids'),
46
+ '_file_paths' => array('title'=>'Downloads: File Paths (WC 2.0.x)','description'=>'File Paths'),
47
+ '_downloadable_files' => array('title'=>'Downloads: Downloadable Files (WC 2.1.x)','description'=>'Downloadable Files'),
48
+ '_download_limit' => array('title'=>'Downloads: Download Limit','description'=>'Download Limit'),
49
+ '_download_expiry' => array('title'=>'Downloads: Download Expiry','description'=>'Download Expiry'),
50
+ '_product_url' => array('title'=>'External: Product URL','description'=>'Product URL if the Product is external'),
51
+ '_button_text' => array('title'=>'External: Button Text','description'=>'Buy button text for Product , if the Product is external'),
52
+ 'images' => array('title'=>'Images/Gallery','description'=>'Image URLs seperated with &#124;'),
53
+ 'product_page_url' => array('title'=>'Product Page URL','description'=>'Product Page URL'),
54
+ 'meta:total_sales' => array('title'=>'meta:total_sales','description'=>'Total sales for the Product'),
55
+ // 'tax:product_type' => array('title'=>'Product Type','description'=>'( eg:- simple , variable)'),
56
+ // 'tax:product_cat' => array('title'=>'Product Categories','description'=>'Product related categories'),
57
+ // 'tax:product_tag' => array('title'=>'Product Tags','description'=>'Product related tags'),
58
+ // 'tax:product_shipping_class' => array('title'=>'Product Shipping Class','description'=>'Allow you to group similar products for shipping'),
59
+ // 'tax:product_visibility' => array('title'=>'Product Visibility: Featured','description'=>'Featured Product'),
60
+
61
+
62
+ );
63
+
64
+ if (class_exists('WPSEO_Options')) {
65
+ /* Yoast is active */
66
+
67
+ $post_columns['meta:_yoast_wpseo_focuskw'] = array('title' => 'meta:_yoast_wpseo_focuskw', 'description' => 'yoast SEO');
68
+ $post_columns['meta:_yoast_wpseo_canonical'] = array('title' => 'meta:_yoast_wpseo_canonical', 'description' => 'yoast SEO');
69
+ $post_columns['meta:_yoast_wpseo_bctitle'] = array('title' => 'meta:_yoast_wpseo_bctitle', 'description' => 'yoast SEO');
70
+ $post_columns['meta:_yoast_wpseo_meta-robots-adv'] = array('title' => 'meta:_yoast_wpseo_meta-robots-adv', 'description' => 'yoast SEO');
71
+ $post_columns['meta:_yoast_wpseo_is_cornerstone'] = array('title' => 'meta:_yoast_wpseo_is_cornerstone', 'description' => 'yoast SEO');
72
+ $post_columns['meta:_yoast_wpseo_metadesc'] = array('title' => 'meta:_yoast_wpseo_metadesc', 'description' => 'yoast SEO');
73
+ $post_columns['meta:_yoast_wpseo_linkdex'] = array('title' => 'meta:_yoast_wpseo_linkdex', 'description' => 'yoast SEO');
74
+ $post_columns['meta:_yoast_wpseo_estimated-reading-time-minutes'] = array('title' => 'meta:yoast_wpseo_estimated-reading-time-minutes', 'description' => 'yoast SEO');
75
+ $post_columns['meta:_yoast_wpseo_content_score'] = array('title' => 'meta:_yoast_wpseo_focuskw', 'description' => 'yoast SEO');
76
+ $post_columns['meta:_yoast_wpseo_title'] = array('title' => 'meta:_yoast_wpseo_title', 'description' => 'yoast SEO');
77
+ $post_columns['meta:_yoast_wpseo_metadesc'] = array('title' => 'meta:_yoast_wpseo_metadesc', 'description' => 'yoast SEO');
78
+ $post_columns['meta:_yoast_wpseo_metakeywords'] = array('title' => 'meta:_yoast_wpseo_metakeywords', 'description' => 'yoast SEO');
79
+ }
80
+
81
+ if (function_exists( 'aioseo' )) {
82
+
83
+ /* All in One SEO is active */
84
+
85
+ $post_columns['meta:_aioseo_title'] = array('title' => 'meta:_aioseo_title', 'description' => 'All in One SEO');
86
+ $post_columns['meta:_aioseo_description'] = array('title' => 'meta:_aioseo_description', 'description' => 'All in One SEO');
87
+ $post_columns['meta:_aioseo_keywords'] = array('title' => 'meta:_aioseo_keywords', 'description' => 'All in One SEO');
88
+ $post_columns['meta:_aioseo_og_title'] = array('title' => 'meta:_aioseo_og_title', 'description' => 'All in One SEO');
89
+ $post_columns['meta:_aioseo_og_description'] = array('title' => 'meta:_aioseo_og_description', 'description' => 'All in One SEO');
90
+ $post_columns['meta:_aioseo_twitter_title'] = array('title' => 'meta:_aioseo_twitter_title', 'description' => 'All in One SEO');
91
+ $post_columns['meta:_aioseo_og_article_tags'] = array('title' => 'meta:_aioseo_og_article_tags', 'description' => 'All in One SEO');
92
+ $post_columns['meta:_aioseo_twitter_description'] = array('title' => 'meta:_aioseo_twitter_description', 'description' => 'All in One SEO');
93
+ }
94
+
95
+ if (apply_filters('wpml_setting', false, 'setup_complete')) {
96
+
97
+ $post_columns['wpml:language_code'] = array('title'=>'wpml:language_code','description'=>'WPML language code');
98
+ $post_columns['wpml:original_product_id'] = array('title'=>'wpml:original_product_id','description'=>'WPML Original Product ID');
99
+ $post_columns['wpml:original_product_sku'] = array('title'=>'wpml:original_product_sku','description'=>'WPML Original Product SKU');
100
+ }
101
+
102
+ return apply_filters('woocommerce_csv_product_import_reserved_fields_pair', $post_columns);
103
+
104
+
105
+
106
+
107
+ return array(
108
+
109
+ 'id' => array('title'=>'Product ID','description'=>'Product ID'),
110
+ 'type' => array('title'=>'Product Type','description'=>'( eg:- simple , variable)'),
111
+ 'sku' => array('title'=>'Product SKU','description'=>'Product SKU - This will unique and Product identifier'),
112
+ 'name' => array('title'=>'Product Title','description'=>'Product Title. ie Name of the product'),
113
+ 'slug' => array('title'=>'Product Permalink','description'=>'Unique part of the product URL'),
114
+ 'date_created' => array('title'=>'Date','description'=>'Product posted date'),
115
+ 'published' => array('title'=>'Published','description'=>''),
116
+ 'featured' => array('title'=>'Visibility: Featured','description'=>'Featured Product'),
117
+ 'catalog_visibility' => array('title'=>'Visibility: Visibility','description'=>'Visibility status ( hidden or visible)'),
118
+ 'short_description' => array('title'=>'Product Short Description','description'=>'Short description about the Product'),
119
+ 'description' => array('title'=>'Product Description','description'=>'Description about the Product'),
120
+ 'date_on_sale_from' => array('title'=>'Sale Price Dates: From','description'=>'Sale Price Dates effect from'),
121
+ 'date_on_sale_to' => array('title'=>'Sale Price Dates: To','description'=>'Sale Price Dates effect to'),
122
+ 'tax_status' => array('title'=>'Tax: Tax Status','description'=>'Taxable product or not'),
123
+ 'tax_class' => array('title'=>'Tax: Tax Class','description'=>'Tax class ( eg:- reduced rate)'),
124
+ 'stock_status' => array('title'=>'Inventory: Stock Status','description'=>'InStock or OutofStock'),
125
+ 'stock' => array('title'=>'Inventory: Stock','description'=>'Stock quantity'),
126
+ 'low_stock_amount' => array('title'=>'Low Stock Amount','description'=>''),
127
+ 'backorders' => array('title'=>'Inventory: Backorders','description'=>'Backorders'),
128
+ 'sold_individually' => array('title'=>'Sold Individually','description'=>''),
129
+ 'weight' => array('title'=>'Dimensions: Weight','description'=>'Wight of product in LB , OZ , KG as of your woocommerce Unit'),
130
+ 'length' => array('title'=>'Dimensions: length','description'=>'Length'),
131
+ 'width' => array('title'=>'Dimensions: width','description'=>'Width'),
132
+ 'height' => array('title'=>'Dimensions: height','description'=>'Height'),
133
+ 'reviews_allowed' => array('title'=>'Comment Status','description'=>'Comment Status ( Open or Closed comments for this prodcut)'),
134
+ 'purchase_note' => array('title'=>'Purchase note','description'=>''),
135
+ 'sale_price' => array('title'=>'Price: Sale Price','description'=>'Sale Price'),
136
+ 'regular_price' => array('title'=>'Price: Regular Price','description'=>'Regular Price'),
137
+ 'category_ids' => array('title'=>'Categories','description'=>''),
138
+ 'tag_ids' => array('title'=>'Tags','description'=>''),
139
+ 'shipping_class_id' => array('title'=>'Shipping class','description'=>''),
140
+ 'images' => array('title'=>'Images/Gallery','description'=>'Image URLs seperated with &#124;'),
141
+ 'download_limit' => array('title'=>'Downloads: Download Limit','description'=>'Download Limit'),
142
+ 'download_expiry' => array('title'=>'Downloads: Download Expiry','description'=>'Download Expiry'),
143
+ 'parent_id' => array('title'=>'Parent ID','description'=>'Parent Product ID , if you are importing variation Product'),
144
+ 'grouped_products' => array('title'=>'Grouped products','description'=>''),
145
+ 'upsell_ids' => array('title'=>'Related Products: Upsell IDs','description'=>'Upsell Product ids'),
146
+ 'cross_sell_ids' => array('title'=>'Related Products: Crosssell IDs','description'=>'Crosssell Product ids'),
147
+ 'product_url' => array('title'=>'External: Product URL','description'=>'Product URL if the Product is external'),
148
+ 'button_text' => array('title'=>'External: Button Text','description'=>'Buy button text for Product , if the Product is external'),
149
+ 'menu_order' => array('title'=>'Menu Order','description'=>'If menu enabled , menu order'),
150
+ );
151
+
152
+ array(
153
+ 'name' => '',
154
+ 'slug' => '',
155
+ 'date_created' => null,
156
+ 'date_modified' => null,
157
+ 'status' => false,
158
+ 'featured' => false,
159
+ 'catalog_visibility' => 'visible',
160
+ 'description' => '',
161
+ 'short_description' => '',
162
+ 'sku' => '',
163
+ 'price' => '',
164
+ 'regular_price' => '',
165
+ 'sale_price' => '',
166
+ 'date_on_sale_from' => null,
167
+ 'date_on_sale_to' => null,
168
+ 'total_sales' => '0',
169
+ 'tax_status' => 'taxable',
170
+ 'tax_class' => '',
171
+ 'manage_stock' => false,
172
+ 'stock_quantity' => null,
173
+ 'stock_status' => 'instock',
174
+ 'backorders' => 'no',
175
+ 'low_stock_amount' => '',
176
+ 'sold_individually' => false,
177
+ 'weight' => '',
178
+ 'length' => '',
179
+ 'width' => '',
180
+ 'height' => '',
181
+ 'upsell_ids' => array(),
182
+ 'cross_sell_ids' => array(),
183
+ 'parent_id' => 0,
184
+ 'reviews_allowed' => true,
185
+ 'purchase_note' => '',
186
+ 'attributes' => array(),
187
+ 'default_attributes' => array(),
188
+ 'menu_order' => 0,
189
+ 'post_password' => '',
190
+ 'virtual' => false,
191
+ 'downloadable' => false,
192
+ 'category_ids' => array(),
193
+ 'tag_ids' => array(),
194
+ 'shipping_class_id' => 0,
195
+ 'downloads' => array(),
196
+ 'image_id' => '',
197
+ 'gallery_image_ids' => array(),
198
+ 'download_limit' => -1,
199
+ 'download_expiry' => -1,
200
+ 'rating_counts' => array(),
201
+ 'average_rating' => 0,
202
+ 'review_count' => 0,
203
+ );
204
+
205
+
206
+ $post_columns = array(
207
+ 'post_title' => 'name',
208
+ 'post_name' => 'slug',
209
+ 'post_parent' => 'parent_id',
210
+ 'ID' => 'ID',
211
+ 'post_excerpt' => 'Short Description',
212
+ 'post_content' => 'Description',
213
+ 'post_status' => 'Status',
214
+ 'post_password' => 'post_password',
215
+ 'menu_order' => 'menu_order',
216
+ 'post_date' => 'post_date',
217
+ 'post_author' => 'post_author',
218
+ 'comment_status' => 'comment_status',
219
+ // Meta
220
+
221
+ '_sku' => 'sku',
222
+ 'parent_sku' => 'parent_sku',
223
+ 'parent' => 'Parent Title',
224
+ '_children' => 'children', //For Grouped products
225
+ '_downloadable' => 'downloadable',
226
+ '_virtual' => 'virtual',
227
+ '_stock' => 'stock',
228
+ '_regular_price' => 'Regular Price',
229
+ '_sale_price' => 'Sale Price',
230
+ '_weight' => 'weight',
231
+ '_length' => 'length',
232
+ '_width' => 'width',
233
+ '_height' => 'height',
234
+ '_tax_class' => 'tax_class',
235
+ '_visibility' => 'visibility',
236
+ '_stock_status' => 'stock_status',
237
+ '_backorders' => 'backorders',
238
+ '_manage_stock' => 'manage_stock',
239
+ '_tax_status' => 'tax_status',
240
+ '_upsell_ids' => 'upsell_ids',
241
+ '_crosssell_ids' => 'crosssell_ids',
242
+ '_featured' => 'featured',
243
+ '_sale_price_dates_from' => 'sale_price_dates_from',
244
+ '_sale_price_dates_to' => 'sale_price_dates_to',
245
+ // Downloadable products
246
+ '_download_limit' => 'download_limit',
247
+ '_download_expiry' => 'download_expiry',
248
+ // Virtual products
249
+ '_product_url' => 'product_url',
250
+ '_button_text' => 'button_text',
251
+ // YOAST
252
+ 'meta:_yoast_wpseo_focuskw' => 'meta:_yoast_wpseo_focuskw',
253
+ 'meta:_yoast_wpseo_title' => 'meta:_yoast_wpseo_title',
254
+ 'meta:_yoast_wpseo_metadesc' => 'meta:_yoast_wpseo_metadesc',
255
+ 'meta:_yoast_wpseo_metakeywords' => 'meta:_yoast_wpseo_metakeywords',
256
+
257
+ 'images' => 'Images (featured and gallery)',
258
+ "$file_path_header" => 'Downloadable file paths',
259
+ 'product_page_url' => 'Product Page URL',
260
+ //'taxonomies' => 'Taxonomies (cat/tags/shipping-class)',
261
+ //'meta' => 'Meta (custom fields)',
262
+ //'attributes' => 'Attributes',
263
+ );
264
+
265
+ if (apply_filters('wpml_setting', false, 'setup_complete')) {
266
+
267
+ $post_columns['wpml:language_code'] = 'wpml:language_code';
268
+ $post_columns['wpml:original_product_id'] = 'wpml:original_product_id';
269
+ $post_columns['wpml:original_product_sku'] = 'wpml:original_product_sku';
270
+ }
271
+
272
+
273
+
274
+
275
+
276
+
277
+ $default_export_columns = array(
278
+ 'id' => __('ID', 'woocommerce'),
279
+ 'type' => __('Type', 'woocommerce'),
280
+ 'sku' => __('SKU', 'woocommerce'),
281
+ 'name' => __('Name', 'woocommerce'),
282
+ 'published' => __('Published', 'woocommerce'),
283
+ 'featured' => __('Is featured?', 'woocommerce'),
284
+ 'catalog_visibility' => __('Visibility in catalog', 'woocommerce'),
285
+ 'short_description' => __('Short description', 'woocommerce'),
286
+ 'description' => __('Description', 'woocommerce'),
287
+ 'date_on_sale_from' => __('Date sale price starts', 'woocommerce'),
288
+ 'date_on_sale_to' => __('Date sale price ends', 'woocommerce'),
289
+ 'tax_status' => __('Tax status', 'woocommerce'),
290
+ 'tax_class' => __('Tax class', 'woocommerce'),
291
+ 'stock_status' => __('In stock?', 'woocommerce'),
292
+ 'stock' => __('Stock', 'woocommerce'),
293
+ 'low_stock_amount' => __('Low stock amount', 'woocommerce'),
294
+ 'backorders' => __('Backorders allowed?', 'woocommerce'),
295
+ 'sold_individually' => __('Sold individually?', 'woocommerce'),
296
+ 'weight' => sprintf(__('Weight (%s)', 'woocommerce'), get_option('woocommerce_weight_unit')),
297
+ 'length' => sprintf(__('Length (%s)', 'woocommerce'), get_option('woocommerce_dimension_unit')),
298
+ 'width' => sprintf(__('Width (%s)', 'woocommerce'), get_option('woocommerce_dimension_unit')),
299
+ 'height' => sprintf(__('Height (%s)', 'woocommerce'), get_option('woocommerce_dimension_unit')),
300
+ 'reviews_allowed' => __('Allow customer reviews?', 'woocommerce'),
301
+ 'purchase_note' => __('Purchase note', 'woocommerce'),
302
+ 'sale_price' => __('Sale price', 'woocommerce'),
303
+ 'regular_price' => __('Regular price', 'woocommerce'),
304
+ 'category_ids' => __('Categories', 'woocommerce'),
305
+ 'tag_ids' => __('Tags', 'woocommerce'),
306
+ 'shipping_class_id' => __('Shipping class', 'woocommerce'),
307
+ 'images' => __('Images', 'woocommerce'),
308
+ 'download_limit' => __('Download limit', 'woocommerce'),
309
+ 'download_expiry' => __('Download expiry days', 'woocommerce'),
310
+ 'parent_id' => __('Parent', 'woocommerce'),
311
+ 'grouped_products' => __('Grouped products', 'woocommerce'),
312
+ 'upsell_ids' => __('Upsells', 'woocommerce'),
313
+ 'cross_sell_ids' => __('Cross-sells', 'woocommerce'),
314
+ 'product_url' => __('External URL', 'woocommerce'),
315
+ 'button_text' => __('Button text', 'woocommerce'),
316
+ 'menu_order' => __('Position', 'woocommerce'),
317
+ );
318
+ echo '<pre>$default_export_columns:-';
319
+ print_r(count($default_export_columns));
320
+ echo '</pre>';
321
+
322
+
323
+ $default_import_columns = array(
324
+ 'ID' => 'id',
325
+ 'Type' => 'type',
326
+ 'SKU' => 'sku',
327
+ 'Name' => 'name',
328
+ 'Published' => 'published',
329
+ 'Is featured?' => 'featured',
330
+ 'Visibility in catalog' => 'catalog_visibility',
331
+ 'Short description' => 'short_description',
332
+ 'Description' => 'description',
333
+ 'Date sale price starts' => 'date_on_sale_from',
334
+ 'Date sale price ends' => 'date_on_sale_to',
335
+ 'Tax status' => 'tax_status',
336
+ 'Tax class' => 'tax_class',
337
+ 'In stock?' => 'stock_status',
338
+ 'Stock' => 'stock_quantity',
339
+ 'Backorders allowed?' => 'backorders',
340
+ 'Low stock amount' => 'low_stock_amount',
341
+ 'Sold individually?' => 'sold_individually',
342
+ sprintf('Weight (%s)', get_option('woocommerce_weight_unit')) => 'weight',
343
+ sprintf('Length (%s)', get_option('woocommerce_dimension_unit')) => 'length',
344
+ sprintf('Width (%s)', get_option('woocommerce_dimension_unit')) => 'width',
345
+ sprintf('Height (%s)', get_option('woocommerce_dimension_unit')) => 'height',
346
+ 'Allow customer reviews?' => 'reviews_allowed',
347
+ 'Purchase note' => 'purchase_note',
348
+ 'Sale price' => 'sale_price',
349
+ 'Regular price' => 'regular_price',
350
+ 'Categories' => 'category_ids',
351
+ 'Tags' => 'tag_ids',
352
+ 'Shipping class' => 'shipping_class_id',
353
+ 'Images' => 'images',
354
+ 'Download limit' => 'download_limit',
355
+ 'Download expiry days' => 'download_expiry',
356
+ 'Parent' => 'parent_id',
357
+ 'Upsells' => 'upsell_ids',
358
+ 'Cross-sells' => 'cross_sell_ids',
359
+ 'Grouped products' => 'grouped_products',
360
+ 'External URL' => 'product_url',
361
+ 'Button text' => 'button_text',
362
+ 'Position' => 'menu_order',
363
+ );
364
+
365
+ echo '<pre>$default_import_columns:-';
366
+ print_r(count($default_import_columns));
367
+ echo '</pre>';
368
+
369
+
370
+ $default_import_columns_1 = array(
371
+ __('ID', 'woocommerce') => 'id',
372
+ __('Type', 'woocommerce') => 'type',
373
+ __('SKU', 'woocommerce') => 'sku',
374
+ __('Name', 'woocommerce') => 'name',
375
+ __('Published', 'woocommerce') => 'published',
376
+ __('Is featured?', 'woocommerce') => 'featured',
377
+ __('Visibility in catalog', 'woocommerce') => 'catalog_visibility',
378
+ __('Short description', 'woocommerce') => 'short_description',
379
+ __('Description', 'woocommerce') => 'description',
380
+ __('Date sale price starts', 'woocommerce') => 'date_on_sale_from',
381
+ __('Date sale price ends', 'woocommerce') => 'date_on_sale_to',
382
+ __('Tax status', 'woocommerce') => 'tax_status',
383
+ __('Tax class', 'woocommerce') => 'tax_class',
384
+ __('In stock?', 'woocommerce') => 'stock_status',
385
+ __('Stock', 'woocommerce') => 'stock_quantity',
386
+ __('Backorders allowed?', 'woocommerce') => 'backorders',
387
+ __('Low stock amount', 'woocommerce') => 'low_stock_amount',
388
+ __('Sold individually?', 'woocommerce') => 'sold_individually',
389
+ /* translators: %s: Weight unit */
390
+ sprintf(__('Weight (%s)', 'woocommerce'), $weight_unit) => 'weight',
391
+ /* translators: %s: Length unit */
392
+ sprintf(__('Length (%s)', 'woocommerce'), $dimension_unit) => 'length',
393
+ /* translators: %s: Width unit */
394
+ sprintf(__('Width (%s)', 'woocommerce'), $dimension_unit) => 'width',
395
+ /* translators: %s: Height unit */
396
+ sprintf(__('Height (%s)', 'woocommerce'), $dimension_unit) => 'height',
397
+ __('Allow customer reviews?', 'woocommerce') => 'reviews_allowed',
398
+ __('Purchase note', 'woocommerce') => 'purchase_note',
399
+ __('Sale price', 'woocommerce') => 'sale_price',
400
+ __('Regular price', 'woocommerce') => 'regular_price',
401
+ __('Categories', 'woocommerce') => 'category_ids',
402
+ __('Tags', 'woocommerce') => 'tag_ids',
403
+ __('Shipping class', 'woocommerce') => 'shipping_class_id',
404
+ __('Images', 'woocommerce') => 'images',
405
+ __('Download limit', 'woocommerce') => 'download_limit',
406
+ __('Download expiry days', 'woocommerce') => 'download_expiry',
407
+ __('Parent', 'woocommerce') => 'parent_id',
408
+ __('Upsells', 'woocommerce') => 'upsell_ids',
409
+ __('Cross-sells', 'woocommerce') => 'cross_sell_ids',
410
+ __('Grouped products', 'woocommerce') => 'grouped_products',
411
+ __('External URL', 'woocommerce') => 'product_url',
412
+ __('Button text', 'woocommerce') => 'button_text',
413
+ __('Position', 'woocommerce') => 'menu_order',
414
+ );
admin/modules/product/export/export.php ADDED
@@ -0,0 +1,611 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
4
+ exit;
5
+ }
6
+
7
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Product_Export')){
8
+ class Wt_Import_Export_For_Woo_Basic_Product_Export {
9
+
10
+ public $parent_module = null;
11
+
12
+ public function __construct($parent_object) {
13
+
14
+ $this->parent_module = $parent_object;
15
+ }
16
+
17
+ public function prepare_header() {
18
+
19
+ $export_columns = $this->parent_module->get_selected_column_names();
20
+
21
+ return apply_filters('hf_alter_product_export_csv_columns', $export_columns);
22
+ }
23
+
24
+ /**
25
+ * Prepare data that will be exported.
26
+ */
27
+ public function prepare_data_to_export($form_data, $batch_offset,$step) {
28
+
29
+ $include_products = !empty($form_data['filter_form_data']['wt_iew_product']) ? $form_data['filter_form_data']['wt_iew_product'] : '';
30
+ $exclude_products = !empty($form_data['filter_form_data']['wt_iew_exclude_product']) ? $form_data['filter_form_data']['wt_iew_exclude_product'] : '';
31
+
32
+ $prod_categories = !empty($form_data['filter_form_data']['wt_iew_product_categories']) ? $form_data['filter_form_data']['wt_iew_product_categories'] : array();
33
+ $prod_tags = !empty($form_data['filter_form_data']['wt_iew_product_tags']) ? $form_data['filter_form_data']['wt_iew_product_tags'] : array();
34
+ $prod_types = !empty($form_data['filter_form_data']['wt_iew_product_types']) ? $form_data['filter_form_data']['wt_iew_product_types'] : array();
35
+ $prod_status = !empty($form_data['filter_form_data']['wt_iew_product_status']) ? $form_data['filter_form_data']['wt_iew_product_status'] : array();
36
+
37
+ $export_sortby = !empty($form_data['filter_form_data']['wt_iew_sort_columns']) ? $form_data['filter_form_data']['wt_iew_sort_columns'] : 'ID';
38
+ $export_sort_order = !empty($form_data['filter_form_data']['wt_iew_order_by']) ? $form_data['filter_form_data']['wt_iew_order_by'] : 'ASC';
39
+
40
+ $export_limit = !empty($form_data['filter_form_data']['wt_iew_limit']) ? intval($form_data['filter_form_data']['wt_iew_limit']) : 999999999; //user limit
41
+ $current_offset = !empty($form_data['filter_form_data']['wt_iew_offset']) ? intval($form_data['filter_form_data']['wt_iew_offset']) : 0; //user offset
42
+
43
+ $batch_count = !empty($form_data['advanced_form_data']['wt_iew_batch_count']) ? $form_data['advanced_form_data']['wt_iew_batch_count'] : Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings('default_export_batch');
44
+ $batch_count = apply_filters('wt_woocommerce_csv_export_limit_per_request', $batch_count); //ajax batch limit
45
+
46
+ $this->export_children_sku = (!empty($form_data['advanced_form_data']['wt_iew_export_children_sku'] ) && $form_data['advanced_form_data']['wt_iew_export_children_sku'] == 'Yes') ? true : false;
47
+
48
+ $this->export_shortcodes = (!empty($form_data['advanced_form_data']['wt_iew_export_shortcode_tohtml']) && $form_data['advanced_form_data']['wt_iew_export_shortcode_tohtml'] == 'Yes') ? true : false;
49
+
50
+ $this->export_images_zip = (!empty($form_data['advanced_form_data']['wt_iew_image_export']) && $form_data['advanced_form_data']['wt_iew_image_export'] == 'Yes') ? true : false;
51
+
52
+ $real_offset = ($current_offset + $batch_offset);
53
+
54
+ if($batch_count<=$export_limit)
55
+ {
56
+ if(($batch_offset+$batch_count)>$export_limit) //last offset
57
+ {
58
+ $limit=$export_limit-$batch_offset;
59
+ }else
60
+ {
61
+ $limit=$batch_count;
62
+ }
63
+ }else
64
+ {
65
+ $limit=$export_limit;
66
+ }
67
+
68
+ $product_array = array();
69
+ if ($batch_offset < $export_limit)
70
+ {
71
+ $args = array(
72
+ 'status' => array('publish', 'private', 'draft', 'pending', 'future'),
73
+ 'type' => array('simple','grouped','external'),
74
+ 'limit' => $limit,
75
+ 'offset' => $real_offset,
76
+ 'orderby' => $export_sortby,
77
+ 'order' => $export_sort_order,
78
+ // 'return' => 'objects',
79
+ 'paginate' => true,
80
+ );
81
+
82
+ // if(1){ //if(is_woocommerce_prior_to_basic('2.7.0')){
83
+ $args['return'] = 'ids';
84
+ // }
85
+
86
+ if (!empty($prod_status)) {
87
+ $args['status'] = $prod_status;
88
+ }
89
+
90
+ if (!empty($prod_types)) {
91
+ $args['type'] = $prod_types;
92
+ }
93
+
94
+ if (!empty($prod_categories)) {
95
+ $args['category'] = $prod_categories;
96
+ }
97
+
98
+ if (!empty($prod_tags)) {
99
+ $args['tag'] = $prod_tags;
100
+ }
101
+
102
+ if (!empty($include_products)) {
103
+ $args['include'] = $include_products;
104
+ }
105
+
106
+ if (!empty($exclude_products)) {
107
+ $args['exclude'] = $exclude_products;
108
+ }
109
+
110
+ $args = apply_filters("woocommerce_csv_product_export_args", $args);
111
+ $products = wc_get_products($args);
112
+
113
+ $total_products=0;
114
+ if($batch_offset==0) //first batch
115
+ {
116
+ $total_item_args=$args;
117
+ $total_item_args['limit']=$export_limit; //user given limit
118
+ $total_item_args['offset']=$current_offset; //user given offset
119
+ $total_products_count = wc_get_products($total_item_args);
120
+ $total_products=count($total_products_count->products);
121
+ }
122
+
123
+ if('export_image' == $step){
124
+ $products_ids = $products;
125
+ }else{
126
+ $products_ids = $products->products;
127
+ }
128
+
129
+
130
+ foreach ($products_ids as $key => $product_id) {
131
+ $product = wc_get_product($product_id);
132
+
133
+ if ($product->is_type('variable') || $product->has_child()) {
134
+ continue;
135
+ }else{
136
+ $product_array[] = $this->generate_row_data_wc_lower($product);
137
+ }
138
+
139
+ }
140
+
141
+ }
142
+ return array(
143
+ 'total' => $total_products,
144
+ 'data' => $product_array,
145
+ );
146
+
147
+ }
148
+
149
+ protected function generate_row_data_wc_lower($product_object) {
150
+
151
+ $export_columns = $this->parent_module->get_selected_column_names();
152
+
153
+ $product = get_post($product_object->get_id());
154
+
155
+ $csv_columns = $export_columns; //Wt_Import_Export_For_Woo_Basic_Product::wt_array_walk($export_columns,'meta:'); // Remove string 'meta:' from keys and values, YOAST support
156
+
157
+ $export_columns = !empty($csv_columns) ? $csv_columns : array();
158
+
159
+ $row = array();
160
+
161
+ if ($product->post_parent == 0)
162
+ $product->post_parent = '';
163
+
164
+ // Pre-process data
165
+ $meta_data = get_post_custom($product->ID);
166
+
167
+ $product->meta = new stdClass;
168
+ $product->attributes = new stdClass;
169
+ // Meta data
170
+
171
+ foreach ($meta_data as $meta => $value) {
172
+
173
+ if (!$meta) {
174
+ continue;
175
+ }
176
+
177
+ $meta_value = maybe_unserialize(maybe_unserialize($value[0]));
178
+
179
+ if (is_array($meta_value)) {
180
+ $meta_value = json_encode($meta_value);
181
+ }
182
+
183
+ if (strstr($meta, 'attribute_pa_')) {
184
+ if ($meta_value) {
185
+ $get_name_by_slug = get_term_by('slug', $meta_value, str_replace('attribute_', '', $meta));
186
+ if ($get_name_by_slug) {
187
+ $product->meta->$meta = self::format_export_meta($get_name_by_slug->name, $meta);
188
+ } else {
189
+ $product->meta->$meta = self::format_export_meta($meta_value, $meta);
190
+ }
191
+ } else {
192
+ $product->meta->$meta = self::format_export_meta($meta_value, $meta);
193
+ }
194
+ } else {
195
+ $product->meta->$meta = self::format_export_meta($meta_value, $meta);
196
+ }
197
+ }
198
+ // Product attributes
199
+ if (isset($meta_data['_product_attributes'][0])) {
200
+
201
+ $attributes = maybe_unserialize(maybe_unserialize($meta_data['_product_attributes'][0]));
202
+
203
+ if (!empty($attributes) && is_array($attributes)) {
204
+ foreach ($attributes as $key => $attribute) {
205
+ if (!$key) {
206
+ continue;
207
+ }
208
+
209
+ $key_to_find_default_attribute = $key;
210
+ if ($attribute['is_taxonomy'] == 1) {
211
+ $terms = wp_get_post_terms($product->ID, $key, array("fields" => "names"));
212
+ if (!is_wp_error($terms)) {
213
+ $attribute_value = implode('|', $terms);
214
+ } else {
215
+ $attribute_value = '';
216
+ }
217
+ } else {
218
+ if (empty($attribute['name'])) {
219
+ continue;
220
+ }
221
+ $key = $attribute['name'];
222
+ $attribute_value = $attribute['value'];
223
+ }
224
+
225
+ if (!isset($attribute['position'])) {
226
+ $attribute['position'] = 0;
227
+ }
228
+ if (!isset($attribute['is_visible'])) {
229
+ $attribute['is_visible'] = 0;
230
+ }
231
+ if (!isset($attribute['is_variation'])) {
232
+ $attribute['is_variation'] = 0;
233
+ }
234
+
235
+ $attribute_data = $attribute['position'] . '|' . $attribute['is_visible'] . '|' . $attribute['is_variation'];
236
+ $_default_attributes = isset($meta_data['_default_attributes'][0]) ? maybe_unserialize(maybe_unserialize($meta_data['_default_attributes'][0])) : '';
237
+
238
+ if (is_array($_default_attributes)) {
239
+ $default_attribute = isset($_default_attributes[$key_to_find_default_attribute]) ? $_default_attributes[$key_to_find_default_attribute] : '';
240
+ $term = get_term_by('slug', $default_attribute, $key_to_find_default_attribute);
241
+ $_default_attribute = (!is_wp_error($term) && !empty($term) ? $term->name : $default_attribute );
242
+
243
+
244
+ } else {
245
+ $_default_attribute = '';
246
+ }
247
+
248
+ $product->attributes->$key = array(
249
+ 'value' => $attribute_value,
250
+ 'data' => $attribute_data,
251
+ 'default' => $_default_attribute
252
+ );
253
+ }
254
+ }
255
+ }
256
+
257
+
258
+ foreach ($csv_columns as $column => $value) {
259
+
260
+ if (!$export_columns || in_array($value, $export_columns) || in_array($column, $export_columns)) {
261
+ if ('_regular_price' == $column && empty($product->meta->$column)) {
262
+ $column = '_price';
263
+ }
264
+ if (!is_woocommerce_prior_to_basic('2.7')) {
265
+ if ('_visibility' == $column) {
266
+ $product_terms = get_the_terms($product->ID, 'product_visibility');
267
+ if (!empty($product_terms)) {
268
+ if (!is_wp_error($product_terms)) {
269
+ $term_slug = '';
270
+ foreach ($product_terms as $i => $term) {
271
+ $term_slug .= $term->slug . (isset($product_terms[$i + 1]) ? '|' : '');
272
+ }
273
+ $row[$column] = $term_slug;
274
+ }
275
+ } else {
276
+ $row[$column] = '';
277
+ }
278
+ continue;
279
+ }
280
+ }
281
+
282
+
283
+ if ('Parent' == $column) {
284
+ if ($product->post_parent) {
285
+ $post_parent_title = get_the_title($product->post_parent);
286
+ if ($post_parent_title) {
287
+ $row[$column] = self::format_data($post_parent_title);
288
+ } else {
289
+ $row[$column] = '';
290
+ }
291
+ } else {
292
+ $row[$column] = '';
293
+ }
294
+ continue;
295
+ }
296
+
297
+ if ('parent_sku' == $column) {
298
+ if ($product->post_parent) {
299
+ $row[$column] = get_post_meta($product->post_parent, '_sku', true);
300
+ } else {
301
+ $row[$column] = '';
302
+ }
303
+ continue;
304
+ }
305
+
306
+
307
+ // Export images/gallery
308
+ if ('images' == $column) {
309
+
310
+ $export_image_metadata = apply_filters('hf_export_image_metadata_flag', TRUE); //filter for disable export image meta datas such as alt,title,content,caption...
311
+ $image_file_names = array();
312
+
313
+ // Featured image
314
+ if (( $featured_image_id = get_post_thumbnail_id($product->ID))) {
315
+ $image_object = get_post($featured_image_id);
316
+ $img_url = wp_get_attachment_image_src($featured_image_id, 'full');
317
+
318
+ $image_meta = '';
319
+ if ($image_object && $export_image_metadata) {
320
+ $image_metadata = get_post_meta($featured_image_id);
321
+ $image_meta = " ! alt : " . ( isset($image_metadata['_wp_attachment_image_alt'][0]) ? $image_metadata['_wp_attachment_image_alt'][0] : '' ) . " ! title : " . $image_object->post_title . " ! desc : " . $image_object->post_content . " ! caption : " . $image_object->post_excerpt;
322
+ }
323
+
324
+ if ($image_object && $image_object->guid) {
325
+ $temp_images_export_to_csv = ($this->export_images_zip ? basename($img_url[0]) : $img_url[0]) . ($export_image_metadata ? $image_meta : '');
326
+ }
327
+
328
+ if (!empty($temp_images_export_to_csv)) {
329
+ $image_file_names[] = $temp_images_export_to_csv;
330
+ }
331
+ }
332
+
333
+ // Images
334
+ $images = isset($meta_data['_product_image_gallery'][0]) ? explode(',', maybe_unserialize(maybe_unserialize($meta_data['_product_image_gallery'][0]))) : false;
335
+ $results = array();
336
+ if ($images) {
337
+ foreach ($images as $image_id) {
338
+ if ($featured_image_id == $image_id) {
339
+ continue;
340
+ }
341
+ $temp_gallery_images_export_to_csv = '';
342
+ $gallery_image_meta = '';
343
+ $gallery_image_object = get_post($image_id);
344
+ $gallery_img_url = wp_get_attachment_image_src($image_id, 'full');
345
+
346
+ if ($gallery_image_object && $export_image_metadata) {
347
+ $gallery_image_metadata = get_post_meta($image_id);
348
+ $gallery_image_meta = " ! alt : " . ( isset($gallery_image_metadata['_wp_attachment_image_alt'][0]) ? $gallery_image_metadata['_wp_attachment_image_alt'][0] : '' ) . " ! title : " . $gallery_image_object->post_title . " ! desc : " . $gallery_image_object->post_content . " ! caption : " . $gallery_image_object->post_excerpt;
349
+ }
350
+
351
+ if ($gallery_image_object && $gallery_image_object->guid) {
352
+ $temp_gallery_images_export_to_csv = ($this->export_images_zip ? basename($gallery_img_url[0]) : $gallery_img_url[0]) . ($export_image_metadata ? $gallery_image_meta : '');
353
+ }
354
+ if (!empty($temp_gallery_images_export_to_csv)) {
355
+ $image_file_names[] = $temp_gallery_images_export_to_csv;
356
+ }
357
+ }
358
+ }
359
+
360
+
361
+ if (!empty($image_file_names)) {
362
+ $row[$column] = implode(' | ', $image_file_names);
363
+ } else {
364
+ $row[$column] = '';
365
+ }
366
+ continue;
367
+ }
368
+
369
+
370
+ // Downloadable files
371
+ if ('file_paths' == $column || 'downloadable_files' == $column) {
372
+ $file_paths_to_export = array();
373
+ if (!function_exists('wc_get_filename_from_url')) {
374
+ $file_paths = maybe_unserialize(maybe_unserialize($meta_data['_file_paths'][0]));
375
+
376
+ if ($file_paths) {
377
+ foreach ($file_paths as $file_path) {
378
+ $file_paths_to_export[] = $file_path;
379
+ }
380
+ }
381
+
382
+ $file_paths_to_export = implode(' | ', $file_paths_to_export);
383
+ $row[] = self::format_data($file_paths_to_export);
384
+ } elseif (isset($meta_data['_downloadable_files'][0])) {
385
+ $file_paths = maybe_unserialize(maybe_unserialize($meta_data['_downloadable_files'][0]));
386
+
387
+ if (is_array($file_paths) || is_object($file_paths)) {
388
+ foreach ($file_paths as $file_path) {
389
+ $file_paths_to_export[] = (!empty($file_path['name']) ? $file_path['name'] : Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_wc_get_filename_from_url($file_path['file']) ) . '::' . $file_path['file'];
390
+ }
391
+ }
392
+ $file_paths_to_export = implode(' | ', $file_paths_to_export);
393
+ }
394
+ if (!empty($file_paths_to_export)) {
395
+ $row[$column] = !empty($file_paths_to_export) ? self::format_data($file_paths_to_export) : '';
396
+ } else {
397
+ $row[$column] = '';
398
+ }
399
+ continue;
400
+ }
401
+
402
+
403
+ // Export taxonomies
404
+ // if ( 'taxonomies' == $column ) {
405
+ if ('tax:' == substr($column, 0, 4)) {
406
+
407
+ $taxonomy_name = substr($column, 4);
408
+
409
+ if (is_taxonomy_hierarchical($taxonomy_name)) {
410
+ $terms = wp_get_post_terms($product->ID, $taxonomy_name, array("fields" => "all"));
411
+ $formatted_terms = array();
412
+
413
+ foreach ($terms as $term) {
414
+ $ancestors = array_reverse(get_ancestors($term->term_id, $taxonomy_name));
415
+ $formatted_term = array();
416
+
417
+ foreach ($ancestors as $ancestor)
418
+ $formatted_term[] = get_term($ancestor, $taxonomy_name)->name;
419
+
420
+ $formatted_term[] = $term->name;
421
+
422
+ $formatted_terms[] = implode(' > ', $formatted_term);
423
+ }
424
+
425
+ $row[$column] = self::format_data(implode('|', $formatted_terms));
426
+ } else {
427
+ $terms = wp_get_post_terms($product->ID, $taxonomy_name, array("fields" => "names"));
428
+
429
+ $row[$column] = self::format_data(implode('|', $terms));
430
+ }
431
+ continue;
432
+ }
433
+
434
+ // Export meta data
435
+ // if ( 'meta' == $column ) {
436
+ if ('meta:' == substr($column, 0, 5)) {
437
+
438
+ $product_meta = substr($column, 5);
439
+
440
+ if (isset($product->meta->$product_meta)) {
441
+ $row[$column] = self::format_data($product->meta->$product_meta);
442
+ } else {
443
+ $row[$column] = '';
444
+ }
445
+
446
+ continue;
447
+ }
448
+
449
+ // Find and export attributes
450
+ // if ('attributes' == $column ) {
451
+ if (strstr($column, 'attribute')) {
452
+ if ('attribute:' == substr($column, 0, 10)) {
453
+ $attribute = substr($column, 10);
454
+ if (isset($product->attributes) && isset($product->attributes->$attribute)) {
455
+ $values = $product->attributes->$attribute;
456
+ $row[$column] = self::format_data($values['value']);
457
+ } else {
458
+ $row[$column] = '';
459
+ }
460
+ continue;
461
+ }
462
+
463
+
464
+ if ('attribute_data:' == substr($column, 0, 15)) {
465
+ $attribute = substr($column, 15);
466
+ if (isset($product->attributes) && isset($product->attributes->$attribute)) {
467
+ $values = $product->attributes->$attribute;
468
+ $row[$column] = self::format_data($values['data']);
469
+ } else {
470
+ $row[$column] = '';
471
+ }
472
+ continue;
473
+ }
474
+
475
+ if ('attribute_default:' == substr($column, 0, 18)) {
476
+ $attribute = substr($column, 18);
477
+ if (isset($product->attributes) && isset($product->attributes->$attribute)) {
478
+ $values = $product->attributes->$attribute;
479
+ $row[$column] = self::format_data($values['default']);
480
+ } else {
481
+ $row[$column] = '';
482
+ }
483
+ continue;
484
+ }
485
+ }
486
+ // WF: Adding product permalink.
487
+ if ('product_page_url' == $column) {
488
+ $product_page_url = '';
489
+ if (!empty($product->ID)) {
490
+ $product_page_url = get_permalink($product->ID);
491
+ }
492
+ if (!empty($product->post_parent)) {
493
+ $product_page_url = get_permalink($product->post_parent);
494
+ }
495
+ $row[$column] = !empty($product_page_url) ? $product_page_url : '';
496
+ continue;
497
+ }
498
+
499
+
500
+ /**
501
+ * WPML
502
+ */
503
+ if (apply_filters('wpml_setting', false, 'setup_complete')) {
504
+ if (in_array($column, array('wpml:language_code', 'wpml:original_product_id', 'wpml:original_product_sku'))) {
505
+ if ('wpml:language_code' == $column) {
506
+ $original_post_language_info = Wt_Import_Export_For_Woo_Basic_Common_Helper::wt_get_wpml_original_post_language_info($product->ID);
507
+ $row[$column] = (isset($original_post_language_info->language_code) && !empty($original_post_language_info->language_code) ? $original_post_language_info->language_code : '');
508
+ continue;
509
+ }
510
+
511
+ /*
512
+ * To get the ID of the original product post
513
+ * https://wpml.org/forums/topic/translated-product-get-id-of-original-lang-for-custom-fields/
514
+ */
515
+
516
+ global $sitepress;
517
+ $original_product_id = icl_object_id($product->ID, 'product', false, $sitepress->get_default_language());
518
+ if ('wpml:original_product_id' == $column) {
519
+ $row[$column] = ($original_product_id ? $original_product_id : '');
520
+ continue;
521
+ }
522
+ if ('wpml:original_product_sku' == $column) {
523
+ $sku = get_post_meta($original_product_id, '_sku', true);
524
+ $row[$column] = ($sku ? $sku : '');
525
+ continue;
526
+ }
527
+ }
528
+ }
529
+
530
+
531
+ // handling default meta and other columns
532
+ if (isset($product->meta->$column)) {
533
+ if (in_array($column, array('_children','_upsell_ids','_crosssell_ids'))) {
534
+ if ($this->export_children_sku) {
535
+ $children_sku = '';
536
+ $children_id_array = str_replace('"', '', explode('|', trim($product->meta->$column, '[' . ']')));
537
+
538
+ if (!empty($children_id_array) && $children_id_array[0] != '""') {
539
+ foreach ($children_id_array as $children_id_array_key => $children_id) {
540
+ $children_sku = !empty($children_sku) ? "{$children_sku}|" . get_post_meta($children_id, '_sku', TRUE) : get_post_meta($children_id, '_sku', TRUE);
541
+ }
542
+ }
543
+ $row[$column] = !empty($children_sku) ? $children_sku : '';
544
+ } else {
545
+ $row[$column] = str_replace('"', '', implode('|', explode(',', trim($product->meta->$column, '[' . ']'))));
546
+ }
547
+ } elseif ('_stock_status' == $column) {
548
+ $stock_status = self::format_data($product->meta->$column);
549
+ $product_type = ( WC()->version < '3.0' ) ? $product_object->product_type : $product_object->get_type();
550
+ $row[$column] = !empty($stock_status) ? $stock_status : ( ( 'variable' == $product_type || 'variable-subscription' == $product_type ) ? '' : 'instock' );
551
+ } elseif(('_sku' == $column)) {
552
+ $row[$column] = $product->meta->$column;
553
+ }else{
554
+ $row[$column] = self::format_data($product->meta->$column);
555
+ }
556
+ } elseif (isset($product->$column) && !is_array($product->$column)) {
557
+ if ($this->export_shortcodes && ( 'post_content' == $column || 'post_excerpt' == $column )) {
558
+ //Convert Shortcodes to html for Description and Short Description
559
+ $row[$column] = do_shortcode($product->$column);
560
+ } elseif ('post_title' === $column) {
561
+ $row[$column] = sanitize_text_field($product->$column);
562
+ } else {
563
+ $row[$column] = self::format_data($product->$column);
564
+ }
565
+ } else {
566
+ $row[$column] = '';
567
+ }
568
+ }
569
+ }
570
+
571
+ return apply_filters('wt_batch_product_export_row_data', $row, $product);
572
+ }
573
+
574
+
575
+ /**
576
+ * Format the data if required
577
+ * @param string $meta_value
578
+ * @param string $meta name of meta key
579
+ * @return string
580
+ */
581
+ public static function format_export_meta($meta_value, $meta) {
582
+ switch ($meta) {
583
+ case '_sale_price_dates_from' :
584
+ case '_sale_price_dates_to' :
585
+ return $meta_value ? date('Y-m-d', $meta_value) : '';
586
+ break;
587
+ case '_upsell_ids' :
588
+ case '_crosssell_ids' :
589
+ return implode('|', array_filter((array) json_decode($meta_value)));
590
+ break;
591
+ default :
592
+ return $meta_value;
593
+ break;
594
+ }
595
+ }
596
+
597
+ public static function format_data($data) {
598
+ if (!is_array($data))
599
+ $data = (string) urldecode($data);
600
+ // $enc = mb_detect_encoding($data, 'UTF-8, ISO-8859-1', true);
601
+ $use_mb = function_exists('mb_detect_encoding');
602
+ $enc = '';
603
+ if ($use_mb) {
604
+ $enc = mb_detect_encoding($data, 'UTF-8, ISO-8859-1', true);
605
+ }
606
+ $data = ( $enc == 'UTF-8' ) ? $data : utf8_encode($data);
607
+
608
+ return $data;
609
+ }
610
+ }
611
+ }
admin/modules/product/import/import.php ADDED
@@ -0,0 +1,1802 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if (!defined('WPINC')) {
4
+ exit;
5
+ }
6
+
7
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Product_Import')){
8
+ class Wt_Import_Export_For_Woo_Basic_Product_Import {
9
+
10
+ public $post_type = 'product';
11
+ public $parent_module = null;
12
+ public $parsed_data = array();
13
+ public $import_columns = array();
14
+ public $merge;
15
+ public $skip_new;
16
+ public $merge_empty_cells;
17
+ public $delete_products;
18
+ public $use_sku_upsell_crosssell;
19
+ public $prod_use_chidren_sku;
20
+ public $pro_stop_thumbnail_regen;
21
+ public $merge_with = 'id';
22
+ public $found_action = 'skip';
23
+ public $id_conflict = 'skip';
24
+
25
+
26
+ var $processed_posts = array();
27
+ var $post_orphans = array();
28
+ var $attachments = array();
29
+ var $upsell_skus = array();
30
+ var $crosssell_skus = array();
31
+ // Results
32
+ var $import_results = array();
33
+
34
+ public $item_data = array();
35
+ public $is_product_exist = false;
36
+
37
+ public function __construct($parent_object) {
38
+
39
+ $this->parent_module = $parent_object;
40
+
41
+ }
42
+
43
+ /* WC object based import */
44
+ public function prepare_data_to_import($import_data,$form_data,$batch_offset,$is_last_batch){
45
+
46
+ $this->merge_with = !empty($form_data['advanced_form_data']['wt_iew_merge_with']) ? $form_data['advanced_form_data']['wt_iew_merge_with'] : 'id';
47
+ $this->found_action = !empty($form_data['advanced_form_data']['wt_iew_found_action']) ? $form_data['advanced_form_data']['wt_iew_found_action'] : 'skip';
48
+ $this->id_conflict = !empty($form_data['advanced_form_data']['wt_iew_id_conflict']) ? $form_data['advanced_form_data']['wt_iew_id_conflict'] : 'skip';
49
+ $this->merge_empty_cells = !empty($form_data['advanced_form_data']['wt_iew_merge_empty_cells']) ? 1 : 0;
50
+ $this->skip_new = !empty($form_data['advanced_form_data']['wt_iew_skip_new']) ? 1 : 0;
51
+
52
+
53
+ $this->use_sku_upsell_crosssell = !empty($form_data['advanced_form_data']['wt_iew_use_sku_upsell_crosssell']) ? 1 : 0;
54
+ $this->prod_use_chidren_sku = !empty($form_data['advanced_form_data']['wt_iew_prod_use_chidren_sku']) ? 1 : 0;
55
+ $this->pro_stop_thumbnail_regen = !empty($form_data['advanced_form_data']['wt_iew_pro_stop_thumbnail_regen']) ? 1 : 0;
56
+
57
+ $this->delete_existing = !empty($form_data['advanced_form_data']['wt_iew_delete_existing']) ? 1 : 0;
58
+
59
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Preparing for import.");
60
+ $success = 0;
61
+ $failed = 0;
62
+ $msg = 'Product imported successfully.';
63
+ foreach ($import_data as $key => $data) {
64
+ $row = $batch_offset+$key+1;
65
+
66
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Row :$row - Parsing item.");
67
+ $parsed_data = $this->parse_data($data);
68
+
69
+ if (!is_wp_error($parsed_data)){
70
+
71
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Row :$row - Processing item.");
72
+ $result = $this->process_item($parsed_data);
73
+
74
+ if(!is_wp_error($result)){
75
+ if($this->is_product_exist){
76
+ $msg = 'Product updated successfully.';
77
+ }
78
+ $this->import_results[$row] = array('row'=>$row, 'message'=>$msg, 'status'=>true, 'post_id'=>$result['id']);
79
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Row :$row - ".$msg);
80
+ $success++;
81
+ }else{
82
+ $this->import_results[$row] = array('row'=>$row, 'message'=>$result->get_error_message(), 'status'=>false, 'post_id'=>'');
83
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Row :$row - Processing failed. Reason: ".$result->get_error_message());
84
+ $failed++;
85
+ }
86
+ }else{
87
+ $this->import_results[$row] = array('row'=>$row, 'message'=>$parsed_data->get_error_message(), 'status'=>false, 'post_id'=>'');
88
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Row :$row - Parsing failed. Reason: ".$parsed_data->get_error_message());
89
+ $failed++;
90
+ }
91
+ }
92
+
93
+ if($is_last_batch && $this->delete_existing){
94
+ $this->delete_existing();
95
+ }
96
+
97
+ $this->clean_after_import();
98
+
99
+
100
+ $import_response=array(
101
+ 'total_success'=>$success,
102
+ 'total_failed'=>$failed,
103
+ 'log_data'=>$this->import_results,
104
+ );
105
+
106
+ return $import_response;
107
+
108
+ }
109
+
110
+ public function clean_after_import() {
111
+ global $wpdb;
112
+ $posts = $wpdb->get_col($wpdb->prepare("SELECT ID FROM {$wpdb->posts} WHERE post_status = '%s' AND post_type IN ( 'product', 'product_variation')", 'importing'));
113
+ if($posts){
114
+ array_map('wp_delete_post',$posts);
115
+ }
116
+ }
117
+
118
+
119
+ public function delete_existing() {
120
+
121
+ $posts = new WP_Query([
122
+ 'post_type' => array( 'product', 'product_variation'),
123
+ 'fields' => 'ids',
124
+ 'posts_per_page' => -1,
125
+ 'post_status' => array( 'publish', 'private', 'draft', 'pending', 'future'),
126
+ 'meta_query' => [
127
+ [
128
+ 'key' => '_wt_delete_existing',
129
+ 'compare' => 'NOT EXISTS',
130
+ ]
131
+ ]
132
+ ]);
133
+
134
+ foreach ($posts->posts as $post) {
135
+ $this->import_results['detele_results'][$post] = wp_trash_post($post);
136
+ }
137
+
138
+
139
+ $posts = new WP_Query([
140
+ 'post_type' => array( 'product', 'product_variation'),
141
+ 'fields' => 'ids',
142
+ 'posts_per_page' => -1,
143
+ 'post_status' => array( 'publish', 'private', 'draft', 'pending', 'future'),
144
+ 'meta_query' => [
145
+ [
146
+ 'key' => '_wt_delete_existing',
147
+ 'compare' => 'EXISTS',
148
+ ]
149
+ ]
150
+ ]);
151
+ foreach ($posts->posts as $post) {
152
+ delete_post_meta($post,'_wt_delete_existing');
153
+ }
154
+
155
+ }
156
+
157
+ /**
158
+ * Parse the data.
159
+ *
160
+ *
161
+ * @param array $data value.
162
+ *
163
+ * @return array
164
+ */
165
+ public function parse_data($data) {
166
+ try {
167
+ $mapped_data = $data['mapping_fields'];
168
+ foreach ($data['meta_mapping_fields'] as $value) {
169
+ $mapped_data = array_merge($mapped_data, $value);
170
+ }
171
+
172
+ $mapped_data = apply_filters('wt_woocommerce_product_importer_pre_parse_data', $mapped_data);
173
+
174
+ $this->item_data = array(); // resetting WC default data before parsing new item to avoid merging last parsed item wp_parse_args
175
+
176
+ if((isset($mapped_data['ID']) && !empty($mapped_data['ID']))||(isset($mapped_data['_sku']) && !empty($mapped_data['_sku']))){
177
+ $this->item_data['id'] = $this->wt_product_existance_check($mapped_data); // to determine wether merge or import
178
+ }
179
+
180
+ if(!$this->merge){
181
+ $default_data = $this->get_default_data();
182
+ $this->item_data = wp_parse_args( $this->item_data, $default_data );
183
+ // $this->item_data = $default_data;
184
+ }
185
+
186
+ if($this->merge && !$this->merge_empty_cells){
187
+ $this->item_data = array();
188
+ $this->item_data['id'] = $this->product_id; // re assinging id after reset default product datas for merge, $this->product_id set from wt_product_existance_check
189
+ }
190
+
191
+
192
+
193
+ foreach ($mapped_data as $column => $value) {
194
+
195
+ if ($this->merge && !$this->merge_empty_cells && $value == '' && !strstr($column, 'attribute')) {
196
+ continue;
197
+ }
198
+
199
+ if (!strstr($column, 'attribute:')) { // to escape case change of attribute name
200
+ $column = strtolower($column);
201
+ }
202
+
203
+
204
+ if ('parent_id' == $column || 'post_parent' == $column || 'parent_sku' == $column) {
205
+ $this->item_data['parent_id'] = $this->wt_parse_parent_field($value,$column);
206
+ continue;
207
+ }
208
+
209
+ if ('type' == $column || 'tax:product_type' == $column) {
210
+ $this->item_data['type'] = $this->wt_parse_type_field($value);
211
+ continue;
212
+ }
213
+ if ('sku' == $column || '_sku' == $column) {
214
+ $this->item_data['sku'] = $value;
215
+ continue;
216
+ }
217
+
218
+ if ('name' == $column || 'post_title' == $column) {
219
+ $this->item_data['name'] = $value;
220
+ continue;
221
+ }
222
+ if ('slug' == $column || 'post_name' == $column) {
223
+ $this->item_data['slug'] = $value;
224
+ continue;
225
+ }
226
+ if ('date_created' == $column || 'post_date' == $column) {
227
+ $this->item_data['date_created'] = $value;
228
+ $this->item_data['date_modified'] = $value;
229
+ continue;
230
+ }
231
+ if ('status' == $column || 'post_status' == $column) {
232
+ $this->item_data['status'] = $this->wt_parse_published_field($value);
233
+ continue;
234
+ }
235
+
236
+ if ('catalog_visibility' == $column || '_visibility' == $column || 'tax:product_visibility' == $column) {
237
+ $this->item_data['catalog_visibility'] = $this->wt_parse_catalog_visibility_field($value);
238
+ continue;
239
+ }
240
+ if ('description' == $column || 'post_content' == $column) {
241
+ $this->item_data['description'] = $this->wt_parse_description_field($value);
242
+ continue;
243
+ }
244
+ if ('short_description' == $column || 'post_excerpt' == $column) {
245
+ $this->item_data['short_description'] = $this->wt_parse_description_field($value);
246
+ continue;
247
+ }
248
+ if ('price' == $column || '_price' == $column) {
249
+ $this->item_data['price'] = wc_format_decimal($value);
250
+ continue;
251
+ }
252
+ if ('regular_price' == $column || '_regular_price' == $column) {
253
+ $this->item_data['regular_price'] = wc_format_decimal($value);
254
+ continue;
255
+ }
256
+ if ('sale_price' == $column || '_sale_price' == $column) {
257
+ $this->item_data['sale_price'] = wc_format_decimal($value);
258
+ continue;
259
+ }
260
+ if ('date_on_sale_from' == $column || '_sale_price_dates_from' == $column) {
261
+ $this->item_data['date_on_sale_from'] = $value;
262
+ continue;
263
+ }
264
+ if ('date_on_sale_to' == $column || '_sale_price_dates_to' == $column) {
265
+ $this->item_data['date_on_sale_to'] = $value;
266
+ continue;
267
+ }
268
+ if ('total_sales' == $column || '_total_sales' == $column) {
269
+ $this->item_data['total_sales'] = $this->wt_parse_int_field($value);
270
+ continue;
271
+ }
272
+ if ('tax_status' == $column || '_tax_status' == $column) {
273
+ $this->item_data['tax_status'] = $this->wt_parse_tax_status_field($value);
274
+ continue;
275
+ }
276
+ if ('tax_class' == $column || '_tax_class' == $column) {
277
+ $this->item_data['tax_class'] = ($value);
278
+ continue;
279
+ }
280
+ if ('stock_quantity' == $column || '_stock' == $column) {
281
+ $this->item_data['stock_quantity'] = $this->wt_parse_stock_quantity_field($value);
282
+ continue;
283
+ }
284
+ if ('manage_stock' == $column || '_manage_stock' == $column) {
285
+ $this->item_data['manage_stock'] = $this->wt_parse_string_to_bool_field($value);
286
+ continue;
287
+ }
288
+ if ('stock_status' == $column || '_stock_status' == $column) {
289
+ $this->item_data['stock_status'] = $this->wt_parse_stock_status_field($value);
290
+ continue;
291
+ }
292
+ if ('backorders' == $column || '_backorders' == $column) {
293
+ $this->item_data['backorders'] = $this->wt_parse_backorders_field($value);
294
+ continue;
295
+ }
296
+ if ('low_stock_amount' == $column || '_low_stock_amount' == $column) {
297
+ $this->item_data['low_stock_amount'] = $this->wt_parse_int_field($value);
298
+ continue;
299
+ }
300
+ if ('sold_individually' == $column || '_sold_individually' == $column) {
301
+ $this->item_data['sold_individually'] = $this->wt_parse_string_to_bool_field($value);
302
+ continue;
303
+ }
304
+ if ('product_url' == $column || '_product_url' == $column) {
305
+ $this->item_data['product_url'] = $value;
306
+ continue;
307
+ }
308
+ if ('button_text' == $column || '_button_text' == $column) {
309
+ $this->item_data['button_text'] = $value;
310
+ continue;
311
+ }
312
+ if ('weight' == $column || '_weight' == $column) {
313
+ $this->item_data['weight'] = ($value);
314
+ continue;
315
+ }
316
+ if ('length' == $column || '_length' == $column) {
317
+ $this->item_data['length'] = ($value);
318
+ continue;
319
+ }
320
+ if ('width' == $column || '_width' == $column) {
321
+ $this->item_data['width'] = ($value);
322
+ continue;
323
+ }
324
+ if ('height' == $column || '_height' == $column) {
325
+ $this->item_data['height'] = ($value);
326
+ continue;
327
+ }
328
+ if ('upsell_ids' == $column || '_upsell_ids' == $column || '_upsell_skus' == $column) {
329
+ $this->item_data['upsell_ids'] = $this->wt_parse_product_ids_field($value);
330
+ continue;
331
+ }
332
+ if ('crosssell_ids' == $column || '_crosssell_ids' == $column || '_crosssell_skus' == $column) {
333
+ $this->item_data['cross_sell_ids'] = $this->wt_parse_product_ids_field($value);
334
+ continue;
335
+ }
336
+ if ('reviews_allowed' == $column || 'comment_status' == $column) {
337
+ $this->item_data['reviews_allowed'] = $this->wt_parse_string_to_bool_field($value);
338
+ continue;
339
+ }
340
+ if ('purchase_note' == $column || '_purchase_note' == $column) {
341
+ $this->item_data['purchase_note'] = ($value);
342
+ continue;
343
+ }
344
+ if ('menu_order' == $column || 'position' == $column) {
345
+ $this->item_data['menu_order'] = $this->wt_parse_int_field($value);
346
+ continue;
347
+ }
348
+ if ('post_password' == $column) {
349
+ $this->item_data['post_password'] = ($value);
350
+ continue;
351
+ }
352
+ if ('virtual' == $column || '_virtual' == $column) {
353
+ $this->item_data['virtual'] = $this->wt_parse_string_to_bool_field($value);
354
+ continue;
355
+ }
356
+ if ('downloadable' == $column || '_downloadable' == $column) {
357
+ $this->item_data['downloadable'] = $this->wt_parse_string_to_bool_field($value);
358
+ continue;
359
+ }
360
+ if ('category_ids' == $column || 'tax:product_cat' == $column) {
361
+ $this->item_data['category_ids'] = $this->wt_parse_categories_field($value);
362
+ continue;
363
+ }
364
+ if ('tag_ids' == $column || 'tax:product_tag' == $column) {
365
+ $this->item_data['tag_ids'] = $this->wt_parse_tags_field($value);
366
+ continue;
367
+ }
368
+ if ('shipping_class_id' == $column || 'tax:product_shipping_class' == $column) {
369
+ $this->item_data['shipping_class_id'] = $this->wt_parse_shipping_class_field($value);
370
+ continue;
371
+ }
372
+ if ('downloads' == $column || '_downloadable_files' == $column) {
373
+ $this->item_data['downloads'] = $this->wt_parse_downloads_field($value);
374
+ continue;
375
+ }
376
+ if ('download_limit' == $column || '_download_limit' == $column) {
377
+ $this->item_data['download_limit'] = $this->wt_parse_int_field($value);
378
+ continue;
379
+ }
380
+ if ('download_expiry' == $column || '_download_expiry' == $column) {
381
+ $this->item_data['download_expiry'] = $this->wt_parse_int_field($value);
382
+ continue;
383
+ }
384
+ if ('rating_counts' == $column) {
385
+ $this->item_data['rating_counts'] = ($value);
386
+ continue;
387
+ }
388
+ if ('average_rating' == $column) {
389
+ $this->item_data['average_rating'] = $this->wt_parse_int_field($value);
390
+ continue;
391
+ }
392
+ if ('review_count' == $column) {
393
+ $this->item_data['review_count'] = $this->wt_parse_int_field($value);
394
+ continue;
395
+ }
396
+ if ('Grouped products' == $column || 'children' == $column || '_children' == $column) {
397
+ $this->item_data['children'] = $this->wt_parse_product_ids_field($value);
398
+ continue;
399
+ }
400
+ if ('images' == $column) {
401
+ $images = $this->wt_parse_images_field($value);
402
+ $this->item_data['raw_image'] = array_shift($images);
403
+ if (!empty($images)) {
404
+ $this->item_data['raw_gallery_image'] = $images;
405
+ }
406
+ unset($images);
407
+ continue;
408
+ }
409
+
410
+ if (strstr($column, 'attribute:')) {
411
+ $this->wt_parse_attribute_field($value, $column);
412
+ continue;
413
+ }
414
+
415
+ if (strstr($column, 'attribute_data:')) {
416
+ $this->wt_parse_attribute_data_field($value, $column);
417
+ continue;
418
+ }
419
+ if (strstr($column, 'attribute_default:')) {
420
+ $this->wt_parse_attribute_default_field($value, $column);
421
+ continue;
422
+ }
423
+
424
+ if (strstr($column, 'meta:')) {
425
+ $this->wt_parse_meta_field($value, $column);
426
+ continue;
427
+ }
428
+
429
+ }
430
+
431
+ if(empty($this->item_data['id'])){
432
+ $this->item_data['id'] = $this->wt_parse_id_field($mapped_data);
433
+ }
434
+
435
+ return $this->item_data;
436
+ } catch (Exception $e) {
437
+ return new WP_Error('woocommerce_product_importer_error', $e->getMessage(), array('status' => $e->getCode()));
438
+ }
439
+ }
440
+
441
+ /**
442
+ * Explode CSV cell values using commas by default, and handling escaped
443
+ * separators.
444
+ *
445
+ * @since 3.2.0
446
+ * @param string $value Value to explode.
447
+ * @param string $separator Separator separating each value. Defaults to comma.
448
+ * @return array
449
+ */
450
+ protected function wt_explode_values( $value, $separator = ',' ) {
451
+ $value = str_replace( '\\,', '::separator::', $value );
452
+ $values = explode( $separator, $value );
453
+ $values = array_map( array( $this, 'wt_explode_values_formatter' ), $values );
454
+
455
+ return $values;
456
+ }
457
+
458
+ /**
459
+ * Remove formatting and trim each value.
460
+ *
461
+ * @since 3.2.0
462
+ * @param string $value Value to format.
463
+ * @return string
464
+ */
465
+ protected function wt_explode_values_formatter( $value ) {
466
+ return trim( str_replace( '::separator::', ',', $value ) );
467
+ }
468
+
469
+ public function wt_parse_product_ids_field($value){
470
+
471
+ if('' == $value){
472
+ return array();
473
+ }
474
+ if($this->use_sku_upsell_crosssell){
475
+ $value = array_map('wc_get_product_id_by_sku',$this->wt_parse_seperation_field($value,'|'));
476
+ }else{
477
+ $value = $this->wt_parse_seperation_field($value,'|');
478
+ }
479
+
480
+ return $value;
481
+ }
482
+
483
+
484
+ public function wt_parse_catalog_visibility_field( $value ) {
485
+ if (strstr($value, '|')) {
486
+ $visibilities = $this->wt_parse_seperation_field($value,'|');
487
+
488
+ if(in_array('featured', $visibilities)){
489
+ $this->item_data['featured'] = true;
490
+ }
491
+
492
+ if(in_array('exclude-from-search', $visibilities)){ // Search result only
493
+ $visibility = 'catalog';
494
+ }
495
+
496
+ if(in_array('exclude-from-catalog', $visibilities)){ // Shop only
497
+ $visibility ='search';
498
+ }
499
+
500
+ if(in_array('exclude-from-catalog', $visibilities) && in_array('exclude-from-search', $visibilities)){ // Hidden
501
+ $visibility ='hidden';
502
+ }
503
+ }else{
504
+
505
+ $visibility = $value = strtolower($value);
506
+
507
+ if('featured' == $value){
508
+ $this->item_data['featured'] = true;
509
+ }
510
+
511
+ if('exclude-from-search' == $value){ // Search result only
512
+ $visibility = 'catalog';
513
+ }
514
+
515
+ if('exclude-from-catalog' == $value){ // Shop only
516
+ $visibility ='search';
517
+ }
518
+ }
519
+
520
+ $options = array_keys( wc_get_product_visibility_options() );
521
+ if ( ! in_array( $visibility, $options ) ) {
522
+
523
+ // $this->error( 'product_invalid_catalog_visibility', __( 'Invalid catalog visibility option.', 'woocommerce' ) );
524
+ $visibility = 'visible';
525
+ }
526
+ return $visibility;
527
+ }
528
+
529
+ /**
530
+ * Parse backorders from a CSV.
531
+ *
532
+ * @param string $value Field value.
533
+ *
534
+ * @return string
535
+ */
536
+ public function wt_parse_backorders_field( $value ) {
537
+ $value = strtolower($value);
538
+ if ( empty( $value ) ) {
539
+ return 'no';
540
+ }
541
+
542
+ if ( 'notify' === $value ) {
543
+ return 'notify';
544
+ } elseif ( is_bool( $value ) ) {
545
+ return $value ? 'yes' : 'no';
546
+ }
547
+
548
+ return 'no';
549
+ }
550
+
551
+
552
+
553
+
554
+ public function wt_parse_stock_quantity_field($value) {
555
+
556
+ if ('' === $value) {
557
+ return $value;
558
+ }
559
+
560
+ return wc_stock_amount($value);
561
+
562
+ }
563
+
564
+ public function wt_parse_stock_status_field($value) {
565
+ $stock_status = $value;
566
+ // Stock is bool or 'backorder'.
567
+ if ( isset( $value ) ) {
568
+ if ( 'backorder' === $value ) {
569
+ $stock_status = 'onbackorder';
570
+ } else {
571
+ $stock_status = $value ? 'instock' : 'outofstock';
572
+ }
573
+ }
574
+ return $stock_status;
575
+
576
+ }
577
+
578
+ public function wt_parse_string_to_bool_field($value) {
579
+ $value = strtolower(trim($value));
580
+
581
+ if ( isset( $value ) ) {
582
+ if ( 'open' == $value ) { // comment_status
583
+ return true;
584
+ }
585
+ if ( '' === $value ) {
586
+ return false;
587
+ } else {
588
+ return wc_string_to_bool($value);
589
+ }
590
+ }
591
+ return false;
592
+
593
+
594
+ }
595
+
596
+ public function wt_parse_parent_field($value,$column){
597
+ if(!empty($this->item_data['parent_id'])){
598
+ return $this->item_data['parent_id'];
599
+ }
600
+ global $wpdb;
601
+
602
+ if ( '' == $value ) {
603
+ return '';
604
+ }
605
+
606
+ $parent_id = '';
607
+ // ID
608
+ if ( 'parent_sku' != $column ) {
609
+ $id = intval( $value );
610
+
611
+ // See if the given ID maps to a valid product allready.
612
+ $existing_id = $wpdb->get_var( $wpdb->prepare( "SELECT ID FROM {$wpdb->posts} WHERE post_type IN ( 'product' ) AND ID = %d;", $id ) ); // WPCS: db call ok, cache ok.
613
+ if ( $existing_id ) {
614
+ $parent_id = absint( $existing_id );
615
+ }
616
+
617
+ }else{
618
+
619
+ // $id = wc_get_product_id_by_sku( $value );
620
+ $value = trim($value);
621
+
622
+ $db_query = $wpdb->prepare("SELECT $wpdb->posts.ID
623
+ FROM $wpdb->posts
624
+ LEFT JOIN $wpdb->postmeta ON ($wpdb->posts.ID = $wpdb->postmeta.post_id)
625
+ WHERE $wpdb->posts.post_status IN ( 'publish', 'private', 'draft', 'pending', 'future' )
626
+ AND $wpdb->posts.post_type IN ( 'product' )
627
+ AND $wpdb->postmeta.meta_key = '_sku' AND $wpdb->postmeta.meta_value = '%s'
628
+ ", $value);
629
+ $id = $wpdb->get_var($db_query);
630
+
631
+ if ( $id ) {
632
+ $parent_id = $id;
633
+ }
634
+
635
+ }
636
+
637
+
638
+ if($parent_id && empty($this->item_data['type'])){
639
+ throw new Exception('Basic version does not support import of variable products.' );
640
+ // $this->item_data['type'] = 'variation';
641
+ }
642
+
643
+ return $parent_id;
644
+
645
+ }
646
+
647
+ public function wt_parse_type_field($value) {
648
+ if(!empty($this->item_data['type'])){
649
+ return $this->item_data['type'];
650
+ }
651
+
652
+ $value = strtolower(trim($value));
653
+
654
+ $type = $value;
655
+
656
+ if ( $value == '') {
657
+ $type = 'simple';
658
+ }
659
+
660
+ if('' == $value && !empty($this->item_data['parent_id'])){
661
+ $type = 'variation';
662
+ }
663
+
664
+
665
+ if( $type == 'variation' || $type == 'variable' ){
666
+ throw new Exception(sprintf('Basic version does not support import of %s products.',$value ));
667
+ }
668
+
669
+
670
+ // Type is the most important part here because we need to be using the correct class and methods.
671
+ elseif ( isset( $value ) ) {
672
+
673
+ $types = array_keys( wc_get_product_types() );
674
+ // $types[] = 'variation';
675
+
676
+ if ( ! in_array( $type, $types, true ) ) {
677
+ throw new Exception(sprintf('Invalid product type %s',$value ));
678
+ }
679
+ }
680
+ return $type;
681
+ }
682
+
683
+ public function wt_parse_meta_field($value,$column) {
684
+ $meta_key = trim(str_replace('meta:', '', $column));
685
+
686
+ /**
687
+ * Handle meta: columns for variation attributes
688
+ */
689
+ if (strstr($column, 'meta:attribute_')) {
690
+
691
+ $attribute_key = (trim(str_replace('meta:attribute_', '', $column)));
692
+
693
+ if (!$attribute_key )
694
+ return;
695
+
696
+ if('variation' == $this->item_data['type']){
697
+ $this->item_data['raw_attributes'][$attribute_key]['value'] = $this->wt_parse_seperation_field($value,'|');
698
+ }
699
+ return;
700
+
701
+ }
702
+ $this->item_data['meta_data'][] = array('key'=>$meta_key,'value'=>$value);
703
+ }
704
+
705
+ public function wt_parse_taxonomy_field($value) {
706
+ return $value;
707
+ }
708
+
709
+ /**
710
+ * Handle Attributes
711
+ */
712
+ public function wt_parse_attribute_field($value,$column) {
713
+ $attribute_key = sanitize_title(trim(str_replace('attribute:', '', $column)));
714
+
715
+ $attribute_args = array('name'=>'',
716
+ 'value'=>array(),
717
+ 'visible'=>1,
718
+ 'taxonomy'=>0,
719
+ 'default'=>'',
720
+ 'position' =>0,
721
+ );
722
+
723
+ if (!$attribute_key)
724
+ return;
725
+
726
+ // Taxonomy
727
+ if (substr($attribute_key, 0, 3) == 'pa_') {
728
+ $this->item_data['raw_attributes'][$attribute_key]['name'] = trim(str_replace('attribute:pa_', '', $column));
729
+ $this->item_data['raw_attributes'][$attribute_key]['taxonomy'] = 1;
730
+ }else{
731
+ $this->item_data['raw_attributes'][$attribute_key]['name'] = trim(str_replace('attribute:', '', $column));
732
+ $this->item_data['raw_attributes'][$attribute_key]['taxonomy'] = 0;
733
+ }
734
+ if('variation' != $this->item_data['type']){
735
+ $this->item_data['raw_attributes'][$attribute_key]['value'] = $this->wt_parse_seperation_field($value,'|');
736
+ }
737
+
738
+ return;
739
+
740
+ }
741
+
742
+ /**
743
+ * Handle Attributes Data - position|is_visible|is_variation
744
+ */
745
+ public function wt_parse_attribute_data_field($value,$column) {
746
+
747
+ $attribute_key = sanitize_title(trim(str_replace('attribute_data:', '', $column)));
748
+
749
+ if (!$attribute_key) {
750
+ return;
751
+ }
752
+
753
+ $values = explode('|', $value);
754
+ $position = isset($values[0]) ? (int) $values[0] : 0;
755
+ $visible = isset($values[1]) ? (int) $values[1] : 1;
756
+ $variation = isset($values[2]) ? (int) $values[2] : 0;
757
+
758
+ $this->item_data['raw_attributes'][$attribute_key]['visible'] = $visible;
759
+ $this->item_data['raw_attributes'][$attribute_key]['position'] = $position;
760
+ return;
761
+
762
+ }
763
+
764
+ /**
765
+ * Handle Attributes Default Values
766
+ */
767
+ public function wt_parse_attribute_default_field($value,$column) {
768
+ $attribute_key = sanitize_title(trim(str_replace('attribute_default:', '', $column)));
769
+
770
+ if (!$attribute_key || '' == $value )
771
+ return;
772
+
773
+
774
+ $this->item_data['raw_attributes'][$attribute_key]['default'] = $value;
775
+ return;
776
+
777
+ }
778
+
779
+
780
+
781
+ public function wt_product_existance_check($data){
782
+ global $wpdb;
783
+ $product_id = 0;
784
+ $this->is_product_exist = false;
785
+
786
+ $id = isset($data['ID']) && !empty($data['ID']) ? absint($data['ID']) : 0;
787
+ $id_found_with_id = '';
788
+ if($id && 'id' == $this->merge_with){
789
+ $id_found_with_id = $wpdb->get_var($wpdb->prepare("SELECT ID FROM {$wpdb->posts} WHERE post_status IN ( 'publish', 'private', 'draft', 'pending', 'future' ) AND ID = %d;", $id)); // WPCS: db call ok, cache ok.
790
+ if($id_found_with_id){
791
+ if(in_array(get_post_type($id_found_with_id), array('product', 'product_variation'))){
792
+ $this->is_product_exist = true;
793
+ $product_id = $id_found_with_id;
794
+ }
795
+ }
796
+ }
797
+
798
+ $sku = isset($data['_sku']) && '' != $data['_sku'] ? trim($data['_sku']) : '';
799
+ $id_found_with_sku = '';
800
+ if(!empty($sku) && 'sku' == $this->merge_with){
801
+ $db_query = $wpdb->prepare("SELECT $wpdb->posts.ID,$wpdb->posts.post_type
802
+ FROM $wpdb->posts
803
+ LEFT JOIN $wpdb->postmeta ON ($wpdb->posts.ID = $wpdb->postmeta.post_id)
804
+ WHERE $wpdb->posts.post_status IN ( 'publish', 'private', 'draft', 'pending', 'future' )
805
+ AND $wpdb->postmeta.meta_key = '_sku' AND $wpdb->postmeta.meta_value = '%s'
806
+ ", $sku);
807
+ $id_found_with_sku = $wpdb->get_row($db_query);
808
+ if ($id_found_with_sku && (in_array($id_found_with_sku->post_type, array('product', 'product_variation')))) {
809
+ $id_found_with_sku = $id_found_with_sku->ID;
810
+ $this->is_product_exist = true;
811
+ $product_id = $id_found_with_sku;
812
+ }
813
+ }
814
+
815
+
816
+ if($this->is_product_exist){
817
+ if('skip' == $this->found_action){
818
+ if($id && $id_found_with_id ){
819
+ throw new Exception(sprintf('Product with same ID already exists. ID: %d',$id ));
820
+ }elseif($sku && $id_found_with_sku ){
821
+ throw new Exception(sprintf('Product with same SKU already exists. SKU: %s',$sku ));
822
+ }else{
823
+ throw new Exception('Product already exists.');
824
+ }
825
+ }elseif('update' == $this->found_action){
826
+ $this->merge = true;
827
+ $this->product_id = $product_id;
828
+ return $product_id;
829
+ }
830
+ }
831
+
832
+ if($this->skip_new){
833
+ throw new Exception('Skipping new item' );
834
+ }
835
+
836
+ if($id && $id_found_with_id && !$this->is_product_exist && 'skip' == $this->id_conflict){
837
+ throw new Exception(sprintf('Importing Product(ID) conflicts with an existing post. ID: %d',$id ));
838
+ }
839
+ }
840
+
841
+
842
+
843
+ /**
844
+ * Parse relative field and return ID.
845
+ *
846
+ * Handles `id` and Product SKU.
847
+ *
848
+ * If we're not doing an update, create a prost and return ID
849
+ * for rows following this one.
850
+ *
851
+ * @param array $data mapped data.
852
+ *
853
+ * @return int|Exception
854
+ */
855
+ public function wt_parse_id_field($data ) {
856
+ if(!empty($this->item_data['id'])){
857
+ return $this->item_data['id'];
858
+ }
859
+
860
+
861
+ $id = isset($data['ID']) && !empty($data['ID']) ? absint($data['ID']) : 0;
862
+ $found_id = $this->wt_product_existance_check($id);
863
+ if($found_id){
864
+ return $found_id;
865
+ }
866
+
867
+ $postdata = array( // if not specifiying id (id is empty) or if not found by given id or Product
868
+ 'post_title' => ($this->item_data['type'] == 'variation' ? 'product variation' : $this->item_data['name'] ),
869
+ 'post_status' => 'importing',
870
+ 'post_type' => $this->post_type,
871
+ );
872
+ if(isset($id) && !empty($id)){
873
+ $postdata['import_id'] = $id;
874
+ }
875
+
876
+ $post_id = wp_insert_post( $postdata, true );
877
+ if($post_id && !is_wp_error($post_id)){
878
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', sprintf('Importing as new '. ($this->parent_module->module_base).' ID:%d',$post_id ));
879
+ return $post_id;
880
+ }else{
881
+ throw new Exception($post_id->get_error_message());
882
+ }
883
+
884
+ }
885
+
886
+
887
+ /**
888
+ * Parse a comma-delineated field from a CSV.
889
+ *
890
+ * @param string $value Field value.
891
+ *
892
+ * @return array
893
+ */
894
+ public function wt_parse_seperation_field( $value, $separator = ',' ) {
895
+ if ( empty( $value ) && '0' !== $value ) {
896
+ return array();
897
+ }
898
+
899
+ return array_map( 'wc_clean', $this->wt_explode_values( $value ,$separator) );
900
+ }
901
+
902
+ /**
903
+ * Parse a field that is generally '1' or '0' but can be something else.
904
+ *
905
+ * @param string $value Field value.
906
+ *
907
+ * @return bool|string
908
+ */
909
+ public function wt_parse_bool_field( $value ) {
910
+ if ( '0' === $value ) {
911
+ return false;
912
+ }
913
+
914
+ if ( '1' === $value ) {
915
+ return true;
916
+ }
917
+
918
+ // Don't return explicit true or false for empty fields or values like 'notify'.
919
+ return wc_clean( $value );
920
+ }
921
+
922
+
923
+ /**
924
+ * Parse the tax status field.
925
+ *
926
+ * @param string $value Field value.
927
+ *
928
+ * @return string
929
+ */
930
+ public function wt_parse_tax_status_field( $value ) {
931
+ if ( '' === $value ) {
932
+ return $value;
933
+ }
934
+ $tax_status = strtolower($value);
935
+ $value = ('taxable' == $tax_status || 'shipping' == $tax_status) ? $tax_status : 'none';
936
+
937
+ return wc_clean( $value );
938
+ }
939
+
940
+ /**
941
+ * Parse a category field from a CSV.
942
+ * Categories are separated by commas and subcategories are "parent > subcategory".
943
+ *
944
+ * @param string $value Field value.
945
+ *
946
+ * @return array of arrays with "parent" and "name" keys.
947
+ */
948
+ public function wt_parse_categories_field( $value ) {
949
+ if ( empty( $value ) ) {
950
+ return array();
951
+ }
952
+ $row_terms = $this->wt_explode_values( $value ,'|' );
953
+ $categories = array();
954
+
955
+ foreach ( $row_terms as $row_term ) {
956
+ $parent = null;
957
+ $_terms = array_map( 'trim', explode( '>', $row_term ) );
958
+ $total = count( $_terms );
959
+
960
+ foreach ( $_terms as $index => $_term ) {
961
+ // Check if category exists. Parent must be empty string or null if doesn't exists.
962
+ $term = term_exists( $_term, 'product_cat', $parent );
963
+
964
+ if ( is_array( $term ) ) {
965
+ $term_id = $term['term_id'];
966
+ // Don't allow users without capabilities to create new categories.
967
+ } elseif ( ! current_user_can( 'manage_product_terms' ) ) {
968
+ break;
969
+ } else {
970
+ $term = wp_insert_term( $_term, 'product_cat', array( 'parent' => intval( $parent ) ) );
971
+
972
+ if ( is_wp_error( $term ) ) {
973
+ break; // We cannot continue if the term cannot be inserted.
974
+ }
975
+
976
+ $term_id = $term['term_id'];
977
+ }
978
+
979
+ // Only requires assign the last category.
980
+ if ( ( 1 + $index ) === $total ) {
981
+ $categories[] = $term_id;
982
+ } else {
983
+ // Store parent to be able to insert or query categories based in parent ID.
984
+ $parent = $term_id;
985
+ }
986
+ }
987
+ }
988
+
989
+ return $categories;
990
+ }
991
+
992
+ /**
993
+ * Parse a tag field from a CSV.
994
+ *
995
+ * @param string $value Field value.
996
+ *
997
+ * @return array
998
+ */
999
+ public function wt_parse_tags_field( $value ) {
1000
+ if ( empty( $value ) ) {
1001
+ return array();
1002
+ }
1003
+
1004
+ $names = $this->wt_explode_values( $value, '|' );
1005
+ $tags = array();
1006
+
1007
+ foreach ( $names as $name ) {
1008
+
1009
+ $term = get_term_by( 'name', $name, 'product_tag' );
1010
+
1011
+ if ( ! $term || is_wp_error( $term ) ) {
1012
+ $term = (object) wp_insert_term( $name, 'product_tag' );
1013
+ }
1014
+
1015
+ if ( ! is_wp_error( $term ) ) {
1016
+ $tags[] = $term->term_id;
1017
+ }
1018
+ }
1019
+
1020
+ return $tags;
1021
+ }
1022
+
1023
+ /**
1024
+ * Parse a tag field from a CSV with space separators.
1025
+ *
1026
+ * @param string $value Field value.
1027
+ *
1028
+ * @return array
1029
+ */
1030
+ public function wt_parse_tags_spaces_field( $value ) {
1031
+ if ( empty( $value ) ) {
1032
+ return array();
1033
+ }
1034
+
1035
+ $names = $this->wt_explode_values( $value, ' ' );
1036
+ $tags = array();
1037
+
1038
+ foreach ( $names as $name ) {
1039
+ $term = get_term_by( 'name', $name, 'product_tag' );
1040
+
1041
+ if ( ! $term || is_wp_error( $term ) ) {
1042
+ $term = (object) wp_insert_term( $name, 'product_tag' );
1043
+ }
1044
+
1045
+ if ( ! is_wp_error( $term ) ) {
1046
+ $tags[] = $term->term_id;
1047
+ }
1048
+ }
1049
+
1050
+ return $tags;
1051
+ }
1052
+
1053
+ /**
1054
+ * Parse a shipping class field from a CSV.
1055
+ *
1056
+ * @param string $value Field value.
1057
+ *
1058
+ * @return int
1059
+ */
1060
+ public function wt_parse_shipping_class_field( $value ) {
1061
+ if ( empty( $value ) ) {
1062
+ return 0;
1063
+ }
1064
+
1065
+ $term = get_term_by( 'name', $value, 'product_shipping_class' );
1066
+
1067
+ if ( ! $term || is_wp_error( $term ) ) {
1068
+ $term = (object) wp_insert_term( $value, 'product_shipping_class' );
1069
+ }
1070
+
1071
+ if ( is_wp_error( $term ) ) {
1072
+ return 0;
1073
+ }
1074
+
1075
+ return $term->term_id;
1076
+ }
1077
+
1078
+ /**
1079
+ * Parse images list from a CSV. Images can be filenames or URLs.
1080
+ *
1081
+ * @param string $value Field value.
1082
+ *
1083
+ * @return array
1084
+ */
1085
+ public function wt_parse_images_field( $value ) {
1086
+ if ( empty( $value ) ) {
1087
+ return array();
1088
+ }
1089
+
1090
+ $images = array();
1091
+ $separator = apply_filters( 'wt_woocommerce_product_import_image_separator', '|' );
1092
+ foreach ( $this->wt_explode_values( $value, $separator ) as $image_data ) {
1093
+ $images[] = $this->arrange_product_images($image_data);
1094
+
1095
+
1096
+ }
1097
+ return $images;
1098
+ }
1099
+
1100
+ /**
1101
+ * Arrange product images metadata
1102
+ */
1103
+ public function arrange_product_images($image_data) {
1104
+ if (!empty($image_data)) {
1105
+ $image_details[] = explode('!', $image_data);
1106
+ foreach ($image_details as $image_detail) {
1107
+ $j = 0;
1108
+ foreach ($image_detail as $current_image_detail) {
1109
+ if ($j == 0) {
1110
+ $images['url'] = trim($current_image_detail);
1111
+ $j++;
1112
+ continue;
1113
+ }
1114
+ @list($image['key'], $image['data']) = explode(':', $current_image_detail);
1115
+ $images[trim(strtolower($image['key']))] = trim($image['data']);
1116
+ }
1117
+ }
1118
+ unset($image_details, $image_detail, $current_image_detail, $image, $image_data, $j);
1119
+ }
1120
+ return $images;
1121
+ }
1122
+
1123
+
1124
+ /**
1125
+ * Parse download file urls, we should allow shortskus here.
1126
+ *
1127
+ * Allow shortskus if present, othersiwe esc_url the value.
1128
+ *
1129
+ * @param string $value Field value.
1130
+ *
1131
+ * @return string
1132
+ */
1133
+ public function wt_parse_download_file_field( $value ) {
1134
+ // Absolute file paths.
1135
+ if ( 0 === strpos( $value, 'http' ) ) {
1136
+ return esc_url_raw( $value );
1137
+ }
1138
+ // Relative and shortsku paths.
1139
+ return wc_clean( $value );
1140
+ }
1141
+
1142
+ /**
1143
+ * Parse an int value field
1144
+ *
1145
+ * @param int $value field value.
1146
+ *
1147
+ * @return int
1148
+ */
1149
+ public function wt_parse_int_field( $value ) {
1150
+ // Remove the ' prepended to fields that start with - if needed.
1151
+ // $value = $this->unescape_data( $value );
1152
+
1153
+ return intval( $value );
1154
+ }
1155
+
1156
+ /**
1157
+ * Parse the published field. 1 is published, 0 is private, -1 is draft.
1158
+ * Alternatively, 'true' can be used for published and 'false' for draft.
1159
+ *
1160
+ * @param string $value Field value.
1161
+ *
1162
+ * @return float|string
1163
+ */
1164
+ public function wt_parse_published_field( $value ) {
1165
+
1166
+ $product_status = strtolower($value);
1167
+
1168
+ // Status is mapped from a special published field.
1169
+ if (in_array($product_status, array(1, '1', TRUE, 'true', 'publish'), TRUE)) {
1170
+ $product_status = 'publish';
1171
+ } elseif (in_array($product_status, array(0, '0', FALSE, 'false', 'draft'), TRUE)) {
1172
+ $product_status = 'draft';
1173
+ }
1174
+
1175
+ if (!in_array($product_status, array('publish', 'private', 'draft', 'pending', 'future', 'inherit', 'trash'))) {
1176
+ $product_status = 'publish';
1177
+ }
1178
+
1179
+ return $product_status;
1180
+
1181
+ }
1182
+
1183
+ public function wt_parse_downloads_field($value){
1184
+ if ( empty( $value ) ) {
1185
+ return array();
1186
+ }
1187
+ $download = array();
1188
+ foreach ( $this->wt_explode_values( $value, '|' ) as $key => $download_data ) {
1189
+ @list($download[$key]['name'], $download[$key]['file']) = explode('::', $download_data);
1190
+ }
1191
+ return $download;
1192
+
1193
+ }
1194
+
1195
+
1196
+ /**
1197
+ * Parse a description value field
1198
+ *
1199
+ * @param string $description field value.
1200
+ *
1201
+ * @return string
1202
+ */
1203
+ public function wt_parse_description_field( $description ) {
1204
+ $parts = explode( "\\\\n", $description );
1205
+ foreach ( $parts as $key => $part ) {
1206
+ $parts[ $key ] = str_replace( '\n', "\n", $part );
1207
+ }
1208
+
1209
+ return implode( '\\\n', $parts );
1210
+ }
1211
+
1212
+
1213
+
1214
+ public function get_default_data(){
1215
+ return array(
1216
+ // 'id' => 0,
1217
+ 'name' => '',
1218
+ 'slug' => '',
1219
+ 'date_created' => null,
1220
+ 'date_modified' => null,
1221
+ 'status' => false,
1222
+ 'featured' => false,
1223
+ 'catalog_visibility' => 'visible',
1224
+ 'description' => '',
1225
+ 'short_description' => '',
1226
+ 'sku' => '',
1227
+ 'price' => '',
1228
+ 'regular_price' => '',
1229
+ 'sale_price' => '',
1230
+ 'date_on_sale_from' => null,
1231
+ 'date_on_sale_to' => null,
1232
+ 'total_sales' => '0',
1233
+ 'tax_status' => 'taxable',
1234
+ 'tax_class' => '',
1235
+ 'manage_stock' => false,
1236
+ 'stock_quantity' => null,
1237
+ 'stock_status' => 'instock',
1238
+ 'backorders' => 'no',
1239
+ 'low_stock_amount' => '',
1240
+ 'sold_individually' => false,
1241
+ 'weight' => '',
1242
+ 'length' => '',
1243
+ 'width' => '',
1244
+ 'height' => '',
1245
+ 'upsell_ids' => array(),
1246
+ 'cross_sell_ids' => array(),
1247
+ 'parent_id' => 0,
1248
+ 'reviews_allowed' => true,
1249
+ 'purchase_note' => '',
1250
+ 'attributes' => array(),
1251
+ 'default_attributes' => array(),
1252
+ 'menu_order' => 0,
1253
+ 'post_password' => '',
1254
+ 'virtual' => false,
1255
+ 'downloadable' => false,
1256
+ 'category_ids' => array(),
1257
+ 'tag_ids' => array(),
1258
+ 'shipping_class_id' => 0,
1259
+ 'downloads' => array(),
1260
+ 'image_id' => '',
1261
+ 'gallery_image_ids' => array(),
1262
+ 'download_limit' => -1,
1263
+ 'download_expiry' => -1,
1264
+ 'rating_counts' => array(),
1265
+ 'average_rating' => 0,
1266
+ 'review_count' => 0,
1267
+ // Grouped product
1268
+ 'children' => array()
1269
+ );
1270
+ }
1271
+
1272
+ public function process_item($data) {
1273
+
1274
+ try {
1275
+ do_action('wt_woocommerce_product_import_before_process_item', $data);
1276
+ $data = apply_filters('wt_woocommerce_product_import_process_item_data', $data);
1277
+
1278
+ // Get product ID from SKU if created during the importation.
1279
+ if (empty($data['id']) && !empty($data['sku'])) {
1280
+ $product_id = wc_get_product_id_by_sku($data['sku']);
1281
+
1282
+ if ($product_id) {
1283
+ $data['id'] = $product_id;
1284
+ }
1285
+ }
1286
+
1287
+ $object = $this->get_product_object($data);
1288
+
1289
+ if (is_wp_error($object)) {
1290
+ return $object;
1291
+ }
1292
+
1293
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', "Found ".$object->get_type()." product object. ID:".$object->get_id());
1294
+
1295
+ if ('external' === $object->get_type()) {
1296
+ unset($data['manage_stock'], $data['stock_status'], $data['backorders'], $data['low_stock_amount']);
1297
+ }
1298
+
1299
+ if ('variation' === $object->get_type()) {
1300
+ if (isset($data['status']) && 'draft' === $data['status']) {
1301
+ $data['status'] = 'private'; // Variations cannot be drafts - set to private.
1302
+ }
1303
+ }
1304
+
1305
+ if ('importing' === $object->get_status()) {
1306
+ $object->set_status($data['status']);
1307
+ }
1308
+
1309
+ $result = $object->set_props(array_diff_key($data, array_flip(array('meta_data', 'raw_image_id', 'raw_gallery_image_ids', 'raw_attributes','attributes','default_attributes','images'))));
1310
+
1311
+ if (is_wp_error($result)) {
1312
+ throw new Exception($result->get_error_message());
1313
+ }
1314
+
1315
+
1316
+ if(isset($data['raw_attributes']) && is_array($data['raw_attributes'])){
1317
+ $data['raw_attributes'] = array_filter($data['raw_attributes'],array( $this, 'wt_remove_empty_attributes' ));
1318
+ // Sort attribute positions
1319
+ if (!function_exists('attributes_cmp')) {
1320
+
1321
+ function attributes_cmp($a, $b) {
1322
+ if ($a['position'] == $b['position'])
1323
+ return 0;
1324
+ return ( $a['position'] < $b['position'] ) ? -1 : 1;
1325
+ }
1326
+
1327
+ }
1328
+ uasort($data['raw_attributes'], 'attributes_cmp');
1329
+ }else{
1330
+ $data['raw_attributes'] = array();
1331
+ }
1332
+
1333
+
1334
+ if (in_array($object->get_type(),array('variation','subscription_variation'))) {
1335
+ $this->set_variation_data($object, $data);
1336
+ } else {
1337
+ $this->set_product_data($object, $data);
1338
+ }
1339
+
1340
+
1341
+ $this->set_image_data($object, $data);
1342
+
1343
+ $this->set_meta_data($object, $data);
1344
+
1345
+ $object = apply_filters('wt_woocommerce_product_import_pre_insert_product_object', $object, $data);
1346
+
1347
+ $object->save();
1348
+
1349
+ if($this->delete_existing){
1350
+ update_post_meta($object->get_id(), '_wt_delete_existing', 1);
1351
+ }
1352
+
1353
+ do_action('wt_woocommerce_product_import_inserted_product_object', $object, $data);
1354
+
1355
+ return $result = array(
1356
+ 'id' => $object->get_id(),
1357
+ 'updated' => $this->merge,
1358
+ );
1359
+ } catch (Exception $e) {
1360
+ return new WP_Error('woocommerce_product_importer_error', $e->getMessage(), array('status' => $e->getCode()));
1361
+ }
1362
+ }
1363
+
1364
+ public function wt_remove_empty_attributes($attribute) {
1365
+ if(!empty($attribute['value'])){
1366
+ return $attribute;
1367
+ }
1368
+ }
1369
+
1370
+ function get_product_object($data) {
1371
+ $id = isset($data['id']) ? absint($data['id']) : 0;
1372
+
1373
+ // Type is the most important part here because we need to be using the correct class and methods.
1374
+ if (isset($data['type'])) {
1375
+ $types = array_keys(wc_get_product_types());
1376
+ $types[] = 'variation';
1377
+
1378
+ if (!in_array($data['type'], $types, true)) {
1379
+ return new WP_Error('woocommerce_product_importer_invalid_type', __('Invalid product type.', 'woocommerce'), array('status' => 401));
1380
+ }
1381
+
1382
+ try {
1383
+ // Prevent getting "variation_invalid_id" error message from Variation Data Store.
1384
+ if ('variation' === $data['type']) {
1385
+ $id = wp_update_post(
1386
+ array(
1387
+ 'ID' => $id,
1388
+ 'post_type' => 'product_variation',
1389
+ )
1390
+ );
1391
+ }
1392
+
1393
+ $product = wc_get_product_object($data['type'], $id);
1394
+ } catch (WC_Data_Exception $e) {
1395
+ return new WP_Error('woocommerce_product_csv_importer_' . $e->getErrorCode(), $e->getMessage(), array('status' => 401));
1396
+ }
1397
+ } elseif (!empty($data['id'])) {
1398
+ $product = wc_get_product($id);
1399
+ if (!$product) {
1400
+ return new WP_Error(
1401
+ 'woocommerce_product_csv_importer_invalid_id',
1402
+ /* translators: %d: product ID */ sprintf(__('Invalid product ID %d.', 'woocommerce'), $id), array(
1403
+ 'id' => $id,
1404
+ 'status' => 401,
1405
+ )
1406
+ );
1407
+ }
1408
+ } else {
1409
+ $product = wc_get_product_object('simple', $id);
1410
+ }
1411
+
1412
+ return apply_filters('wt_woocommerce_product_import_get_product_object', $product, $data);
1413
+ }
1414
+
1415
+ function set_variation_data(&$variation, $data) {
1416
+ $parent = false;
1417
+
1418
+ // Check if parent exist.
1419
+ if (isset($data['parent_id'])) {
1420
+ $parent = wc_get_product($data['parent_id']);
1421
+
1422
+ if ($parent) {
1423
+ $variation->set_parent_id($parent->get_id());
1424
+ }
1425
+ }
1426
+
1427
+ // Stop if parent does not exists.
1428
+ if (!$parent) {
1429
+ return new WP_Error('woocommerce_product_importer_missing_variation_parent_id', 'Variation cannot be imported: Missing parent ID or parent does not exist yet.', array('status' => 401));
1430
+ }
1431
+
1432
+ // Stop if parent is a product variation.
1433
+ if ($parent->is_type('variation')) {
1434
+ return new WP_Error('woocommerce_product_importer_parent_set_as_variation', 'Variation cannot be imported: Parent product cannot be a product variation', array('status' => 401));
1435
+ }
1436
+
1437
+ if (isset($data['raw_attributes'])) {
1438
+ $attributes = array();
1439
+ $parent_attributes = $this->get_variation_parent_attributes($data['raw_attributes'], $parent);
1440
+
1441
+ foreach ($data['raw_attributes'] as $attribute) {
1442
+ $attribute_id = 0;
1443
+
1444
+ // Get ID if is a global attribute.
1445
+ if (!empty($attribute['taxonomy'])) {
1446
+ $attribute_id = $this->get_attribute_taxonomy_id($attribute['name']);
1447
+ }
1448
+
1449
+ if ($attribute_id) {
1450
+ $attribute_name = wc_attribute_taxonomy_name_by_id($attribute_id);
1451
+ } else {
1452
+ $attribute_name = sanitize_title($attribute['name']);
1453
+ }
1454
+
1455
+ if (!isset($parent_attributes[$attribute_name]) || !$parent_attributes[$attribute_name]->get_variation()) {
1456
+ continue;
1457
+ }
1458
+
1459
+ $attribute_key = sanitize_title($parent_attributes[$attribute_name]->get_name());
1460
+ $attribute_value = isset($attribute['value']) ? current($attribute['value']) : '';
1461
+
1462
+ if ($parent_attributes[$attribute_name]->is_taxonomy()) {
1463
+ // If dealing with a taxonomy, we need to get the slug from the name posted to the API.
1464
+ $term = get_term_by('name', $attribute_value, $attribute_name);
1465
+
1466
+ if ($term && !is_wp_error($term)) {
1467
+ $attribute_value = $term->slug;
1468
+ } else {
1469
+ $attribute_value = sanitize_title($attribute_value);
1470
+ }
1471
+ }
1472
+
1473
+ $attributes[$attribute_key] = $attribute_value;
1474
+ }
1475
+ $variation->set_attributes($attributes);
1476
+ }
1477
+ }
1478
+
1479
+ function get_attribute_taxonomy_id($raw_name) {
1480
+ global $wpdb, $wc_product_attributes;
1481
+
1482
+ // These are exported as labels, so convert the label to a name if possible first.
1483
+ $attribute_labels = wp_list_pluck(wc_get_attribute_taxonomies(), 'attribute_label', 'attribute_name');
1484
+ $attribute_name = array_search($raw_name, $attribute_labels, true);
1485
+
1486
+ if (!$attribute_name) {
1487
+ $attribute_name = wc_sanitize_taxonomy_name($raw_name);
1488
+ }
1489
+
1490
+ $attribute_id = wc_attribute_taxonomy_id_by_name($attribute_name);
1491
+
1492
+ // Get the ID from the name.
1493
+ if ($attribute_id) {
1494
+ return $attribute_id;
1495
+ }
1496
+
1497
+ // If the attribute does not exist, create it.
1498
+ $attribute_id = wc_create_attribute(
1499
+ array(
1500
+ 'name' => $raw_name,
1501
+ 'slug' => $attribute_name,
1502
+ 'type' => 'select',
1503
+ 'order_by' => 'menu_order',
1504
+ 'has_archives' => false,
1505
+ )
1506
+ );
1507
+
1508
+ if (is_wp_error($attribute_id)) {
1509
+ throw new Exception($attribute_id->get_error_message(), 400);
1510
+ }
1511
+
1512
+ // Register as taxonomy while importing.
1513
+ $taxonomy_name = wc_attribute_taxonomy_name($attribute_name);
1514
+ register_taxonomy(
1515
+ $taxonomy_name, apply_filters('woocommerce_taxonomy_objects_' . $taxonomy_name, array('product')), apply_filters(
1516
+ 'woocommerce_taxonomy_args_' . $taxonomy_name, array(
1517
+ 'labels' => array(
1518
+ 'name' => $raw_name,
1519
+ ),
1520
+ 'hierarchical' => true,
1521
+ 'show_ui' => false,
1522
+ 'query_var' => true,
1523
+ 'rewrite' => false,
1524
+ )
1525
+ )
1526
+ );
1527
+
1528
+ // Set product attributes global.
1529
+ $wc_product_attributes = array();
1530
+
1531
+ foreach (wc_get_attribute_taxonomies() as $taxonomy) {
1532
+ $wc_product_attributes[wc_attribute_taxonomy_name($taxonomy->attribute_name)] = $taxonomy;
1533
+ }
1534
+
1535
+ return $attribute_id;
1536
+ }
1537
+
1538
+ function get_variation_parent_attributes($attributes, $parent) {
1539
+ $parent_attributes = $parent->get_attributes();
1540
+ $require_save = false;
1541
+
1542
+ foreach ($attributes as $attribute) {
1543
+ $attribute_id = 0;
1544
+
1545
+ // Get ID if is a global attribute.
1546
+ if (!empty($attribute['taxonomy'])) {
1547
+ $attribute_id = $this->get_attribute_taxonomy_id($attribute['name']);
1548
+ }
1549
+
1550
+ if ($attribute_id) {
1551
+ $attribute_name = wc_attribute_taxonomy_name_by_id($attribute_id);
1552
+ } else {
1553
+ $attribute_name = sanitize_title($attribute['name']);
1554
+ }
1555
+
1556
+ // Check if attribute handle variations.
1557
+ if (isset($parent_attributes[$attribute_name]) && !$parent_attributes[$attribute_name]->get_variation()) {
1558
+ // Re-create the attribute to CRUD save and generate again.
1559
+ $parent_attributes[$attribute_name] = clone $parent_attributes[$attribute_name];
1560
+ $parent_attributes[$attribute_name]->set_variation(1);
1561
+
1562
+ $require_save = true;
1563
+ }
1564
+ }
1565
+
1566
+ // Save variation attributes.
1567
+ if ($require_save) {
1568
+ $parent->set_attributes(array_values($parent_attributes));
1569
+ $parent->save();
1570
+ }
1571
+
1572
+ return $parent_attributes;
1573
+ }
1574
+
1575
+ function set_product_data(&$product, $data) {
1576
+ if (isset($data['raw_attributes'])) {
1577
+ $attributes = array();
1578
+ $default_attributes = array();
1579
+ $existing_attributes = $product->get_attributes();
1580
+
1581
+ foreach ($data['raw_attributes'] as $position => $attribute) {
1582
+ $attribute_id = 0;
1583
+
1584
+ // Get ID if is a global attribute.
1585
+ if (!empty($attribute['taxonomy'])) {
1586
+ $attribute_id = $this->get_attribute_taxonomy_id($attribute['name']);
1587
+ }
1588
+
1589
+ // Set attribute visibility.
1590
+ if (isset($attribute['visible'])) {
1591
+ $is_visible = $attribute['visible'];
1592
+ } else {
1593
+ $is_visible = 1;
1594
+ }
1595
+
1596
+ // Get name.
1597
+ $attribute_name = $attribute_id ? wc_attribute_taxonomy_name_by_id($attribute_id) : $attribute['name'];
1598
+
1599
+ // Set if is a variation attribute based on existing attributes if possible so updates via CSV do not change this.
1600
+ $is_variation = 0;
1601
+
1602
+ if ($existing_attributes) {
1603
+ foreach ($existing_attributes as $existing_attribute) {
1604
+ if (method_exists($existing_attribute,'get_name') && $existing_attribute->get_name() === $attribute_name) {
1605
+ $is_variation = $existing_attribute->get_variation();
1606
+ break;
1607
+ }
1608
+ }
1609
+ }
1610
+
1611
+ if ($attribute_id) {
1612
+ if (isset($attribute['value'])) {
1613
+ $options = array_map('wc_sanitize_term_text_based', $attribute['value']);
1614
+ $options = array_filter($options, 'strlen');
1615
+ } else {
1616
+ $options = array();
1617
+ }
1618
+
1619
+ // Check for default attributes and set "is_variation".
1620
+ if (!empty($attribute['default']) && in_array($attribute['default'], $options, true)) {
1621
+ $default_term = get_term_by('name', $attribute['default'], $attribute_name);
1622
+
1623
+ if ($default_term && !is_wp_error($default_term)) {
1624
+ $default = $default_term->slug;
1625
+ } else {
1626
+ $default = sanitize_title($attribute['default']);
1627
+ }
1628
+
1629
+ $default_attributes[$attribute_name] = $default;
1630
+ $is_variation = 1;
1631
+ }
1632
+
1633
+ if (!empty($options)) {
1634
+ $attribute_object = new WC_Product_Attribute();
1635
+ $attribute_object->set_id($attribute_id);
1636
+ $attribute_object->set_name($attribute_name);
1637
+ $attribute_object->set_options($options);
1638
+ $attribute_object->set_position($position);
1639
+ $attribute_object->set_visible($is_visible);
1640
+ $attribute_object->set_variation($is_variation);
1641
+ $attributes[] = $attribute_object;
1642
+ }
1643
+ } elseif (isset($attribute['value'])) {
1644
+ // Check for default attributes and set "is_variation".
1645
+ if (!empty($attribute['default']) && in_array($attribute['default'], $attribute['value'], true)) {
1646
+ $default_attributes[sanitize_title($attribute['name'])] = $attribute['default'];
1647
+ $is_variation = 1;
1648
+ }
1649
+
1650
+ $attribute_object = new WC_Product_Attribute();
1651
+ $attribute_object->set_name($attribute['name']);
1652
+ $attribute_object->set_options($attribute['value']);
1653
+ $attribute_object->set_position($position);
1654
+ $attribute_object->set_visible($is_visible);
1655
+ $attribute_object->set_variation($is_variation);
1656
+ $attributes[] = $attribute_object;
1657
+ }
1658
+ }
1659
+
1660
+ $product->set_attributes($attributes);
1661
+
1662
+ // Set variable default attributes.
1663
+ if ($product->is_type('variable')) {
1664
+ $product->set_default_attributes($default_attributes);
1665
+ }
1666
+ }
1667
+ }
1668
+
1669
+ function set_image_data(&$product, $data) {
1670
+ // Image URLs need converting to IDs before inserting.
1671
+ if (isset($data['raw_image'])) {
1672
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'Setting Featured Image. URL:'.$data['raw_image']['url']);
1673
+ $image_id = $this->get_attachment_id_from_url($data['raw_image']['url'], $product->get_id());
1674
+ if($image_id){
1675
+ $product->set_image_id($image_id);
1676
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'Attachment ID:'.$image_id);
1677
+ }
1678
+ }
1679
+
1680
+ // Gallery image URLs need converting to IDs before inserting.
1681
+ if (isset($data['raw_gallery_image'])) {
1682
+ $gallery_image_ids = array();
1683
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'Setting Gallery Images.');
1684
+ foreach ($data['raw_gallery_image'] as $image_id) {
1685
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'Image URL:'.$image_id['url']);
1686
+ $gallery_image_id = $this->get_attachment_id_from_url($image_id['url'], $product->get_id());
1687
+ if($gallery_image_id){
1688
+ $gallery_image_ids[] = $gallery_image_id;
1689
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'Attachment ID:'.$gallery_image_id);
1690
+ }
1691
+ }
1692
+ $product->set_gallery_image_ids(array_filter($gallery_image_ids));
1693
+ }
1694
+ }
1695
+
1696
+ function get_attachment_id_from_url($url, $product_id) {
1697
+ if (empty($url)) {
1698
+ return 0;
1699
+ }
1700
+
1701
+ $id = 0;
1702
+ $upload_dir = wp_upload_dir(null, false);
1703
+ $base_url = $upload_dir['baseurl'] . '/';
1704
+
1705
+ // Check first if attachment is inside the WordPress uploads directory, or we're given a filename only.
1706
+ if (false !== strpos($url, $base_url) || false === strpos($url, '://')) {
1707
+ // Search for yyyy/mm/slug.extension or slug.extension - remove the base URL.
1708
+ $file = str_replace($base_url, '', $url);
1709
+ $args = array(
1710
+ 'post_type' => 'attachment',
1711
+ 'post_status' => 'any',
1712
+ 'fields' => 'ids',
1713
+ 'meta_query' => array(// @codingStandardsIgnoreLine.
1714
+ 'relation' => 'OR',
1715
+ array(
1716
+ 'key' => '_wp_attached_file',
1717
+ 'value' => '^' . $file,
1718
+ 'compare' => 'REGEXP',
1719
+ ),
1720
+ array(
1721
+ 'key' => '_wp_attached_file',
1722
+ 'value' => '/' . $file,
1723
+ 'compare' => 'LIKE',
1724
+ ),
1725
+ array(
1726
+ 'key' => '_wt_attachment_source',
1727
+ 'value' => '/' . $file,
1728
+ 'compare' => 'LIKE',
1729
+ ),
1730
+ ),
1731
+ );
1732
+ } else {
1733
+ // This is an external URL, so compare to source.
1734
+ $args = array(
1735
+ 'post_type' => 'attachment',
1736
+ 'post_status' => 'any',
1737
+ 'fields' => 'ids',
1738
+ 'meta_query' => array(// @codingStandardsIgnoreLine.
1739
+ array(
1740
+ 'value' => $url,
1741
+ 'key' => '_wt_attachment_source',
1742
+ ),
1743
+ ),
1744
+ );
1745
+ }
1746
+
1747
+ $ids = get_posts($args); // @codingStandardsIgnoreLine.
1748
+
1749
+ if ($ids) {
1750
+ $id = current($ids);
1751
+ }
1752
+
1753
+ // Upload if attachment does not exists.
1754
+ if (!$id && stristr($url, '://')) {
1755
+ add_filter( 'https_ssl_verify', '__return_false' );
1756
+ $upload = wc_rest_upload_image_from_url($url);
1757
+ if (is_wp_error($upload)) {
1758
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', 'URL:'.$url.' Reason:'.$upload->get_error_message());
1759
+ return;
1760
+ //throw new Exception($upload->get_error_message(), 400);
1761
+ }
1762
+
1763
+ $id = wc_rest_set_uploaded_image_as_attachment($upload, $product_id);
1764
+
1765
+ if (!wp_attachment_is_image($id)) {
1766
+ /* translators: %s: image URL */
1767
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', sprintf(__('Not able to attach "%s".'), $url));
1768
+ return;
1769
+ // throw new Exception(sprintf(__('Not able to attach "%s".', 'woocommerce'), $url), 400);
1770
+ }
1771
+
1772
+ // Save attachment source for future reference.
1773
+ update_post_meta($id, '_wt_attachment_source', $url);
1774
+ }
1775
+
1776
+ if (!$id) {
1777
+ /* translators: %s: image URL */
1778
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->parent_module->module_base, 'import', sprintf(__('Unable to use image "%s".'), $url));
1779
+ return;
1780
+ // throw new Exception(sprintf(__('Unable to use image "%s".', 'woocommerce'), $url), 400);
1781
+ }
1782
+
1783
+ return $id;
1784
+ }
1785
+
1786
+ function set_meta_data(&$product, $data) {
1787
+ if (isset($data['meta_data'])) {
1788
+ foreach ($data['meta_data'] as $meta) {
1789
+ if(''== $meta)
1790
+ continue;
1791
+ $function = 'set_' . $meta[ 'key' ];
1792
+ $has_setter = is_callable( array( $product, $function ) );
1793
+ if ( $has_setter ) {
1794
+ $product->{$function}( $meta[ 'value' ] );
1795
+ continue;
1796
+ }
1797
+ $product->update_meta_data($meta['key'], $meta['value']);
1798
+ }
1799
+ }
1800
+ }
1801
+ }
1802
+ }
admin/modules/product/product.php ADDED
@@ -0,0 +1,814 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 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
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Product section of the plugin
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+
13
+ if(!class_exists('Wt_Import_Export_For_Woo_Basic_Product')){
14
+ class Wt_Import_Export_For_Woo_Basic_Product {
15
+
16
+ public $module_id = '';
17
+ public static $module_id_static = '';
18
+ public $module_base = 'product';
19
+ public $module_name = 'Product Import Export for WooCommerce';
20
+ public $min_base_version= '1.0.0'; /* Minimum `Import export plugin` required to run this add on plugin */
21
+
22
+ private $importer = null;
23
+ private $exporter = null;
24
+ private $product_categories = null;
25
+ private $product_tags = null;
26
+ private $product_taxonomies = array();
27
+ private $all_meta_keys = array();
28
+ private $product_attributes = array();
29
+ private $exclude_hidden_meta_columns = array();
30
+ private $found_product_meta = array();
31
+ private $found_product_hidden_meta = array();
32
+ private $selected_column_names = null;
33
+
34
+ public function __construct()
35
+ {
36
+ /**
37
+ * Checking the minimum required version of `Import export plugin` plugin available
38
+ */
39
+ if(!Wt_Import_Export_For_Woo_Basic_Common_Helper::check_base_version($this->module_base, $this->module_name, $this->min_base_version))
40
+ {
41
+ return;
42
+ }
43
+ if(!function_exists('is_plugin_active'))
44
+ {
45
+ include_once(ABSPATH.'wp-admin/includes/plugin.php');
46
+ }
47
+ if(!is_plugin_active('woocommerce/woocommerce.php'))
48
+ {
49
+ return;
50
+ }
51
+
52
+ $this->module_id = Wt_Import_Export_For_Woo_Basic::get_module_id($this->module_base);
53
+ self::$module_id_static = $this->module_id;
54
+
55
+ add_filter('wt_iew_exporter_post_types_basic', array($this, 'wt_iew_exporter_post_types_basic'), 10, 1);
56
+ add_filter('wt_iew_importer_post_types_basic', array($this, 'wt_iew_exporter_post_types_basic'), 10, 1);
57
+
58
+ add_filter('wt_iew_exporter_alter_filter_fields_basic', array($this, 'exporter_alter_filter_fields'), 10, 3);
59
+
60
+ add_filter('wt_iew_exporter_alter_mapping_fields_basic', array($this, 'exporter_alter_mapping_fields'), 10, 3);
61
+ add_filter('wt_iew_importer_alter_mapping_fields_basic', array($this, 'get_importer_post_columns'), 10, 3);
62
+
63
+ add_filter('wt_iew_exporter_alter_advanced_fields_basic', array($this, 'exporter_alter_advanced_fields'), 10, 3);
64
+ add_filter('wt_iew_importer_alter_advanced_fields_basic', array($this, 'importer_alter_advanced_fields'), 10, 3);
65
+
66
+ add_filter('wt_iew_exporter_alter_meta_mapping_fields_basic', array($this, 'exporter_alter_meta_mapping_fields'), 10, 3);
67
+ add_filter('wt_iew_importer_alter_meta_mapping_fields_basic', array($this, 'importer_alter_meta_mapping_fields'), 10, 3);
68
+
69
+ add_filter('wt_iew_exporter_alter_mapping_enabled_fields_basic', array($this, 'exporter_alter_mapping_enabled_fields'), 10, 3);
70
+ add_filter('wt_iew_importer_alter_mapping_enabled_fields_basic', array($this, 'exporter_alter_mapping_enabled_fields'), 10, 3);
71
+
72
+ add_filter('wt_iew_exporter_do_export_basic', array($this, 'exporter_do_export'), 10, 7);
73
+ add_filter('wt_iew_importer_do_import_basic', array($this, 'importer_do_import'), 10, 8);
74
+
75
+ add_filter('wt_iew_importer_steps_basic', array($this, 'importer_steps'), 10, 2);
76
+
77
+ }
78
+
79
+ /**
80
+ * Altering advanced step description
81
+ */
82
+ public function importer_steps($steps, $base)
83
+ {
84
+ if($this->module_base==$base)
85
+ {
86
+ $steps['advanced']['description']=__('Use advanced options from below to decide updates to existing products, batch import count. You can also save the template file for future imports.');
87
+ }
88
+ return $steps;
89
+ }
90
+
91
+ public function importer_do_import($import_data, $base, $step, $form_data, $selected_template_data, $method_import, $batch_offset, $is_last_batch) {
92
+ if ($this->module_base != $base) {
93
+ return $import_data;
94
+ }
95
+
96
+ if(0 == $batch_offset){
97
+ $memory = size_format(wt_let_to_num_basic(ini_get('memory_limit')));
98
+ $wp_memory = size_format(wt_let_to_num_basic(WP_MEMORY_LIMIT));
99
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->module_base, 'import', '---[ New import started at '.date('Y-m-d H:i:s').' ] PHP Memory: ' . $memory . ', WP Memory: ' . $wp_memory);
100
+ }
101
+
102
+ include plugin_dir_path(__FILE__) . 'import/import.php';
103
+ $import = new Wt_Import_Export_For_Woo_Basic_Product_Import($this);
104
+
105
+ $response = $import->prepare_data_to_import($import_data,$form_data,$batch_offset,$is_last_batch);
106
+
107
+ if($is_last_batch){
108
+ Wt_Import_Export_For_Woo_Basic_Logwriter::write_log($this->module_base, 'import', '---[ Import ended at '.date('Y-m-d H:i:s').']---');
109
+ }
110
+ return $response;
111
+ }
112
+
113
+ public function exporter_do_export($export_data, $base, $step, $form_data, $selected_template_data, $method_export, $batch_offset) {
114
+ if ($this->module_base != $base) {
115
+ return $export_data;
116
+ }
117
+
118
+ switch ($method_export) {
119
+ case 'quick':
120
+ $this->set_export_columns_for_quick_export($form_data);
121
+ break;
122
+
123
+ case 'template':
124
+ case 'new':
125
+ $this->set_selected_column_names($form_data);
126
+ break;
127
+
128
+ default:
129
+ break;
130
+ }
131
+
132
+ include plugin_dir_path(__FILE__) . 'export/export.php';
133
+ $export = new Wt_Import_Export_For_Woo_Basic_Product_Export($this);
134
+
135
+ $header_row = $export->prepare_header();
136
+
137
+ $data_row = $export->prepare_data_to_export($form_data, $batch_offset,$step);
138
+
139
+
140
+ $export_data = array(
141
+ 'head_data' => $header_row,
142
+ 'body_data' => $data_row['data'],
143
+ 'total' => $data_row['total'],
144
+ );
145
+
146
+
147
+ return $export_data;
148
+ }
149
+
150
+ /**
151
+ * Adding current post type to export list
152
+ *
153
+ */
154
+ public function wt_iew_exporter_post_types_basic($arr) {
155
+ $arr['product'] = __('Product');
156
+ return $arr;
157
+ }
158
+
159
+ /**
160
+ * Add/Remove steps in export section.
161
+ * @param array $steps array of built in steps
162
+ * @param string $base product, order etc
163
+ * @return array $steps
164
+ */
165
+ public function wt_iew_exporter_steps($steps, $base) {
166
+ if ($base == $this->module_base) {
167
+ foreach ($steps as $stepk => $stepv) {
168
+ $out[$stepk] = $stepv;
169
+ if ($stepk == 'filter') {
170
+ /*
171
+ $out['product']=array(
172
+ 'title'=>'Product',
173
+ 'description'=>'',
174
+ );
175
+ */
176
+ }
177
+ }
178
+ } else {
179
+ $out = $steps;
180
+ }
181
+ return $out;
182
+ }
183
+
184
+
185
+ /*
186
+ * Setting default export columns for quick export
187
+ */
188
+
189
+ public function set_export_columns_for_quick_export($form_data) {
190
+
191
+ $post_columns = self::get_product_post_columns();
192
+
193
+ $this->selected_column_names = array_combine(array_keys($post_columns), array_keys($post_columns));
194
+
195
+ if (isset($form_data['method_export_form_data']['mapping_enabled_fields']) && !empty($form_data['method_export_form_data']['mapping_enabled_fields'])) {
196
+ foreach ($form_data['method_export_form_data']['mapping_enabled_fields'] as $value) {
197
+ $additional_quick_export_fields[$value] = array('fields' => array());
198
+ }
199
+
200
+ $export_additional_columns = $this->exporter_alter_meta_mapping_fields($additional_quick_export_fields, $this->module_base, array());
201
+ foreach ($export_additional_columns as $value) {
202
+ $this->selected_column_names = array_merge($this->selected_column_names, $value['fields']);
203
+ }
204
+ }
205
+ }
206
+
207
+
208
+ /**
209
+ * Get product categories
210
+ * @return array $categories
211
+ */
212
+ private function get_product_categories() {
213
+ if (!is_null($this->product_categories)) {
214
+ return $this->product_categories;
215
+ }
216
+ $out = array();
217
+ $product_categories = get_terms('product_cat');
218
+ if (!is_wp_error($product_categories)) {
219
+ $version = get_bloginfo('version');
220
+ foreach ($product_categories as $category) {
221
+ $out[$category->slug] = (( $version < '4.8') ? $category->name : get_term_parents_list($category->term_id, 'product_cat', array('separator' => ' -> ')));
222
+ }
223
+ }
224
+ $this->product_categories = $out;
225
+ return $out;
226
+ }
227
+
228
+ private function get_product_tags() {
229
+ if (!is_null($this->product_tags)) {
230
+ return $this->product_tags;
231
+ }
232
+ $out = array();
233
+ $product_tags = get_terms('product_tag');
234
+ if (!is_wp_error($product_tags)) {
235
+ foreach ($product_tags as $tag) {
236
+ $out[$tag->slug] = $tag->name;
237
+ }
238
+ }
239
+ $this->product_tags = $out;
240
+ return $out;
241
+ }
242
+
243
+ public static function get_product_types() {
244
+ // return include plugin_dir_path(__FILE__) . 'data/data-allowed-product-types.php';
245
+
246
+ $product_types = array();
247
+ foreach ( wc_get_product_types() as $value => $label ) {
248
+ $product_types[esc_attr( $value )] = esc_html( $label );
249
+ }
250
+
251
+ return array_merge($product_types, array('variation' => 'Product variations'));
252
+ }
253
+
254
+ public static function get_product_statuses() {
255
+ $product_statuses = array('publish', 'private', 'draft', 'pending', 'future');
256
+ return apply_filters('wt_iew_allowed_product_statuses', array_combine($product_statuses, $product_statuses));
257
+ }
258
+
259
+ public static function get_product_sort_columns() {
260
+ // $sort_columns = array('post_parent', 'ID', 'post_author', 'post_date', 'post_title', 'post_name', 'post_modified', 'menu_order', 'post_modified_gmt', 'rand', 'comment_count');
261
+ $sort_columns = array('ID'=>'ID', 'name'=>'post_title', 'type'=>'Product Type', 'date'=>'post_date', 'modified'=>'post_modified');
262
+ return apply_filters('wt_iew_allowed_product_sort_columns', $sort_columns);
263
+ }
264
+
265
+ public static function get_product_post_columns() {
266
+ return include plugin_dir_path(__FILE__) . 'data/data-product-post-columns.php';
267
+ }
268
+
269
+ public function get_importer_post_columns($fields, $base, $step_page_form_data) {
270
+ if ($base != $this->module_base) {
271
+ return $fields;
272
+ }
273
+ $colunm = include plugin_dir_path(__FILE__) . 'data/data/data-wf-reserved-fields-pair.php';
274
+ // $colunm = array_map(function($vl){ return array('title'=>$vl, 'description'=>$vl); }, $arr);
275
+ return $colunm;
276
+ }
277
+
278
+ public function exporter_alter_mapping_enabled_fields($mapping_enabled_fields, $base, $form_data_mapping_enabled_fields) {
279
+ if ($base == $this->module_base) {
280
+ $mapping_enabled_fields = array();
281
+ $mapping_enabled_fields['taxonomies'] = array(__('Taxonomies (cat/tags/shipping-class)'), 1);
282
+
283
+ $mapping_enabled_fields['attributes'] = array(__('Attributes'), 1);
284
+
285
+ }
286
+ return $mapping_enabled_fields;
287
+ }
288
+
289
+
290
+ public function exporter_alter_meta_mapping_fields($fields, $base, $step_page_form_data) {
291
+ if ($base != $this->module_base) {
292
+ return $fields;
293
+ }
294
+
295
+ foreach ($fields as $key => $value) {
296
+ switch ($key) {
297
+ case 'taxonomies':
298
+ $product_taxonomies = $this->wt_get_product_taxonomies();
299
+ foreach ($product_taxonomies as $taxonomy) {
300
+ if (strstr($taxonomy->name, 'pa_'))
301
+ continue; // Skip attributes
302
+ $fields[$key]['fields']['tax:' . $taxonomy->name] = 'tax:' . $taxonomy->name;
303
+ }
304
+ break;
305
+
306
+
307
+
308
+ case 'attributes':
309
+ $found_attributes = $this->wt_get_product_attributes();
310
+
311
+ if(!empty($meta_attributes)){ // adding meta attributes
312
+ foreach ($meta_attributes as $attribute_value) {
313
+ $fields[$key]['fields']['meta:' . $attribute_value] = 'meta:' . $attribute_value;
314
+ }
315
+ }
316
+
317
+ foreach ($found_attributes as $attribute) {
318
+ $fields[$key]['fields']['attribute:' . $attribute] = 'attribute:' . $attribute;
319
+ $fields[$key]['fields']['attribute_data:' . $attribute] = 'attribute_data:' . $attribute;
320
+ $fields[$key]['fields']['attribute_default:' . $attribute] = 'attribute_default:' . $attribute;
321
+ }
322
+
323
+ break;
324
+
325
+
326
+ default:
327
+ break;
328
+ }
329
+ }
330
+
331
+ return $fields;
332
+ }
333
+
334
+ public function importer_alter_meta_mapping_fields($fields, $base, $step_page_form_data) {
335
+ if ($base != $this->module_base) {
336
+ return $fields;
337
+ }
338
+
339
+ $fields=$this->exporter_alter_meta_mapping_fields($fields, $base, $step_page_form_data);
340
+ $out=array();
341
+ foreach ($fields as $key => $value)
342
+ {
343
+ $value['fields']=array_map(function($vl){ return array('title'=>$vl, 'description'=>$vl); }, $value['fields']);
344
+ $out[$key]=$value;
345
+ }
346
+ return $out;
347
+ }
348
+
349
+ public function wt_get_product_taxonomies() {
350
+
351
+ if (!empty($this->product_taxonomies)) {
352
+ return $this->product_taxonomies;
353
+ }
354
+ $product_ptaxonomies = get_object_taxonomies('product', 'name');
355
+ $product_vtaxonomies = get_object_taxonomies('product_variation', 'name');
356
+ $product_taxonomies = array_merge($product_ptaxonomies, $product_vtaxonomies);
357
+
358
+ $this->product_taxonomies = $product_taxonomies;
359
+ return $this->product_taxonomies;
360
+ }
361
+
362
+ public function wt_get_found_product_meta() {
363
+
364
+ if (!empty($this->found_product_meta)) {
365
+ return $this->found_product_meta;
366
+ }
367
+
368
+ // Loop products and load meta data
369
+ $found_product_meta = array();
370
+ // Some of the values may not be usable (e.g. arrays of arrays) but the worse
371
+ // that can happen is we get an empty column.
372
+
373
+ $all_meta_keys = $this->wt_get_all_meta_keys();
374
+ $csv_columns = self::get_product_post_columns();
375
+ $exclude_hidden_meta_columns = $this->wt_get_exclude_hidden_meta_columns();
376
+ foreach ($all_meta_keys as $meta) {
377
+
378
+ if (!$meta || (substr((string) $meta, 0, 1) == '_') || in_array($meta, $exclude_hidden_meta_columns) || in_array($meta, array_keys($csv_columns)) || in_array('meta:' . $meta, array_keys($csv_columns)))
379
+ continue;
380
+
381
+ $found_product_meta[] = $meta;
382
+ }
383
+
384
+ $found_product_meta = array_diff($found_product_meta, array_keys($csv_columns));
385
+
386
+ $this->found_product_meta = $found_product_meta;
387
+ return $this->found_product_meta;
388
+ }
389
+
390
+ public function wt_get_found_product_hidden_meta() {
391
+
392
+ if (!empty($this->found_product_hidden_meta)) {
393
+ return $this->found_product_hidden_meta;
394
+ }
395
+
396
+ // Loop products and load meta data
397
+ $found_product_meta = array();
398
+ // Some of the values may not be usable (e.g. arrays of arrays) but the worse
399
+ // that can happen is we get an empty column.
400
+
401
+ $all_meta_keys = $this->wt_get_all_meta_keys();
402
+ $csv_columns = self::get_product_post_columns();//$this->get_selected_column_names();
403
+ $exclude_hidden_meta_columns = $this->wt_get_exclude_hidden_meta_columns();
404
+ foreach ($all_meta_keys as $meta) {
405
+
406
+ if (!$meta || (substr((string) $meta, 0, 1) != '_') || in_array($meta, $exclude_hidden_meta_columns) || in_array($meta, array_keys($csv_columns)) || in_array('meta:' . $meta, array_keys($csv_columns)))
407
+ continue;
408
+
409
+ $found_product_meta[] = $meta;
410
+ }
411
+
412
+ $found_product_meta = array_diff($found_product_meta, array_keys($csv_columns));
413
+
414
+ $this->found_product_hidden_meta = $found_product_meta;
415
+ return $this->found_product_hidden_meta;
416
+ }
417
+
418
+ public function wt_get_exclude_hidden_meta_columns() {
419
+
420
+ if (!empty($this->exclude_hidden_meta_columns)) {
421
+ return $this->exclude_hidden_meta_columns;
422
+ }
423
+
424
+ $exclude_hidden_meta_columns = include( plugin_dir_path(__FILE__) . 'data/data-wf-hidden-meta-columns.php' );
425
+
426
+ $this->exclude_hidden_meta_columns = $exclude_hidden_meta_columns;
427
+ return $this->exclude_hidden_meta_columns;
428
+ }
429
+
430
+ public function wt_get_all_meta_keys() {
431
+
432
+ if (!empty($this->all_meta_keys)) {
433
+ return $this->all_meta_keys;
434
+ }
435
+
436
+ $all_meta_pkeys = self::get_all_metakeys('product');
437
+ $all_meta_vkeys = self::get_all_metakeys('product_variation');
438
+ $all_meta_keys = array_merge($all_meta_pkeys, $all_meta_vkeys);
439
+ $all_meta_keys = array_unique($all_meta_keys);
440
+
441
+ $this->all_meta_keys = $all_meta_keys;
442
+ return $this->all_meta_keys;
443
+ }
444
+
445
+ /**
446
+ * Get a list of all the meta keys for a post type. This includes all public, private,
447
+ * used, no-longer used etc. They will be sorted once fetched.
448
+ */
449
+ public static function get_all_metakeys($post_type = 'product') {
450
+ global $wpdb;
451
+
452
+ $meta = $wpdb->get_col($wpdb->prepare(
453
+ "SELECT DISTINCT pm.meta_key
454
+ FROM {$wpdb->postmeta} AS pm
455
+ LEFT JOIN {$wpdb->posts} AS p ON p.ID = pm.post_id
456
+ WHERE p.post_type = %s
457
+ AND p.post_status IN ( 'publish', 'private', 'draft', 'pending', 'future' )", $post_type
458
+ ));
459
+
460
+ sort($meta);
461
+
462
+ return $meta;
463
+ }
464
+
465
+ public function set_selected_column_names($full_form_data) {
466
+ if (is_null($this->selected_column_names)) {
467
+ if (isset($full_form_data['mapping_form_data']['mapping_selected_fields']) && !empty($full_form_data['mapping_form_data']['mapping_selected_fields'])) {
468
+ $this->selected_column_names = $full_form_data['mapping_form_data']['mapping_selected_fields'];
469
+ }
470
+ if (isset($full_form_data['meta_step_form_data']['mapping_selected_fields']) && !empty($full_form_data['meta_step_form_data']['mapping_selected_fields'])) {
471
+ $export_additional_columns = $full_form_data['meta_step_form_data']['mapping_selected_fields'];
472
+ foreach ($export_additional_columns as $value) {
473
+ $this->selected_column_names = array_merge($this->selected_column_names, $value);
474
+ }
475
+ }
476
+ }
477
+
478
+ return $full_form_data;
479
+ }
480
+
481
+ public function get_selected_column_names() {
482
+
483
+ return $this->selected_column_names;
484
+ }
485
+
486
+ public function wt_get_product_attributes() {
487
+ if (!empty($this->product_attributes)) {
488
+ return $this->product_attributes;
489
+ }
490
+ $found_pattributes = self::get_all_product_attributes('product');
491
+ $found_vattributes = self::get_all_product_attributes('product_variation');
492
+ $found_attributes = array_merge($found_pattributes, $found_vattributes);
493
+ $found_attributes = array_unique($found_attributes);
494
+
495
+ $this->product_attributes = $found_attributes;
496
+ return $this->product_attributes;
497
+ }
498
+
499
+ /**
500
+ * Get a list of all the product attributes for a post type.
501
+ * These require a bit more digging into the values.
502
+ */
503
+ public static function get_all_product_attributes($post_type = 'product') {
504
+
505
+ global $wpdb;
506
+
507
+ $results = $wpdb->get_col($wpdb->prepare(
508
+ "SELECT DISTINCT pm.meta_value
509
+ FROM {$wpdb->postmeta} AS pm
510
+ LEFT JOIN {$wpdb->posts} AS p ON p.ID = pm.post_id
511
+ WHERE p.post_type = %s
512
+ AND p.post_status IN ( 'publish', 'pending', 'private', 'draft' )
513
+ AND pm.meta_key = '_product_attributes'", $post_type
514
+ ));
515
+
516
+ // Go through each result, and look at the attribute keys within them.
517
+ $result = array();
518
+
519
+ if (!empty($results)) {
520
+ foreach ($results as $_product_attributes) {
521
+ $attributes = maybe_unserialize(maybe_unserialize($_product_attributes));
522
+ if (!empty($attributes) && is_array($attributes)) {
523
+ foreach ($attributes as $key => $attribute) {
524
+ if (!$key) {
525
+ continue;
526
+ }
527
+ if (!strstr($key, 'pa_')) {
528
+ if (empty($attribute['name'])) {
529
+ continue;
530
+ }
531
+ $key = $attribute['name'];
532
+ }
533
+
534
+ $result[$key] = $key;
535
+ }
536
+ }
537
+ }
538
+ }
539
+
540
+ sort($result);
541
+
542
+ return $result;
543
+ }
544
+
545
+ public function exporter_alter_mapping_fields($fields, $base, $mapping_form_data) {
546
+ if ($base == $this->module_base) {
547
+ $fields = self::get_product_post_columns();
548
+ }
549
+ return $fields;
550
+ }
551
+
552
+ public function exporter_alter_advanced_fields($fields, $base, $advanced_form_data) {
553
+ if ($this->module_base != $base) {
554
+ return $fields;
555
+ }
556
+ $out = array();
557
+
558
+ foreach ($fields as $fieldk => $fieldv) {
559
+ $out[$fieldk] = $fieldv;
560
+ }
561
+
562
+
563
+
564
+ return $out;
565
+ }
566
+
567
+ public function importer_alter_advanced_fields($fields, $base, $advanced_form_data) {
568
+ if ($this->module_base != $base) {
569
+ return $fields;
570
+ }
571
+ $out = array();
572
+
573
+ $out['skip_new'] = array(
574
+ 'label' => __("Update only"),
575
+ 'type' => 'radio',
576
+ 'radio_fields' => array(
577
+ '1' => __('Yes'),
578
+ '0' => __('No')
579
+ ),
580
+ 'value' => '0',
581
+ 'field_name' => 'skip_new',
582
+ 'help_text_conditional'=>array(
583
+ array(
584
+ 'help_text'=> __('The store is updated with the data from the input file only for matching/existing records from the file.'),
585
+ 'condition'=>array(
586
+ array('field'=>'wt_iew_skip_new', 'value'=>1)
587
+ )
588
+ ),
589
+ array(
590
+ 'help_text'=> __('The entire data from the input file is processed for an update or insert as the case maybe.'),
591
+ 'condition'=>array(
592
+ array('field'=>'wt_iew_skip_new', 'value'=>0)
593
+ )
594
+ )
595
+ ),
596
+ 'form_toggler'=>array(
597
+ 'type'=>'parent',
598
+ 'target'=>'wt_iew_skip_new',
599
+ )
600
+ );
601
+
602
+ $out['merge_with'] = array(
603
+ 'label' => __("Match products by their"),
604
+ 'type' => 'radio',
605
+ 'radio_fields' => array(
606
+ 'id' => __('ID'),
607
+ 'sku' => __('SKU'),
608
+ ),
609
+ 'value' => 'id',
610
+ 'field_name' => 'merge_with',
611
+ 'help_text' => __('The products are either looked up based on their ID or SKU as per the selection.'),
612
+ 'help_text_conditional'=>array(
613
+ array(
614
+ 'help_text'=> __('If the post ID of the product being imported exists already(for any of the other post types like coupon, order, user, pages, media etc) skip the product from being updated into the store.'),
615
+ 'condition'=>array(
616
+ array('field'=>'wt_iew_merge_with', 'value'=>'id'),
617
+ 'AND',
618
+ array('field'=>'wt_iew_skip_new', 'value'=>1)
619
+ )
620
+ )
621
+ )
622
+ );
623
+
624
+ $out['found_action_merge'] = array(
625
+ 'label' => __("If product exists in the store"),
626
+ 'type' => 'radio',
627
+ 'radio_fields' => array(
628
+ 'skip' => __('Skip'),
629
+ 'update' => __('Update'),
630
+ ),
631
+ 'value' => 'skip',
632
+ 'field_name' => 'found_action',
633
+ 'help_text_conditional'=>array(
634
+ array(
635
+ 'help_text'=> __('Retains the product in the store as is and skips the matching product from the input file.'),
636
+ 'condition'=>array(
637
+ array('field'=>'wt_iew_found_action', 'value'=>'skip')
638
+ )
639
+ ),
640
+ array(
641
+ 'help_text'=> __('Update product as per data from the input file'),
642
+ 'condition'=>array(
643
+ array('field'=>'wt_iew_found_action', 'value'=>'update')
644
+ )
645
+ )
646
+ ),
647
+ 'form_toggler'=>array(
648
+ 'type'=>'parent',
649
+ 'target'=>'wt_iew_found_action'
650
+ )
651
+ );
652
+
653
+ $out['merge_empty_cells'] = array(
654
+ 'label' => __("Update even if empty values"),
655
+ 'type' => 'radio',
656
+ 'radio_fields' => array(
657
+ '1' => __('Yes'),
658
+ '0' => __('No')
659
+ ),
660
+ 'value' => '0',
661
+ 'field_name' => 'merge_empty_cells',
662
+ 'help_text' => __('Updates the product data respectively even if some of the columns in the input file contains empty value.'),
663
+ 'form_toggler'=>array(
664
+ 'type'=>'child',
665
+ 'id'=>'wt_iew_found_action',
666
+ 'val'=>'update',
667
+ )
668
+ );
669
+
670
+
671
+
672
+ foreach ($fields as $fieldk => $fieldv) {
673
+ $out[$fieldk] = $fieldv;
674
+ }
675
+ return $out;
676
+ }
677
+
678
+ /**
679
+ * Customize the items in filter export page
680
+ */
681
+ public function exporter_alter_filter_fields($fields, $base, $filter_form_data) {
682
+ if ($this->module_base != $base) {
683
+ return $fields;
684
+ }
685
+
686
+ /* altering help text of default fields */
687
+ $fields['limit']['label']=__('Total number of products to export');
688
+ $fields['limit']['help_text']=__('Exports specified number of products. e.g. Entering 500 with a skip count of 10 will export products from 11th to 510th position.');
689
+ $fields['offset']['label']=__('Skip first <i>n</i> orders');
690
+ $fields['offset']['help_text']=__('Skips specified number of products from the beginning. e.g. Enter 10 to skip first 10 products from export.');
691
+
692
+
693
+ $fields['product'] = array(
694
+ 'label' => __('Products', 'wt-import-export-for-woo'),
695
+ 'placeholder' => __('All products', 'wt-import-export-for-woo'),
696
+ 'field_name' => 'product',
697
+ 'sele_vals' => array(),
698
+ 'help_text' => __('Export specific products. Keyin the product names to export to export multiple products.', 'wt-import-export-for-woo'),
699
+ 'type' => 'multi_select',
700
+ 'css_class' => 'wc-product-search',
701
+ 'validation_rule' => array('type'=>'text_arr')
702
+ );
703
+
704
+ $fields['exclude_product'] = array(
705
+ 'label' => __('Exclude products', 'wt-import-export-for-woo'),
706
+ 'placeholder' => __('Exclude products', 'wt-import-export-for-woo'),
707
+ 'field_name' => 'exclude_product',
708
+ 'sele_vals' => array(),
709
+ 'help_text' => __('Use this if you need to exclude a specific or multiple products from your export list.', 'wt-import-export-for-woo'),
710
+ 'type' => 'multi_select',
711
+ 'css_class' => 'wc-product-search',
712
+ 'validation_rule' => array('type'=>'text_arr')
713
+ );
714
+
715
+ $fields['product_categories'] = array(
716
+ 'label' => __('Product categories', 'wt-import-export-for-woo'),
717
+ 'placeholder' => __('Any category', 'wt-import-export-for-woo'),
718
+ 'field_name' => 'product_categories',
719
+ 'sele_vals' => $this->get_product_categories(),
720
+ 'help_text' => __('Export products belonging to a particular or from multiple categories. Just select the respective categories.', 'wt-import-export-for-woo'),
721
+ 'type' => 'multi_select',
722
+ 'css_class' => 'wc-enhanced-select',
723
+ 'validation_rule' => array('type'=>'text_arr')
724
+ );
725
+
726
+ $fields['product_tags'] = array(
727
+ 'label' => __('Product tags', 'wt-import-export-for-woo'),
728
+ 'placeholder' => __('Any tag', 'wt-import-export-for-woo'),
729
+ 'field_name' => 'product_tags',
730
+ 'sele_vals' => $this->get_product_tags(),
731
+ 'help_text' => __('Enter the product tags to export only the respective products that have been tagged accordingly.', 'wt-import-export-for-woo'),
732
+ 'type' => 'multi_select',
733
+ 'css_class' => 'wc-enhanced-select',
734
+ 'validation_rule' => array('type'=>'text_arr')
735
+ );
736
+
737
+ $fields['product_status'] = array(
738
+ 'label' => __('Product status', 'wt-import-export-for-woo'),
739
+ 'placeholder' => __('Any status', 'wt-import-export-for-woo'),
740
+ 'field_name' => 'product_status',
741
+ 'sele_vals' => self::get_product_statuses(),
742
+ 'help_text' => __('Filter products by their status.', 'wt-import-export-for-woo'),
743
+ 'type' => 'multi_select',
744
+ 'css_class' => 'wc-enhanced-select',
745
+ 'validation_rule' => array('type'=>'text_arr')
746
+ );
747
+
748
+
749
+
750
+ return $fields;
751
+ }
752
+
753
+ /**
754
+ * Get File name by url
755
+ * @param string $file_url URL of the file.
756
+ * @return string the base name of the given URL (File name).
757
+ */
758
+ public static function xa_wc_get_filename_from_url($file_url) {
759
+ $parts = parse_url($file_url);
760
+ if (isset($parts['path'])) {
761
+ return basename($parts['path']);
762
+ }
763
+ }
764
+
765
+ /**
766
+ * Get info like language code, parent product ID etc by product id.
767
+ * @param int Product ID.
768
+ * @return array/false.
769
+ */
770
+ public static function wt_get_wpml_original_post_language_info($element_id) {
771
+ $get_language_args = array('element_id' => $element_id, 'element_type' => 'post_product');
772
+ $original_post_language_info = apply_filters('wpml_element_language_details', null, $get_language_args);
773
+ return $original_post_language_info;
774
+ }
775
+
776
+ public static function wt_get_product_id_by_sku($sku) {
777
+ global $wpdb;
778
+ $post_exists_sku = $wpdb->get_var($wpdb->prepare("
779
+ SELECT $wpdb->posts.ID
780
+ FROM $wpdb->posts
781
+ LEFT JOIN $wpdb->postmeta ON ( $wpdb->posts.ID = $wpdb->postmeta.post_id )
782
+ WHERE $wpdb->posts.post_status IN ( 'publish', 'private', 'draft', 'pending', 'future' )
783
+ AND $wpdb->postmeta.meta_key = '_sku' AND $wpdb->postmeta.meta_value = '%s'
784
+ ", $sku));
785
+ if ($post_exists_sku) {
786
+ return $post_exists_sku;
787
+ }
788
+ return false;
789
+ }
790
+
791
+ /**
792
+ * To strip the specific string from the array key as well as value.
793
+ * @param array $array.
794
+ * @param string $data.
795
+ * @return array.
796
+ */
797
+ public static function wt_array_walk($array, $data) {
798
+ $new_array = array();
799
+ foreach ($array as $key => $value) {
800
+ $new_array[str_replace($data, '', $key)] = str_replace($data, '', $value);
801
+ }
802
+ return $new_array;
803
+ }
804
+
805
+ public function get_item_by_id($id) {
806
+ $post['edit_url']=get_edit_post_link($id);
807
+ $post['title'] = get_the_title($id);
808
+ return $post;
809
+ }
810
+
811
+ }
812
+ }
813
+
814
+ new Wt_Import_Export_For_Woo_Basic_Product();
admin/partials/_form_field_generator.php ADDED
@@ -0,0 +1,378 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ foreach($form_fields as $key=>$value)
6
+ {
7
+ /* setting default value form fields list array */
8
+ $vl=(isset($value['value']) ? $value['value'] : '');
9
+ $vl=($vl=='' && isset($value['default_value']) ? $value['default_value'] : $vl);
10
+
11
+ $type=(isset($value['type']) ? $value['type'] : 'text');
12
+ $css_class=(isset($value['css_class']) ? $value['css_class'] : '');
13
+ $html_id=(isset($value['html_id']) ? ' id="'.$value['html_id'].'" ' : '');
14
+ $tr_id=(isset($value['tr_id']) ? ' id="'.$value['tr_id'].'" ' : '');
15
+ $tr_class=(isset($value['tr_class']) ? $value['tr_class'] : '');
16
+ $td_class1=(isset($value['td_class1']) ? $value['td_class1'] : '');
17
+ $td_class2=(isset($value['td_class2']) ? $value['td_class2'] : '');
18
+ $td_class3=(isset($value['td_class3']) ? $value['td_class3'] : '');
19
+
20
+ $tr_html=(isset($value['tr_html']) ? $value['tr_html'] : '');
21
+ $field_html=(isset($value['field_html']) ? $value['field_html'] : '');
22
+ $help_text=(isset($value['help_text']) ? $value['help_text'] : '');
23
+ $placeholder=(isset($value['placeholder']) ? $value['placeholder'] : '');
24
+ $attr_arr=(isset($value['attr']) ? $value['attr'] : array());
25
+ $after_form_field_html=(isset($value['after_form_field_html']) ? $value['after_form_field_html'] : ''); /* after form field `td` */
26
+ $after_form_field=(isset($value['after_form_field']) ? $value['after_form_field'] : ''); /* after form field */
27
+ $before_form_field=(isset($value['before_form_field']) ? $value['before_form_field'] : '');
28
+ $merge_left=(isset($value['merge_left']) ? $value['merge_left'] : false); /* merge field td with left td */
29
+ $merge_right=(isset($value['merge_right']) ? $value['merge_right'] : false); /* merge field td with right td */
30
+ $colspan=1;
31
+ if($merge_left)
32
+ {
33
+ $colspan++;
34
+ }
35
+ if($merge_right)
36
+ {
37
+ $colspan++;
38
+ }
39
+ $colspan_attr='';
40
+ if($colspan>1)
41
+ {
42
+ $colspan_attr=' colspan="'.$colspan.'"';
43
+ }
44
+
45
+ /**
46
+ * conditional help texts
47
+ * !!Important: Using OR mixed with AND then add OR conditions first.
48
+ */
49
+ $conditional_help_html='';
50
+ if(isset($value['help_text_conditional']) && is_array($value['help_text_conditional']))
51
+ {
52
+ foreach ($value['help_text_conditional'] as $help_text_config)
53
+ {
54
+ if(is_array($help_text_config))
55
+ {
56
+ $condition_attr='';
57
+ if(is_array($help_text_config['condition']))
58
+ {
59
+ $previous_type=''; /* this for avoiding fields without glue */
60
+ foreach ($help_text_config['condition'] as $condition)
61
+ {
62
+ if(is_array($condition))
63
+ {
64
+ if($previous_type!='field')
65
+ {
66
+ $condition_attr.='['.$condition['field'].'='.$condition['value'].']';
67
+ $previous_type='field';
68
+ }
69
+ }else
70
+ {
71
+ if(is_string($condition))
72
+ {
73
+ $condition=strtoupper($condition);
74
+ if(($condition=='AND' || $condition=='OR') && $previous_type!='glue')
75
+ {
76
+ $condition_attr.='['.$condition.']';
77
+ $previous_type='glue';
78
+ }
79
+ }
80
+ }
81
+ }
82
+ }
83
+ $conditional_help_html.='<span class="wt-iew_form_help wt-iew_conditional_help_text" data-iew-help-condition="'.esc_attr($condition_attr).'">'.$help_text_config['help_text'].'</span>';
84
+ }
85
+ }
86
+ }
87
+
88
+ $form_toggler_p_class="";
89
+ $form_toggler_register="";
90
+ $form_toggler_child="";
91
+ if(isset($value['form_toggler']))
92
+ {
93
+ if($value['form_toggler']['type']=='parent')
94
+ {
95
+ $form_toggler_p_class="wt_iew_form_toggler";
96
+ $form_toggler_register=' wf_frm_tgl-target="'.$value['form_toggler']['target'].'"';
97
+ }
98
+ elseif($value['form_toggler']['type']=='child')
99
+ {
100
+ $form_toggler_child=' wf_frm_tgl-id="'.$value['form_toggler']['id'].'" wf_frm_tgl-val="'.$value['form_toggler']['val'].'" '.(isset($value['form_toggler']['chk']) ? 'wf_frm_tgl-chk="'.$value['form_toggler']['chk'].'"' : '').(isset($value['form_toggler']['depth']) ? ' wf_frm_tgl-lvl="'.$value['form_toggler']['depth'].'"' : '');
101
+ }else
102
+ {
103
+ $form_toggler_child=' wf_frm_tgl-id="'.$value['form_toggler']['id'].'" wf_frm_tgl-val="'.$value['form_toggler']['val'].'" '.(isset($value['form_toggler']['chk']) ? 'wf_frm_tgl-chk="'.$value['form_toggler']['chk'].'"' : '').(isset($value['form_toggler']['depth']) ? ' wf_frm_tgl-lvl="'.$value['form_toggler']['depth'].'"' : '');
104
+ $form_toggler_p_class="wt_iew_form_toggler";
105
+ $form_toggler_register=' wf_frm_tgl-target="'.$value['form_toggler']['target'].'"';
106
+ }
107
+ }
108
+
109
+ $field_group_attr=(isset($value['field_group']) ? ' data-field-group="'.$value['field_group'].'" ' : '');
110
+ $tr_class.=(isset($value['field_group']) ? ' wt_iew_field_group_children ' : ''); //add an extra class to tr when field grouping enabled
111
+
112
+ if($type=='image_export')
113
+ {
114
+ $css_class.=' wt_iew_separate_image_export';
115
+ }
116
+
117
+ $attr='';
118
+ $has_class_attr=0;
119
+ $css_attr_value='';
120
+ foreach ($attr_arr as $attr_key => $attr_value)
121
+ {
122
+ if($attr_key=='class')
123
+ {
124
+ $attr_value.=" ".$form_toggler_p_class." ".$css_class;
125
+ $form_toggler_p_class='';
126
+ $css_class='';
127
+ $has_class_attr=1;
128
+ $css_attr_value=$attr_value;
129
+ }
130
+ $attr.=$attr_key.'="'.$attr_value.'" ';
131
+ }
132
+
133
+ $css_class.=($form_toggler_p_class!="" ? ' '.$form_toggler_p_class : '');
134
+ $css_attr=($css_class!="" ? ' class="'.$css_class.'"' : '');
135
+
136
+
137
+ if($tr_html=="")
138
+ {
139
+ $form_field_name = isset($value['field_name']) ? $value['field_name'] : '';
140
+ $form_data_key=(substr($form_field_name,0,8)!=='wt_iew_' ? 'wt_iew_' : '').$form_field_name;
141
+
142
+ /* checking field value exist in form data array */
143
+ if(isset($form_data[$form_data_key]))
144
+ {
145
+ $vl=$form_data[$form_data_key];
146
+ }
147
+ if($type=='field_group_head') //heading for field group
148
+ {
149
+ $visibility=(isset($value['show_on_default']) ? $value['show_on_default'] : 0);
150
+ ?>
151
+ <tr <?php echo $tr_id.$field_group_attr;?> class="<?php echo $tr_class;?>">
152
+ <td colspan="3" class="wt_iew_field_group">
153
+ <div class="wt_iew_field_group_hd">
154
+ <?php echo isset($value['head']) ? $value['head'] : ''; ?>
155
+ <div class="wt_iew_field_group_toggle_btn" data-id="<?php echo isset($value['group_id']) ? $value['group_id'] : ''; ?>" data-visibility="<?php echo $visibility; ?>"><span class="dashicons dashicons-arrow-<?php echo ($visibility==1 ? 'down' : 'right'); ?>"></span></div>
156
+ </div>
157
+ <div class="wt_iew_field_group_content">
158
+ <table></table>
159
+ </div>
160
+ </td>
161
+ </tr>
162
+ <?php
163
+ }else
164
+ {
165
+ ?>
166
+ <tr <?php echo $tr_id.$field_group_attr;?> class="<?php echo $tr_class;?>" <?php echo $form_toggler_child; ?>>
167
+ <?php
168
+ if(!$merge_left) /* if merge left not enabled */
169
+ {
170
+ ?>
171
+ <th class="<?php echo $td_class1;?>">
172
+ <label><?php echo isset($value['label']) ? $value['label'] : ''; ?></label>
173
+ </th>
174
+ <?php
175
+ }
176
+ ?>
177
+ <td <?php echo $colspan_attr;?> class="<?php echo $td_class2;?>">
178
+
179
+ <?php
180
+ if($field_html=='')
181
+ {
182
+ echo $before_form_field;
183
+ if($type=='text' || $type=='number' || $type=='password')
184
+ {
185
+ ?>
186
+ <input placeholder="<?php echo $placeholder;?>" type="<?php echo $type; ?>" <?php echo $html_id;?> <?php echo $css_attr;?> name="<?php echo $form_data_key;?>" value="<?php echo $vl;?>" <?php echo $attr;?> >
187
+ <?php
188
+ }
189
+ if($type=='textarea')
190
+ {
191
+ ?>
192
+ <textarea placeholder="<?php echo $placeholder;?>" <?php echo $html_id;?> <?php echo $css_attr;?> name="<?php echo $form_data_key;?>" <?php echo $attr;?> ><?php echo $vl;?></textarea>
193
+ <?php
194
+ }
195
+ elseif($type=='multi_select')
196
+ {
197
+ $sele_vals=(isset($value['sele_vals']) && is_array($value['sele_vals']) ? $value['sele_vals'] : array());
198
+ $vl=(is_array($vl) ? $vl : array($vl));
199
+ $vl=array_filter($vl);
200
+ ?>
201
+ <select <?php echo $html_id;?> <?php echo $css_attr;?> data-placeholder="<?php echo $placeholder;?>" name="<?php echo $form_data_key;?>" multiple="multiple" <?php echo $attr;?> >
202
+ <?php
203
+ foreach($sele_vals as $sele_val=>$sele_lbl)
204
+ {
205
+ ?>
206
+ <option value="<?php echo $sele_val;?>" <?php echo (in_array($sele_val,$vl) ? 'selected' : ''); ?>><?php echo $sele_lbl;?></option>
207
+ <?php
208
+ }
209
+
210
+ /* in the case of ajax product search selectbox */
211
+ if($has_class_attr==1)
212
+ {
213
+ $css_class_arr=explode(" ", $css_attr_value);
214
+ }else
215
+ {
216
+ $css_class_arr=explode(" ", $css_class);
217
+ }
218
+ if(count($sele_vals)==0 && in_array('wc-product-search', $css_class_arr))
219
+ {
220
+ foreach($vl as $single_vl)
221
+ {
222
+ $single_vl=(int) $single_vl;
223
+ if($single_vl>0)
224
+ {
225
+ $product=wc_get_product($single_vl);
226
+ ?>
227
+ <option value="<?php echo $single_vl;?>" selected><?php echo $product->get_title();?></option>
228
+ <?php
229
+ }
230
+ }
231
+ }
232
+ ?>
233
+ </select>
234
+ <?php
235
+ }
236
+ elseif($type=='select')
237
+ {
238
+ $sele_vals=(isset($value['sele_vals']) && is_array($value['sele_vals']) ? $value['sele_vals'] : array());
239
+ $vl=(is_array($vl) ? $vl : array($vl));
240
+ ?>
241
+ <select <?php echo $html_id;?> <?php echo $css_attr;?> data-placeholder="<?php echo $placeholder;?>" name="<?php echo $form_data_key;?>" <?php echo $attr;?> <?php echo $form_toggler_register;?> >
242
+ <?php
243
+ foreach($sele_vals as $sele_val=>$sele_lbl)
244
+ {
245
+ $sele_lbl_txt=(is_array($sele_lbl) ? ( isset($sele_lbl['value']) ? $sele_lbl['value'] : (isset($sele_lbl[0]) ? $sele_lbl[0] : '' ) ) : $sele_lbl);
246
+
247
+ /* check any extra data to append */
248
+ $sele_extra_attr='';
249
+ if(is_array($sele_lbl))
250
+ {
251
+ foreach($sele_lbl as $sele_lblk=>$sele_lblv)
252
+ {
253
+ if($sele_lblk=='value')
254
+ {
255
+ continue;
256
+ }
257
+ $sele_extra_attr.=' data-'.$sele_lblk.'="'.$sele_lblv.'"';
258
+ }
259
+ }
260
+ ?>
261
+ <option value="<?php echo $sele_val;?>" <?php echo (in_array($sele_val,$vl) ? 'selected' : ''); ?> <?php echo $sele_extra_attr; ?> ><?php echo $sele_lbl_txt;?></option>
262
+ <?php
263
+ }
264
+ ?>
265
+ </select>
266
+ <?php
267
+ }
268
+ elseif($type=='radio') //radio button
269
+ {
270
+ ?>
271
+ <div class="wt_form_radio_block">
272
+ <?php
273
+ $radio_fields=isset($value['radio_fields']) ? $value['radio_fields'] : array();
274
+ foreach ($radio_fields as $rad_vl=>$rad_label)
275
+ {
276
+ ?>
277
+ <input <?php echo $css_attr;?> type="radio" id="<?php echo $form_data_key.'_'.$rad_vl;?>" name="<?php echo $form_data_key;?>" value="<?php echo $rad_vl;?>" <?php echo ($vl==$rad_vl) ? ' checked="checked"' : ''; ?> <?php echo $attr;?> <?php echo $form_toggler_register;?> /> <?php echo $rad_label; ?>
278
+ &nbsp;&nbsp;
279
+ <?php
280
+ }
281
+ ?>
282
+ </div>
283
+ <?php
284
+ }
285
+ elseif($type=='image_export') //image export radio button
286
+ {
287
+ ?>
288
+ <div class="wt_form_radio_block">
289
+ <?php
290
+ $radio_fields=array(
291
+ 'Yes' => __('Yes'),
292
+ 'No' => __('No')
293
+ );
294
+ foreach ($radio_fields as $rad_vl=>$rad_label)
295
+ {
296
+ ?>
297
+ <input <?php echo $css_attr;?> type="radio" id="<?php echo $form_data_key.'_'.$rad_vl;?>" name="<?php echo $form_data_key;?>" value="<?php echo $rad_vl;?>" <?php echo ($vl==$rad_vl) ? ' checked="checked"' : ''; ?> <?php echo $attr;?> <?php echo $form_toggler_register;?> /> <?php echo $rad_label; ?>
298
+ &nbsp;&nbsp;
299
+ <?php
300
+ }
301
+ ?>
302
+ </div>
303
+ <?php
304
+ }
305
+ elseif($type=='checkbox') //checkbox
306
+ {
307
+ ?>
308
+ <div class="wt_form_checkbox_block">
309
+ <?php
310
+ $checkbox_fields=isset($value['checkbox_fields']) ? $value['checkbox_fields'] : array();
311
+ foreach ($checkbox_fields as $chk_vl=>$chk_label)
312
+ {
313
+ ?>
314
+ <input <?php echo $css_attr;?> type="checkbox" id="<?php echo $form_data_key.'_'.$chk_vl;?>" name="<?php echo $form_data_key;?>" value="<?php echo $chk_vl;?>" <?php echo ($vl==$chk_vl) ? ' checked="checked"' : ''; ?> <?php echo $attr;?> <?php echo $form_toggler_register;?> /> <?php echo $chk_label; ?>
315
+ &nbsp;&nbsp;
316
+ <?php
317
+ }?>
318
+ </div>
319
+ <?php
320
+ }elseif($type=='uploader')
321
+ {
322
+ $field_id=(isset($value['html_id']) ? $value['html_id'] : $form_data_key);
323
+ ?>
324
+ <div class="wt_iew_file_attacher_dv">
325
+ <input <?php echo ($html_id!="" ? $html_id : 'id="'.$field_id.'"');?> placeholder="<?php echo $placeholder;?>" <?php echo $css_attr;?> type="text" name="<?php echo $form_data_key; ?>" value="<?php echo $vl; ?>" <?php echo $attr;?>/>
326
+ <input type="button" name="upload_file" data-wt_iew_file_attacher_title="<?php _e('Choose a file.'); ?>" data-wt_iew_file_attacher_button_text="<?php _e('Select'); ?>" class="wf_button button button-primary wt_iew_file_attacher" wt_iew_file_attacher_target="#<?php echo $field_id; ?>" value="<?php _e('Upload'); ?>" />
327
+ </div>
328
+ <?php
329
+ }elseif($type=='dropzone') /* dropzone file uploader */
330
+ {
331
+ $dropzone_id=(isset($value['dropzone']) ? $value['dropzone'] : $form_data_key.'_dropzone');
332
+ $field_id=(isset($value['html_id']) ? $value['html_id'] : $form_data_key);
333
+ ?>
334
+ <input <?php echo $css_attr;?> type="hidden" name="<?php echo $form_data_key; ?>" value="<?php echo $vl; ?>" <?php echo $attr;?> <?php echo ($html_id!="" ? $html_id : 'id="'.$field_id.'"');?>/>
335
+
336
+ <div id="<?php echo $dropzone_id;?>" class="wt_iew_dropzone" wt_iew_dropzone_target="#<?php echo $field_id; ?>">
337
+ <div class="dz-message">
338
+ <?php _e('Drop files here or click to upload');?>
339
+ <br /><br /><div class="wt_iew_dz_file_success"></div> <br />
340
+ <div class="wt_iew_dz_file_name"></div> <br />
341
+ <div class="wt_iew_dz_remove_link"></div> <br />
342
+ </div>
343
+ </div>
344
+ <?php
345
+ }
346
+ echo $after_form_field;
347
+ }else
348
+ {
349
+ echo $field_html;
350
+ }
351
+ if($help_text!="")
352
+ {
353
+ ?>
354
+ <span class="wt-iew_form_help"><?php echo $help_text;?></span>
355
+ <?php
356
+ }
357
+ echo $conditional_help_html;
358
+ ?>
359
+ </td>
360
+ <?php
361
+ if(!$merge_right) /* if merge right not enabled */
362
+ {
363
+ ?>
364
+ <td class="<?php echo $td_class3;?>">
365
+ <?php echo $after_form_field_html; ?>
366
+ </td>
367
+ <?php
368
+ }
369
+ ?>
370
+ </tr>
371
+ <?php
372
+ }
373
+ }else
374
+ {
375
+ echo $tr_html;
376
+ }
377
+ }
378
+ ?>
admin/partials/wt-import-export-for-woo-admin-display.php ADDED
@@ -0,0 +1,76 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ $wf_admin_view_path=WT_P_IEW_PLUGIN_PATH.'admin/views/';
6
+ $wf_img_path=WT_P_IEW_PLUGIN_URL.'images/';
7
+ ?>
8
+ <div class="wrap" id="<?php echo WT_IEW_PLUGIN_ID_BASIC;?>">
9
+ <h2 class="wp-heading-inline">
10
+ <?php _e('Import Export for WooCommerce');?>
11
+ </h2>
12
+ <div class="nav-tab-wrapper wp-clearfix wt-iew-tab-head">
13
+ <?php
14
+ $tab_head_arr=array(
15
+ 'wt-advanced'=>__('General'),
16
+ 'wt-help'=>__('Help Guide'),
17
+ 'wt-pro-upgrade'=>__('Pro Upgrade')
18
+ );
19
+ if(isset($_GET['debug']))
20
+ {
21
+ $tab_head_arr['wt-debug']='Debug';
22
+ }
23
+ Wt_Import_Export_For_Woo_Basic::generate_settings_tabhead($tab_head_arr);
24
+ ?>
25
+ </div>
26
+ <div class="wt-iew-tab-container">
27
+ <?php
28
+ //inside the settings form
29
+ $setting_views_a=array(
30
+ 'wt-advanced'=>'admin-settings-advanced.php',
31
+ );
32
+
33
+ //outside the settings form
34
+ $setting_views_b=array(
35
+ 'wt-help'=>'admin-settings-help.php',
36
+ );
37
+ $setting_views_b['wt-pro-upgrade']='admin-settings-marketing.php';
38
+ if(isset($_GET['debug']))
39
+ {
40
+ $setting_views_b['wt-debug']='admin-settings-debug.php';
41
+ }
42
+ ?>
43
+ <form method="post" class="wt_iew_settings_form_basic">
44
+ <?php
45
+ // Set nonce:
46
+ if (function_exists('wp_nonce_field'))
47
+ {
48
+ wp_nonce_field(WT_IEW_PLUGIN_ID_BASIC);
49
+ }
50
+ foreach ($setting_views_a as $target_id=>$value)
51
+ {
52
+ $settings_view=$wf_admin_view_path.$value;
53
+ if(file_exists($settings_view))
54
+ {
55
+ include $settings_view;
56
+ }
57
+ }
58
+ ?>
59
+ <?php
60
+ //settings form fields for module
61
+ do_action('wt_iew_plugin_settings_form');?>
62
+ </form>
63
+ <?php
64
+ foreach ($setting_views_b as $target_id=>$value)
65
+ {
66
+ $settings_view=$wf_admin_view_path.$value;
67
+ if(file_exists($settings_view))
68
+ {
69
+ include $settings_view;
70
+ }
71
+ }
72
+ ?>
73
+ <?php do_action('wt_iew_plugin_out_settings_form');?>
74
+ </div>
75
+ <?php //include $wf_admin_view_path."market.php"; ?>
76
+ </div>
admin/views/_save_template_popup.php ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Template saving popup HTML for Import/Export
4
+ *
5
+ * @link
6
+ *
7
+ * @package Wt_Import_Export_For_Woo
8
+ */
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+ ?>
13
+ <div class="wt_iew_template_name wt_iew_popup" data-save-label="<?php _e('Save');?>" data-saveas-label="<?php _e('Save as');?>">
14
+ <div class="wt_iew_popup_hd">
15
+ <span style="line-height:40px;" class="dashicons dashicons-edit"></span>
16
+ <span class="wt_iew_popup_hd_label"></span>
17
+ <div class="wt_iew_popup_close">X</div>
18
+ </div>
19
+ <div class="wt_iew_warn_box">
20
+ <div class="wt_iew_warn wt_iew_template_name_wrn">
21
+ <?php _e('Please enter name');?>
22
+ </div>
23
+ </div>
24
+ <div class="wt_iew_template_name_box">
25
+ <label class="wt_iew_template_name_label"><?php _e('Template name');?></label>
26
+ <input type="text" name="wt_iew_template_name_field" class="wt_iew_text_field wt_iew_template_name_field">
27
+ <div class="wt_iew_popup_footer">
28
+ <button type="button" name="" class="button-secondary wt_iew_popup_cancel">
29
+ <?php _e('Cancel');?>
30
+ </button>
31
+ <button type="button" name="" class="button-primary wt_iew_template_create_btn"></button>
32
+ </div>
33
+ </div>
34
+ </div>
admin/views/admin-settings-advanced.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-tab-content" data-id="<?php echo $target_id;?>">
7
+ <?php
8
+ $fields=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings_fields();
9
+
10
+ $advanced_settings=Wt_Import_Export_For_Woo_Basic_Common_Helper::get_advanced_settings();
11
+ ?>
12
+ <table class="form-table wt-iew-form-table">
13
+ <?php
14
+ Wt_Import_Export_For_Woo_Basic_Common_Helper::field_generator($fields, $advanced_settings);
15
+ ?>
16
+ </table>
17
+ <?php
18
+ include "admin-settings-save-button.php";
19
+ ?>
20
+ </div>
admin/views/admin-settings-debug.php ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-tab-content" data-id="<?php echo $target_id;?>">
7
+
8
+ </div>
admin/views/admin-settings-help.php ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-tab-content" data-id="<?php echo $target_id;?>">
7
+ <ul class="wt_iew_sub_tab">
8
+ <li style="border-left:none; padding-left: 0px;" data-target="help-links"><a><?php _e('Help Links'); ?></a></li>
9
+ <li data-target="help-doc"><a><?php _e('Sample CSV');?></a></li>
10
+ </ul>
11
+ <div class="wt_iew_sub_tab_container">
12
+ <div class="wt_iew_sub_tab_content" data-id="help-links" style="display:block;">
13
+ <!--<h3><?php //_e('Help Links'); ?></h3>-->
14
+ <ul class="wf-help-links">
15
+ <li>
16
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL;?>assets/images/documentation.png">
17
+ <h3><?php _e('Documentation'); ?></h3>
18
+ <p><?php _e('Refer to our documentation to set up and get started.'); ?></p>
19
+ <a target="_blank" href="https://www.webtoffee.com/category/documentation/" class="button button-primary">
20
+ <?php _e('Documentation'); ?>
21
+ </a>
22
+ </li>
23
+ <li>
24
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL;?>assets/images/support.png">
25
+ <h3><?php _e('Help and Support'); ?></h3>
26
+ <p><?php _e('We would love to help you on any queries or issues.'); ?></p>
27
+ <a target="_blank" href="https://www.webtoffee.com/support/" class="button button-primary">
28
+ <?php _e('Contact Us'); ?>
29
+ </a>
30
+ </li>
31
+ </ul>
32
+ </div>
33
+ <div class="wt_iew_sub_tab_content" data-id="help-doc">
34
+ <!--<h3><?php //_e( 'Help Docs' ); ?></h3>-->
35
+ <ul class="wf-help-links">
36
+ <?php do_action( 'wt_user_addon_basic_help_content' ); ?>
37
+ <?php do_action( 'wt_order_addon_basic_help_content' ); ?>
38
+ <?php do_action( 'wt_coupon_addon_basic_help_content' ); ?>
39
+ <?php do_action( 'wt_product_addon_basic_help_content' ); ?>
40
+ </ul>
41
+ </div>
42
+ </div>
43
+ </div>
admin/views/admin-settings-marketing.php ADDED
@@ -0,0 +1,528 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'WPINC' ) ) {
3
+ die;
4
+ }
5
+ ?>
6
+ <div class="wt-iew-tab-content" data-id="<?php echo $target_id;?>">
7
+ <div class="wt-ier-wrapper">
8
+ <h2 class="wt-ier-page-title"><?php _e('Make a complete import and export for your store\'s valuable data, all in one place.');?></h2>
9
+ <p class="wt-ier-subp"><?php _e('Get access to advanced features and premium support. Upgrade to the premium version.');?></p>
10
+ <div class="wt-ier-row">
11
+ <div class="wt-ier-col-12 wt-ier-col-lg-4 wt-ier-lg-4 wt-ier-mb-lg-0">
12
+ <div class="wt-ier-p-5 wt-ier-box-wrapper wt-ier-box-highlight">
13
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/product-ie.svg" class="wt-ier-thumbnails">
14
+ <h3 class="wt-ier-plugin-name"><?php _e('Product import export plugin for wooCommerce');?></h3>
15
+ <p class="wt-ier-p"><?php _e('Easily export and import all types of products and product information.');?></p>
16
+ <div class="wt-ier-d-sm-flex wt-ier-btn-group">
17
+ <a href="https://www.webtoffee.com/product/product-import-export-woocommerce/?utm_source=free_plugin_revamp&utm_medium=basic_revamp&utm_campaign=Product_Import_Export&utm_content=<?php echo WT_P_IEW_VERSION; ?>" target="_blank" class="wt-ier-primary-btn wt-ier-btn"><?php _e('Get Premium');?></a>
18
+ <a href="" class="wt-ier-secondary-btn wt-ier-btn" data-toggle="modal" data-target="#wt-ier-comparison-modal-product"><?php _e('Compare with basic');?></a>
19
+ </div>
20
+ </div>
21
+ </div>
22
+ <div class="wt-ier-col-12 wt-ier-col-lg-4 wt-ier-lg-4 wt-ier-mb-lg-0">
23
+ <div class="wt-ier-p-5 wt-ier-box-wrapper wt-ier-box-highlight">
24
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/customer-ie.svg" class="wt-ier-thumbnails">
25
+ <h3 class="wt-ier-plugin-name"><?php _e('Customer Import Export for WooCommerce');?></h3>
26
+ <p class="wt-ier-p"><?php _e('Easily import or export WordPress User and WooCommerce Customer data from/to a CSV file!');?></p>
27
+ <div class="wt-ier-d-sm-flex wt-ier-btn-group">
28
+ <a href="https://www.webtoffee.com/product/wordpress-users-woocommerce-customers-import-export/?utm_source=free_plugin_revamp&utm_medium=basic_revamp&utm_campaign=User_Import_Export&utm_content=<?php echo WT_P_IEW_VERSION; ?>" class="wt-ier-primary-btn wt-ier-btn" target="_blank"><?php _e('Get Premium');?></a>
29
+ <a href="" class="wt-ier-secondary-btn wt-ier-btn" data-toggle="modal" data-target="#wt-ier-comparison-modal-customer"><?php _e('Compare with basic');?></a>
30
+ </div>
31
+ </div>
32
+ </div>
33
+ <div class="wt-ier-col-12 wt-ier-col-lg-4 wt-ier-lg-4 wt-ier-mb-lg-0">
34
+ <div class="wt-ier-p-5 wt-ier-box-wrapper wt-ier-box-highlight">
35
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/order-ie.svg" class="wt-ier-thumbnails">
36
+ <h3 class="wt-ier-plugin-name"><?php _e('Order, Coupon, Subscription Export Import for WooCommerce');?></h3>
37
+ <p class="wt-ier-p"><?php _e('Export or Import WooCommerce orders, Coupons and Subscriptions.');?></p>
38
+ <div class="wt-ier-d-sm-flex wt-ier-btn-group">
39
+ <a href="https://www.webtoffee.com/product/order-import-export-plugin-for-woocommerce/?utm_source=free_plugin_revamp&utm_medium=basic_revamp&utm_campaign=Order_Import_Export&utm_content=<?php echo WT_P_IEW_VERSION; ?>" class="wt-ier-primary-btn wt-ier-btn" target="_blank"><?php _e('Get Premium');?></a>
40
+ <a href="" class="wt-ier-secondary-btn wt-ier-btn" data-toggle="modal" data-target="#wt-ier-comparison-modal-order"><?php _e('Compare with basic');?></a>
41
+ </div>
42
+ </div>
43
+ </div>
44
+ </div>
45
+ <!--------product imp-exp comparison table --------->
46
+ <div id="wt-ier-comparison-modal-product" class="wt-ier-modal">
47
+ <div class="wt-ier-modal-content">
48
+ <div class="wt-ier-resposive-table">
49
+ <table class="wt-ier-table">
50
+
51
+ <thead>
52
+ <tr class="wt-ier-top-tr">
53
+ <td></td>
54
+ <td colspan="3"><span class="wt-ier-close">&times;</span></td>
55
+ </tr>
56
+ <tr>
57
+ <th><?php _e('Features');?></th>
58
+ <th><?php _e('Free');?></th>
59
+ <th><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/pre-icon.svg" class="wt-ier-pre-icon"><?php _e('Premium');?></th>
60
+ <th><?php _e('Import Export Suite');?></th>
61
+ </tr>
62
+ </thead>
63
+ <tbody>
64
+ <tr>
65
+ <td><?php _e('Import and export products');?></td>
66
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
67
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
68
+ <td>
69
+ <ul>
70
+ <li><?php _e('Products');?></li>
71
+ <li><?php _e('Reviews');?></li>
72
+ <li><?php _e('Orders');?></li>
73
+ <li><?php _e('Coupons');?></li>
74
+ <li><?php _e('Subscriptions');?></li>
75
+ <li><?php _e('Users');?></li>
76
+ </ul>
77
+ </td>
78
+ </tr>
79
+ <tr>
80
+ <td><?php _e('Export and import with product images');?></td>
81
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
82
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
83
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
84
+ </tr>
85
+ <tr>
86
+ <td><?php _e('Batch import/export');?></td>
87
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
88
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
89
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
90
+ </tr>
91
+ <tr>
92
+ <td><?php _e('Quick import/export');?></td>
93
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
94
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
95
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
96
+ </tr>
97
+ <tr>
98
+ <td><?php _e('Bulk product update');?></td>
99
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
100
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
101
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
102
+ </tr>
103
+ <tr>
104
+ <td><?php _e('Advanced import/export filters');?></td>
105
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"><p><?php _e('Limited');?></p></td>
106
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
107
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
108
+ </tr>
109
+ <tr>
110
+ <td><?php _e('Option to save a template for future import/exports');?></td>
111
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
112
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
113
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
114
+ </tr>
115
+ <tr>
116
+ <td><?php _e('Export/Import mapping');?></td>
117
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
118
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
119
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
120
+ </tr>
121
+ <tr>
122
+ <td><?php _e('Import by uploading CSV');?></td>
123
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
124
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
125
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
126
+ </tr>
127
+ <tr>
128
+ <td><?php _e('Import/Export history');?></td>
129
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
130
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
131
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
132
+ </tr>
133
+ <tr>
134
+ <td><?php _e('Debug logs');?></td>
135
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
136
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
137
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
138
+ </tr>
139
+ <tr>
140
+ <td><?php _e('Supports multiple file formats');?></td>
141
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"><p><?php _e('Only supports CSV');?></p></td>
142
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
143
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
144
+ </tr>
145
+ <tr>
146
+ <td><?php _e('Import/Export file via FTP/SFTP');?></td>
147
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
148
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
149
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
150
+ </tr>
151
+ <tr>
152
+ <td><?php _e('Import from URL');?></td>
153
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
154
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
155
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
156
+ </tr>
157
+ <tr>
158
+ <td><?php _e('Export product images as a zip');?></td>
159
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
160
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
161
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
162
+ </tr>
163
+ <tr>
164
+ <td><?php _e('Choose delimiter');?></td>
165
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
166
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
167
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
168
+ </tr>
169
+ <tr>
170
+ <td><?php _e('Support for multiple product types');?></td>
171
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
172
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
173
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
174
+ </tr>
175
+ <tr>
176
+ <td><?php _e('Automatic scheduled import/export');?></td>
177
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
178
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
179
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
180
+ </tr>
181
+ <tr>
182
+ <td><?php _e('Import/Export hidden meta');?></td>
183
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
184
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
185
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
186
+ </tr>
187
+ <tr>
188
+ <td><?php _e('Third-party plugin filter support');?></td>
189
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
190
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
191
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
192
+ </tr>
193
+ <tr>
194
+ <td><?php _e('Import/Export Product ratings');?></td>
195
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
196
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
197
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
198
+ </tr>
199
+ <tr>
200
+ <td><?php _e('Import/export products reviews');?></td>
201
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
202
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
203
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
204
+ </tr>
205
+
206
+ </tbody>
207
+ </table>
208
+ </div>
209
+ </div>
210
+ </div>
211
+ <!--------customer imp-exp comparison table --------->
212
+ <div id="wt-ier-comparison-modal-customer" class="wt-ier-modal">
213
+ <div class="wt-ier-modal-content">
214
+ <div class="wt-ier-resposive-table">
215
+ <table class="wt-ier-table">
216
+
217
+ <thead>
218
+ <tr class="wt-ier-top-tr">
219
+ <td></td>
220
+ <td colspan="3"><span class="wt-ier-close">&times;</span></td>
221
+ </tr>
222
+ <tr>
223
+ <th><?php _e('Features');?></th>
224
+ <th><?php _e('Free');?></th>
225
+ <th><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/pre-icon.svg" class="wt-ier-pre-icon"><?php _e('Premium');?></th>
226
+ <th><?php _e('Import Export Suite');?></th>
227
+ </tr>
228
+ </thead>
229
+ <tbody>
230
+ <tr>
231
+ <td><?php _e('Import/Export Users');?></td>
232
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
233
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
234
+ <td>
235
+ <ul>
236
+ <li><?php _e('Products');?></li>
237
+ <li><?php _e('Reviews');?></li>
238
+ <li><?php _e('Orders');?></li>
239
+ <li><?php _e('Coupons');?></li>
240
+ <li><?php _e('Subscriptions');?></li>
241
+ <li><?php _e('Users');?></li>
242
+ </ul>
243
+ </td>
244
+ </tr>
245
+ <tr>
246
+ <td><?php _e('Import/Export customers');?></td>
247
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
248
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
249
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
250
+ </tr>
251
+ <tr>
252
+ <td><?php _e('Retain user password on Import/Export');?></td>
253
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
254
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
255
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
256
+ </tr>
257
+ <tr>
258
+ <td><?php _e('Bulk update data');?></td>
259
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
260
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
261
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
262
+ </tr>
263
+ <tr>
264
+ <td><?php _e('Evaluation fields');?></td>
265
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
266
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
267
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
268
+ </tr>
269
+ <tr>
270
+ <td><?php _e('Advanced filters');?></td>
271
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"><p><?php _e('Limited options');?></p></td>
272
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
273
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
274
+ </tr>
275
+ <tr>
276
+ <td><?php _e('Quick Import/Export');?></td>
277
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
278
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
279
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
280
+ </tr>
281
+ <tr>
282
+ <td><?php _e('Import/Export with pre-saved template');?></td>
283
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
284
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
285
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
286
+ </tr>
287
+ <tr>
288
+ <td><?php _e('View Import/Export history');?></td>
289
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
290
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
291
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
292
+ </tr>
293
+ <tr>
294
+ <td><?php _e('View debug log');?></td>
295
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
296
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
297
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
298
+ </tr>
299
+ <tr>
300
+ <td><?php _e('Batch Import/Export');?></td>
301
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
302
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
303
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
304
+ </tr>
305
+ <tr>
306
+ <td><?php _e('Customer Notification via email');?></td>
307
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
308
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
309
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
310
+ </tr>
311
+ <tr>
312
+ <td><?php _e('Supports multiple file formats');?></td>
313
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"><p><?php _e('CSV only');?></p></td>
314
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
315
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
316
+ </tr>
317
+ <tr>
318
+ <td><?php _e('Choose delimiter');?></td>
319
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
320
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
321
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
322
+ </tr>
323
+ <tr>
324
+ <td><?php _e('Import from URL');?></td>
325
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
326
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
327
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
328
+ </tr>
329
+ <tr>
330
+ <td><?php _e('Import/export via FTP');?></td>
331
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
332
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
333
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
334
+ </tr>
335
+ <tr>
336
+ <td><?php _e('Scheduled Import/Export using Cron');?></td>
337
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
338
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
339
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
340
+ </tr>
341
+ <tr>
342
+ <td><?php _e('Third-party plugin filter support');?></td>
343
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
344
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
345
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
346
+ </tr>
347
+
348
+ </tbody>
349
+ </table>
350
+ </div>
351
+ </div>
352
+ </div>
353
+ <!--------order imp-exp comparison table --------->
354
+ <div id="wt-ier-comparison-modal-order" class="wt-ier-modal">
355
+ <div class="wt-ier-modal-content">
356
+ <div class="wt-ier-resposive-table">
357
+ <table class="wt-ier-table">
358
+
359
+ <thead>
360
+ <tr class="wt-ier-top-tr">
361
+ <td></td>
362
+ <td colspan="3"><span class="wt-ier-close">&times;</span></td>
363
+ </tr>
364
+ <tr>
365
+ <th><?php _e('Features');?></th>
366
+ <th><?php _e('Free');?></th>
367
+ <th><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/pre-icon.svg" class="wt-ier-pre-icon"><?php _e('Premium');?></th>
368
+ <th><?php _e('Import Export Suite');?></th>
369
+ </tr>
370
+ </thead>
371
+ <tbody>
372
+ <tr>
373
+ <td><?php _e('Export and Import orders');?> </td>
374
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
375
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
376
+ <td>
377
+ <ul>
378
+ <li><?php _e('Products');?></li>
379
+ <li><?php _e('Reviews');?></li>
380
+ <li><?php _e('Orders');?></li>
381
+ <li><?php _e('Coupons');?></li>
382
+ <li><?php _e('Subscriptions');?></li>
383
+ <li><?php _e('Users');?></li>
384
+ </ul>
385
+ </td>
386
+ </tr>
387
+ <tr>
388
+ <td><?php _e('Export and Import Coupons');?> </td>
389
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
390
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
391
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
392
+ </tr>
393
+ <tr>
394
+ <td><?php _e('Batch Import/Export');?></td>
395
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
396
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
397
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
398
+ </tr>
399
+ <tr>
400
+ <td><?php _e('Quick Import/Export');?></td>
401
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
402
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
403
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
404
+ </tr>
405
+ <tr>
406
+ <td><?php _e('Easy Import/export with pre-saved template');?></td>
407
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
408
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
409
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
410
+ </tr>
411
+ <tr>
412
+ <td><?php _e('Export/Import column mapping');?></td>
413
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
414
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
415
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
416
+ </tr>
417
+ <tr>
418
+ <td><?php _e('Bulk update of data');?></td>
419
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
420
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
421
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
422
+ </tr>
423
+ <tr>
424
+ <td><?php _e('Support evaluation fields');?></td>
425
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
426
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
427
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
428
+ </tr>
429
+ <tr>
430
+ <td><?php _e('View debug logs');?></td>
431
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
432
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
433
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
434
+ </tr>
435
+ <tr>
436
+ <td><?php _e('Import/Export history');?></td>
437
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
438
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
439
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
440
+ </tr>
441
+ <tr>
442
+ <td><?php _e('Advanced filters');?></td>
443
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"><p><?php _e('Limited');?></p></td>
444
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
445
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
446
+ </tr>
447
+ <tr>
448
+ <td><?php _e('Supports multiple file formats');?></td>
449
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"><p><?php _e('CSV only');?></p></td>
450
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
451
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
452
+ </tr>
453
+ <tr>
454
+ <td><?php _e('Export/Import subscription orders');?> </td>
455
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
456
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
457
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
458
+ </tr>
459
+ <tr>
460
+ <td><?php _e('Import and Export via FTP/SFTP');?></td>
461
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
462
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
463
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
464
+ </tr>
465
+ <tr>
466
+ <td><?php _e('Scheduled automatic Import/Export using Cron job');?></td>
467
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
468
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
469
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
470
+ </tr>
471
+ <tr>
472
+ <td><?php _e('Platform independent XML Import/Export');?> </td>
473
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
474
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
475
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
476
+ </tr>
477
+ <tr>
478
+ <td><?php _e('Multiple Import methods');?></td>
479
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"><p><?php _e('Upload CSV only');?></p></td>
480
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
481
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
482
+ </tr>
483
+ <tr>
484
+ <td><?php _e('Choose delimiter');?></td>
485
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
486
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
487
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
488
+ </tr>
489
+ <tr>
490
+ <td><?php _e('Third-party plugin filter support');?></td>
491
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/no.svg"></td>
492
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
493
+ <td><img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/yes.svg"></td>
494
+ </tr>
495
+ </tbody>
496
+ </table>
497
+ </div>
498
+ </div>
499
+ </div>
500
+ <!--------comparison table ends here--------->
501
+ <div class=" wt-ier-box-wrapper wt-ier-mt-5 wt-ier-suite">
502
+ <div class="wt-ier-row wt-ier-p-5">
503
+ <div class="wt-ier-col-12 wt-ier-col-lg-6">
504
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/suite.svg" class="wt-ier-thumbnails">
505
+ <h2 class="wt-ier-page-title"><?php _e('Import Export Suite for WooCommerce');?></h2>
506
+ <p class="wt-ier-p"><?php _e('WooCommerce Import Export Suite is an all-in-one bundle of plugins that will enable you to import and export WooCommerce products, product reviews, orders, customers, coupons, and subscriptions.');?></p>
507
+ <a href="https://www.webtoffee.com/product/woocommerce-import-export-suite/?utm_source=free_plugin_revamp&utm_medium=basic_revamp&utm_campaign=Import_Export_Suite&utm_content=<?php echo WT_P_IEW_VERSION; ?>" class="wt-ier-primary-btn" target="_blank"><?php _e('Get Premium');?></a>
508
+ </div>
509
+ </div>
510
+ </div>
511
+ </div>
512
+ <script>
513
+ jQuery("a[data-toggle=modal]").click(function(e){
514
+ e.preventDefault();
515
+ var target=jQuery(this).attr('data-target');
516
+ jQuery(target).css('display','block');
517
+ });
518
+ jQuery(document).click(function (e) {
519
+ if (jQuery(e.target).is('.wt-ier-modal')) {
520
+ jQuery('.wt-ier-modal').css('display','none');
521
+ }
522
+
523
+ });
524
+ jQuery(".wt-ier-close").click(function (e) {
525
+ jQuery(this).closest('.wt-ier-modal').css('display','none');
526
+ });
527
+ </script>
528
+ </div>
admin/views/admin-settings-save-button.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // If this file is called directly, abort.
3
+ if ( ! defined( 'WPINC' ) ) {
4
+ die;
5
+ }
6
+ $settings_button_title=isset($settings_button_title) ? $settings_button_title : 'Update Settings';
7
+ $before_button_text=isset($before_button_text) ? $before_button_text : '';
8
+ $after_button_text=isset($after_button_text) ? $after_button_text : '';
9
+ ?>
10
+ <div style="clear: both;"></div>
11
+ <div class="wt-iew-plugin-toolbar bottom">
12
+ <div class="left">
13
+ </div>
14
+ <div class="right">
15
+ <?php echo $before_button_text; ?>
16
+ <input type="submit" name="wt_iew_update_admin_settings_form" value="<?php _e($settings_button_title); ?>" class="button button-primary" style="float:right;"/>
17
+ <?php echo $after_button_text; ?>
18
+ <span class="spinner" style="margin-top:11px"></span>
19
+ </div>
20
+ </div>
admin/views/market.php ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if (!defined('ABSPATH')) {
3
+ exit;
4
+ }
5
+ ?>
6
+
7
+ <div class="wt-import-export-upsell-wrapper market-box table-box-main">
8
+ <div class="ier-premium-upgrade">
9
+ <div class="wt-ier-sidebar-wrapper wt-ier-p-5">
10
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/crown.svg" class="wt-ier-sidebar-img">
11
+ <h3 class="wt-ier-sidebar-title wt-ier-center"><?php _e('Do not leave any data behind!<br>Upgrade to pro.');?></h3>
12
+ <div class="wt-ier-row">
13
+ <div class="wt-ier-col-12 wt-ier-col-md-6 wt-ier-border-md-right">
14
+ <div class="wt-ier-flex wt-ier-v-center ">
15
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/money-back-badge.svg" class="wt-ier-icon">
16
+ <p class="wt-ier-sidebar-p"><?php _e('30 Day Money Back Guarantee');?></p>
17
+ </div>
18
+ </div>
19
+ <div class="wt-ier-col-12 wt-ier-col-md-6">
20
+ <div class="wt-ier-flex wt-ier-v-center">
21
+ <img src="<?php echo WT_P_IEW_PLUGIN_URL; ?>assets/images/upgrade/support.svg" class="wt-ier-icon">
22
+ <p class="wt-ier-sidebar-p"><?php _e('Fast and Superior Support');?></p>
23
+ </div>
24
+ </div>
25
+ </div>
26
+ <div class="wt-ier-center wt-ier-pt-4">
27
+ <a href="<?php echo admin_url( 'admin.php?page=wt_import_export_for_woo_basic#wt-pro-upgrade' );?>" target="_blank" class="wt-ier-green-btn"><?php _e('Upgrade to Premium');?></a>
28
+ </div>
29
+ </div>
30
+ </div>
31
+ </div>
assets/images/documentation.png ADDED
Binary file
assets/images/drag_icon.png ADDED
Binary file
assets/images/loading.gif ADDED
Binary file
assets/images/sample-csv.png ADDED
Binary file
assets/images/support.png ADDED
Binary file
assets/images/upgrade/crown.svg ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="112" height="82" viewBox="0 0 112 82" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M23.3438 52.874L30.2262 30.5085L54.0251 51.7273L59.4742 51.1539L76.966 30.5085L89.5822 51.1539L76.6773 61.5803H45.4226L23.3438 52.874Z" fill="#FFA000"/>
3
+ <path d="M102.381 27.4384L75.9367 41.3863L55.0677 18.5389L36.362 41.0264L10.54 27.4445L17.453 69.3431C17.5391 69.8503 17.8024 70.3105 18.1959 70.6418C18.5894 70.9732 19.0877 71.1542 19.6021 71.1527H93.3411C93.8544 71.1516 94.3507 70.969 94.7422 70.637C95.1337 70.3051 95.3951 69.8453 95.4801 69.3391L102.381 27.4384Z" fill="#FFC107"/>
4
+ <path d="M56.473 79.8305C76.8349 79.8305 93.3415 74.9759 93.3415 68.9873C93.3415 62.9988 76.8349 58.1442 56.473 58.1442C36.1111 58.1442 19.6045 62.9988 19.6045 68.9873C19.6045 74.9759 36.1111 79.8305 56.473 79.8305Z" fill="#FFA000"/>
5
+ <path d="M56.473 82C37.0699 82 17.4351 77.5269 17.4351 68.9874C17.4351 60.4478 37.0699 55.9747 56.473 55.9747C75.8761 55.9747 95.5109 60.4478 95.5109 68.9874C95.5109 77.5269 75.8801 82 56.473 82ZM56.473 60.3116C33.7009 60.3116 21.7719 65.9518 21.7719 68.9874C21.7719 72.023 33.6907 77.6591 56.473 77.6591C79.2553 77.6591 91.172 72.0189 91.172 68.9833C91.172 65.9477 79.2533 60.3116 56.473 60.3116Z" fill="#FFD54F"/>
6
+ <path d="M56.4625 52.319C59.9278 52.319 62.7371 49.5098 62.7371 46.0444C62.7371 42.5791 59.9278 39.7699 56.4625 39.7699C52.9972 39.7699 50.188 42.5791 50.188 46.0444C50.188 49.5098 52.9972 52.319 56.4625 52.319Z" fill="#FFD54F"/>
7
+ <path d="M63.0586 47.9028C62.1945 44.7554 59.7709 45.0665 58.4717 45.4873C61.5967 44.4707 61.3365 42.2708 60.938 40.9655C61.3446 42.2708 62.7679 44.4789 65.4578 43.3504C63.2742 44.2755 62.3938 45.4812 63.0586 47.9028Z" fill="white"/>
8
+ <path d="M53.1525 10.5443C53.1525 8.57208 49.8526 5.27216 47.8804 5.27216C49.8526 5.27216 53.1525 1.97223 53.1525 0C53.1525 1.97223 56.4525 5.27216 58.4247 5.27216C56.4525 5.27623 53.1525 8.57208 53.1525 10.5443Z" fill="#FFD83B"/>
9
+ <path d="M5.27215 66.8524C5.27215 64.8802 1.9702 61.5803 0 61.5803C1.9702 61.5803 5.27215 58.2783 5.27215 56.3081C5.27215 58.2783 8.57208 61.5803 10.5443 61.5803C8.58021 61.5803 5.27215 64.8802 5.27215 66.8524Z" fill="#FFD83B"/>
10
+ <path d="M31.1693 25.9073C31.1693 25.2181 30.0164 24.0652 29.3271 24.0652C30.0164 24.0652 31.1693 22.9124 31.1693 22.2231C31.1693 22.9124 32.3221 24.0652 33.0114 24.0652C32.3221 24.0652 31.1693 25.2201 31.1693 25.9073Z" fill="#FFD83B"/>
11
+ <path d="M81.0443 25.9073C81.0443 25.2181 79.8914 24.0652 79.2021 24.0652C79.8914 24.0652 81.0443 22.9124 81.0443 22.2231C81.0443 22.9124 82.1971 24.0652 82.8864 24.0652C82.1971 24.0652 81.0443 25.2201 81.0443 25.9073Z" fill="#FFD83B"/>
12
+ <path d="M8.95618 19.8199C8.95618 18.4435 6.6505 16.1357 5.27197 16.1357C6.6505 16.1357 8.95618 13.8301 8.95618 12.4515C8.95618 13.8301 11.2619 16.1357 12.6404 16.1357C11.2619 16.1378 8.95618 18.4435 8.95618 19.8199Z" fill="#FFD83B"/>
13
+ <path d="M107.891 20.2509C107.891 18.8724 105.584 16.5647 104.207 16.5647C105.584 16.5647 107.891 14.259 107.891 12.8805C107.891 14.259 110.197 16.5647 111.575 16.5647C110.197 16.5667 107.891 18.8724 107.891 20.2509Z" fill="#FFD83B"/>
14
+ <path d="M106.419 70.3395C106.419 68.5848 103.481 65.6468 101.727 65.6468C103.481 65.6468 106.419 62.7088 106.419 60.9541C106.419 62.7088 109.357 65.6468 111.112 65.6468C109.357 65.663 106.419 68.5929 106.419 70.3395Z" fill="#FFD83B"/>
15
+ </svg>
assets/images/upgrade/customer-ie.svg ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="70" height="70" viewBox="0 0 70 70" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
2
+ <g clip-path="url(#clip0)">
3
+ <rect width="70" height="70" rx="5" fill="url(#pattern0)"/>
4
+ <rect y="-28" width="74" height="120" fill="url(#pattern1)"/>
5
+ <rect x="-1" y="-24" width="76" height="118" fill="url(#pattern2)"/>
6
+ </g>
7
+ <defs>
8
+ <pattern id="pattern0" patternContentUnits="objectBoundingBox" width="1" height="1">
9
+ <use xlink:href="#image0" transform="scale(0.0166667)"/>
10
+ </pattern>
11
+ <pattern id="pattern1" patternContentUnits="objectBoundingBox" width="1" height="1">
12
+ <use xlink:href="#image1" transform="translate(-0.0221622) scale(0.00324324 0.002)"/>
13
+ </pattern>
14
+ <pattern id="pattern2" patternContentUnits="objectBoundingBox" width="1" height="1">
15
+ <use xlink:href="#image2" transform="scale(0.00310559 0.00200021)"/>
16
+ </pattern>
17
+ <clipPath id="clip0">
18
+ <rect width="70" height="70" rx="5" fill="white"/>
19
+ </clipPath>
20
+ <image id="image0" width="60" height="60" xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAYAAAA6/NlyAAAAAXNSR0IArs4c6QAABr9JREFUaAXtWF1sFUUU/mbubUtbKFCkaotIQgkQBAUjgagUQSJJY0BQfDDGoBA18oQJ8UEjL7z7oj7pAwk+SYLCi0rE+BMlGqJBkfgTNSGiEJDyIz/t3fH7Zna5F/rQn917ryl70t7dmT0zc77znTlzdk10sOhwA4m9gbB6qDngsc54znDO8BjzQB7SY4zQQXByhge5ZIx15AyPMUIHwckZHuSSMdaRMzwiQo2DgV6ns3+lNpxV/1lLcfgTavkyMOMMSmy6KPTrieXzQpG/rqw3/PnLmsZDdZxN82QLewSAxab45JWjfvzZYe22Ek6fdbA2GNU5GXhnBzC3m6DljVGKHKYZjZHzdKOfbMCPALCW5KJal6y2tkZ4YCFw5oJFQwE4ccbhw4PA7gMRXp5DGyPqpRGCDYtpQd5ng5d2jfibVljZWMIvASUCswWHY38Z9DzncPutwCdvxQZKdVQifuUxzmN5HeBtidGVQXSPiOFge1jV0Q5jDIoFtmnUtE6LBTNL2P+Nw8NbIjQ2hB1YHpOgT6yuoKziNlAZRim029uA7c8a3HYLx6XYJmFGYBSAk6EhPxttMnrftjjceyfw/ucO+75IdHQVmgSRwIo5XSv72fSivsHyVC8Bd3Ec10kr2iipxJFlb3w/sPIei5ZxcVsXn2wS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pC27VzAdlIMsCkNkaR2Tmyilj+ioyCK5eIA+xULpeKguoD1ijTTkMRD4MR1Lj6M5R9gOqFC3IoF571KiuNEA+Tv+jeeiwbA24DaGcLclO2yyJ7EzsWLwjstPEWtihb3CIHAUVRYHuTVByhtRsatsp97K/EbKQKpGgfszDwAQ3/hoSBRXEoDSAB8SKEtND2tgNBvDYN1HhXGScwxxS21+XNJChUNIm9gs7t/+Pf/2Q=="/>
23
+ </defs>
24
+ </svg>
assets/images/upgrade/money-back-badge.svg ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="30" height="25" viewBox="0 0 30 25" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M15.2043 25C21.9706 25 27.4326 19.4167 27.4326 12.5C27.4326 5.58333 21.9299 0 15.2043 0C8.43803 0 2.97607 5.58333 2.97607 12.5C2.97607 19.4167 8.43803 25 15.2043 25Z" fill="black"/>
3
+ <path d="M15.2043 25C21.9706 25 27.4326 19.4167 27.4326 12.5C27.4326 5.58333 21.9299 0 15.2043 0C8.43803 0 2.97607 5.58333 2.97607 12.5C2.97607 19.4167 8.43803 25 15.2043 25Z" fill="url(#paint0_linear)"/>
4
+ <path d="M29.5516 9.08325H0.48913C0.203804 9.08325 0 9.29159 0 9.58325V15.9166C0 16.1666 0.203804 16.4166 0.48913 16.4166H29.5516C29.7962 16.4166 30.0408 16.2083 30.0408 15.9166V9.58325C30 9.29159 29.7962 9.08325 29.5516 9.08325Z" fill="black"/>
5
+ <path d="M29.5516 9.08325H0.48913C0.203804 9.08325 0 9.29159 0 9.58325V15.9166C0 16.1666 0.203804 16.4166 0.48913 16.4166H29.5516C29.7962 16.4166 30.0408 16.2083 30.0408 15.9166V9.58325C30 9.29159 29.7962 9.08325 29.5516 9.08325Z" fill="url(#paint1_linear)"/>
6
+ <path d="M5.50282 13.6666V12.0833L5.99195 13.0416H6.44032L6.92945 12.0833V13.6666H7.41858V11.0833H6.92945L6.23652 12.5416L5.54358 11.0833H5.09521V13.6666H5.50282ZM8.72293 13.7083C9.29358 13.7083 9.61967 13.3333 9.61967 12.8333V12.5416C9.61967 12.0416 9.29358 11.6666 8.72293 11.6666C8.15228 11.6666 7.82619 12.0416 7.82619 12.5416V12.8333C7.86695 13.3333 8.19304 13.7083 8.72293 13.7083ZM8.72293 13.3333C8.43761 13.3333 8.31532 13.1249 8.31532 12.8749V12.5416C8.31532 12.2916 8.43761 12.0833 8.72293 12.0833C9.00826 12.0833 9.13054 12.2916 9.13054 12.5416V12.8749C9.13054 13.1249 9.00826 13.3333 8.72293 13.3333ZM10.5572 13.6666V12.5416C10.5572 12.2916 10.6795 12.1666 10.924 12.1666C11.1686 12.1666 11.2501 12.3333 11.2501 12.5416V13.6666H11.7392V12.4583C11.7392 11.9999 11.4947 11.7083 11.0871 11.7083C10.8017 11.7083 10.6387 11.7916 10.5164 11.9999V11.7916H10.068V13.7083H10.5572V13.6666ZM13.0436 13.7083C13.4512 13.7083 13.7773 13.4583 13.8588 13.1249H13.4104C13.3697 13.2499 13.2474 13.3749 13.0436 13.3749C12.7583 13.3749 12.636 13.1666 12.636 12.9583V12.9166H13.8588V12.5833C13.8588 12.1249 13.5735 11.7499 13.0028 11.7499C12.4322 11.7499 12.1468 12.1249 12.1468 12.6249V12.8749C12.1468 13.4166 12.5137 13.7083 13.0436 13.7083ZM13.4104 12.5416H12.636C12.636 12.2916 12.7583 12.0833 13.0436 12.0833C13.2881 12.0833 13.4104 12.2499 13.4104 12.4999V12.5416ZM15.0001 14.3333L15.8153 11.7916H15.3262L14.9593 13.1666L14.5517 11.7916H14.0626L14.7148 13.7083L14.511 14.3749H15.0001V14.3333ZM18.2202 13.6666C18.7093 13.6666 19.0762 13.3749 19.0762 12.9583C19.0762 12.6249 18.8724 12.4166 18.6278 12.3333C18.7909 12.2499 18.9539 12.0416 18.9539 11.7499C18.9539 11.3749 18.6686 11.0833 18.2202 11.0833H17.0789V13.6666H18.2202ZM18.0572 12.1666H17.5273V11.4999H18.0572C18.261 11.4999 18.3833 11.6249 18.3833 11.8333C18.3833 11.9999 18.3017 12.1666 18.0572 12.1666ZM18.1795 13.2499H17.5273V12.5416H18.1387C18.3833 12.5416 18.5055 12.6666 18.5055 12.8749C18.5463 13.1249 18.424 13.2499 18.1795 13.2499ZM20.0545 13.7083C20.2583 13.7083 20.5028 13.6249 20.5843 13.4999V13.6666H21.0735V12.4583C21.0735 11.9999 20.7474 11.7083 20.299 11.7083C19.8914 11.7083 19.6061 11.9166 19.4838 12.2916H19.9322C19.9729 12.2083 20.0952 12.1249 20.2583 12.1249C20.4621 12.1249 20.5843 12.2499 20.5843 12.4166V12.6666C20.5028 12.5833 20.3398 12.4999 20.0952 12.4999C19.6468 12.4999 19.3208 12.7083 19.3208 13.1249C19.3615 13.4999 19.6468 13.7083 20.0545 13.7083ZM20.1767 13.3749C19.9729 13.3749 19.8099 13.2916 19.8099 13.0833C19.8099 12.9166 19.9729 12.7916 20.1767 12.7916C20.3805 12.7916 20.5436 12.8749 20.5436 13.0416C20.5843 13.2499 20.4213 13.3749 20.1767 13.3749ZM22.3778 13.7083C22.867 13.7083 23.2338 13.3749 23.2338 12.9583H22.7854C22.7447 13.1666 22.6632 13.2916 22.3778 13.2916C22.0925 13.2916 21.9702 13.1249 21.9702 12.8333V12.5416C21.9702 12.2916 22.0925 12.0833 22.3778 12.0833C22.6224 12.0833 22.7447 12.2499 22.7854 12.4166H23.2338C23.2338 11.9583 22.867 11.6666 22.3778 11.6666C21.8072 11.6666 21.4811 12.0416 21.4811 12.5416V12.8333C21.4811 13.3333 21.8072 13.7083 22.3778 13.7083ZM24.1713 13.6666V12.7499L24.7827 13.6666H25.3534L24.7012 12.6666L25.3534 11.7499H24.7827L24.1713 12.6249V10.9583H23.6822V13.6666H24.1713Z" fill="white"/>
7
+ <path d="M10.8421 6.45833C10.7198 6.45833 10.5975 6.41667 10.516 6.375C10.4345 6.33333 10.353 6.25 10.2715 6.20833C10.2307 6.125 10.1899 6.04167 10.1899 5.91667H10.4753C10.4753 5.95833 10.516 6.04167 10.516 6.08333C10.5568 6.125 10.5975 6.16667 10.6383 6.16667C10.6791 6.20833 10.7606 6.20833 10.8421 6.20833C10.9236 6.20833 10.9644 6.20833 11.0459 6.16667C11.0867 6.125 11.1682 6.08333 11.1682 6.04167C11.209 6 11.209 5.95833 11.209 5.875C11.209 5.79167 11.209 5.75 11.1682 5.70833C11.1274 5.66667 11.0867 5.625 11.0459 5.58333C10.9644 5.54167 10.9236 5.54167 10.8421 5.54167H10.6791V5.29167H10.8421C10.9236 5.29167 10.9644 5.29167 11.0459 5.25C11.0867 5.20833 11.1274 5.20833 11.1682 5.125C11.209 5.08333 11.209 5.04167 11.209 4.95833C11.209 4.91667 11.209 4.83333 11.1682 4.79167C11.1274 4.75 11.0867 4.70833 11.0459 4.66667C11.0052 4.625 10.9236 4.625 10.8829 4.625C10.8014 4.625 10.7606 4.625 10.7198 4.66667C10.6791 4.70833 10.6383 4.70833 10.5975 4.75C10.5568 4.79167 10.5568 4.83333 10.5568 4.91667H10.2715C10.2715 4.79167 10.3122 4.70833 10.353 4.625C10.3937 4.54167 10.4753 4.5 10.5975 4.45833C10.6791 4.41667 10.8014 4.375 10.9236 4.375C11.0459 4.375 11.1682 4.41667 11.2497 4.45833C11.3312 4.5 11.4128 4.58333 11.4535 4.66667C11.4943 4.75 11.535 4.83333 11.535 4.91667C11.535 5.04167 11.4943 5.125 11.4535 5.20833C11.4128 5.29167 11.3312 5.33333 11.209 5.375C11.3312 5.375 11.4128 5.45833 11.4943 5.54167C11.5758 5.625 11.6166 5.70833 11.6166 5.83333C11.6166 5.95833 11.5758 6.04167 11.535 6.125C11.4943 6.20833 11.4128 6.29167 11.2905 6.33333C11.0867 6.45833 10.9644 6.45833 10.8421 6.45833Z" fill="white"/>
8
+ <path d="M12.5132 6.45837C12.3502 6.45837 12.2279 6.41671 12.1464 6.33337C12.0649 6.25004 11.9834 6.12504 11.9018 6.00004C11.8611 5.83337 11.8203 5.66671 11.8203 5.45837C11.8203 5.25004 11.8611 5.08337 11.9018 4.91671C11.9426 4.75004 12.0241 4.66671 12.1464 4.58337C12.2687 4.50004 12.391 4.45837 12.5132 4.45837C12.6763 4.45837 12.7986 4.50004 12.8801 4.58337C13.0024 4.66671 13.0431 4.79171 13.1247 4.91671C13.1654 5.08337 13.2062 5.25004 13.2062 5.45837C13.2062 5.66671 13.1654 5.83337 13.1247 6.00004C13.0839 6.16671 13.0024 6.25004 12.8801 6.33337C12.7986 6.41671 12.6763 6.45837 12.5132 6.45837ZM12.5132 6.20837C12.6355 6.20837 12.7578 6.12504 12.7986 6.00004C12.8801 5.87504 12.9209 5.70837 12.9209 5.45837C12.9209 5.29171 12.9209 5.16671 12.8801 5.04171C12.8393 4.91671 12.7986 4.83337 12.7578 4.79171C12.7171 4.75004 12.6355 4.70837 12.554 4.70837C12.4317 4.70837 12.3094 4.79171 12.2687 4.91671C12.1872 5.04171 12.1464 5.20837 12.1464 5.45837C12.1464 5.62504 12.1464 5.75004 12.1872 5.87504C12.2279 6.00004 12.2687 6.08337 12.3094 6.12504C12.3502 6.20837 12.4317 6.20837 12.5132 6.20837Z" fill="white"/>
9
+ <path d="M14.837 6.45829H14.2256V4.54163H14.837C15.0408 4.54163 15.1631 4.58329 15.3261 4.66663C15.4484 4.74996 15.5707 4.83329 15.6115 4.99996C15.693 5.12496 15.7337 5.33329 15.7337 5.49996C15.7337 5.70829 15.693 5.87496 15.6115 5.99996C15.5299 6.12496 15.4484 6.24996 15.2854 6.33329C15.2038 6.41663 15.0408 6.45829 14.837 6.45829ZM14.5109 6.16663H14.837C15 6.16663 15.0816 6.12496 15.2038 6.08329C15.2854 6.04163 15.3669 5.95829 15.4076 5.83329C15.4484 5.70829 15.4892 5.58329 15.4892 5.45829C15.4892 5.29163 15.4484 5.16663 15.4076 5.08329C15.3669 4.95829 15.2854 4.91663 15.2038 4.83329C15.1223 4.79163 15 4.74996 14.8778 4.74996H14.5517V6.16663H14.5109Z" fill="white"/>
10
+ <path d="M16.5087 6.45846C16.4271 6.45846 16.3456 6.45846 16.2641 6.41679C16.1826 6.37512 16.1418 6.33346 16.1011 6.25012C16.0603 6.16679 16.0195 6.12512 16.0195 6.00012C16.0195 5.91679 16.0195 5.83346 16.0603 5.79179C16.1011 5.75012 16.1418 5.70846 16.1826 5.66679C16.2233 5.62512 16.3049 5.62512 16.3456 5.58346C16.4271 5.58346 16.4679 5.54179 16.5494 5.54179C16.6309 5.54179 16.7125 5.54179 16.7532 5.50012C16.794 5.50012 16.8347 5.50012 16.8755 5.45846C16.9163 5.45846 16.9163 5.41679 16.9163 5.37512C16.9163 5.29179 16.8755 5.20846 16.8347 5.16679C16.794 5.12512 16.7125 5.08346 16.6309 5.08346C16.5494 5.08346 16.4679 5.12512 16.4271 5.16679C16.3864 5.20846 16.3456 5.25012 16.3049 5.29179L16.0603 5.25012C16.1011 5.16679 16.1418 5.08346 16.1826 5.04179C16.2233 5.00012 16.3049 4.95846 16.3864 4.91679C16.4679 4.87512 16.5494 4.87512 16.6309 4.87512C16.6717 4.87512 16.7532 4.87512 16.794 4.87512C16.8755 4.87512 16.9163 4.91679 16.957 4.95846C16.9978 5.00012 17.0386 5.04179 17.0793 5.12512C17.1201 5.20846 17.1201 5.29179 17.1201 5.37512V6.33346H16.8347V6.25012C16.8347 6.29179 16.794 6.33346 16.7532 6.37512C16.7125 6.41679 16.6717 6.45846 16.6309 6.45846C16.6717 6.45846 16.5902 6.45846 16.5087 6.45846ZM16.5494 6.25012C16.6309 6.25012 16.6717 6.25012 16.7532 6.20846C16.794 6.16679 16.8347 6.12512 16.8755 6.08346C16.9163 6.04179 16.9163 6.00012 16.9163 5.91679V5.75012C16.9163 5.75012 16.8755 5.75012 16.8755 5.79179C16.8347 5.79179 16.8347 5.79179 16.794 5.83346C16.7532 5.83346 16.7125 5.83346 16.6717 5.83346C16.6309 5.83346 16.5902 5.83346 16.5902 5.83346C16.5494 5.83346 16.4679 5.83346 16.4271 5.87512C16.3864 5.87512 16.3456 5.91679 16.3049 5.95846C16.3049 5.95846 16.3049 6.00012 16.3049 6.04179C16.3049 6.12512 16.3456 6.16679 16.3864 6.20846C16.4271 6.20846 16.5087 6.25012 16.5494 6.25012Z" fill="white"/>
11
+ <path d="M17.6896 6.95833C17.6489 6.95833 17.6081 6.95833 17.5673 6.95833C17.5266 6.95833 17.5266 6.95833 17.4858 6.95833L17.5673 6.70833C17.6489 6.75 17.6896 6.75 17.7711 6.70833C17.8119 6.70833 17.8527 6.625 17.8934 6.54167L17.9342 6.45833L17.4043 5H17.6896L18.0565 6.125L18.4233 5H18.7086L18.138 6.625C18.0972 6.70833 18.0565 6.75 18.0157 6.83333C17.9749 6.875 17.9342 6.91667 17.8527 6.95833C17.8527 6.95833 17.7711 6.95833 17.6896 6.95833Z" fill="white"/>
12
+ <path d="M20.0546 5.33325L19.8101 5.37492C19.8101 5.33325 19.7693 5.29159 19.7693 5.29159C19.7285 5.24992 19.7285 5.24992 19.6878 5.20825C19.647 5.20825 19.6063 5.16659 19.5247 5.16659C19.4432 5.16659 19.3617 5.16659 19.3209 5.20825C19.2802 5.24992 19.2394 5.29159 19.2394 5.33325C19.2394 5.37492 19.2394 5.41659 19.2802 5.45825C19.3209 5.49992 19.3617 5.49992 19.4432 5.54159L19.6878 5.58325C19.8101 5.62492 19.9323 5.66659 19.9731 5.70825C20.0546 5.79159 20.0546 5.87492 20.0546 5.95825C20.0546 6.04159 20.0139 6.12492 19.9731 6.20825C19.9323 6.29159 19.8508 6.33325 19.7693 6.37492C19.6878 6.41659 19.5655 6.41659 19.484 6.41659C19.3209 6.41659 19.1986 6.37492 19.0764 6.33325C18.9948 6.24992 18.9133 6.16659 18.8726 6.04159L19.1579 5.99992C19.1579 6.08325 19.1986 6.12492 19.2802 6.16659C19.3209 6.20825 19.4024 6.20825 19.484 6.20825C19.5655 6.20825 19.647 6.20825 19.6878 6.16659C19.7285 6.12492 19.7693 6.08325 19.7693 6.04159C19.7693 5.99992 19.7693 5.95825 19.7285 5.91659C19.6878 5.87492 19.647 5.87492 19.5655 5.83325L19.3209 5.79159C19.1986 5.74992 19.0764 5.70825 19.0356 5.62492C18.9541 5.54159 18.9541 5.45825 18.9541 5.37492C18.9541 5.29159 18.9948 5.20825 19.0356 5.16659C19.0764 5.08325 19.1579 5.04159 19.2394 4.99992C19.3209 4.95825 19.4025 4.95825 19.5247 4.95825C19.6878 4.95825 19.8101 4.99992 19.8916 5.04159C19.9731 5.12492 20.0139 5.24992 20.0546 5.33325Z" fill="white"/>
13
+ <path d="M9.98625 18.375C9.98625 18.3334 9.94549 18.25 9.90472 18.2084C9.86396 18.1667 9.8232 18.125 9.78244 18.0834C9.74168 18.0417 9.70092 18.0417 9.66016 18C9.6194 18 9.53788 17.9584 9.49711 17.9584C9.37483 17.9584 9.29331 18 9.21179 18.0417C9.13027 18.0834 9.04874 18.1667 9.00798 18.2917C8.96722 18.4584 8.96722 18.5834 8.96722 18.75C8.96722 18.9167 9.00798 19.0417 9.04874 19.1667C9.08951 19.2917 9.17103 19.375 9.25255 19.4167C9.33407 19.4584 9.45635 19.5 9.53788 19.5C9.66016 19.5 9.74168 19.4584 9.8232 19.4167C9.90473 19.375 9.94549 19.3334 9.98625 19.25C10.027 19.1667 10.0678 19.0834 10.0678 18.9584H10.1493H9.6194V18.7084H10.3531V18.9167C10.3531 19.0834 10.3123 19.2084 10.2716 19.3334C10.1901 19.4584 10.1085 19.5417 9.98625 19.625C9.86396 19.7084 9.74168 19.7084 9.57864 19.7084C9.41559 19.7084 9.25255 19.6667 9.13027 19.5834C9.00798 19.5 8.8857 19.375 8.84494 19.25C8.76342 19.0834 8.72266 18.9167 8.72266 18.7084C8.72266 18.5417 8.76342 18.4167 8.80418 18.2917C8.84494 18.1667 8.8857 18.0834 8.96722 18C9.04874 17.9167 9.13027 17.8334 9.25255 17.7917C9.37483 17.75 9.45635 17.7084 9.57864 17.7084C9.66016 17.7084 9.78244 17.7084 9.86396 17.75C9.94549 17.7917 10.027 17.8334 10.1085 17.875C10.1901 17.9167 10.2308 18 10.2716 18.0834C10.3123 18.1667 10.3531 18.25 10.3531 18.3334H9.98625V18.375Z" fill="white"/>
14
+ <path d="M11.5349 19.0832V18.2499H11.8202V19.7082H11.5349V19.4582C11.4942 19.5415 11.4534 19.5832 11.3719 19.6665C11.2904 19.7082 11.2088 19.7499 11.0866 19.7499C11.005 19.7499 10.9235 19.7499 10.842 19.7082C10.7605 19.6665 10.7197 19.6249 10.6789 19.5415C10.6382 19.4582 10.6382 19.3749 10.6382 19.2499V18.3332H10.9235V19.2082C10.9235 19.2915 10.9643 19.3749 11.005 19.4582C11.0458 19.4999 11.1273 19.5415 11.2088 19.5415C11.2496 19.5415 11.3311 19.5415 11.3719 19.4999C11.4126 19.4582 11.4534 19.4165 11.4942 19.3749C11.5349 19.2499 11.5349 19.1665 11.5349 19.0832Z" fill="white"/>
15
+ <path d="M12.5946 19.7083C12.5131 19.7083 12.4316 19.7083 12.35 19.6667C12.2685 19.625 12.2278 19.5833 12.187 19.5C12.1462 19.4167 12.1055 19.375 12.1055 19.25C12.1055 19.1667 12.1055 19.0833 12.1462 19.0417C12.187 19 12.2278 18.9583 12.2685 18.9167C12.3093 18.875 12.3908 18.875 12.4316 18.8333C12.5131 18.8333 12.5538 18.7917 12.6354 18.7917C12.7169 18.7917 12.7984 18.7917 12.8392 18.75C12.8799 18.75 12.9207 18.75 12.9614 18.7083C13.0022 18.7083 13.0022 18.6667 13.0022 18.625C13.0022 18.5417 12.9614 18.4583 12.9207 18.4167C12.8799 18.375 12.7984 18.3333 12.7169 18.3333C12.6354 18.3333 12.5538 18.375 12.5131 18.4167C12.4723 18.4583 12.4316 18.5 12.3908 18.5417L12.1462 18.5C12.187 18.4167 12.2278 18.3333 12.2685 18.2917C12.3093 18.25 12.3908 18.2083 12.4723 18.1667C12.5538 18.125 12.6354 18.125 12.7169 18.125C12.7576 18.125 12.8392 18.125 12.8799 18.125C12.9614 18.125 13.0022 18.1667 13.043 18.2083C13.0837 18.25 13.1245 18.2917 13.1653 18.375C13.206 18.4583 13.206 18.5417 13.206 18.625V19.5833H13.043V19.375C13.043 19.4167 13.0022 19.4583 12.9614 19.5C12.9207 19.5417 12.8799 19.5833 12.8392 19.5833C12.7576 19.7083 12.6761 19.7083 12.5946 19.7083ZM12.6761 19.5C12.7576 19.5 12.7984 19.5 12.8799 19.4583C12.9207 19.4167 12.9614 19.375 13.0022 19.3333C13.043 19.2917 13.043 19.25 13.043 19.1667V19C13.043 19 13.0022 19 13.0022 19.0417C12.9614 19.0417 12.9614 19.0417 12.9207 19.0833C12.8799 19.0833 12.8392 19.0833 12.7984 19.0833C12.7576 19.0833 12.7169 19.0833 12.7169 19.0833C12.6761 19.0833 12.5946 19.0833 12.5538 19.125C12.5131 19.125 12.4723 19.1667 12.4316 19.2083C12.3908 19.25 12.3908 19.2917 12.3908 19.3333C12.3908 19.4167 12.4316 19.4583 12.4723 19.5C12.5131 19.5 12.5946 19.5 12.6761 19.5Z" fill="white"/>
16
+ <path d="M13.6548 19.7082V18.2499H13.9401V18.4999C13.9809 18.4165 14.0216 18.3749 14.0624 18.3332C14.1439 18.2915 14.1847 18.2499 14.2662 18.2499H14.307C14.3477 18.2499 14.3477 18.2499 14.3477 18.2499V18.4999H14.307C14.2662 18.4999 14.2662 18.4999 14.2254 18.4999C14.1439 18.4999 14.1032 18.4999 14.0624 18.5415C14.0216 18.5832 13.9809 18.6249 13.9401 18.6665C13.8994 18.7082 13.8993 18.7915 13.8993 18.8332V19.7082H13.6548Z" fill="white"/>
17
+ <path d="M15.0819 19.7083C15.0004 19.7083 14.9189 19.7083 14.8373 19.6667C14.7558 19.625 14.7151 19.5833 14.6743 19.5C14.6335 19.4167 14.5928 19.375 14.5928 19.25C14.5928 19.1667 14.5928 19.0833 14.6335 19.0417C14.6743 19 14.7151 18.9583 14.7558 18.9167C14.7966 18.875 14.8781 18.875 14.9189 18.8333C15.0004 18.8333 15.0411 18.7917 15.1227 18.7917C15.2042 18.7917 15.2857 18.7917 15.3265 18.75C15.3672 18.75 15.408 18.75 15.4488 18.7083C15.4895 18.7083 15.4895 18.6667 15.4895 18.625C15.4895 18.5417 15.4488 18.4583 15.408 18.4167C15.3672 18.375 15.2857 18.3333 15.2042 18.3333C15.1227 18.3333 15.0411 18.375 15.0004 18.4167C14.9596 18.4583 14.9189 18.5 14.8781 18.5417L14.6335 18.5C14.6743 18.4167 14.7151 18.3333 14.7558 18.2917C14.7966 18.25 14.8781 18.2083 14.9596 18.1667C15.0411 18.125 15.1227 18.125 15.2042 18.125C15.2449 18.125 15.3265 18.125 15.3672 18.125C15.4488 18.125 15.4895 18.1667 15.5303 18.2083C15.571 18.25 15.6118 18.2917 15.6526 18.375C15.6933 18.4583 15.6933 18.5417 15.6933 18.625V19.5833H15.4895V19.375C15.4895 19.4167 15.4488 19.4583 15.408 19.5C15.3672 19.5417 15.3265 19.5833 15.2857 19.5833C15.2042 19.7083 15.1634 19.7083 15.0819 19.7083ZM15.1227 19.5C15.2042 19.5 15.2449 19.5 15.3265 19.4583C15.3672 19.4167 15.408 19.375 15.4488 19.3333C15.4895 19.2917 15.4895 19.25 15.4895 19.1667V19C15.4895 19 15.4488 19 15.4488 19.0417C15.408 19.0417 15.408 19.0417 15.3672 19.0833C15.3265 19.0833 15.2857 19.0833 15.2449 19.0833C15.2042 19.0833 15.1634 19.0833 15.1634 19.0833C15.1227 19.0833 15.0411 19.0833 15.0004 19.125C14.9596 19.125 14.9189 19.1667 14.8781 19.2083C14.8373 19.25 14.8373 19.2917 14.8373 19.3333C14.8373 19.4167 14.8781 19.4583 14.9189 19.5C15.0004 19.5 15.0411 19.5 15.1227 19.5Z" fill="white"/>
18
+ <path d="M16.3859 18.8332V19.7082H16.1006V18.2499H16.3452V18.4999C16.3859 18.4165 16.4267 18.3749 16.5082 18.3332C16.5897 18.2915 16.6712 18.2499 16.7528 18.2499C16.8343 18.2499 16.9158 18.2499 16.9973 18.2915C17.0789 18.3332 17.1196 18.3749 17.1604 18.4582C17.2011 18.5415 17.2011 18.6249 17.2011 18.7499V19.6665H16.9158V18.7915C16.9158 18.6665 16.875 18.6249 16.8343 18.5415C16.7935 18.4999 16.712 18.4582 16.6305 18.4582C16.549 18.4582 16.5082 18.4582 16.4674 18.4999C16.4267 18.5415 16.3859 18.5832 16.3452 18.6249C16.4267 18.7082 16.3859 18.7499 16.3859 18.8332Z" fill="white"/>
19
+ <path d="M18.3423 18.25V18.4583H17.5679V18.25H18.3423ZM17.7717 17.9166H18.057V19.2916C18.057 19.3333 18.057 19.375 18.0978 19.4166C18.0978 19.4583 18.1385 19.4583 18.1793 19.4583C18.22 19.4583 18.22 19.4583 18.2608 19.4583C18.3016 19.4583 18.3016 19.4583 18.3016 19.4583H18.3423L18.3831 19.7083C18.3831 19.7083 18.3423 19.7083 18.3016 19.7083C18.2608 19.7083 18.22 19.7083 18.1793 19.7083C18.0978 19.7083 18.057 19.7083 17.9755 19.6666C17.894 19.625 17.8532 19.5833 17.8124 19.5416C17.7717 19.5 17.7717 19.4166 17.7717 19.3333V17.9166Z" fill="white"/>
20
+ <path d="M19.2388 19.7083C19.1166 19.7083 18.9943 19.6666 18.872 19.625C18.7905 19.5833 18.7089 19.4583 18.6274 19.375C18.5867 19.25 18.5459 19.125 18.5459 19C18.5459 18.8333 18.5867 18.7083 18.6274 18.625C18.6682 18.5 18.7497 18.4166 18.872 18.375C18.9535 18.2916 19.0758 18.2916 19.1981 18.2916C19.2796 18.2916 19.3611 18.2916 19.4426 18.3333C19.5242 18.375 19.5649 18.4166 19.6465 18.4583C19.6872 18.5 19.7687 18.5833 19.7687 18.6666C19.8095 18.75 19.8095 18.875 19.8095 19V19.0833H18.6682V18.875H19.5649C19.5649 18.7916 19.5649 18.75 19.5242 18.6666C19.4834 18.625 19.4426 18.5833 19.4019 18.5416C19.3611 18.5 19.2796 18.5 19.1981 18.5C19.1166 18.5 19.035 18.5 18.9943 18.5416C18.9535 18.5833 18.9127 18.625 18.872 18.7083C18.8312 18.75 18.8312 18.8333 18.8312 18.9166V19.0833C18.8312 19.1666 18.8312 19.25 18.872 19.3333C18.9127 19.4166 18.9535 19.4583 18.9943 19.5C19.035 19.5416 19.1166 19.5416 19.1981 19.5416C19.2388 19.5416 19.2796 19.5416 19.3611 19.5C19.4019 19.5 19.4426 19.4583 19.4834 19.4166C19.5242 19.375 19.5242 19.3333 19.5649 19.2916L19.8095 19.3333C19.7687 19.4166 19.7687 19.5 19.6872 19.5416C19.6465 19.5833 19.5649 19.625 19.4834 19.6666C19.4426 19.7083 19.3611 19.7083 19.2388 19.7083Z" fill="white"/>
21
+ <path d="M20.7466 19.7083C20.6244 19.7083 20.5021 19.6666 20.3798 19.625C20.2983 19.5833 20.2168 19.4583 20.1352 19.375C20.0945 19.25 20.0537 19.125 20.0537 19C20.0537 18.8333 20.0945 18.7083 20.1352 18.625C20.176 18.5 20.2575 18.4166 20.3798 18.375C20.4613 18.2916 20.5836 18.2916 20.7059 18.2916C20.7874 18.2916 20.8689 18.2916 20.9505 18.3333C21.032 18.375 21.0727 18.4166 21.1543 18.4583C21.195 18.5 21.2765 18.5833 21.2765 18.6666C21.3173 18.75 21.3173 18.875 21.3173 19V19.0833H20.176V18.875H21.032C21.032 18.7916 21.032 18.75 20.9912 18.6666C20.9504 18.625 20.9097 18.5833 20.8689 18.5416C20.8282 18.5 20.7466 18.5 20.6651 18.5C20.5836 18.5 20.5021 18.5 20.4613 18.5416C20.4206 18.5833 20.3798 18.625 20.339 18.7083C20.3798 18.75 20.3798 18.7916 20.3798 18.875V19.0416C20.3798 19.125 20.3798 19.2083 20.4206 19.2916C20.4613 19.375 20.5021 19.4166 20.5428 19.4583C20.5836 19.5 20.6651 19.5 20.7466 19.5C20.7874 19.5 20.8282 19.5 20.9097 19.4583C20.9504 19.4583 20.9912 19.4166 21.032 19.375C21.0727 19.3333 21.0727 19.2916 21.1135 19.25L21.3581 19.2916C21.3173 19.375 21.3173 19.4583 21.2358 19.5C21.195 19.5416 21.1135 19.5833 21.032 19.625C20.9504 19.7083 20.8689 19.7083 20.7466 19.7083Z" fill="white"/>
22
+ <defs>
23
+ <linearGradient id="paint0_linear" x1="13.4206" y1="0.621958" x2="17.1739" y2="24.6911" gradientUnits="userSpaceOnUse">
24
+ <stop stop-color="#72D0FF"/>
25
+ <stop offset="1" stop-color="#349EFA"/>
26
+ </linearGradient>
27
+ <linearGradient id="paint1_linear" x1="-3.41209" y1="12.7435" x2="13.6943" y2="12.7435" gradientUnits="userSpaceOnUse">
28
+ <stop stop-color="#9795E7"/>
29
+ <stop offset="1" stop-color="#544EFA"/>
30
+ </linearGradient>
31
+ </defs>
32
+ </svg>
assets/images/upgrade/no.svg ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M10 8.8688L7.7376 6.6056L6.6056 7.7376L8.8688 10L6.6056 12.2624L7.7376 13.3944L10 11.1312L12.2624 13.3944L13.3944 12.2624L11.1312 10L13.3944 7.7376L12.2624 6.6056L10 8.8688Z" fill="url(#paint0_linear)"/>
3
+ <circle cx="10" cy="10" r="9.5" stroke="#E71313"/>
4
+ <defs>
5
+ <linearGradient id="paint0_linear" x1="10" y1="2" x2="10" y2="18" gradientUnits="userSpaceOnUse">
6
+ <stop stop-color="#F91F1F"/>
7
+ <stop offset="1" stop-color="#DA0B0B"/>
8
+ </linearGradient>
9
+ </defs>
10
+ </svg>
assets/images/upgrade/order-ie.svg ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="70" height="70" viewBox="0 0 70 70" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
2
+ <g clip-path="url(#clip0)">
3
+ <rect width="70" height="70" rx="5" fill="url(#pattern0)"/>
4
+ <rect y="-28" width="74" height="120" fill="url(#pattern1)"/>
5
+ <rect x="-1" y="-28" width="74" height="116" fill="url(#pattern2)"/>
6
+ </g>
7
+ <defs>
8
+ <pattern id="pattern0" patternContentUnits="objectBoundingBox" width="1" height="1">
9
+ <use xlink:href="#image0" transform="scale(0.0166667)"/>
10
+ </pattern>
11
+ <pattern id="pattern1" patternContentUnits="objectBoundingBox" width="1" height="1">
12
+ <use xlink:href="#image1" transform="translate(-0.0221622) scale(0.00324324 0.002)"/>
13
+ </pattern>
14
+ <pattern id="pattern2" patternContentUnits="objectBoundingBox" width="1" height="1">
15
+ <use xlink:href="#image2" transform="translate(-0.00475676) scale(0.00313514 0.002)"/>
16
+ </pattern>
17
+ <clipPath id="clip0">
18
+ <rect width="70" height="70" rx="5" fill="white"/>
19
+ </clipPath>
20
+ <image id="image0" width="60" height="60" xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAYAAAA6/NlyAAAAAXNSR0IArs4c6QAABr9JREFUaAXtWF1sFUUU/mbubUtbKFCkaotIQgkQBAUjgagUQSJJY0BQfDDGoBA18oQJ8UEjL7z7oj7pAwk+SYLCi0rE+BMlGqJBkfgTNSGiEJDyIz/t3fH7Zna5F/rQn917ryl70t7dmT0zc77znTlzdk10sOhwA4m9gbB6qDngsc54znDO8BjzQB7SY4zQQXByhge5ZIx15AyPMUIHwckZHuSSMdaRMzwiQo2DgV6ns3+lNpxV/1lLcfgTavkyMOMMSmy6KPTrieXzQpG/rqw3/PnLmsZDdZxN82QLewSAxab45JWjfvzZYe22Ek6fdbA2GNU5GXhnBzC3m6DljVGKHKYZjZHzdKOfbMCPALCW5KJal6y2tkZ4YCFw5oJFQwE4ccbhw4PA7gMRXp5DGyPqpRGCDYtpQd5ng5d2jfibVljZWMIvASUCswWHY38Z9DzncPutwCdvxQZKdVQifuUxzmN5HeBtidGVQXSPiOFge1jV0Q5jDIoFtmnUtE6LBTNL2P+Nw8NbIjQ2hB1YHpOgT6yuoKziNlA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gW/SQ8D3B0KZwG5NPVryclDvnwTOKkS4Gr++1aQDB+d3y0O/h7H+9MVKkOlJKwzK4AcU2XWxvZX5ahoGgE/R0UXbun1IKM6j+ZLHzEixSCSkePQAwsZwlyYdInuHyP26Ymiw3WT8bINNnaJ2STo2pAVge1Q7/6sfd9qRKq1fLupld9av4JPD+yKF0CCTIbl0dlgeKsdqC26JxwHBj/AH18yWfCYdznn976uO9GQHxRV6/RdX+9MExfW490D1pvRFomxCamNzPm8YrDr1awj9YfqULMvT8RWg3sp+aPyI/yo8V6qFFkgxAfZBpLOQnJuS7ZbHqumb3o0gQ/N+PyVPtSRbnlN+1IExfR/FEQJ83/ADj/ANA//9k="/>
23
+ </defs>
24
+ </svg>
assets/images/upgrade/pre-icon.svg ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <svg width="20" height="16" viewBox="0 0 20 16" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M2.04889 1.80188L5.85389 5.14988L9.24389 0.975878C9.33881 0.859188 9.45884 0.765417 9.59503 0.701548C9.73123 0.63768 9.88007 0.605359 10.0305 0.606993C10.1809 0.608626 10.329 0.644173 10.4638 0.710986C10.5986 0.777798 10.7165 0.874154 10.8089 0.992878L14.0439 5.14888L17.9719 1.75288C18.1261 1.61979 18.3174 1.53699 18.52 1.51556C18.7226 1.49413 18.9269 1.5351 19.1056 1.63298C19.2843 1.73085 19.4288 1.88097 19.5198 2.06324C19.6108 2.24551 19.644 2.45123 19.6149 2.65288L18.1149 12.9999H1.92189L0.398888 2.69988C0.368636 2.49711 0.401433 2.28995 0.492839 2.10645C0.584245 1.92294 0.729841 1.77197 0.909909 1.67397C1.08998 1.57597 1.29581 1.53568 1.49954 1.55856C1.70327 1.58144 1.89504 1.66638 2.04889 1.80188ZM1.99989 13.9999H17.9999V14.9999C17.9999 15.2651 17.8945 15.5194 17.707 15.707C17.5195 15.8945 17.2651 15.9999 16.9999 15.9999H2.99989C2.73467 15.9999 2.48032 15.8945 2.29278 15.707C2.10525 15.5194 1.99989 15.2651 1.99989 14.9999V13.9999Z" fill="#007CBA"/>
3
+ </svg>
assets/images/upgrade/product-ie.svg ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <svg width="70" height="70" viewBox="0 0 70 70" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
2
+ <g clip-path="url(#clip0)">
3
+ <rect width="70" height="70" rx="5" fill="url(#pattern0)"/>
4
+ <rect y="-28" width="74" height="120" fill="url(#pattern1)"/>
5
+ </g>
6
+ <defs>
7
+ <pattern id="pattern0" patternContentUnits="objectBoundingBox" width="1" height="1">
8
+ <use xlink:href="#image0" transform="scale(0.0166667)"/>
9
+ </pattern>
10
+ <pattern id="pattern1" patternContentUnits="objectBoundingBox" width="1" height="1">
11
+ <use xlink:href="#image1" transform="translate(-0.0221622) scale(0.00324324 0.002)"/>
12
+ </pattern>
13
+ <clipPath id="clip0">
14
+ <rect width="70" height="70" rx="5" fill="white"/>
15
+ </clipPath>
16
+ <image id="image0" width="60" height="60" xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADwAAAA8CAYAAAA6/NlyAAAAAXNSR0IArs4c6QAABr9JREFUaAXtWF1sFUUU/mbubUtbKFCkaotIQgkQBAUjgagUQSJJY0BQfDDGoBA18oQJ8UEjL7z7oj7pAwk+SYLCi0rE+BMlGqJBkfgTNSGiEJDyIz/t3fH7Zna5F/rQn917ryl70t7dmT0zc77znTlzdk10sOhwA4m9gbB6qDngsc54znDO8BjzQB7SY4zQQXByhge5ZIx15AyPMUIHwckZHuSSMdaRMzwiQo2DgV6ns3+lNpxV/1lLcfgTavkyMOMMSmy6KPTrieXzQpG/rqw3/PnLmsZDdZxN82QLewSAxab45JWjfvzZYe22Ek6fdbA2GNU5GXhnBzC3m6DljVGKHKYZjZHzdKOfbMCPALCW5KJal6y2tkZ4YCFw5oJFQwE4ccbhw4PA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6xeDXRNve4AZ8p8EE0CCQRC1Nr6ZcWchJZLKtJgrLAcXg10Tb3oH1YTtNeYJw0/clTNgiGAlCQSIFOpfeupfeupfeupfeupfeupfeupfeupfeupfeupfeupfesMy3uICCKCigAyik8SDl/5WQCb1Q/D3pGCYTgEy8AsgFNQRYnW59Dn0OfQ59Dn0OfQ59Dn0OfQ59Dn0A2Z0g2kRH5uRYQDUzQ2AwAAAgALAFgLH+vn/9k="/>
18
+ </defs>
19
+ </svg>
assets/images/upgrade/suite-cover.svg ADDED
@@ -0,0 +1,125 @@
 
 
 
1
+ <svg width="614" height="336" viewBox="0 0 614 336" fill="none" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
2
+ <path d="M197.544 -53.7737C242.059 -123.338 224.773 -181.177 222.299 -221.16L473.642 -307.629L678.089 174.499C678.089 174.499 512.238 310.802 352.832 312.425C193.425 314.048 136.182 226.488 125.179 153.111C114.176 79.7349 153.029 15.7902 197.544 -53.7737Z" fill="#E8F2FF"/>
3
+ <path d="M291.249 6.26931C363.843 -33.1107 376.668 -92.0995 393.829 -128.