Automattic\WooCommerce\Admin\Notes
SellingOnlineCourses::check_onboarding_profile() public WC 1.0
Check to see if the profiler options match before possibly adding note.
{} Это метод класса: SellingOnlineCourses{}
Хуков нет.
Возвращает
Null. Ничего.
Использование
$result = SellingOnlineCourses::check_onboarding_profile( $old_value, $value, $option );
- $old_value(объект) (обязательный)
- The old option value.
- $value(объект) (обязательный)
- The new option value.
- $option(строка) (обязательный)
- The name of the option.
Код SellingOnlineCourses::check_onboarding_profile() SellingOnlineCourses::check onboarding profile WC 5.0.0
public static function check_onboarding_profile( $old_value, $value, $option ) {
// Skip adding if this store is in the education/learning industry.
if ( ! isset( $value['industry'] ) ) {
return;
}
$industry_slugs = array_column( $value['industry'], 'slug' );
if ( ! in_array( 'education-and-learning', $industry_slugs, true ) ) {
return;
}
self::possibly_add_note();
}