Update payment.rb

This commit is contained in:
2016-08-05 21:26:11 -04:00
committed by GitHub
parent e3b49358bb
commit 0495ac1bc5

View File

@@ -17,26 +17,6 @@ class Payment
validates_presence_of :customer_id, :account_id, :payment_method_id, :total_amount validates_presence_of :customer_id, :account_id, :payment_method_id, :total_amount
validates :total_amount, numericality: true validates :total_amount, numericality: true
#Required dependency for ActiveModel::Errors
extend ActiveModel::Naming
def initialize
@errors = ActiveModel::Errors.new(self)
end
# The following methods are needed to be minimally implemented
def read_attribute_for_validation(attr)
send(attr)
end
def self.human_attribute_name(attr, options = {})
attr
end
def self.lookup_ancestors
[self]
end
def save def save
payment = Quickbooks::Model::Payment.new payment = Quickbooks::Model::Payment.new