Skip to content

Commit

Permalink
Adding created_at field for events
Browse files Browse the repository at this point in the history
  • Loading branch information
Jacques Crocker committed Jun 7, 2011
1 parent 4ab4f3a commit ee2c7ca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Expand Up @@ -278,6 +278,7 @@ AARRR tracks the raw metric data in a 2 main tables:
* `revenue`: revenue the was generated on this event
* `referral_code`: referral code that was generated for this event
* `client`: client used (web, device, etc)
* `created_at`: date the event was performed

### Reports

Expand Down
3 changes: 2 additions & 1 deletion lib/aarrr/session.rb
Expand Up @@ -61,7 +61,8 @@ def track!(event_name, options = {})
"data" => options["data"],
"revenue" => options["revenue"],
"referral_code" => options["referral_code"],
"client" => options["client"]
"client" => options["client"],
"created_at" => options["created_at"] || Time.now.getutc
})

# update user with last updated time
Expand Down

0 comments on commit ee2c7ca

Please sign in to comment.