[wp-trac] [WordPress Trac] #55895: Register custom post statuses
WordPress Trac
noreply at wordpress.org
Thu Jun 2 13:42:04 UTC 2022
#55895: Register custom post statuses
--------------------------------------+------------------------------
Reporter: angryjim | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Posts, Post Types | Version:
Severity: normal | Resolution:
Keywords: dev-feedback needs-patch | Focuses:
--------------------------------------+------------------------------
Changes (by SergeyBiryukov):
* keywords: dev-feedback needs-patch needs-testing post-status custom-
post-status => dev-feedback needs-patch
Old description:
> When a developer register a custom post status with {{{
> register_post_status() }}} The post status is not added to the visual
> parts of a post this means you can not set the post to this new status
> after register the new post status.
>
> There have been several workarounds to this adding functions to get them
> visible but with recent WP versions this seems to have stopped working.
>
> Another feature to add is regarding the {{{ get_post_statuses() }}} and
> {{{ get_page_statuses()}}} only returns a static array instead of
> checking the available post statues. There should also be a filter on
> this function to Add The correct label for your custom post status.
>
> Things to improve:
> - Expand get_post_statuses() and get_page_statuses() to actually return
> the registered statuses. Add a filter to be able to label your custom
> post status correctly.
> - When custom post status is added it should also be available:
> • In the post list overview the post status if not published should be
> in the name like (draft etc)
> • When quick editing / bulk editing the options of all post status
> types should be available.
> • When editing a post the post status should be available in the right
> settings column this should also work with the classic- and Gutenberg-
> mode.
>
>
> There is an old ticket with large thread about similar issues here:
> https://core.trac.wordpress.org/ticket/12706
New description:
When a developer register a custom post status with {{{
register_post_status() }}} The post status is not added to the visual
parts of a post this means you can not set the post to this new status
after register the new post status.
There have been several workarounds to this adding functions to get them
visible but with recent WP versions this seems to have stopped working.
Another feature to add is regarding the {{{ get_post_statuses() }}} and
{{{ get_page_statuses()}}} only returns a static array instead of checking
the available post statues. There should also be a filter on this function
to Add The correct label for your custom post status.
Things to improve:
- Expand get_post_statuses() and get_page_statuses() to actually return
the registered statuses. Add a filter to be able to label your custom post
status correctly.
- When custom post status is added it should also be available:
• In the post list overview the post status if not published should be
in the name like (draft etc)
• When quick editing / bulk editing the options of all post status types
should be available.
• When editing a post the post status should be available in the right
settings column this should also work with the classic- and Gutenberg-
mode.
There is an old ticket with large thread about similar issues here:
#12706.
--
Comment:
Hi there, welcome to WordPress Trac! Thanks for the ticket.
Adjusting the keywords per
[https://make.wordpress.org/core/handbook/contribute/trac/keywords/ Trac
Workflow Keywords].
--
Ticket URL: <https://core.trac.wordpress.org/ticket/55895#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list