Created
August 20, 2015 06:37
-
-
Save talsafran/e95fc79b284e78924be5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ApplicationController < ActionController::Base | |
... | |
private | |
def track_event | |
mixpanel.track(event_user, event_name, event_properties) | |
end | |
def event_properties | |
{} | |
end | |
... | |
end | |
class OrdersController < ApplicationController | |
... | |
private | |
def event_properties | |
{ quantity: @order.quantity, meal_name: @order.meal.name } | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment