How to use the Metabox user dashboard for moderation

Support MB Frontend Submission How to use the Metabox user dashboard for moderation

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #41338
    ShemzoneShemzone
    Participant

    Hello
    I have a Metabox frontend submission form in frontend. All the posts submitted from this form are in "draft" status.
    I'm looking for a solution for a moderator to validate these posts.
    I have tried with the Metabox user dashboard but the posts displayed are his own, not those of the people who submitted the posts from the frontend form.

    Do you have a solution?

    Thank you for your help

    #41342
    PiotrPiotr
    Participant

    Hi,

    First, try to modify WP_Query arguments with rwmb_frontend_dashboard_query_args (check docs); e.g., adding this would let the moderator see all posts:

    $args['author'] = 0;

    You will have to use conditions within above-mentioned filter to allow only selected users/roles see all posts in a dashboard.

    Next, not sure what you mean by "moderation", is it to hide/publish the post? If so, I use custom field group with radio buttons having options corresponding with post status, e.g., "publish", "draft". The field group is then assigned to a post type. Upon submitting the form, you might fire wp_update_post to update post status according to the option selected in the form's field group with rwmb_after_save_post action (see docs).

    #41347
    ShemzoneShemzone
    Participant

    Hi @Piotr and thanks for your suggestions. I will try to implement them. About the moderation, yes it is about that, publish or not (or hide) the posts.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.