Class: FacebookApp::AchievementsController
- Inherits:
-
FacebookAppController
- Object
- ActionController::Base
- FacebookAppController
- FacebookApp::AchievementsController
- Defined in:
- app/controllers/facebook_app/achievements_controller.rb
Instance Method Summary collapse
- #create ⇒ Object
-
#register_with_fb ⇒ Object
needs to be done once per Facebook app.
- #show ⇒ Object
Instance Method Details
#create ⇒ Object
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_fb ⇒ Object
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 |
#show ⇒ Object
6 7 |
# File 'app/controllers/facebook_app/achievements_controller.rb', line 6 def show end |