Class: FacebookApp::AchievementsController

Inherits:
FacebookAppController show all
Defined in:
app/controllers/facebook_app/achievements_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject



9
10
11
12
# File 'app/controllers/facebook_app/achievements_controller.rb', line 9

def create
  @user_uid = AwardSet.find_by_uid(params[:id])
  app_graph.graph_call("#{user_uid}/achievements", {:achievement => achievement_url(1)}, :post)
end

#register_with_fbObject

needs to be done once per Facebook app. make sure your app is set as a Game



16
17
18
# File 'app/controllers/facebook_app/achievements_controller.rb', line 16

def register_with_fb
  @app_graph.graph_call("#{FB.app_id}/achievements", {:achievement => achievement_url(1), :display_order => 1 }, :post) 
end

#showObject



6
7
# File 'app/controllers/facebook_app/achievements_controller.rb', line 6

def show 
end