foodsoft/app/models/bank_gateway.rb
2022-02-18 10:09:15 +01:00

8 lines
266 B
Ruby

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_presence_of :name, :url
end