Pony.fm/resources/assets/scripts/app/controllers/playlists-list.coffee

12 lines
377 B
CoffeeScript
Raw Normal View History

2015-08-31 17:42:21 +02:00
window.pfm.preloaders['playlists-list'] = [
'playlists', '$state'
(playlists, $state) ->
playlists.fetchList($state.params.page, true)
]
angular.module('ponyfm').controller "playlists-list", [
'$scope', 'playlists', '$state',
($scope, playlists, $state) ->
playlists.fetchList($state.params.page).done (searchResults) ->
$scope.playlists = searchResults.playlists
]