- if @artist.status == 0 .alert-message.warning %p= t('search.loading') .row.artist-info .span4.columns.pic = image_tag @artist.pic_url unless @artist.pic_url.nil? .span7.columns.desc %h2 =@artist.name %small= " "+@artist.original_name.to_s %p= @artist.desc.html_safe unless @artist.desc.nil? - unless @artist.artist_links.empty? .service-icons %a.foreign-link{ href: "http://last.fm/artist/#{@artist.name.gsub(" ", "+")}", target: '_blank' } = image_tag 'services/lastfm.ico' - @artist.artist_links.each do |service| - if ['wikipedia', 'microblog', 'official_homepage', 'social_network', 'youtube'].include?(service.service) %a.foreign-link{ href: service.url, target: '_blank' } = image_tag 'services/'+service.service+(service.service == 'official_homepage' ? '.png' : '.ico') .row .span7.offset4 %h3= t('player.playlists') %table.zebra-striped %tr %td %span.label.success.set-playlist{ href: "", 'data-playlist' => "lastfm-top50/#{@artist.id}" }= t('player.set_playlist') %a.page-link.playlist-name{ href: "/playlist/lastfm-top50/#{@artist.id}" }= "#{@artist.name}: Last.fm TOP" - @artist.playlists.each do |playlist| %tr - @artist.playlists.each do |playlist| %td %span.label.success.set-playlist{ href: "", 'data-playlist' => playlist.id }= t('player.set_playlist') %a.playlist-name{ href: "", 'data-playlist-id' => playlist.id }= playlist.name - @artist.albums.each do |album| .row.album .span4.columns.art %img{ src: album.pic_url } .button-container %a.btn.add-album{ 'data-tracks' => album.tracks.map(&:id).join(",") }= t('player.add') .span7.columns.tracks %h3{ 'data-album-id' => album.id } = album.name %small= " ("+album.year.to_s+")" %table.zebra-striped.tracklist - album.tracks.each do |track| %tr{ class: (track.available == false ? "unavailable" : nil) } %td.song-title= track.name %td.song-duration .s-duration= (track.duration != '0:00' ? track.duration : ' '.html_safe) %span.label.success.s-add{ 'data-album-id' => album.id, 'data-id' => track.id }= t('player.add_one')