MarcusBarnes / islandora_compound_batch

Provides the basic ability to batch import compound objects into Islandora.
GNU General Public License v3.0
3 stars 12 forks source link

Allow assignment of content model for parent objects #35

Closed mjordan closed 6 years ago

mjordan commented 6 years ago

This PR adds new functionality described in #26 plus addresses some cleanup described in #33 and #34. WRT #26, I have only implemented the "presence of an OBJ file in the parent's directory" option and not any Drush options. I have also updated the README file to describe this new option. I will open PRs for the other options later if we decide we want them.

To test this PR:

  1. Make sure that the Compound Solution Pack's "Only allow compound objects to have child objects associated with them" option is unchecked.
  2. Unzip the attached .zip file and ingest its contents: drush -v --user=admin islandora_compound_batch_preprocess --target=/vagrant/issue26test --namespace=islandora --parent=some:collection, then sudo drush -v --user=admin islandora_batch_ingest. This should create two compound objects, "First compound object" (3 children) and "Second compound object" (4 children). The changes in this PR should not have any effect during this test ingest.
  3. Delete both of these objects from your collection.
  4. Copy the attached PDF file into the 'compound1' root directory, so it is a sibling of 'compound1/MODS.xml'.
  5. Re-ingest the objects, as above. The changes in this PR will have had the following effect: "First compound object" will now have the PDF Content Model, and will have the file you copied as its OBJ datastream. However, "First compound object" will also have three children, as it did during the first ingest.

issue26test.zip OBJ.pdf

mjordan commented 6 years ago

@MarcusBarnes bump on this. I could use my branch of this for my migration if you can't test and merge any time soon, so let me know.

MarcusBarnes commented 6 years ago

@mjordan I'll go through the testing steps right now and report back.

MarcusBarnes commented 6 years ago

@mjordan Tested and it works as described. Thank you!

mjordan commented 6 years ago

Sweet, thanks very much.