Automattic\WooCommerce\Admin\Features\OnboardingTasks

TaskLists::init_default_lists()public staticWC 1.0

Initialize default lists.

{} Это метод класса: TaskLists{}

Хуков нет.

Возвращает

null. Ничего.

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

$result = TaskLists::init_default_lists();

Код TaskLists::init_default_lists() WC 6.4.1

public static function init_default_lists() {
	self::add_list(
		array(
			'id'           => 'setup',
			'title'        => __( 'Get ready to start selling', 'woocommerce' ),
			'tasks'        => array(
				'StoreDetails',
				'Purchase',
				'Products',
				'WooCommercePayments',
				'Payments',
				'Tax',
				'Shipping',
				'Marketing',
				'Appearance',
			),
			'event_prefix' => 'tasklist_',
		)
	);
	self::add_list(
		array(
			'id'      => 'extended',
			'title'   => __( 'Things to do next', 'woocommerce' ),
			'sort_by' => array(
				array(
					'key'   => 'is_complete',
					'order' => 'asc',
				),
				array(
					'key'   => 'level',
					'order' => 'asc',
				),
			),
			'tasks'   => array(
				'AdditionalPayments',
			),
		)
	);
	self::add_list(
		array(
			'id'           => 'setup_two_column',
			'hidden_id'    => 'setup',
			'title'        => __( 'Get ready to start selling', 'woocommerce' ),
			'tasks'        => array(
				'Products',
				'WooCommercePayments',
				'Payments',
				'Tax',
				'Shipping',
				'Marketing',
				'Appearance',
			),
			'event_prefix' => 'tasklist_',
		)
	);
	self::add_list(
		array(
			'id'           => 'extended_two_column',
			'hidden_id'    => 'extended',
			'title'        => __( 'Things to do next', 'woocommerce' ),
			'sort_by'      => array(
				array(
					'key'   => 'is_complete',
					'order' => 'asc',
				),
				array(
					'key'   => 'level',
					'order' => 'asc',
				),
			),
			'tasks'        => array(
				'AdditionalPayments',
			),
			'event_prefix' => 'extended_tasklist_',
		)
	);
}