Support

Account

Home Forums General Issues User meta revisions? Reply To: User meta revisions?

  • What you basically need is two views. For the user you need a view that only shows the fields that the user is allowed to alter. On the second view you need the admin to see both the old and the new updated data.

    I would create 2 fields for each field. One that holds the approved content and one that holds a duplicate of the approved content for editing by the user.

    Let’s say you have a text field, you create two text fields one named text_field_live and the other named text_field_edit. Check out this add on I created recently https://github.com/Hube2/acf-user-role-field-setting.

    Since edits can only be made to the text_field_edit field I would use an acf/load_field filter https://www.advancedcustomfields.com/resources/acfload_field/ to set the text_field_live field as read only $field['readonly'] = 1;.

    Now I’d create a true/false field for Approve Changes that only the admin has access to.

    Now you have two views, one of the user and one for the admin.

    Next I would look create an acf/save_post filter https://www.advancedcustomfields.com/resources/acfsave_post/.

    
    is approved true?
        NO - Return
    
    Copy the edit fields to the live fields
    
    Set approved to false