Sha256: e320b91a6dd3c76bbb372e873f01dcac8d62092873cc7c24e55954abe7e1f8fc
Contents?: true
Size: 878 Bytes
Versions: 30
Compression:
Stored size: 878 Bytes
Contents
- resource = (@_effective_resource || Effective::Resource.new(controller_path)) - @resource = instance_variable_get('@' + resource.name) if resource.name - if @resource .row .col-8 %h1= @page_title .col-4.text-right - resource.member_post_actions.each do |action| - if EffectiveResources.authorized?(controller, action, @resource) && (path = resource.action_path(action, @resource)).present? = link_to action.to_s.titleize, path, class: 'btn btn-sm btn-primary', data: { confirm: "Really #{action} #{@resource}?", method: :post } - if EffectiveResources.authorized?(controller, :destroy, @resource) && (path = resource.action_path(:destroy, @resource)).present? = link_to 'Delete', path, class: 'btn btn-sm btn-danger', data: { confirm: "Really delete #{@resource}?", method: :delete } = render_resource_form(resource)
Version data entries
30 entries across 30 versions & 1 rubygems