Closed anxgstadler closed 1 month ago
There are several ways:
Thanks for your reply!
As far as I understand it, tags can be selected or deselcted by themselves, so there should be no need for a second tag to disable the first one. (Or if in fact there is, the documentation should say so.) Currently the documentation only says that if you want to make a tag selected from the beginning, call the default() method.
Thanks for the workaround with the parameter in the url. :-)
I tried the first approach, adding a second tag. - And indeed, when I select the second tag, the first (default) one is automatically disabled.
This would be very important to mention in the documentation. Nowhere does it say currently that tags are mutually exclusive and only one can be activated at any time. From reading the documentation I thought that I could have one tag that filters for the users' active state and a second or third tag that (additionally) filters for something else, but this seems to not be possible.
The default tag is the one that is applied if none of the tags is selected, the query-tag parameter is missing
The main use of the default tag is: all->default | active | inactive
It really needs to be added to the documentation that the default tag cannot be the only one. Thank you
MoonShine Version
2.21.1
Laravel Version
11.20.0
PHP Version
8.3
Database Driver & Version
PostgreSQL
Description
I have a resource page that shows entities that have an is_active flag. I added a single Tag called "Show active only" that filters for entities where is_active = true. Since the list should only show active entries by default, I set this Tag to be active by default.
But now I can't deselect the tag in order to show all entities regardless of their state: When I click the tag button, the same page shows again, with the tag still being active.
How can I deselect a tag that is active by default?
(If I don't set it as default, the tag button behaves correctly, I can set and unset it by clicking on it.)
Steps To Reproduce