Pony.fm/public/scripts/app/controllers/artist-content.coffee

12 lines
414 B
CoffeeScript
Raw Normal View History

2013-08-01 04:47:21 +02:00
window.pfm.preloaders['artist-content'] = [
'artists', '$state'
(artists, $state) ->
$.when.all [artists.fetch($state.params.slug, true), artists.fetchContent($state.params.slug, true)]
]
angular.module('ponyfm').controller "artist-content", [
'$scope', 'artists', '$state'
($scope, artists, $state) ->
artists.fetchContent($state.params.slug).done (artistResponse) ->
$scope.content = artistResponse
]