The problem was, that I changed the capabilities AFTER I already created the role. I noticed, that if I change the roles slug, the role became duplicated. So I searched, and found
remove_role( 'tabellenadmin' );
Add that line somewhere before add_role(). You first have to remove the role, before you can change it.
Related Posts:
- Apply custom role capabilities to administrator (without plugin)
- Roles & capabilities GUI that does not create separate table
- How to add custom JavaScript in functions?
- The Capability to choose post/page template
- Remove or disable Appearance > Patterns
- Displaying the number of updates available in the Admin area
- Remove a menu item created by a plugin
- How to remove Customize from admin menu bar after WP 4.3
- Modify Admin Bar Link
- Run functions only in the admin area?
- difference between add_object_page and add_menu_page
- How do I code access to the built-in UI of a CPT when it’s placed as submenu of another CPT that is protected by role?
- Remove Menu Page Giving Error
- How do I redirect upon login a specific user based on role?
- Print Dashboard menu name and link
- How to add another user to this remove_menu function?
- Add a new subscriber role using a function
- How to allow “Add New” capability of CPT when links to its UI are placed as a submenu?
- How to change menu page capability
- How to test for Super Admin
- Custom roles can’t access to wp-admin
- Custom registration URL lost when user makes signup mistake
- Custom function for specific user role
- Hide Author.php template from specific user role
- Logout hyperlink within a sub-menu
- edit role display name and label name without plugins
- Add Featured image column into wordpress admin on pages AND posts
- create shortcode to list users with specific meta key value
- Toggle User Roles with button
- Change position of media in admin menu
- How to change or add user role after getting post request data about pay? [closed]
- Custom post types as sub menu pages and role capabilities issue
- Execute a ultimate member action when user role is updated
- Move ‘current-menu-item’ class on #adminmenu li from Posts to Pages for Taxonomy Edit Screen
- Role capability issue
- Creating A New Admin Menu Tab For Theme Options
- Allowing users to view private posts (pending approval)
- WordPress Remove Submenus
- Allow Contributor to edit their own posts after Adm aproval
- How to set default post editor based on role?
- How to keep the capability of users and disable Gutenberg editor in WordPress?
- load CSS only for administrators on backend
- Adding additional roles on registration
- How to add array [closed]
- Get users with different roles and call function on each of them (user_meta)
- How can I show different content for different user-levels?
- How to change a specific admin label
- Custom user role still showing up after deletion, ideas?
- Allow a user or role to view drafts and previews, but not other admin privileges?
- How to load a css file depending on the current role
- User role and capablities only for 1 plugin
- Allow user select role in wordpress default registration without plugin
- Remove check boxes and its label from screen option for custom role
- Add Change role button for list of user in an event
- How to show only specific category post by user role without plugin and restrict all other cats
- Change user role based on total number of items ordered
- How to add publish/draft button in Admin Post Lists
- Remove all video attachment, both files and post/postmeta from database?
- Which method is more correct for removing WooCommerce Extensions menu item?
- delete_user_meta for user in spesific group
- Change the second role depending on the first
- Restrict certain roles registrations by domain
- Multisite Admin Roles
- Hide certain post types from editors
- How to add next height number in Order Attributes inside the Add new page. [duplicate]
- Function Reference for custom link in Admin Menu Management Page
- Grant access to admin menu?
- Welcome Mails based on user role
- Sync roles across several plugins
- How to disable plugin capability : “create new category”
- Get all users from role and add to dropdown (select) – wordpress, javascript
- Would it be possible to disable embeds for specific user roles? If so, how?
- How to make my logged-in user-role shortcode displaying name instead of slug?
- Custom User Role not working
- How to give plugin access to specific role(s)
- Redirect User Role When on Specific Page
- WP_Query for Attachments not working as expected
- Undefined variable issue for wp_get_attachment_image_url
- Customise the WordPress gallery html layout
- How to force one script to load before google tag manager script
- Change class woocommerce on function.php
- Text replace for the whole body tag
- Bizarre Child Menu Issue on WP Site
- How to display my comment count in the wordpress admin bar?
- Block access to plugins.php for custom role
- Login cookies blocked after customizing hashing method
- Counting posts and trigger it [closed]
- Show ‘Add to Cart’ on Out of Stock products
- Combine page types and Custom Taxonomy in a functions.php command
- reWrite wp-content url to point on my cdn
- Allow contributor user role to perform copy operation PHP
- Order column custom date using pre_get_posts
- query_vars treat as single var from URL
- Running javascript without hooking wp_head
- Issue passing action class to nested function. Admin Columns
- Populate Product Regular Price with a calculated ACF Field Value
- Header menu aligned right on all pages except for single-post page [closed]
- Can’t load assets
- Display link to category over featured image
- Does hook have an effect on increasing the page load?