# == Schema Information # # Table name: stores # # id :bigint not null, primary key # latitude :float # longitude :float # name :string # created_at :datetime not null # updated_at :datetime not null # chain_id :integer not null # # Indexes # # index_stores_on_chain_id (chain_id) # # Foreign Keys # # fk_rails_... (chain_id => chains.id) # class Store < ApplicationRecord has_one_attached :image belongs_to :chain end