Automattic\WooCommerce\EmailEditor\Engine
Email_Editor::register_email_post_sent_status
Register the 'sent' post status for emails.
Method of the class: Email_Editor{}
Hooks from the method
Returns
null. Nothing (null).
Usage
// private - for code of main (parent) class only $result = $this->register_email_post_sent_status(): void;
Email_Editor::register_email_post_sent_status() Email Editor::register email post sent status code WC 10.6.2
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
);
}