Class: FormAction

Inherits:
CompositeAction show all
Defined in:
lib/ribit/action.rb

Constant Summary collapse

ID =
'form'

Instance Attribute Summary

Attributes inherited from WebAction

#id

Instance Method Summary collapse

Methods inherited from CompositeAction

#add_action, #run

Methods inherited from WebAction

#add_headers, #run

Constructor Details

#initialize(ribitData) ⇒ FormAction

Returns a new instance of FormAction.



119
120
121
# File 'lib/ribit/action.rb', line 119

def initialize( ribitData )
  super( ID )
end

Instance Method Details

#get_child_action_id(pageRequest) ⇒ Object



124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
# File 'lib/ribit/action.rb', line 124

def get_child_action_id( pageRequest )
  query = pageRequest.get_query_data
  
  # Only that name has a value that is attached
  # to pressed button

    @actions.each_key do |key|
      if ( query[key] != nil )
        return key
      end
    end

  # no action found    
  return nil
end