Support

Account

Forum Replies Created

  • It needs to be a different filter. so i coded(copy pasted) this:

    function wb_wc_memberships_for_teams_allowed_meta_box_ids( $allowed_meta_box_ids ) {
    	if ( function_exists( 'acf_get_field_groups' ) ) {
    
    		$field_groups = array_merge(			
    			acf_get_field_groups( array( 'post_type' => 'wc_memberships_team' ) )
    		);
    
    		foreach ( $field_groups as $field_group ) {
    			$allowed_meta_box_ids[] = 'acf-' . $field_group['key'];
    		}
    	}
    	return $allowed_meta_box_ids;
    }
    
    add_filter( 'wc_memberships_for_teams_allowed_meta_box_ids', 'wb_wc_memberships_for_teams_allowed_meta_box_ids' );
  • forbiddenChunk’s link works great for members, but not teams. I tried modifying it to allow adding acf to teams:

    
    $field_groups = array_merge(
    			acf_get_field_groups( array( 'post_type' => 'wc_membership_plan' ) ),
    			acf_get_field_groups( array( 'post_type' => 'wc_user_membership' ) ),
    			acf_get_field_groups( array( 'post_type' => 'wc_memberships_team' ) )
    		);

    .. but this didnt work. any ideas how to allow ACF fields in wp-admin pages for woo teams?

Viewing 2 posts - 1 through 2 (of 2 total)