File: /home/royaltuning/public_html/public/wp-content/plugins/easysales/Changelog.md
# Changelog
## v1.1.89
- Fixed issue with undefined getOrderDetails method
## v1.1.88
- Fixed issue with undefined getOrderDetails method
## v1.1.87
- Retrieve Apaczka locker id from order
## v1.1.86
- Retrieve FanBox locker id from order
## v1.1.85
- Fix product private option
## v1.1.84
- Get product EAN from Global Unique ID if exists
## v1.1.83
- Fix default value for EAN option
## v1.1.82
- EAN options for products
## v1.1.81
- Retrieve InPost courier locker id from order
## v1.1.80
- Remove processing status from mapping settings, since it is reserved for easySales process groups.
## v1.1.79
- Send pending/on-hold orders as new to easySales
## v1.1.78
- Fix warnings from wp_get_attachment_image_src
## v1.1.77
- Increase products limit per page from 100 to 500
## v1.1.76
- Fix fetching orders on a longer period of time
## v1.1.75
- Added option to select for what country to use the tax rate
## v1.1.74
- Shipping address phone fix
## v1.1.73
- Retrieve delegate information
## v1.1.72
- Fix hooks inconsistency
## v1.1.71
- SameDay new plugin compatibility v2.
## v1.1.70
- SameDay new plugin compatibility v1.
## v1.1.69
- Fixed an issue where products disappear from ATUM bundles when stock updates.
## v1.1.68
- Product brand term fix. Order product tax divide by 0 fix.
## v1.1.67
- Product brand & ean fix
## v1.1.66
- Product variation sizes fix
## v1.1.65
- Atum Inventory Management - variable product
## v1.1.64
- Plugin compatibility with Atum Inventory Management plugin
## v1.1.63
- Add API option to fetch trash products
## v1.1.62
- Added original payment gateway as separate field.
## v1.1.61
- Added a new select option to choose order tax calculation method
## v1.1.60
- Added compatibility with curiero module for Innoship lockers
## v1.1.59
- Fetch cash on delivery orders with payment status - unpaid
## v1.1.58
- Fallback to main product ID, if SKU is missing, when fetching variations
## v1.1.57
- Retrieve Speedy offices
## v1.1.56
- Retrieve Foxpost lockers
## v1.1.55
- Fix payment status type definition
## v1.1.54
- Added payment status and original status
## v1.1.53
- Added compatibility with curiero module for PF PJ
## v1.1.52
- Multisite compatibility for disabled network woocommerce
## v1.1.51
- Multisite compatibility
-
## v1.1.50
- Added option to update prices for products
## v1.1.49
- Added support for Fan Courier Lockers
## v1.1.48
- Fix issue with fetching private products
## v1.1.47
- Added compatibility with module GLS Shipping pentru WooCommerce
## v1.1.46
- Updated get Sameday locker id
## v1.1.45
- Added tax_number as metadata to extract Company identification number
## v1.1.44
- Added WPBakery plugin shortcodes compatibility
## v1.1.43
- Adapt Order Transformer for new WooCommerce version when fetching CurieRO Locker IDs
## v1.1.42
- Prioritize SmartBill plugin post meta fields in orders for juridical information
## v1.1.41
- CurieRO Sameday Locker compatibility
## v1.1.40
- Filtered product empty characteristic values
## v1.1.39
- Fix issue with dimensions when empty string
## v1.1.38
- Fix query issue with old SameDay module
## v1.1.37
- Fix issue checking if shipping method is locker
## v1.1.36
- Fix issue with saving fetch private products option
## v1.1.35
- Added fetch private products option
- Added compatibility with Sequential Order Numbers for WooCommerce
- Fix issue when fetching single parent product and variation
## v1.1.34
- Added is_vat_exempt meta field compatibility
## v1.1.33
- Compatibility with WooCommerce High Performance Order Storage (HPOS)
## v1.1.32
- Map card_locker payment method to cash on delivery ES
## v1.1.31
- Skip order products with 0 quantity
## v1.1.30
- Send original payment method name to easySales
## v1.1.29
- Added compatibility with Additional Variation Images Gallery for WooCommerce
- Fixed minor issue when requesting single product (only used for debugging)
- Added compatibility with new easySales SameDay Advanced locker picker
## v1.1.28
- Fixed issue with trying to access array offset on value of type null on ProductTransformer.php line 489
## v1.1.27
- Add fallback for when order item tax is calculated based on customer shipping address
## v1.1.25
- Add compatibility with new Sameday module for lockers
## v1.1.24
- Get tax from the order item
## v1.1.23
- Mark DPD cod orders as COD when they
## v1.1.22
- Fetch variation weight
## v1.1.21
- Remove retrieve county name by postal code logic.
## v1.1.20
- Add filters for modifying order / product data that is being transmitted to easySales. More information below.
- Update module settings section and only display current woocommerce statuses
- Add new settings to allow update of custom order status when order is finalized / cancelled from easySales.
### es_product_info_transform
Example:
```php
add_filter('es_product_info_transform', 'transformProduct', 10, 4);
/**
*
* Change SKU of product before being sent to easySales
*
* @param array $transformedProduct easySales API format array
* @param string $type object that is being changed; can have the following values: product, price, stock
* @param $product - the main woocommerce product
* @param $variation - product variation; this parameter will not exist for woocommerce simple products
* @return array
*/
function transformProduct($transformedProduct, $type, $product, $variation = null) {
if ($type === 'product') {
if ($variation) {
$transformedProduct['sku'] = 'es-f-variation';
} else {
$transformedProduct['sku'] = 'es-f-simple';
}
} else if ($type === 'stock') {
if ($variation) {
$transformedProduct['sku'] = 'es-s-variation';
} else {
$transformedProduct['sku'] = 'es-s-simple';
}
} else if ($type === 'price') {
if ($variation) {
$transformedProduct['sku'] = 'es-p-variation';
} else {
$transformedProduct['sku'] = 'es-p-simple';
}
}
return $transformed;
}
```
### es_order_info_transform
Example:
```php
add_filter('es_order_info_transform', 'transformProduct', 10, 4);
/**
*
* Change Customer note before being sent to easySales
*
* @param array $transformedOrder easySales API format array
* @param $product - the main woocommerce product
* @param $variation - product variation; this parameter will not exist for woocommerce simple products
* @return array
*/
function transformOrder($transformedOrder, $order) {
if ($order->get_id() === 123) {
$transformedOrder['observations'] = 'Changed observation';
}
return $transformedOrder;
}
```
## v1.1.12
- Added order status mapping from settings page
## v1.1.11
- Add new methods: getProductPrices and getProductStocks
## v1.1.10
- Fixed an issue when Order Discount Total is 0, but Order Discount Tax is not.
## v1.1.9
- Added new status mapping for custom status "livrata"
## v1.1.8
- Add filter for invoice order series (es_invoice_series: Receives 2 parameters - default invoice series from es plugin settings and order)
- Return to ES currency for orders
## v1.1.7
- Add compatibility with VidaXL dropshipping plugin
## v1.1.6
- Fix sometimes missing attributes from variation name
## v1.1.5
- Add support for R-Create reusable packages
## v1.1.4
- Add option to calculate county by postal code, if county is missing.
## v1.1.3
- Fix issue when fee/voucher tax is 0
## v1.1.2
- Add fallback option for vouchers, when discounts are created but not properly saved in Woocommerce coupons
## v1.1.1
- Update the way variation name is generated
## v1.1.0
- Prepare for retrieving product dimensions and weight
- send discounts and vouchers separately in order to be available in ES
- retrieve fees with total value less than 0 as discounts
## v1.0.19
- Refactor the way we retrieve tax rate for order products
## v1.0.18
- Check if taxes are disabled globally when fetching orders/products
## v1.0.17
- fix order products total price
## v1.0.16
- support for order product tax_rate when tax is calculated on delivery
## v1.0.15
- support for product tax_rate when tax is calculated on delivery
## v1.0.14
- decode html special chars for characteristics, brand and warehouse location
## v1.0.13
- Change text for Default Brand in module settings
- Fetch Shipping method name for orders