Module: ActionDispatch::Routing::Mapper::Resources
- Defined in:
- lib/express_admin/commandable.rb
Instance Method Summary collapse
- #resources_with_commandable(*resources, &block) ⇒ Object (also: #resources)
Instance Method Details
#resources_with_commandable(*resources, &block) ⇒ Object Also known as: resources
57 58 59 60 61 62 63 64 65 66 |
# File 'lib/express_admin/commandable.rb', line 57 def resources_with_commandable(*resources, &block) unless @concerns[:commandable] concern :commandable, ExpressAdmin::Commandable.new end resources_without_commandable(*resources) do |resource| block.call(resource) unless block.nil? concerns :commandable end end |