Version Description
- Fixed: Payment date update
- Fixed: Mail sending with on-hold status on import
Download this release
Release Info
Developer | webtoffee |
Plugin | Order Export & Order Import for WooCommerce |
Version | 2.0.5 |
Comparing to | |
See all releases |
Code changes from version 2.0.4 to 2.0.5
- admin/modules/export/export.php +1 -1
- admin/modules/history/history.php +4 -1
- admin/modules/import/classes/class-import-ajax.php +1 -0
- admin/modules/import/import.php +1 -1
- admin/modules/order/data/data-order-post-columns.php +2 -0
- admin/modules/order/data/data/data-wf-reserved-fields-pair.php +2 -0
- admin/modules/order/export/export.php +4 -0
- admin/modules/order/import/import.php +9 -3
- includes/class-wt-import-export-for-woo.php +1 -1
- order-import-export-for-woocommerce.php +2 -2
- readme.txt +7 -3
admin/modules/export/export.php
CHANGED
@@ -126,7 +126,7 @@ class Wt_Import_Export_For_Woo_Basic_Export
|
|
126 |
$fields['default_export_batch']=array(
|
127 |
'label'=>__("Default Export batch count"),
|
128 |
'type'=>'number',
|
129 |
-
'value' =>
|
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'),
|
126 |
$fields['default_export_batch']=array(
|
127 |
'label'=>__("Default Export batch count"),
|
128 |
'type'=>'number',
|
129 |
+
'value' =>100,
|
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'),
|
admin/modules/history/history.php
CHANGED
@@ -162,7 +162,10 @@ class Wt_Import_Export_For_Woo_Basic_History
|
|
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 */
|
162 |
include plugin_dir_path(__FILE__).'views/_log_table.php';
|
163 |
$out['html']=ob_get_clean();
|
164 |
}
|
165 |
+
}else{
|
166 |
+
$out['status']=1;
|
167 |
+
$out['html']= sprintf( __( 'Please check the Save import log is enabled under <a target = "_blank" href="%s">settings</a>' ), admin_url('admin.php?page=wt_import_export_for_woo_basic'));
|
168 |
+
}
|
169 |
}
|
170 |
}
|
171 |
}else /* raw log viewing */
|
admin/modules/import/classes/class-import-ajax.php
CHANGED
@@ -144,6 +144,7 @@ class Wt_Import_Export_For_Woo_Basic_Import_Ajax
|
|
144 |
{
|
145 |
$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
|
146 |
$file_path=$this->import_obj->get_file_path($file_name);
|
|
|
147 |
if(@move_uploaded_file($_FILES['wt_iew_import_file']['tmp_name'], $file_path))
|
148 |
{
|
149 |
$out['msg']='';
|
144 |
{
|
145 |
$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
|
146 |
$file_path=$this->import_obj->get_file_path($file_name);
|
147 |
+
// phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged
|
148 |
if(@move_uploaded_file($_FILES['wt_iew_import_file']['tmp_name'], $file_path))
|
149 |
{
|
150 |
$out['msg']='';
|
admin/modules/import/import.php
CHANGED
@@ -151,7 +151,7 @@ class Wt_Import_Export_For_Woo_Basic_Import
|
|
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.'),
|
155 |
'validation_rule'=>array('type'=>'absint'),
|
156 |
)
|
157 |
);
|
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 |
);
|
admin/modules/order/data/data-order-post-columns.php
CHANGED
@@ -8,6 +8,7 @@ return apply_filters('hf_csv_order_post_columns', array(
|
|
8 |
'order_id' => 'order_id',
|
9 |
'order_number' => 'order_number',
|
10 |
'order_date' => 'order_date',
|
|
|
11 |
'status' => 'status',
|
12 |
'shipping_total' => 'shipping_total',
|
13 |
'shipping_tax_total' => 'shipping_tax_total',
|
@@ -21,6 +22,7 @@ return apply_filters('hf_csv_order_post_columns', array(
|
|
21 |
//'refunded_total' => 'refunded_total',
|
22 |
'order_currency' => 'order_currency',
|
23 |
'payment_method' => 'payment_method',
|
|
|
24 |
'shipping_method' => 'shipping_method',
|
25 |
'customer_id' => 'customer_id',
|
26 |
'customer_user' => 'customer_user',
|
8 |
'order_id' => 'order_id',
|
9 |
'order_number' => 'order_number',
|
10 |
'order_date' => 'order_date',
|
11 |
+
'paid_date' => 'paid_date',
|
12 |
'status' => 'status',
|
13 |
'shipping_total' => 'shipping_total',
|
14 |
'shipping_tax_total' => 'shipping_tax_total',
|
22 |
//'refunded_total' => 'refunded_total',
|
23 |
'order_currency' => 'order_currency',
|
24 |
'payment_method' => 'payment_method',
|
25 |
+
'payment_method_title' => 'payment_method_title',
|
26 |
'shipping_method' => 'shipping_method',
|
27 |
'customer_id' => 'customer_id',
|
28 |
'customer_user' => 'customer_user',
|
admin/modules/order/data/data/data-wf-reserved-fields-pair.php
CHANGED
@@ -5,6 +5,7 @@ return apply_filters('woocommerce_csv_order_reserved_fields_pair',array(
|
|
5 |
'order_id' => array('title'=>'Order ID ','description'=>'Order ID '),
|
6 |
'order_number' => array('title'=>'Order Number','description'=>'Order Number'),
|
7 |
'order_date' => array('title'=>'Order Date','description'=>'Order Date', 'type' => 'date'),
|
|
|
8 |
'status' => array('title'=>'Order Status','description'=>'Order Status ( processing , pending ...) '),
|
9 |
'shipping_total' => array('title'=>'Shipping Total','description'=>'Shipping Total amount'),
|
10 |
'shipping_tax_total' => array('title'=>'Shipping Tax Total','description'=>'Shipping Tax Total'),
|
@@ -18,6 +19,7 @@ return apply_filters('woocommerce_csv_order_reserved_fields_pair',array(
|
|
18 |
//'refunded_total' => array('title'=>'refunded_total','description'=>'refunded_total'),
|
19 |
'order_currency' => array('title'=>'order_currency','description'=>'Order Currency'),
|
20 |
'payment_method' => array('title'=>'payment_method','description'=>'Payment Method'),
|
|
|
21 |
'shipping_method' => array('title'=>'shipping_method','description'=>'Shipping Method'),
|
22 |
'customer_email' => array('title'=>'customer_email','description'=>'Customer Email ( if not provided order will be created as Guest)'),
|
23 |
'customer_user' => array('title'=>'customer_user','description'=>'Customer id ( if not provided order will be created as Guest)'),
|
5 |
'order_id' => array('title'=>'Order ID ','description'=>'Order ID '),
|
6 |
'order_number' => array('title'=>'Order Number','description'=>'Order Number'),
|
7 |
'order_date' => array('title'=>'Order Date','description'=>'Order Date', 'type' => 'date'),
|
8 |
+
'paid_date' => array('title'=>'Paid Date','description'=>'Paid Date', 'type' => 'date'),
|
9 |
'status' => array('title'=>'Order Status','description'=>'Order Status ( processing , pending ...) '),
|
10 |
'shipping_total' => array('title'=>'Shipping Total','description'=>'Shipping Total amount'),
|
11 |
'shipping_tax_total' => array('title'=>'Shipping Tax Total','description'=>'Shipping Tax Total'),
|
19 |
//'refunded_total' => array('title'=>'refunded_total','description'=>'refunded_total'),
|
20 |
'order_currency' => array('title'=>'order_currency','description'=>'Order Currency'),
|
21 |
'payment_method' => array('title'=>'payment_method','description'=>'Payment Method'),
|
22 |
+
'payment_method_title' => array('title'=>'payment_method_title','description'=>'Payment Method Title'),
|
23 |
'shipping_method' => array('title'=>'shipping_method','description'=>'Shipping Method'),
|
24 |
'customer_email' => array('title'=>'customer_email','description'=>'Customer Email ( if not provided order will be created as Guest)'),
|
25 |
'customer_user' => array('title'=>'customer_user','description'=>'Customer id ( if not provided order will be created as Guest)'),
|
admin/modules/order/export/export.php
CHANGED
@@ -524,6 +524,7 @@ class Wt_Import_Export_For_Woo_Basic_Order_Export {
|
|
524 |
'order_id' => $order->id,
|
525 |
'order_number' => $order->get_order_number(),
|
526 |
'order_date' => date('Y-m-d H:i:s', strtotime(get_post($order->id)->post_date)),
|
|
|
527 |
'status' => $order->get_status(),
|
528 |
'shipping_total' => $order->get_total_shipping(),
|
529 |
'shipping_tax_total' => wc_format_decimal($order->get_shipping_tax(), 2),
|
@@ -536,6 +537,7 @@ class Wt_Import_Export_For_Woo_Basic_Order_Export {
|
|
536 |
'order_total' => wc_format_decimal($order->get_total(), 2),
|
537 |
'order_currency' => $order->get_order_currency(),
|
538 |
'payment_method' => $order->payment_method,
|
|
|
539 |
'shipping_method' => $order->get_shipping_method(),
|
540 |
'customer_id' => $order->get_user_id(),
|
541 |
'customer_user' => $order->get_user_id(),
|
@@ -575,6 +577,7 @@ class Wt_Import_Export_For_Woo_Basic_Order_Export {
|
|
575 |
'order_id' => $order->get_id(),
|
576 |
'order_number' => $order->get_order_number(),
|
577 |
'order_date' => date('Y-m-d H:i:s', strtotime(get_post($order->get_id())->post_date)),
|
|
|
578 |
'status' => $order->get_status(),
|
579 |
'shipping_total' => $order->get_total_shipping(),
|
580 |
'shipping_tax_total' => wc_format_decimal($order->get_shipping_tax(), 2),
|
@@ -587,6 +590,7 @@ class Wt_Import_Export_For_Woo_Basic_Order_Export {
|
|
587 |
'order_total' => wc_format_decimal($order->get_total(), 2),
|
588 |
'order_currency' => $order->get_currency(),
|
589 |
'payment_method' => $order->get_payment_method(),
|
|
|
590 |
'shipping_method' => $order->get_shipping_method(),
|
591 |
'customer_id' => $order->get_user_id(),
|
592 |
'customer_user' => $order->get_user_id(),
|
524 |
'order_id' => $order->id,
|
525 |
'order_number' => $order->get_order_number(),
|
526 |
'order_date' => date('Y-m-d H:i:s', strtotime(get_post($order->id)->post_date)),
|
527 |
+
'paid_date' => date('Y-m-d H:i:s', get_post_meta($order->id, '_date_paid')),
|
528 |
'status' => $order->get_status(),
|
529 |
'shipping_total' => $order->get_total_shipping(),
|
530 |
'shipping_tax_total' => wc_format_decimal($order->get_shipping_tax(), 2),
|
537 |
'order_total' => wc_format_decimal($order->get_total(), 2),
|
538 |
'order_currency' => $order->get_order_currency(),
|
539 |
'payment_method' => $order->payment_method,
|
540 |
+
'payment_method' => $order->payment_method_title,
|
541 |
'shipping_method' => $order->get_shipping_method(),
|
542 |
'customer_id' => $order->get_user_id(),
|
543 |
'customer_user' => $order->get_user_id(),
|
577 |
'order_id' => $order->get_id(),
|
578 |
'order_number' => $order->get_order_number(),
|
579 |
'order_date' => date('Y-m-d H:i:s', strtotime(get_post($order->get_id())->post_date)),
|
580 |
+
'paid_date' => date('Y-m-d H:i:s', strtotime($order->get_date_paid())),
|
581 |
'status' => $order->get_status(),
|
582 |
'shipping_total' => $order->get_total_shipping(),
|
583 |
'shipping_tax_total' => wc_format_decimal($order->get_shipping_tax(), 2),
|
590 |
'order_total' => wc_format_decimal($order->get_total(), 2),
|
591 |
'order_currency' => $order->get_currency(),
|
592 |
'payment_method' => $order->get_payment_method(),
|
593 |
+
'payment_method_title' => $order->get_payment_method_title(),
|
594 |
'shipping_method' => $order->get_shipping_method(),
|
595 |
'customer_id' => $order->get_user_id(),
|
596 |
'customer_user' => $order->get_user_id(),
|
admin/modules/order/import/import.php
CHANGED
@@ -192,12 +192,16 @@ class Wt_Import_Export_For_Woo_Basic_Order_Import {
|
|
192 |
continue;
|
193 |
}
|
194 |
|
|
|
|
|
|
|
|
|
195 |
|
196 |
-
|
197 |
-
if ( 'date_created' == $column || 'post_date' == $column || '_paid_date' == $column || 'order_date' == $column) {
|
198 |
$date = $this->wt_parse_date_field($value,$column);
|
199 |
$this->item_data['date_created'] = date('Y-m-d H:i:s', $date);
|
200 |
-
|
|
|
201 |
continue;
|
202 |
}
|
203 |
|
@@ -1925,6 +1929,8 @@ class Wt_Import_Export_For_Woo_Basic_Order_Import {
|
|
1925 |
// Processing order emails
|
1926 |
remove_action( 'woocommerce_order_status_pending_to_processing_notification', array( $email_class->emails['WC_Email_Customer_Processing_Order'], 'trigger' ) );
|
1927 |
remove_action( 'woocommerce_order_status_pending_to_on-hold_notification', array( $email_class->emails['WC_Email_Customer_Processing_Order'], 'trigger' ) );
|
|
|
|
|
1928 |
|
1929 |
// Completed order emails
|
1930 |
remove_action( 'woocommerce_order_status_completed_notification', array( $email_class->emails['WC_Email_Customer_Completed_Order'], 'trigger' ) );
|
192 |
continue;
|
193 |
}
|
194 |
|
195 |
+
if ('_payment_method_title' == $column || 'payment_method_title' == $column) {
|
196 |
+
$this->item_data['payment_method_title'] = $value;
|
197 |
+
continue;
|
198 |
+
}
|
199 |
|
200 |
+
if ( 'date_created' == $column || 'post_date' == $column || '_paid_date' == $column || 'paid_date' == $column || 'order_date' == $column) {
|
|
|
201 |
$date = $this->wt_parse_date_field($value,$column);
|
202 |
$this->item_data['date_created'] = date('Y-m-d H:i:s', $date);
|
203 |
+
if('_paid_date' == $column || 'paid_date' == $column)
|
204 |
+
$this->item_data['date_paid'] = date('Y-m-d H:i:s', $date);
|
205 |
continue;
|
206 |
}
|
207 |
|
1929 |
// Processing order emails
|
1930 |
remove_action( 'woocommerce_order_status_pending_to_processing_notification', array( $email_class->emails['WC_Email_Customer_Processing_Order'], 'trigger' ) );
|
1931 |
remove_action( 'woocommerce_order_status_pending_to_on-hold_notification', array( $email_class->emails['WC_Email_Customer_Processing_Order'], 'trigger' ) );
|
1932 |
+
remove_action( 'woocommerce_order_status_pending_to_on-hold_notification', array( $email_class->emails['WC_Email_Customer_On_Hold_Order'], 'trigger' ) );
|
1933 |
+
remove_action( 'woocommerce_order_status_processing_to_on-hold_notification', array( $email_class->emails['WC_Email_Customer_On_Hold_Order'], 'trigger' ) );
|
1934 |
|
1935 |
// Completed order emails
|
1936 |
remove_action( 'woocommerce_order_status_completed_notification', array( $email_class->emails['WC_Email_Customer_Completed_Order'], 'trigger' ) );
|
includes/class-wt-import-export-for-woo.php
CHANGED
@@ -80,7 +80,7 @@ class Wt_Import_Export_For_Woo_Basic {
|
|
80 |
if ( defined( 'WT_O_IEW_VERSION' ) ) {
|
81 |
$this->version = WT_O_IEW_VERSION;
|
82 |
} else {
|
83 |
-
$this->version = '2.0.
|
84 |
}
|
85 |
$this->plugin_name = 'wt-import-export-for-woo-basic';
|
86 |
|
80 |
if ( defined( 'WT_O_IEW_VERSION' ) ) {
|
81 |
$this->version = WT_O_IEW_VERSION;
|
82 |
} else {
|
83 |
+
$this->version = '2.0.5';
|
84 |
}
|
85 |
$this->plugin_name = 'wt-import-export-for-woo-basic';
|
86 |
|
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: 2.0.
|
10 |
Text Domain: order-import-export-for-woocommerce
|
11 |
WC tested up to: 5.3.0
|
12 |
License: GPLv3
|
@@ -45,7 +45,7 @@ if ( !defined( 'WT_IEW_DEBUG_BASIC_TROUBLESHOOT' ) ) {
|
|
45 |
* Start at version 1.0.0 and use SemVer - https://semver.org
|
46 |
* Rename this for your plugin and update it as you release new versions.
|
47 |
*/
|
48 |
-
define( 'WT_O_IEW_VERSION', '2.0.
|
49 |
|
50 |
/**
|
51 |
* The code that runs during plugin activation.
|
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: 2.0.5
|
10 |
Text Domain: order-import-export-for-woocommerce
|
11 |
WC tested up to: 5.3.0
|
12 |
License: GPLv3
|
45 |
* Start at version 1.0.0 and use SemVer - https://semver.org
|
46 |
* Rename this for your plugin and update it as you release new versions.
|
47 |
*/
|
48 |
+
define( 'WT_O_IEW_VERSION', '2.0.5' );
|
49 |
|
50 |
/**
|
51 |
* The code that runs during plugin activation.
|
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.7
|
7 |
Requires PHP: 5.6
|
8 |
-
Stable tag: 2.0.
|
9 |
License: GPLv3
|
10 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
11 |
|
@@ -213,6 +213,9 @@ Yes.
|
|
213 |
|
214 |
== Changelog ==
|
215 |
|
|
|
|
|
|
|
216 |
= 2.0.4 =
|
217 |
* Text corrections and batch count defaulted to 10
|
218 |
= 2.0.3 =
|
@@ -432,5 +435,6 @@ Yes.
|
|
432 |
|
433 |
== Upgrade Notice ==
|
434 |
|
435 |
-
= 2.0.
|
436 |
-
*
|
|
5 |
Requires at least: 3.0.1
|
6 |
Tested up to: 5.7
|
7 |
Requires PHP: 5.6
|
8 |
+
Stable tag: 2.0.5
|
9 |
License: GPLv3
|
10 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
11 |
|
213 |
|
214 |
== Changelog ==
|
215 |
|
216 |
+
= 2.0.5 =
|
217 |
+
* Fixed: Payment date update
|
218 |
+
* Fixed: Mail sending with on-hold status on import
|
219 |
= 2.0.4 =
|
220 |
* Text corrections and batch count defaulted to 10
|
221 |
= 2.0.3 =
|
435 |
|
436 |
== Upgrade Notice ==
|
437 |
|
438 |
+
= 2.0.5 =
|
439 |
+
* Fixed: Payment date update
|
440 |
+
* Fixed: Mail sending with on-hold status on import
|