class Output ActiveRecord Base belongs_to employee has_many output_pro

1
2
3
4
5
6
7
8
class Output < ActiveRecord::Base
belongs_to :employee
has_many :output_products
has_many :products, :through => :output_products
accepts_nested_attributes_for :output_products,
:allow_destroy => true
end