Changeset 2938705 for users-customers-import-export-for-wp-woocommerce
- Timestamp:
- 07/14/2023 11:32:47 AM (22 months ago)
- Location:
- users-customers-import-export-for-wp-woocommerce
- Files:
-
- 197 added
- 8 edited
-
tags/2.4.2 (added)
-
tags/2.4.2/admin (added)
-
tags/2.4.2/admin/class-wt-import-export-for-woo-admin.php (added)
-
tags/2.4.2/admin/classes (added)
-
tags/2.4.2/admin/classes/class-csvreader.php (added)
-
tags/2.4.2/admin/classes/class-csvwriter.php (added)
-
tags/2.4.2/admin/classes/class-log.php (added)
-
tags/2.4.2/admin/classes/class-logreader.php (added)
-
tags/2.4.2/admin/classes/class-logwriter.php (added)
-
tags/2.4.2/admin/css (added)
-
tags/2.4.2/admin/css/images (added)
-
tags/2.4.2/admin/css/images/ui-bg_flat_0_aaaaaa_40x100.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_flat_75_ffffff_40x100.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_glass_55_fbf9ee_1x400.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_glass_65_ffffff_1x400.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_glass_75_dadada_1x400.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_glass_75_e6e6e6_1x400.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_glass_95_fef1ec_1x400.png (added)
-
tags/2.4.2/admin/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png (added)
-
tags/2.4.2/admin/css/images/ui-icons_222222_256x240.png (added)
-
tags/2.4.2/admin/css/images/ui-icons_2e83ff_256x240.png (added)
-
tags/2.4.2/admin/css/images/ui-icons_454545_256x240.png (added)
-
tags/2.4.2/admin/css/images/ui-icons_888888_256x240.png (added)
-
tags/2.4.2/admin/css/images/ui-icons_cd0a0a_256x240.png (added)
-
tags/2.4.2/admin/css/jquery-ui.css (added)
-
tags/2.4.2/admin/css/select2.css (added)
-
tags/2.4.2/admin/css/wt-import-export-for-woo-admin.css (added)
-
tags/2.4.2/admin/index.php (added)
-
tags/2.4.2/admin/js (added)
-
tags/2.4.2/admin/js/dropzone.min.js (added)
-
tags/2.4.2/admin/js/select2.js (added)
-
tags/2.4.2/admin/js/tiptip.js (added)
-
tags/2.4.2/admin/js/wt-import-export-for-woo-admin.js (added)
-
tags/2.4.2/admin/modules (added)
-
tags/2.4.2/admin/modules/export (added)
-
tags/2.4.2/admin/modules/export/assets (added)
-
tags/2.4.2/admin/modules/export/assets/js (added)
-
tags/2.4.2/admin/modules/export/assets/js/main.js (added)
-
tags/2.4.2/admin/modules/export/classes (added)
-
tags/2.4.2/admin/modules/export/classes/class-export-ajax.php (added)
-
tags/2.4.2/admin/modules/export/export.php (added)
-
tags/2.4.2/admin/modules/export/views (added)
-
tags/2.4.2/admin/modules/export/views/_export_advanced_page.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_filter_page.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_footer.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_header.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_mapping_page.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_mapping_tr_html.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_meta_step_page.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_method_export_page.php (added)
-
tags/2.4.2/admin/modules/export/views/_export_post_type_page.php (added)
-
tags/2.4.2/admin/modules/export/views/main.php (added)
-
tags/2.4.2/admin/modules/history (added)
-
tags/2.4.2/admin/modules/history/assets (added)
-
tags/2.4.2/admin/modules/history/assets/js (added)
-
tags/2.4.2/admin/modules/history/assets/js/main.js (added)
-
tags/2.4.2/admin/modules/history/history.php (added)
-
tags/2.4.2/admin/modules/history/views (added)
-
tags/2.4.2/admin/modules/history/views/_history_list.php (added)
-
tags/2.4.2/admin/modules/history/views/_log_list.php (added)
-
tags/2.4.2/admin/modules/history/views/_log_table.php (added)
-
tags/2.4.2/admin/modules/history/views/settings.php (added)
-
tags/2.4.2/admin/modules/import (added)
-
tags/2.4.2/admin/modules/import/assets (added)
-
tags/2.4.2/admin/modules/import/assets/js (added)
-
tags/2.4.2/admin/modules/import/assets/js/main.js (added)
-
tags/2.4.2/admin/modules/import/classes (added)
-
tags/2.4.2/admin/modules/import/classes/class-import-ajax.php (added)
-
tags/2.4.2/admin/modules/import/import.php (added)
-
tags/2.4.2/admin/modules/import/views (added)
-
tags/2.4.2/admin/modules/import/views/_import_advanced_page.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_footer.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_header.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_mapping_page.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_mapping_tr_html.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_meta_step_page.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_method_import_page.php (added)
-
tags/2.4.2/admin/modules/import/views/_import_post_type_page.php (added)
-
tags/2.4.2/admin/modules/import/views/main.php (added)
-
tags/2.4.2/admin/modules/user (added)
-
tags/2.4.2/admin/modules/user/data (added)
-
tags/2.4.2/admin/modules/user/data/data (added)
-
tags/2.4.2/admin/modules/user/data/data-user-columns.php (added)
-
tags/2.4.2/admin/modules/user/data/data/data-wf-reserved-fields-pair.php (added)
-
tags/2.4.2/admin/modules/user/export (added)
-
tags/2.4.2/admin/modules/user/export/class-wt-customerimpexpcsv-basic-exporter.php (added)
-
tags/2.4.2/admin/modules/user/export/export.php (added)
-
tags/2.4.2/admin/modules/user/import (added)
-
tags/2.4.2/admin/modules/user/import/import.php (added)
-
tags/2.4.2/admin/modules/user/user.php (added)
-
tags/2.4.2/admin/partials (added)
-
tags/2.4.2/admin/partials/_form_field_generator.php (added)
-
tags/2.4.2/admin/partials/wt-import-export-for-woo-admin-display.php (added)
-
tags/2.4.2/admin/views (added)
-
tags/2.4.2/admin/views/_save_template_popup.php (added)
-
tags/2.4.2/admin/views/admin-settings-advanced.php (added)
-
tags/2.4.2/admin/views/admin-settings-debug.php (added)
-
tags/2.4.2/admin/views/admin-settings-help.php (added)
-
tags/2.4.2/admin/views/admin-settings-marketing.php (added)
-
tags/2.4.2/admin/views/admin-settings-other-solutions.php (added)
-
tags/2.4.2/admin/views/admin-settings-pre-saved-templates.php (added)
-
tags/2.4.2/admin/views/admin-settings-save-button.php (added)
-
tags/2.4.2/admin/views/market.php (added)
-
tags/2.4.2/assets (added)
-
tags/2.4.2/assets/images (added)
-
tags/2.4.2/assets/images/documentation.png (added)
-
tags/2.4.2/assets/images/drag_icon.png (added)
-
tags/2.4.2/assets/images/gopro (added)
-
tags/2.4.2/assets/images/gopro/blue-crown.svg (added)
-
tags/2.4.2/assets/images/gopro/money-back.svg (added)
-
tags/2.4.2/assets/images/gopro/new_flag.svg (added)
-
tags/2.4.2/assets/images/gopro/order-ie.svg (added)
-
tags/2.4.2/assets/images/gopro/product-ie.svg (added)
-
tags/2.4.2/assets/images/gopro/suite.svg (added)
-
tags/2.4.2/assets/images/gopro/support.svg (added)
-
tags/2.4.2/assets/images/gopro/thumbnail.svg (added)
-
tags/2.4.2/assets/images/gopro/tick.svg (added)
-
tags/2.4.2/assets/images/gopro/user-ie.svg (added)
-
tags/2.4.2/assets/images/gopro/white-crown.svg (added)
-
tags/2.4.2/assets/images/loading.gif (added)
-
tags/2.4.2/assets/images/other_solutions (added)
-
tags/2.4.2/assets/images/other_solutions/Sequential-order-number-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/WordPress-backup-and-migration-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/bestsellers_plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/display-discounts.png (added)
-
tags/2.4.2/assets/images/other_solutions/fbt_plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/gdpr-cookie-concent-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/giftcards_plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/order-import-export-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/pdf-invoice-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/product-feed-sync.png (added)
-
tags/2.4.2/assets/images/other_solutions/product-import-export-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/promote_crown.png (added)
-
tags/2.4.2/assets/images/other_solutions/request-quote.png (added)
-
tags/2.4.2/assets/images/other_solutions/smart-coupons-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/stripe-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/subscription-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/suite-1-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/url-coupons-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/user-import-export-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt-paypal-plugin.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_al_logo.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_ipc_logo.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_pi_logo.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_pl_logo.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_qrcode_logo.png (added)
-
tags/2.4.2/assets/images/other_solutions/wt_sdd_logo.png (added)
-
tags/2.4.2/assets/images/sample-csv.png (added)
-
tags/2.4.2/assets/images/support.png (added)
-
tags/2.4.2/assets/images/upgrade (added)
-
tags/2.4.2/assets/images/upgrade/crown.svg (added)
-
tags/2.4.2/assets/images/upgrade/customer-ie.svg (added)
-
tags/2.4.2/assets/images/upgrade/money-back-badge.svg (added)
-
tags/2.4.2/assets/images/upgrade/no.svg (added)
-
tags/2.4.2/assets/images/upgrade/order-ie.svg (added)
-
tags/2.4.2/assets/images/upgrade/pre-icon.svg (added)
-
tags/2.4.2/assets/images/upgrade/product-ie.svg (added)
-
tags/2.4.2/assets/images/upgrade/suite-cover.svg (added)
-
tags/2.4.2/assets/images/upgrade/suite.svg (added)
-
tags/2.4.2/assets/images/upgrade/support.svg (added)
-
tags/2.4.2/assets/images/upgrade/wt-money-back.svg (added)
-
tags/2.4.2/assets/images/upgrade/wt-satisfaction-rating.svg (added)
-
tags/2.4.2/assets/images/upgrade/yes.svg (added)
-
tags/2.4.2/assets/images/webtoffee-logo_small.png (added)
-
tags/2.4.2/assets/images/wt-close-button.png (added)
-
tags/2.4.2/assets/images/wt-error-icon.png (added)
-
tags/2.4.2/helpers (added)
-
tags/2.4.2/helpers/class-wt-common-helper.php (added)
-
tags/2.4.2/helpers/class-wt-import-export-helper.php (added)
-
tags/2.4.2/helpers/class-wt-security-helper.php (added)
-
tags/2.4.2/includes (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo-activator.php (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo-deactivator.php (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo-i18n.php (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo-loader.php (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo-remoteadapter.php (added)
-
tags/2.4.2/includes/class-wt-import-export-for-woo.php (added)
-
tags/2.4.2/includes/class-wt-non-apache-info.php (added)
-
tags/2.4.2/includes/class-wt-userimport-uninstall-feedback.php (added)
-
tags/2.4.2/includes/index.php (added)
-
tags/2.4.2/index.php (added)
-
tags/2.4.2/languages (added)
-
tags/2.4.2/languages/users-customers-import-export-for-wp-woocommerce.pot (added)
-
tags/2.4.2/license.txt (added)
-
tags/2.4.2/public (added)
-
tags/2.4.2/public/class-wt-import-export-for-woo-public.php (added)
-
tags/2.4.2/public/css (added)
-
tags/2.4.2/public/css/wt-import-export-for-woo-public.css (added)
-
tags/2.4.2/public/index.php (added)
-
tags/2.4.2/public/js (added)
-
tags/2.4.2/public/js/wt-import-export-for-woo-public.js (added)
-
tags/2.4.2/public/partials (added)
-
tags/2.4.2/public/partials/wt-import-export-for-woo-public-display.php (added)
-
tags/2.4.2/readme.txt (added)
-
tags/2.4.2/uninstall.php (added)
-
tags/2.4.2/user_import_export_review_request.php (added)
-
tags/2.4.2/users-customers-import-export-for-wp-woocommerce.php (added)
-
trunk/admin/css/wt-import-export-for-woo-admin.css (modified) (1 diff)
-
trunk/admin/modules/user/data/data-user-columns.php (modified) (1 diff)
-
trunk/admin/modules/user/data/data/data-wf-reserved-fields-pair.php (modified) (1 diff)
-
trunk/admin/modules/user/export/export.php (modified) (2 diffs)
-
trunk/admin/modules/user/import/import.php (modified) (6 diffs)
-
trunk/includes/class-wt-import-export-for-woo.php (modified) (1 diff)
-
trunk/readme.txt (modified) (4 diffs)
-
trunk/users-customers-import-export-for-wp-woocommerce.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
users-customers-import-export-for-wp-woocommerce/trunk/admin/css/wt-import-export-for-woo-admin.css
r2884206 r2938705 306 306 /* to enable "word-break: break-all" */ 307 307 padding: 5px; 308 word-break: break-all; /* 4. */308 word-break: normal; /* 4. */ 309 309 } 310 310 -
users-customers-import-export-for-wp-woocommerce/trunk/admin/modules/user/data/data-user-columns.php
r2912763 r2938705 68 68 $columns['shipping_state'] = 'shipping_state'; 69 69 $columns['shipping_country'] = 'shipping_country'; 70 $columns['wc_last_active'] = 'wc_last_active'; 70 71 71 72 endif; -
users-customers-import-export-for-wp-woocommerce/trunk/admin/modules/user/data/data/data-wf-reserved-fields-pair.php
r2912763 r2938705 63 63 $columns['shipping_state'] = array('title'=>'Shipping state','description'=>''); 64 64 $columns['shipping_country'] = array('title'=>'Shipping country','description'=>''); 65 65 $columns['wc_last_active'] =array('title'=>'Wc last active','description'=>''); 66 66 endif; 67 67 -
users-customers-import-export-for-wp-woocommerce/trunk/admin/modules/user/export/export.php
r2912763 r2938705 177 177 global $wpdb; 178 178 $csv_columns = $this->parent_module->get_selected_column_names(); 179 179 180 180 $user = get_user_by('id', $id); 181 182 181 $customer_data = array(); 182 183 183 foreach ($csv_columns as $key => $value) { 184 184 … … 215 215 continue; 216 216 } 217 if( $key == 'last_update'){ 218 $date_in_timestamp = (!empty($user->{$key})) ? $user->{$key} : 0; 219 $customer_data[$key] = date('Y-m-d H:i:s', $date_in_timestamp); 220 continue; 221 } 222 if($key == 'wc_last_active'){ 223 $date_in_timestamp = (!empty($user->{$key})) ? $user->{$key} : 0; 224 $customer_data[$key] = date('Y-m-d', $date_in_timestamp); 225 continue; 226 } 227 217 228 218 229 $customer_data[$key] = isset($user->{$key}) ? maybe_serialize($user->{$key}) : ''; -
users-customers-import-export-for-wp-woocommerce/trunk/admin/modules/user/import/import.php
r2846895 r2938705 12 12 public $parent_module = null; 13 13 public $parsed_data = array(); 14 public $user_all_fields = array(); 15 public $user_base_fields = array(); 16 public $use_same_password = array(); 17 public $user_meta_fields = array(); 18 public $current_user = array(); 14 19 15 20 … … 33 38 public function __construct($parent_object) { 34 39 40 $this->current_user = get_current_user_id(); 35 41 $this->parent_module = $parent_object; 36 42 $this->user_all_fields = include plugin_dir_path( __FILE__).'../data/data-user-columns.php'; … … 127 133 */ 128 134 public function parse_users( $data ) { 129 135 130 136 try{ 131 137 $data = apply_filters('wt_user_importer_pre_parse_data', $data); … … 222 228 223 229 foreach ($this->user_meta_fields as $key => $value){ 230 if($key == 'wc_last_active' || $key == 'last_update'){ 231 $date = isset( $item[$key] ) ? trim($item[$key]) : "" ; 232 $item[$key] = strtotime($date); 233 } 224 234 $user_meta[] = array( 'key' => $key, 'value' => isset( $item[$key] ) ? trim($item[$key]) : "" ); 225 235 } 226 236 227 237 // the $user_details array will now contain the necessary name-value pairs for the wp_users table, and also any meta data in the 'usermeta' array 228 238 $parsed_details = array(); … … 230 240 $parsed_details['user_details'] = $user_details; 231 241 $parsed_details['user_meta'] = $user_meta; 232 233 242 return $parsed_details; 234 243 } catch (Exception $e) { … … 253 262 254 263 if ($user_id && $this->merge) { 255 $current_user = get_current_user_id();264 $current_user = $this->current_user; 256 265 if ($current_user == $user_id) { 257 $usr_msg = 'This user is currently logged in hence we cannot update.'; 258 $this->hf_log_data_change('user-csv-import', sprintf(__('> “%s”' . $usr_msg), $user_id), true); 266 $this->hf_log_data_change('user-csv-import', sprintf(__('> “%s” This user is currently logged in hence we cannot update.'), $user_id), true); 259 267 unset($post); 260 return new WP_Error( 'parse-error',sprintf(__('> “%s”' . $usr_msg), $user_id)); 261 } 268 return new WP_Error( 'parse-error',sprintf(__('> “%s” This user is currently logged in hence we cannot update.'), $user_id)); 269 } 270 $user = get_userdata($user_id); 271 $roles = $user->roles; 272 $only_update_admin_with_admin = apply_filters('wt_ier_update_admin_only_by_admin_user', true); 273 if(in_array('administrator', $roles) && $only_update_admin_with_admin ){ 274 $current_user = get_userdata($current_user); 275 $current_roles = $current_user->roles; 276 if(!in_array('administrator', $current_roles)){ 277 return new WP_Error( 'parse-error',sprintf(__('> “%s” Only a user with an Administrator role has the capability to update a user with an Administrator role.'), $user_id)); 278 } 279 } 280 262 281 $user_id = $this->hf_update_customer($user_id, $post); 263 282 } else { -
users-customers-import-export-for-wp-woocommerce/trunk/includes/class-wt-import-export-for-woo.php
r2927717 r2938705 81 81 $this->version = WT_U_IEW_VERSION; 82 82 } else { 83 $this->version = '2.4. 1';83 $this->version = '2.4.2'; 84 84 } 85 85 $this->plugin_name = 'wt-import-export-for-woo-basic'; -
users-customers-import-export-for-wp-woocommerce/trunk/readme.txt
r2927717 r2938705 6 6 Tested up to: 6.2 7 7 Requires PHP: 5.6 8 Stable tag: 2.4. 18 Stable tag: 2.4.2 9 9 License: GPLv3 10 10 License URI: http://www.gnu.org/licenses/gpl-3.0.html … … 26 26 🔸 Export specific users based on username/email - Suggests email addresses and names in export data filter fields while you type in. 27 27 🔸 Tested OK with WordPress 6.2 28 🔸 Tested OK with WooCommerce 7.8 28 🔸 Tested OK with WooCommerce 7.8.2 29 29 🔸 Tested OK with PHP 8.2 30 30 … … 206 206 == Changelog == 207 207 208 = 2.4.2 2023-07-14 = 209 * [Fix] - Admin user details are updated when importing as shop manager. 210 * [Add] - Export and Import the last activity data of users. 211 * [Compatibility] - Tested OK with WooCommerce 7.8.2 208 212 = 2.4.1 2023-06-19 = 209 213 * [Fix] – Importing custom CSV with a colon in the column heading. … … 452 456 == Upgrade Notice == 453 457 454 = 2.4. 1=455 * [Fix] – Importing custom CSV with a colon in the column heading.456 * [ Fix] – Auto delete history option does not delete import logs457 * [ Update] – Tested OK with WooCommerce 7.8458 = 2.4.2 = 459 * [Fix] - Admin user details are updated when importing as shop manager. 460 * [Add] - Export and Import the last activity data of users. 461 * [Compatibility] - Tested OK with WooCommerce 7.8.2 -
users-customers-import-export-for-wp-woocommerce/trunk/users-customers-import-export-for-wp-woocommerce.php
r2927717 r2938705 6 6 Author: WebToffee 7 7 Author URI: https://www.webtoffee.com/product/wordpress-users-woocommerce-customers-import-export/ 8 Version: 2.4. 18 Version: 2.4.2 9 9 Text Domain: users-customers-import-export-for-wp-woocommerce 10 10 Domain Path: /languages 11 WC tested up to: 7.8 11 WC tested up to: 7.8.2 12 12 Requires at least: 3.0 13 13 Requires PHP: 5.6 … … 49 49 * Rename this for your plugin and update it as you release new versions. 50 50 */ 51 define('WT_U_IEW_VERSION', '2.4. 1');51 define('WT_U_IEW_VERSION', '2.4.2'); 52 52 53 53 /**
Note: See TracChangeset
for help on using the changeset viewer.