diff --git a/app/models/client_prefix.rb b/app/models/client_prefix.rb index 31ff1f6cf..5d0cc5cab 100644 --- a/app/models/client_prefix.rb +++ b/app/models/client_prefix.rb @@ -6,7 +6,7 @@ class ClientPrefix < ActiveRecord::Base self.table_name = "datacentre_prefixes" - belongs_to :client, foreign_key: :datacentre, touch: true + belongs_to :client, foreign_key: :datacentre #, touch: true belongs_to :prefix, foreign_key: :prefixes belongs_to :provider_prefix, foreign_key: :allocator_prefixes diff --git a/app/models/provider_prefix.rb b/app/models/provider_prefix.rb index 7645c12c1..18188353c 100644 --- a/app/models/provider_prefix.rb +++ b/app/models/provider_prefix.rb @@ -6,7 +6,7 @@ class ProviderPrefix < ActiveRecord::Base self.table_name = "allocator_prefixes" - belongs_to :provider, foreign_key: :allocator, touch: true + belongs_to :provider, foreign_key: :allocator #, touch: true belongs_to :prefix, foreign_key: :prefixes has_many :client_prefixes, foreign_key: :allocator_prefixes, dependent: :destroy has_many :clients, through: :client_prefixes