Skip to content

Instantly share code, notes, and snippets.

@dealingwith
Created June 21, 2013 02:18
Show Gist options
  • Save dealingwith/5828397 to your computer and use it in GitHub Desktop.
Save dealingwith/5828397 to your computer and use it in GitHub Desktop.
def widget
combined = Player.for_widget(@property.cr_campaign).reverse
others = PlayerMove.others.for(@property.cr_campaign).for_widget.reverse
render :json => {
:combined => combined.as_json(Player.widget_json),
:others => others.as_json(PlayerMove.widget_json)
}, :callback => params[:callback]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment