Automattic\WooCommerce\Internal\Admin\Settings\PaymentsProviders\WooPayments

WooPaymentsService::get_onboarding_step_required_stepsprivateWC 1.0

Get the IDs of the onboarding steps that are required for the given step.

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

Хуков нет.

Возвращает

Массив|Строку[]. The IDs of the onboarding steps that are required for the given step.

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

// private - только в коде основоного (родительского) класса
$result = $this->get_onboarding_step_required_steps( $step_id ): array;
$step_id(строка) (обязательный)
The ID of the onboarding step.

Код WooPaymentsService::get_onboarding_step_required_steps() WC 11.0.1

private function get_onboarding_step_required_steps( string $step_id ): array {
	switch ( $step_id ) {
		// Both the test account and business verification (live account) steps require a working WPCOM connection.
		case self::ONBOARDING_STEP_TEST_ACCOUNT:
		case self::ONBOARDING_STEP_BUSINESS_VERIFICATION:
			return array(
				self::ONBOARDING_STEP_WPCOM_CONNECTION,
			);
		default:
			return array();
	}
}