tabletop-companion/app/models/game_system.rb

11 lines
297 B
Ruby
Raw Permalink Normal View History

2024-05-26 10:45:10 +00:00
# frozen_string_literal: true
2024-05-26 08:51:31 +00:00
class GameSystem < ApplicationRecord
2024-06-05 15:00:02 +00:00
has_many :characters, dependent: :restrict_with_error
has_many :tables, dependent: :restrict_with_error
2024-05-26 10:42:48 +00:00
validates :name, presence: true,
uniqueness: true,
length: { maximum: 100 }
2024-05-26 08:51:31 +00:00
end