Automattic\WooCommerce\Internal\Admin

Settings::get_default_actionable_order_statuses │ public static │ WC 11.2.0

The default order statuses considered actionable in Analytics, before a merchant saves the option. Single source of truth for the Settings UI and every runtime consumer, so the filtered value applies everywhere without saving the option.

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

Возвращает

array.

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

$result = Settings::get_default_actionable_order_statuses(): array;

Список изменений

С версии 11.2.0 Введена.

Код Settings::get_default_actionable_order_statuses() WC 11.2.2

public static function get_default_actionable_order_statuses(): array {
	$builtin_default = array( OrderStatus::PROCESSING, OrderStatus::ON_HOLD );

	/**
	 * Filters the default set of order statuses considered actionable in Analytics.
	 *
	 * @since 11.2.0
	 *
	 * @param array $default_statuses Default actionable order statuses.
	 */
	$filtered = apply_filters( 'woocommerce_analytics_settings_default_actionable_order_statuses', $builtin_default );

	return self::get_valid_order_statuses_or_default( $filtered, $builtin_default );
}