Sha256: 2c3922a8c77547bb9b4d63bd3d60fb955e3c63d7be6a594bd8cdc7a9e8e50ed5

Contents?: true

Size: 710 Bytes

Versions: 9

Compression:

Stored size: 710 Bytes

Contents

require 'digest/sha1'
require "uri"

require "not_relational/domain_model.rb"
class Mediafile < NotRelational::DomainModel
    
     property :id,:string,:is_primary_key=>true
     property :mediaitem_id,:string
     property :mimeType,:string
     
     property :width,:unsigned_integer
     property :height,:unsigned_integer
     property :fileSize,:unsigned_integer
     property :bucket,:string
     property :guid,:string,:unique=>true
     
     belongs_to :Mediaitem
     
  
  
  
     def url
      return "http://s3.amazonaws.com/#{self.bucket}/media/#{self.guid}"
    end
     def view_url
       
      return "/media/#{self.mediaitem.guid}/#{width}x#{height}/show.html"
    end
   
    
   
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
cloudwow-not_relational-0.1.0 test/models/media_file.rb
cloudwow-not_relational-0.1.11 test/models/media_file.rb
cloudwow-not_relational-0.1.2 test/models/media_file.rb
cloudwow-not_relational-0.1.3 test/models/media_file.rb
cloudwow-not_relational-0.1.5 test/models/media_file.rb
cloudwow-not_relational-0.1.6 test/models/media_file.rb
cloudwow-not_relational-0.1.7 test/models/media_file.rb
cloudwow-not_relational-0.1.8 test/models/media_file.rb
cloudwow-not_relational-0.1.9 test/models/media_file.rb