Sha256: f5b256f648bb50b08689f284f6b0da592a4f5b0ff5da2116b22d5cd80b6b42e1

Contents?: true

Size: 464 Bytes

Versions: 16

Compression:

Stored size: 464 Bytes

Contents

module Bhf
  module ViewHelpers
    module ActionView

      def bhf_edit(object, options = {})
        return unless session[Bhf::Engine.config.session_auth_name.to_s] == true

        options[:platform_name] ||= object.class.to_s.pluralize.downcase

        return unless object.bhf_can_edit?(options)

        render :partial => 'bhf/helper/frontend_edit', :locals => { :platform_name => options[:platform_name], :object => object }
      end

    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
bhf-0.3.7 lib/bhf/view_helpers.rb
bhf-0.3.6.4 lib/bhf/view_helpers.rb
bhf-0.3.6.3 lib/bhf/view_helpers.rb
bhf-0.3.6.2 lib/bhf/view_helpers.rb
bhf-0.3.6.1 lib/bhf/view_helpers.rb
bhf-0.3.5 lib/bhf/view_helpers.rb
bhf-0.3.4 lib/bhf/view_helpers.rb
bhf-0.3.3 lib/bhf/view_helpers.rb
bhf-0.3.2 lib/bhf/view_helpers.rb
bhf-0.3.1 lib/bhf/view_helpers.rb
bhf-0.3.0 lib/bhf/view_helpers.rb
bhf-0.2.9 lib/bhf/view_helpers.rb
bhf-0.2.8 lib/bhf/view_helpers.rb
bhf-0.2.7 lib/bhf/view_helpers.rb
bhf-0.2.6 lib/bhf/view_helpers.rb
bhf-0.2.5 lib/bhf/view_helpers.rb