Sha256: f2d8b89e13d2d8f640dc583d490936cd9a666cedaf724e098fc93dd67bca2cb3

Contents?: true

Size: 477 Bytes

Versions: 12

Compression:

Stored size: 477 Bytes

Contents

# coding: utf-8

module Redditor
  class TextBlock < ActiveRecord::Base
    self.table_name = "redditor_text_blocks"

    # attr_accessible :body, :page_id, :position, :temp_id, :translations_attributes
    attr_accessor :temp_id

    belongs_to :page, :class_name => "Redditor::Page"

    default_scope -> { order(:position) }

    validates :position, :body, :presence => true
    
    def self.model_name
      ActiveModel::Name.new(self, nil, 'TextBlock')
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
redditor-0.1.11 app/models/redditor/text_block.rb
redditor-0.1.10 app/models/redditor/text_block.rb
redditor-0.1.9 app/models/redditor/text_block.rb
redditor-0.1.8 app/models/redditor/text_block.rb
redditor-0.1.7 app/models/redditor/text_block.rb
redditor-0.1.6 app/models/redditor/text_block.rb
redditor-0.1.5 app/models/redditor/text_block.rb
redditor-0.1.4 app/models/redditor/text_block.rb
redditor-0.1.3 app/models/redditor/text_block.rb
redditor-0.1.2 app/models/redditor/text_block.rb
redditor-0.1.1 app/models/redditor/text_block.rb
redditor-0.1.0 app/models/redditor/text_block.rb