Automattic\WooCommerce\EmailEditor\Engine
Email_Editor::register_email_post_sent_status
Register the 'sent' post status for emails.
Метод класса: Email_Editor{}
Хуки из метода
Возвращает
void. Ничего (null).
Использование
// private - только в коде основоного (родительского) класса $result = $this->register_email_post_sent_status(): void;
Код Email_Editor::register_email_post_sent_status() Email Editor::register email post sent status WC 11.1.0
private function register_email_post_sent_status(): void {
$default_args = array(
'public' => false,
'exclude_from_search' => true,
'internal' => true, // for now, we hide it, if we use the status in the listings we may flip this and following values.
'show_in_admin_all_list' => false,
'show_in_admin_status_list' => false,
'private' => true, // required by the preview in new tab feature for sent post (newsletter). Posts are only visible to site admins and editors.
);
$args = apply_filters( 'woocommerce_email_editor_post_sent_status_args', $default_args );
register_post_status(
'sent',
$args
);
}