33 lines
898 B
Ruby
33 lines
898 B
Ruby
# == Schema Information
|
|
#
|
|
# Table name: price_reports
|
|
#
|
|
# id :bigint not null, primary key
|
|
# discount_price :decimal(, )
|
|
# downvotes :integer
|
|
# price :decimal(, )
|
|
# reported_at :datetime
|
|
# upvotes :integer
|
|
# created_at :datetime not null
|
|
# updated_at :datetime not null
|
|
# guest_id :integer not null
|
|
# product_id :integer not null
|
|
# store_id :integer not null
|
|
#
|
|
# Indexes
|
|
#
|
|
# index_price_reports_on_guest_id (guest_id)
|
|
# index_price_reports_on_product_id (product_id)
|
|
# index_price_reports_on_store_id (store_id)
|
|
#
|
|
# Foreign Keys
|
|
#
|
|
# fk_rails_... (guest_id => guests.id)
|
|
# fk_rails_... (product_id => products.id)
|
|
# fk_rails_... (store_id => stores.id)
|
|
#
|
|
class PriceReport < ApplicationRecord
|
|
belongs_to :product
|
|
belongs_to :store
|
|
belongs_to :guest
|
|
end
|