diff --git a/app/factories/bulkrax/object_factory.rb b/app/factories/bulkrax/object_factory.rb index 9e9e8ee6..dd5d3770 100644 --- a/app/factories/bulkrax/object_factory.rb +++ b/app/factories/bulkrax/object_factory.rb @@ -253,7 +253,7 @@ def clean_attrs(attrs) def collection_type(attrs) return attrs if attrs['collection_type_gid'].present? - attrs['collection_type_gid'] = Hyrax::CollectionType.find_or_create_default_collection_type.gid + attrs['collection_type_gid'] = Hyrax::CollectionType.find_or_create_default_collection_type.to_global_id.to_s attrs end diff --git a/app/models/bulkrax/csv_collection_entry.rb b/app/models/bulkrax/csv_collection_entry.rb index c62f46dd..ea6df632 100644 --- a/app/models/bulkrax/csv_collection_entry.rb +++ b/app/models/bulkrax/csv_collection_entry.rb @@ -15,7 +15,7 @@ def add_identifier def add_collection_type_gid return if self.parsed_metadata['collection_type_gid'].present? - self.parsed_metadata['collection_type_gid'] = ::Hyrax::CollectionType.find_or_create_default_collection_type.gid + self.parsed_metadata['collection_type_gid'] = ::Hyrax::CollectionType.find_or_create_default_collection_type.to_global_id.to_s end end end diff --git a/app/parsers/bulkrax/oai_dc_parser.rb b/app/parsers/bulkrax/oai_dc_parser.rb index 4116ac52..4319ab3f 100644 --- a/app/parsers/bulkrax/oai_dc_parser.rb +++ b/app/parsers/bulkrax/oai_dc_parser.rb @@ -67,7 +67,7 @@ def create_collections metadata = { visibility: 'open' } - metadata[:collection_type_gid] = Hyrax::CollectionType.find_or_create_default_collection_type.gid if defined?(::Hyrax) + metadata[:collection_type_gid] = Hyrax::CollectionType.find_or_create_default_collection_type.to_global_id.to_s if defined?(::Hyrax) collections.each_with_index do |set, index| next unless collection_name == 'all' || collection_name == set.spec