Heeeey, im here again 🖖 Just a fast quesion, if i...
# avo-2
k
Heeeey, im here again 🖖 Just a fast quesion, if i want to have in the menu resources with a filter applied, how should i do? Example:
Copy code
section "Clients", icon: "heroicons/solid/archive-box" do
      resource :clients, label: "Active"
      resource :clients, label: "Rejected"
    end
l
Hmmm, interesting
Haven't thought about that use case
there isn't an option to do that using the
resource
operator. maybe that would be a good feature to have, so PRs are welcomed
what you coudl do is to first go and apply that filter on the resource, get the url and then use the
link_to
operator to map it out in the menu
Copy code
ruby
section "Clients", icon: "heroicons/solid/archive-box" do
  link_to "Active", "/avo/resource/clients?filters=THE_FILTER_QUERY"
  link_to "Rejected", "/avo/resource/clients?filters=THE_FILTER_QUERY"
end