Order Export & Order Import for WooCommerce - Version 1.6.9

Version Description

  • [Improvement] Coupons expiry date import and export.
Download this release

Release Info

Developer webtoffee
Plugin Icon 128x128 Order Export & Order Import for WooCommerce
Version 1.6.9
Comparing to
See all releases

Code changes from version 1.6.8 to 1.6.9

includes/exporter/class-wf-cpnimpexpcsv-exporter.php CHANGED
@@ -64,6 +64,9 @@ class WF_CpnImpExpCsv_Exporter {
64
  } elseif (isset($product->$column) && !is_array($product->$column)) {
65
  if ($column === 'post_title') {
66
  $row[] = sanitize_text_field($product->$column);
 
 
 
67
  } else {
68
  $row[] = self::format_data($product->$column);
69
  }
64
  } elseif (isset($product->$column) && !is_array($product->$column)) {
65
  if ($column === 'post_title') {
66
  $row[] = sanitize_text_field($product->$column);
67
+ }elseif($column =='date_expires'){
68
+ $row[] = !empty($product->$column)?date("Y-m-d",$product->$column): '' ;
69
+
70
  } else {
71
  $row[] = self::format_data($product->$column);
72
  }
includes/exporter/data/data-wf-post-columns-coupon.php CHANGED
@@ -21,7 +21,7 @@ return apply_filters('coupon_csv_coupon_post_columns', array(
21
  'usage_limit_per_user' => 'usage_limit_per_user',
22
  'usage_count' => 'usage_count',
23
  'limit_usage_to_x_items' => 'limit_usage_to_x_items',
24
- 'expiry_date' => 'expiry_date',
25
  'date_expires' => 'date_expires',
26
  'free_shipping' => 'free_shipping',
27
  'exclude_sale_items' => 'exclude_sale_items',
21
  'usage_limit_per_user' => 'usage_limit_per_user',
22
  'usage_count' => 'usage_count',
23
  'limit_usage_to_x_items' => 'limit_usage_to_x_items',
24
+ //'expiry_date' => 'expiry_date',
25
  'date_expires' => 'date_expires',
26
  'free_shipping' => 'free_shipping',
27
  'exclude_sale_items' => 'exclude_sale_items',
includes/importer/class-wf-csv-parser-coupon.php CHANGED
@@ -90,6 +90,12 @@ class WF_CSV_Parser_Coupon {
90
  $this->post_defaults['post_type'] = 'shop_coupon';
91
  $post_id = ( ! empty( $item['id'] ) ) ? $item['id'] : 0;
92
  $post_id = ( ! empty( $item['post_id'] ) ) ? $item['post_id'] : $post_id;
 
 
 
 
 
 
93
  if ( $merging ) {
94
  $coupon['merging'] = true;
95
  $WF_CSV_Coupon_Import->hf_coupon_log_data_change( 'coupon-csv-import', sprintf( __('> Row %s - preparing for merge.', 'order-import-export-for-woocommerce'), $this->row ) );
90
  $this->post_defaults['post_type'] = 'shop_coupon';
91
  $post_id = ( ! empty( $item['id'] ) ) ? $item['id'] : 0;
92
  $post_id = ( ! empty( $item['post_id'] ) ) ? $item['post_id'] : $post_id;
93
+ if (!empty($item['date_expires'])) {
94
+ $item['expiry_date'] = $item['date_expires'];
95
+ if (false === ( $item['date_expires'] = strtotime($item['date_expires']) )) {
96
+ $WF_CSV_Coupon_Import->hf_coupon_log_data_change('coupon-csv-import', __('> > Invalid date_expires format', 'order-import-export-for-woocommerce'));
97
+ }
98
+ }
99
  if ( $merging ) {
100
  $coupon['merging'] = true;
101
  $WF_CSV_Coupon_Import->hf_coupon_log_data_change( 'coupon-csv-import', sprintf( __('> Row %s - preparing for merge.', 'order-import-export-for-woocommerce'), $this->row ) );
order-import-export-for-woocommerce.php CHANGED
@@ -6,7 +6,7 @@ Plugin URI: https://wordpress.org/plugins/order-import-export-for-woocommerce/
6
  Description: Export and Import Order detail including line items, From and To your WooCommerce Store.
7
  Author: WebToffee
8
  Author URI: https://www.webtoffee.com/product/woocommerce-order-coupon-subscription-export-import/
9
- Version: 1.6.8
10
  Text Domain: order-import-export-for-woocommerce
11
  WC tested up to: 4.5.2
12
  License: GPLv3
@@ -24,7 +24,7 @@ define("WF_CPN_IMP_EXP_ID", "wf_cpn_imp_exp");
24
  define("wf_coupon_csv_im_ex", "wf_coupon_csv_im_ex");
25
 
26
  if (!defined('WF_ORDERIMPEXP_CURRENT_VERSION')) {
27
- define("WF_ORDERIMPEXP_CURRENT_VERSION", "1.6.8");
28
  }
29
 
30
  /**
6
  Description: Export and Import Order detail including line items, From and To your WooCommerce Store.
7
  Author: WebToffee
8
  Author URI: https://www.webtoffee.com/product/woocommerce-order-coupon-subscription-export-import/
9
+ Version: 1.6.9
10
  Text Domain: order-import-export-for-woocommerce
11
  WC tested up to: 4.5.2
12
  License: GPLv3
24
  define("wf_coupon_csv_im_ex", "wf_coupon_csv_im_ex");
25
 
26
  if (!defined('WF_ORDERIMPEXP_CURRENT_VERSION')) {
27
+ define("WF_ORDERIMPEXP_CURRENT_VERSION", "1.6.9");
28
  }
29
 
30
  /**
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: order export, order import, woocommerce export orders, woocommerce import
5
  Requires at least: 3.0.1
6
  Tested up to: 5.5
7
  Requires PHP: 5.6
8
- Stable tag: 1.6.8
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
 
@@ -118,6 +118,8 @@ By default, admin and store manager are given access to export orders from your
118
 
119
  == Changelog ==
120
 
 
 
121
  = 1.6.8 =
122
  * Tested OK with WC 4.5.2
123
  * [Improvement] import date format.
@@ -302,6 +304,5 @@ By default, admin and store manager are given access to export orders from your
302
 
303
  == Upgrade Notice ==
304
 
305
- = 1.6.8 =
306
- * Tested OK with WC 4.5.2
307
- * [Improvement] import date format.
5
  Requires at least: 3.0.1
6
  Tested up to: 5.5
7
  Requires PHP: 5.6
8
+ Stable tag: 1.6.9
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
 
118
 
119
  == Changelog ==
120
 
121
+ = 1.6.9 =
122
+ * [Improvement] Coupons expiry date import and export.
123
  = 1.6.8 =
124
  * Tested OK with WC 4.5.2
125
  * [Improvement] import date format.
304
 
305
  == Upgrade Notice ==
306
 
307
+ = 1.6.9 =
308
+ * [Improvement] Coupons expiry date import and export.