bulkrax 3.0.0.beta5 → 3.0.0.beta6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA256:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: 744a122509bc57b9b9a24367c2eee3660d3184bd8209543de43e7f9bf3b1c6ef
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: c9156dba83a463872cf700d93d12770b5967a1e28f269aba0141d0ae9a280e8e
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 3abe5abd1a882ebe4090a75c8600a9c9e35ede83fdaab22aaf33966d5b412fc256835ccef6ab7eaf3776f5ff7a4b0c27eaf94ac77fccf99985b7ad1dc2172c78
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 6f1387ce3876c65f23b15cb0cf6824040af2071f59a7f2c3d68377c78994d543f1bd7beced5a334e9467bc7285c1930da9acc6ac7c9e2fdddbdcd0b156541386
         
     | 
| 
         @@ -59,6 +59,7 @@ module Bulkrax 
     | 
|
| 
       59 
59 
     | 
    
         
             
                  if factory_class == Collection
         
     | 
| 
       60 
60 
     | 
    
         
             
                    add_collection_type_gid
         
     | 
| 
       61 
61 
     | 
    
         
             
                  elsif factory_class == FileSet
         
     | 
| 
      
 62 
     | 
    
         
            +
                    validate_presence_of_filename!
         
     | 
| 
       62 
63 
     | 
    
         
             
                    add_path_to_file
         
     | 
| 
       63 
64 
     | 
    
         
             
                    validate_presence_of_parent!
         
     | 
| 
       64 
65 
     | 
    
         
             
                  else
         
     | 
| 
         @@ -250,7 +251,7 @@ module Bulkrax 
     | 
|
| 
       250 
251 
     | 
    
         
             
                  split_references = record[parent_field_mapping].split(/\s*[;|]\s*/)
         
     | 
| 
       251 
252 
     | 
    
         
             
                  split_references.each do |c_reference|
         
     | 
| 
       252 
253 
     | 
    
         
             
                    matching_collection_entries = importerexporter.entries.select do |e|
         
     | 
| 
       253 
     | 
    
         
            -
                      (e.raw_metadata[source_identifier 
     | 
| 
      
 254 
     | 
    
         
            +
                      (e.raw_metadata&.[](source_identifier) == c_reference) &&
         
     | 
| 
       254 
255 
     | 
    
         
             
                        e.is_a?(CsvCollectionEntry)
         
     | 
| 
       255 
256 
     | 
    
         
             
                    end
         
     | 
| 
       256 
257 
     | 
    
         
             
                    raise ::StandardError, 'Only expected to find one matching entry' if matching_collection_entries.count > 1
         
     | 
| 
         @@ -17,6 +17,12 @@ module Bulkrax 
     | 
|
| 
       17 
17 
     | 
    
         
             
                  parsed_metadata['file']
         
     | 
| 
       18 
18 
     | 
    
         
             
                end
         
     | 
| 
       19 
19 
     | 
    
         | 
| 
      
 20 
     | 
    
         
            +
                def validate_presence_of_filename!
         
     | 
| 
      
 21 
     | 
    
         
            +
                  return if parsed_metadata&.[]('file')&.map(&:present?)&.any?
         
     | 
| 
      
 22 
     | 
    
         
            +
             
     | 
| 
      
 23 
     | 
    
         
            +
                  raise StandardError, 'File set must have a filename'
         
     | 
| 
      
 24 
     | 
    
         
            +
                end
         
     | 
| 
      
 25 
     | 
    
         
            +
             
     | 
| 
       20 
26 
     | 
    
         
             
                def validate_presence_of_parent!
         
     | 
| 
       21 
27 
     | 
    
         
             
                  return if parsed_metadata[related_parents_parsed_mapping]&.map(&:present?)&.any?
         
     | 
| 
       22 
28 
     | 
    
         | 
| 
         @@ -193,7 +193,7 @@ module Bulkrax 
     | 
|
| 
       193 
193 
     | 
    
         
             
                    instance_variable_set(instance_var, ActiveFedora::SolrService.post(
         
     | 
| 
       194 
194 
     | 
    
         
             
                      extra_filters.to_s,
         
     | 
| 
       195 
195 
     | 
    
         
             
                      fq: [
         
     | 
| 
       196 
     | 
    
         
            -
                        "#{work_identifier} 
     | 
| 
      
 196 
     | 
    
         
            +
                        "#{::Solrizer.solr_name(work_identifier)}:(#{complete_entry_identifiers.join(' OR ')})",
         
     | 
| 
       197 
197 
     | 
    
         
             
                        "has_model_ssim:(#{models_to_search.join(' OR ')})"
         
     | 
| 
       198 
198 
     | 
    
         
             
                      ],
         
     | 
| 
       199 
199 
     | 
    
         
             
                      fl: 'id',
         
     | 
    
        data/lib/bulkrax/version.rb
    CHANGED