Automattic\WooCommerce\Admin\Features\OnboardingTasks

Task::get_json()publicWC 1.0

Get the task as JSON.

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

Хуков нет.

Возвращает

Массив.

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

$Task = new Task();
$Task->get_json();

Код Task::get_json() WC 6.4.1

public function get_json() {
	$this->possibly_track_completion();

	return array(
		'id'             => $this->get_id(),
		'parentId'       => $this->get_parent_id(),
		'title'          => $this->get_title(),
		'canView'        => $this->can_view(),
		'content'        => $this->get_content(),
		'additionalInfo' => $this->get_additional_info(),
		'actionLabel'    => $this->get_action_label(),
		'actionUrl'      => $this->get_action_url(),
		'isComplete'     => $this->is_complete(),
		'time'           => $this->get_time(),
		'level'          => $this->get_level(),
		'isActioned'     => $this->is_actioned(),
		'isDismissed'    => $this->is_dismissed(),
		'isDismissable'  => $this->is_dismissable(),
		'isSnoozed'      => $this->is_snoozed(),
		'isSnoozeable'   => $this->is_snoozeable(),
		'snoozedUntil'   => $this->get_snoozed_until(),
		'additionalData' => self::convert_object_to_camelcase( $this->get_additional_data() ),
		'eventPrefix'    => $this->prefix_event( '' ),
	);
}