10 lines
228 B
Ruby
10 lines
228 B
Ruby
|
# frozen_string_literal: true
|
||
|
|
||
|
class DiceRoll < ApplicationRecord
|
||
|
belongs_to :rollable, polymorphic: true
|
||
|
belongs_to :table
|
||
|
|
||
|
validates :result, presence: true,
|
||
|
numericality: { only_integer: true }
|
||
|
end
|