Sha256: ce4881659918c150fc46d27da9806c342da97c8da3b213663cb1679a730fddcb

Contents?: true

Size: 670 Bytes

Versions: 1

Compression:

Stored size: 670 Bytes

Contents

class AgentImportResult < ActiveRecord::Base
  attr_accessible :agent_import_file_id, :agent_id, :body
  default_scope { order('agent_import_results.id') }
  scope :file_id, proc{|file_id| where(agent_import_file_id: file_id)}
  scope :failed, -> { where(agent_id: nil) }

  belongs_to :agent_import_file
  belongs_to :agent

  validates_presence_of :agent_import_file_id
end

# == Schema Information
#
# Table name: agent_import_results
#
#  id                   :integer          not null, primary key
#  agent_import_file_id :integer
#  agent_id             :integer
#  body                 :text
#  created_at           :datetime
#  updated_at           :datetime
#

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
enju_biblio-0.1.0.pre63 app/models/agent_import_result.rb