13 lines
227 B
Ruby
Raw Normal View History

class Track < ActiveRecord::Base
set_table_name 'musicbrainz.bh_track'
2011-04-06 02:58:11 +04:00
belongs_to :release
2011-04-06 02:58:11 +04:00
def convertLength
(length /= 1000).round!
end
2011-04-06 02:58:11 +04:00
def clearName
name.gsub('&', 'and').gsub(/[^a-z0-9]/, '').downcase
end
end