You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's possible to give a custom action a parameter.
It's possible to have multiple version of the same custom action by overriding custom_key.
However, I don't see a way for the I18N label from rails_admin.en.yml to indicate which version of the same custom action is being used based on the parameter or the custom key.
Is there another way to accomplish the same idea?
Otherwise, you end up with multiple versions of the same action but they cannot be distinguished by hover text or in the bulk actions list.
# store a parameter for the actionregister_instance_option:new_statusdonilend# lets me have multiple versions of the same action based on parameterregister_instance_option:custom_keydonew_statusend# i can even change the icon based on the parameterregister_instance_option:link_icondocasenew_statuswhen:good"icon-thumbs-up"when:bad"icon-thumbs-down"when:ugly"icon-eye-open"endend
in rails_admin.en.yml
# i want to include the custom_key in these strings # so that each instance of the action has a different # hover label and bulk update labelupdate_status:
menu: "Update status"bulk_link: "Update selected %{model_label_plural}"
The text was updated successfully, but these errors were encountered:
It's possible to give a custom action a parameter.
It's possible to have multiple version of the same custom action by overriding
custom_key
.However, I don't see a way for the I18N label from
rails_admin.en.yml
to indicate which version of the same custom action is being used based on the parameter or the custom key.Is there another way to accomplish the same idea?
Otherwise, you end up with multiple versions of the same action but they cannot be distinguished by hover text or in the bulk actions list.
For example
in
rails_admin.rb
in
update_status_action.rb
in
rails_admin.en.yml
The text was updated successfully, but these errors were encountered: