Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of if proc #41

Open
SteveyblamWork opened this issue Dec 29, 2022 · 0 comments · May be fixed by #48
Open

Use of if proc #41

SteveyblamWork opened this issue Dec 29, 2022 · 0 comments · May be fixed by #48

Comments

@SteveyblamWork
Copy link

Hi, This plugin is great. Thanks for the hard work. Is there a way to use the passed in if: proc to determine when the collection actions will be shown? Similar to how it's done with batch actions?

batch_action :do_something, if: proc { @current_scope.scope_method == :something } do |ids|

Many thanks
Stephen

guewen added a commit to qoqa/active_admin_scoped_collection_actions that referenced this issue Feb 4, 2025
@guewen guewen linked a pull request Feb 4, 2025 that will close this issue
guewen added a commit to qoqa/active_admin_scoped_collection_actions that referenced this issue Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant