price-point-api/app/models/user.rb

21 lines
519 B
Ruby
Raw Normal View History

2026-05-25 16:15:06 +00:00
# == Schema Information
#
2026-05-30 14:54:26 +00:00
# Table name: users
2026-05-25 16:15:06 +00:00
#
# id :bigint not null, primary key
# email :string
# name :string
# password_digest :string
2026-05-30 14:54:26 +00:00
# role :integer
2026-05-25 16:15:06 +00:00
# created_at :datetime not null
# updated_at :datetime not null
#
# Indexes
#
2026-05-30 14:54:26 +00:00
# index_users_on_email (email) UNIQUE
2026-05-25 16:15:06 +00:00
#
2026-05-30 14:54:26 +00:00
class User < ApplicationRecord
has_many :price_reports, dependent: :nullify
has_many :moderation_logs, foreign_key: :admin_id, dependent: :nullify
2026-05-17 11:12:43 +00:00
end