I've created a view that provides a listing of a particular media type on my site. I'd like to place an "Add new" link at the top of this view and have it visible only to users who can actually add new media of that type. Does anyone know a straightforward way of doing this?
What I've tried:
- Adding a View header component of type "Text area": Nope, can't restrict visibility
- Using the menu's Menu block and trying to insert that as a Views header component: Nope, can't restrict visibility
- Using the menu's Menu block and adding it to the Block layout with a specific "Show on this page" set to just the Views page I had created. This worked, but with several of these links to create, I would be unacceptably cluttering up my Block layout with one-off menu blocks.
- Creating a menu with one menu item and rendering it with the "Rendered entity: Custom menu item": Nope, can't restrict visibility AND it renders in a useless way (unformatted data)
I find it strange that you can't create a Views header/footer element and specify its visibility based on roles/permissions.
Any ideas/solutions that won't be duplicative or hard to maintain?