Sha256: 69e1e3effbc5f9e7f592fb25b05e9951f01bdd0a42c54896be154dc4fe0dbab1
Contents?: true
Size: 749 Bytes
Versions: 1
Compression:
Stored size: 749 Bytes
Contents
module Refinery module Pods class Pod < Refinery::Core::BaseModel self.table_name = 'refinery_pods' POD_TYPES = %w(content banner gallery video) acts_as_indexed :fields => [:name, :body, :url, :pod_type] validates_presence_of :name validates_inclusion_of :pod_type, :in => POD_TYPES belongs_to :image, :class_name => '::Refinery::Image' belongs_to :portfolio_entry, :class_name => '::Refinery::Portfolio::Gallery' belongs_to :video, :class_name => '::Refinery::Videos::Video' has_and_belongs_to_many :pages, :class_name => '::Refinery::Page', :join_table => 'refinery_pages_pods' def system_name pod_type end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
refinerycms-pods-2.0.1 | app/models/refinery/pods/pod.rb |