Skip to content

Instantly share code, notes, and snippets.

@rdavila
Created September 6, 2012 23:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rdavila/3661112 to your computer and use it in GitHub Desktop.
Save rdavila/3661112 to your computer and use it in GitHub Desktop.
class Admin.Routers.Menus extends Backbone.Router
routes:
'': 'fetchData'
fetchData: ->
Admin.Collections.MenuCategories.fetch
success: (col, resp) ->
names = col.pluck('name')
$("#menu_menu_category_id").autocomplete(data: names)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment