1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-07-18 20:59:39 +02:00
Maybe/app/models/security/price.rb

7 lines
190 B
Ruby
Raw Normal View History

class Security::Price < ApplicationRecord
belongs_to :security
validates :date, :price, :currency, presence: true
validates :date, uniqueness: { scope: %i[security_id currency] }
end