forked from zuorasc/zuora
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #31 from Sage/fix_v2.0.4-sage
Fix v2.0.4 sage
- Loading branch information
Showing
34 changed files
with
782 additions
and
1,405 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
module Zuora::Objects | ||
class CreditBalanceAdjustment < Base | ||
belongs_to :account | ||
belongs_to :source_transaction | ||
#module Zuora::Objects | ||
#class CreditBalanceAdjustment < Base | ||
#belongs_to :account | ||
#belongs_to :source_transaction | ||
|
||
validates_length_of :accounting_code, :maximum => 100, :allow_nil => true | ||
validates_numericality_of :amount | ||
validates_length_of :comment, :maximum => 255, :allow_nil => true | ||
validates_length_of :reference_id, :maximum => 60, :allow_nil => true | ||
validates_presence_of :source_transaction_id, :if => Proc.new { |c| c.source_transaction_type == 'Adjustment' } | ||
validates_inclusion_of :source_transaction_type, :in => %w(Invoice Payment Refund Adjustment), :unless => :source_transaction | ||
validates_length_of :source_transaction_number, :maximum => 50, :if => Proc.new { |c| c.source_transaction_type == 'Adjustment' && !c.source_transaction } | ||
validates_inclusion_of :transferred_to_accounting, :in => %w(Processing Yes Error Ignore), :allow_nil => true | ||
validates_inclusion_of :type, :in => %w(Increase Decrease) | ||
#validates_length_of :accounting_code, :maximum => 100, :allow_nil => true | ||
#validates_numericality_of :amount | ||
#validates_length_of :comment, :maximum => 255, :allow_nil => true | ||
#validates_length_of :reference_id, :maximum => 60, :allow_nil => true | ||
#validates_presence_of :source_transaction_id, :if => Proc.new { |c| c.source_transaction_type == 'Adjustment' } | ||
#validates_inclusion_of :source_transaction_type, :in => %w(Invoice Payment Refund Adjustment), :unless => :source_transaction | ||
#validates_length_of :source_transaction_number, :maximum => 50, :if => Proc.new { |c| c.source_transaction_type == 'Adjustment' && !c.source_transaction } | ||
#validates_inclusion_of :transferred_to_accounting, :in => %w(Processing Yes Error Ignore), :allow_nil => true | ||
#validates_inclusion_of :type, :in => %w(Increase Decrease) | ||
|
||
define_attributes do | ||
read_only :created_by_id, :created_date, :updated_by_id, :updated_date | ||
end | ||
end | ||
end | ||
#define_attributes do | ||
#read_only :created_by_id, :created_date, :updated_by_id, :updated_date | ||
#end | ||
#end | ||
#end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.