Automattic\WooCommerce\Internal\Orders

OrderActionsRestController::get_args_for_order_actions()privateWC 1.0

Get the accepted arguments for the POST request.

Метод класса: OrderActionsRestController{}

Хуков нет.

Возвращает

Массив[].

Использование

// private - только в коде основоного (родительского) класса
$result = $this->get_args_for_order_actions(): array;

Код OrderActionsRestController::get_args_for_order_actions() WC 9.5.1

private function get_args_for_order_actions(): array {
	return array(
		'id'    => array(
			'description' => __( 'Unique identifier of the order.', 'woocommerce' ),
			'type'        => 'integer',
			'context'     => array( 'view', 'edit' ),
			'readonly'    => true,
		),
		'email' => array(
			'description'       => __( 'Email address to send the order details to.', 'woocommerce' ),
			'type'              => 'string',
			'format'            => 'email',
			'required'          => false,
			'validate_callback' => 'rest_validate_request_arg',
		),
	);
}