Class: Metry::Goal
- Inherits:
-
Object
- Object
- Metry::Goal
- Includes:
- MongoMapper::Document
- Defined in:
- lib/metry/goal.rb
Instance Method Summary collapse
Instance Method Details
#path_regexp ⇒ Object
10 11 12 |
# File 'lib/metry/goal.rb', line 10 def path_regexp Regexp.new("^#{path}$") end |
#visitors ⇒ Object
14 15 16 |
# File 'lib/metry/goal.rb', line 14 def visitors Event.find(:all, :conditions => {:path => path_regexp}).inject({}){|a,e| a[e.visitor_id] = e.visitor; a}.values end |