Open jechols opened 2 weeks ago
Maybe this is being over-engineered. This can be a much easier change if the MARC XML upload is kept separate from title entry, and we can look for integration opportunities another time.
We could even use the upload to pre-create a title, but not bother associating the file with the title: NCA reads MARC and sends it to staging and prod ONI Agents, then if the LCCN is unique, the title form is pre-filled.
When creating a new title, allow a user to just upload MARC XML instead of filling out a form. Parse the XML, fill in fields, and present an edit view so they can tweak it, add sftp info, etc.
Existing titles should be able to get MARC XML associated with their records for future use. It might make sense to only allow this after some sanity checks. e.g., the uploaded MARC has the same LCCN obviously, but also the same title.