Browse the Ruby on Rails Community.

You are here: Browse Railsplugins Media Plug

Media Plug

map.resources :plugged_assets

class CreatePluggedAssets < ActiveRecord::Migration def self.up create_table :plugged_assets do |t| t.column :content_type, :string t.column :filename, :string t.column :thumbnail, :string t.column :size, :integer t.column :width, :integer t.column :height, :integer t.column :type, :string t.column :parent_id, :string t.column :upload_id, :string t.column :status, :string, :default => “pending” t.column :file_url, :string t.column :mediaplug_attachable_id, :integer t.column :mediaplug_attachable_type, :string t.timestamps end end end

def self.down
  drop_table :plugged_assets
end

NOTE: This description has been extracted from the Plugin README and so the formatting may need updating to make browser friendly

Users


See all details


Membership

+ Join this railsplugin

Record Maintainer

'None'