credit_payment.rb 267 B

12345678910111213
  1. class CreditPayment < ActiveRecord::Base
  2. belongs_to :customer
  3. belongs_to :pointsale
  4. belongs_to :user
  5. belongs_to :credit
  6. has_one :cash_registers_move
  7. enum status: [:active, :cancelled]
  8. scope :activos, -> { where(credit_payments: { status: 0 }) }
  9. end