oldhaven/rails/app/controllers/artist_controller.rb

12 lines
278 B
Ruby
Raw Normal View History

2011-04-03 20:21:05 +04:00
class ArtistController < ApplicationController
def view
2011-04-03 22:32:27 +04:00
@artist = Artist.getByName(params[:name])
@albums = ReleaseGroup.getArtistAlbums(@artist.id)
2011-04-04 22:10:22 +04:00
rg_ids = []
2011-04-03 22:32:27 +04:00
@albums.each do |a|
2011-04-04 22:10:22 +04:00
rg_ids << a.id
2011-04-03 22:32:27 +04:00
end
2011-04-04 23:08:49 +04:00
@releases = Release.getReleases(rg_ids, true, true);
2011-04-03 20:21:05 +04:00
end
end