Created
July 23, 2013 17:16
Revisions
-
killthekitten created this gist
Jul 23, 2013 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,11 @@ class TariffSchemeFeeRule < ActiveRecord::Base belongs_to :tariff_scheme belongs_to :fee_rule belongs_to :currency validates :currency_id, uniqueness: { scope: [:fee_rule_id, :tariff_scheme_id] }, presence: true end class TariffScheme < ActiveRecord::Base accepts_nested_attributes_for :tariff_scheme_fee_rules, allow_destroy: true end