12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
# File 'lib/acts_as_kaltura/video.rb', line 12
def acts_as_kaltura_video(options = { })
attr_accessor :video_file, :uploaded_video_token
self._kaltura_options = options
if options[:delegate].present?
delegates_kaltura_attributes options[:delegate]
end
validates :video_file, :presence => { :on => :create }
before_save :process_uploaded_video_file
before_create :create_kaltura_video_entry
before_update :update_kaltura_video_entry
after_destroy :destroy_kaltura_video_entry
end
|