handle order actions

This commit is contained in:
Almira Krdzic
2018-10-31 10:23:59 +01:00
parent 5aca4e8572
commit 308c836460
17 changed files with 834 additions and 649 deletions

View File

@@ -65,13 +65,14 @@ class Wiaas_Order_Fields {
public static function map_order_to_entry($order_id, $form, $bundle_item_id = null) {
if (empty($form['fields']) ||
empty(GFCommon::get_fields_by_type( $form, array('wiaas_order')) ) ) {
// form does not have order field so cannot be mapped
return false;
}
error_log(json_encode('here'));
$order = wc_get_order($order_id);
$bundle_item = $order->get_item($bundle_item_id);