vidpush/app/models/videolisting.rb
2014-04-24 12:51:50 -04:00

16 lines
366 B
Ruby

class Videolisting < ActiveRecord::Base
belongs_to :campaign
validates :videocode, presence: true, uniqueness: true
validates :voiceoverselection, presence: true
validates :musicselection, presence: true
def init
self.producttypeid = 721
end
def asseturls_array
self.asseturls.split(',').collect { |url| { asseturl: url.strip } }
end
end