also maybe related. even if as user has all the rights for a custom post type, they need the "read" capability, otherwise the list of "select existing ...." is always empty...
Thank you for waiting.
From testing, I understand you are referring to the default "read" capability that is available under "Other capabilities", in the change permissions screen.
( screenshot: hidden link )
If that is correct, this is the lowest most basic capability that is by default available for even the lowest built-in "subscriber" role.
( ref: https://wordpress.org/support/article/roles-and-capabilities/ )
I can see that by removing this particular capabilty, the "Connect existing {post type}" option in the relationship management section on the post/page edit screen always shows no results found message. However, I can't think of a use case where someone would want to remove this capability from any user role.
Hi,
thanks for your reply. In my usecase I wanted to hide everything "normal" WordPress related from the user, so I also not gave them the read capability. with read I had to use other methods to hide certain links in the WP dashboard.
Also I think it would be clearer to understand for admins that if a user has the rights to a custom post type it gets listed... I for example just found out because it was not working that I needed to grant a seemingly unrelated right.
Thank you for sharing this feedback.
I've passed it to the concerned team for further review and will keep you updated through this ticket.
Thank you for your patience.