Module: Ruhl::Rails::Helper

Included in:
Presenter
Defined in:
lib/ruhl/rails/helper.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) form_authenticity



4
5
6
# File 'lib/ruhl/rails/helper.rb', line 4

def form_authenticity
  {:value => form_authenticity_token, :type => "hidden", :name => "authenticity_token"}
end

- (Object) i(type, column)



8
9
10
11
12
13
14
15
# File 'lib/ruhl/rails/helper.rb', line 8

def i(type,column)
  model = presentee.class.name.underscore
  { :type => type,
    :id   => "#{model}_#{column}", 
    :name => "#{model}[#{column}]",
    :value => presentee.send(column)
  }
end