Automattic\WooCommerce\Admin\Features\OnboardingTasks\Tasks
CustomizeStore::mark_task_as_complete_block_theme()
Mark the CYS task as complete whenever the user updates their global styles.
Метод класса: CustomizeStore{}
Хуков нет.
Возвращает
null
. Ничего (null).
Использование
$CustomizeStore = new CustomizeStore(); $CustomizeStore->mark_task_as_complete_block_theme( $post_id, $post, $update );
- $post_id(int) (обязательный)
- Post ID.
- $post(WP_Post) (обязательный)
- Post object.
- $update(true|false) (обязательный)
- Whether this is an existing post being updated.
Код CustomizeStore::mark_task_as_complete_block_theme() CustomizeStore::mark task as complete block theme WC 9.7.1
public function mark_task_as_complete_block_theme( $post_id, $post, $update ) { if ( $post instanceof WP_Post ) { $is_cys_complete = $this->has_custom_global_styles( $post ) || $this->has_custom_template( $post ); if ( $is_cys_complete ) { update_option( 'woocommerce_admin_customize_store_completed', 'yes' ); } } }