DIY sync
WooCommerce FLOWii Connector
Zoznam action a filter hookov podporovaných pluginom WooCommerce FLOWii Connector. Uvedené hooky môžete používať v šablónach vašich e-shopov pridaním do súboru functions.php
alebo použitím pluginu pre snippet hooky.
tlw_wc_flowii_conn_sync_order
- filter hook pre úpravu výstupného poľa s údajmi objednávky smerom z e-shopu do FLOWii
/**
* filter hook for order sync to FLOWii
* @param array $order_flowii order request output to FLOWii
* @param obj $order eshop order data
* @param str $flowii_customer_id FLOWii partner ID
* @param str $flowii_contract_id FLOWii contract ID
* @return array final order request to FLOWii
*/
add_filter('tlw_wc_flowii_conn_sync_order', function($order_flowii, $order, $flowii_customer_id, $flowii_contract_id) {
return $order_flowii;
}, 10, 4);
tlw_wc_flowii_conn_sync_order_item
- filter hook pre úpravu výstupného poľa s údajmi položky produktu v objednávke smerom z e-shopu do FLOWii
/**
* filter hook for order item sync to FLOWii
* @param array $order_item_flowii order item request output to FLOWii
* @param obj $item eshop order item
* @return array final order item request to FLOWii
*/
add_filter('tlw_wc_flowii_conn_sync_order_item', function($order_item_flowii, $item) {
return $order_item_flowii;
}, 10, 2);
tlw_wc_flowii_conn_sync_contract
- filter hook pre úpravu výstupného poľa s údajmi zákazky smerom z e-shopu do FLOWii
/**
* filter hook for contract sync to FLOWii
* @param array $contract_flowii contract request output to FLOWii
* @param obj $order eshop order data
* @param str $flowii_customer_id FLOWii partner ID
* @return array final contract request to FLOWii
*/
add_filter('tlw_wc_flowii_conn_sync_contract', function($contract_flowii, $order, $flowii_customer_id) {
return $contract_flowii;
}, 10, 3);
tlw_wc_flowii_conn_sync_product
- filter hook pre úpravu vstupného poľa s údajmi produktu smerom z FLOWii do e-shopu
/**
* filter hook for product sync from FLOWii to eshop
* @param array $product_eshop product request output to eshop
* @param obj $product_flowii FLOWii product data
* @return array final product request to eshop
*/
add_filter('tlw_wc_flowii_conn_sync_product', function($product_eshop, $product_flowii) {
return $product_eshop;
}, 10, 2);
tlw_wc_flowii_conn_sync_partner
- filter hook pre úpravu výstupného poľa s údajmi zákazníka smerom z e-shopu do FLOWii
/**
* filter hook for customer sync to FLOWii
* @param array $customer customer request output to FLOWii
* @param obj $order eshop order data
* @param obj $flowii_customer FLOWii partner data
* @return array final customer request to FLOWii
*/
add_filter('tlw_wc_flowii_conn_sync_partner', function($customer, $order, $flowii_customer) {
return $customer;
}, 10, 3);