Marks currently playin track in tracklist
This commit is contained in:
@@ -42,16 +42,16 @@ class ArtistController < ApplicationController
|
||||
return
|
||||
end
|
||||
end
|
||||
data['artist'] = {name: artist.name, desc: ActionController::Base.helpers.strip_tags(artist.desc), pic: artist.pic_url}
|
||||
data['artist'] = {id: artist.id, name: artist.name, desc: ActionController::Base.helpers.strip_tags(artist.desc), pic: artist.pic_url}
|
||||
data['albums'] = []
|
||||
albums = artist.albums
|
||||
albums.each do |album|
|
||||
if @@default_album_types.include? album.album_type
|
||||
tmp_album = {name: album.name, year: album.year, pic: album.pic_url}
|
||||
tmp_album = {id: album.id, name: album.name, year: album.year, pic: album.pic_url}
|
||||
album_tracks = []
|
||||
bonus_tracks = []
|
||||
album.tracks.each do |track|
|
||||
tmp_track = {name: track.name, live: track.live, acoustic: track.acoustic}
|
||||
tmp_track = {id: track.id, name: track.name, live: track.live, acoustic: track.acoustic}
|
||||
if track.length
|
||||
time = (track.length / 1000).round
|
||||
time_m = (time / 60).floor
|
||||
|
||||
Reference in New Issue
Block a user