lib/ddr/models/indexing.rb in ddr-models-2.7.2 vs lib/ddr/models/indexing.rb in ddr-models-2.7.3
- old
+ new
@@ -101,10 +101,13 @@
end
if has_multires_image?
fields[MULTIRES_IMAGE_FILE_PATH] = multires_image_file_path
end
if has_struct_metadata?
- fields[STRUCTURE] = structure.dereferenced_structure.to_json
+ # STRUCT is an interim index field to facilitate conversion of STRUCTURE field definition.
+ fields[STRUCT] = fields[STRUCTURE] = structure.dereferenced_structure.to_json
+ fields[STRUCTURE_SOURCE] = structure.repository_maintained? ? Ddr::Models::Structure::REPOSITORY_MAINTAINED
+ : Ddr::Models::Structure::EXTERNALLY_PROVIDED
end
if has_extracted_text?
fields[EXTRACTED_TEXT] = extractedText.content
end
if is_a? Component