Namespace \PlusBusinessSoftware\King
Bestand: Plus_King_Orders.php
/**
* @filter order_king_json_objects
* @param object An object containing all orders in King form.
* @param array An array of orders to send to King.
* @return object An object containing all orders in King form.
*/
$uitvoer->king_object = apply_filters( 'order_king_json_objects', $this->form_order_king_json_objects( $uitvoer->new_orders ), $uitvoer->new_orders );
/**
* Allow manipulation of an orderkop property value
*
* @filter plus_orderkop_json_filter_[$ork_property_name]
* @param mixed $prop_value The value for the property.
* @param string $ork_property_name The name of the property.
* @param array $woo_order The WooCommerce order in REST API form.
* @return mixed The value for the property.
*/
$order->orderkop->$ork_property_name = apply_filters( 'plus_orderkop_json_filter_' . $ork_property_name, $prop_value, $ork_property_name, $woo_order );
/**
* Allow manipulation of an orderregel property value
*
* @filter plus_orderregel_json_filter_[$orr_property_name]
* @param mixed $prop_value The value for the property.
* @param string $orr_property_name The name of the property.
* @param array $woo_order The WooCommerce order in REST API form.
* @param array $orderline The WooCommerce order line in REST API form.
* @return mixed The value for the property.
*/
$orderregel->$orr_property_name = apply_filters( 'plus_orderregel_json_filter_' . $orr_property_name, $prop_value, $orr_property_name, $woo_order, $orderline );
/**
* Allow manipulation of an orderregel property value
*
* @filter plus_verzendregel_json_filter_[$orr_property_name]
* @param mixed $prop_value The value for the property.
* @param string $orr_property_name The name of the property.
* @param array $woo_order The WooCommerce order in REST API form.
* @param array $shippingline The WooCommerce shipping line in REST API form.
* @return mixed The value for the property.
*/
$orderregel->$orr_property_name = apply_filters( 'plus_verzendregel_json_filter_' . $orr_property_name, $prop_value, $orr_property_name, $woo_order, $shippingline );
/**
* Filter: plus_orders_after_order_lines
*
* @param object $order A plain php object containing the order information.
* @param array $woo_order A WooCommerce as supplied by the WooCommerce REST API.
* @param array $orr_properties An array of properties that an order line might have.
* @return object $order The php object containing the order information.
*
* Adding a new order line:
*
* apply_filters( 'plus_orders_after_order_lines', function( $order, $woo_order, $orr_properties ) {
* $new_orderline = new \stdClass();
* $new_orderline->orr_soort = 'TEKST'
* $new_orderline->orr_tekstopfactuur = 'Hier komt de inhoud voor een tekstregel'
* $order->orderregels[] = $new_orderline;
* return $order;
* }, 10, 3 );
*
*/
$order = apply_filters( 'plus_orders_after_order_lines', $order, $woo_order, $orr_properties );