using ACF Pro, I have a set of ACF fields that are attached to my “ad” custom post type. As expected, they do appear when editing or creating such a CPT.
I’d like to have a function to make them NOT appear on post-new.php?post_type=ad when user doesn’t have at least a published “site” custom post type.
(that’s because I don’t want my user to be able to draft and submit an “ad” if he didn’t get its “site” approved first)
I already have the “check if user has at least a published “site” CPT” part, but I can’t figure out how to prevent / remove the fields from my edit.php page.
I tried removing the metabox, but it doesn’t seem to work (or I don’t get the ID right ?)
Is there an action / filter I should use ? I didn’t find anything about that.