Sha256: e3a3ca44874517f38ec0661c32d43f816b3553f93313b2434aa6ef4d7d76ec47
Contents?: true
Size: 371 Bytes
Versions: 159
Compression:
Stored size: 371 Bytes
Contents
module AuxModel def add_newsitem item n = Newsitem.new case item.class.name when 'Video' n.video_id = item.id when 'Photo' raise 'Not Implemented' when 'Report' raise 'Not Implemented' when 'Gallery' raise 'Not Implmented' else raise 'Not Implemented' end self.newsitems << n self.save end end
Version data entries
159 entries across 159 versions & 3 rubygems