foodsoft/app/models/bank_gateway.rb

9 lines
270 B
Ruby
Raw Normal View History

2021-03-05 12:43:40 +01:00
class BankGateway < ApplicationRecord
has_many :bank_accounts, dependent: :nullify
belongs_to :unattended_user, class_name: 'User', optional: true
scope :with_unattended_support, -> { where.not(unattended_user: nil) }
validates :name, :url, presence: true
2021-03-05 12:43:40 +01:00
end