• User Roll Editor 4.18.3
    Conflict Plugin Woocommerce 2.3.7
    Theme: Canvas

    After I edit a roll using User Roll Editor the user has no access to the Admin Toolbar.
    If I deactivate Woocommerce the problem goes away.

    I am trying to achieve what Vladimir Garagulya did in his youtube video where he duplicates the author role, renames it Product_Owner, and edits the roll to be able to upload and edit their products.

    However, after editing a roll, Admin Toolbar access disappears for users of that roll type. If the original user roll remains unchanged (User Roll Editor was not used to edit the roll) the Admin Toolbar remains visible for the user type upon log in. If you edit the user roll type using User Roll Editor, users of that roll type lose their Admin Toolbar forever!

    Here is what I tried:
    I changed themes. Problem persisted
    I disabled ALL plugins. Problem was gone.
    I added back Woocommerce. Problem came back. Woocommerce won’t give users with and edited roll an Admin Toolbar.

    What could be causing this conflict with Woocommerce and User Roll Editor? How do yo fix it?

    https://wordpress.org/plugins/user-role-editor/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Vladimir Garagulya

    (@shinephp)

    I do not think that it is a conflict. There are not enough permissions possibly. Please send a link to the screenshot of the edited user role.

    Plugin Author Vladimir Garagulya

    (@shinephp)

    This is the code from WooCommerce which hide admin bar:

    /**
     * Prevent any user who cannot 'edit_posts' (subscribers, customers etc) from seeing the admin bar
     *
     * Note: get_option( 'woocommerce_lock_down_admin', true ) is a deprecated option here for backwards compat. Defaults to true.
     *
     * @access public
     * @param bool $show_admin_bar
     * @return bool
     */
    function wc_disable_admin_bar( $show_admin_bar ) {
    	if ( apply_filters( 'woocommerce_disable_admin_bar', get_option( 'woocommerce_lock_down_admin', 'yes' ) === 'yes' ) && ! ( current_user_can( 'edit_posts' ) || current_user_can( 'manage_woocommerce' ) ) ) {
    		$show_admin_bar = false;
    	}
    
    	return $show_admin_bar;
    }

    So user should be able to edit posts.

    Richard_Rasch

    (@richard_rasch)

    What if a user need to do both. login into the dashboard and update their woocommerce info?

    Plugin Author Vladimir Garagulya

    (@shinephp)

    It is possible to allow access to the admin dashboard for all or selected users at WooCommerce enabled site:
    https://www.role-editor.com/woocommerce-admin-bar-access

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘User Roll Editor vs. Woocommerce – Admin Toolbar Disappears’ is closed to new replies.