lib/registry/registry_record.rb
# Runs the collation of source records again.
# Typically performed after a source record has been added or updated.
Runs the collation of source records again.
Typically performed after a source record has been added or updated.
Runs the collation of source records again . Typically performed after a source record has been added or updated .
def recollate
      @sources = SourceRecord.where(:source_id.in => source_record_ids)
      self.source_org_codes = @sources.collect(&:org_code)
      self.source_org_codes.uniq!
      @@collator.extract_fields(@sources)
                .each_with_index { |(k, v), _i| self[k] = v }
      save
    end
def recollate @sources = SourceRecord . where ( :source_id . in => source_record_ids ) self . source_org_codes = @sources . collect ( & :org_code ) self . source_org_codes . uniq! @@collator . extract_fields ( @sources ) . each_with_index { | ( k , v ) , _i | self [ k ] = v } save end
Runs the collation of source records again.
Runs the collation of source records again .