metacatui icon indicating copy to clipboard operation
metacatui copied to clipboard

When a metadata doc is opened in the editor with no resource map, check for broken resource map chains

Open laurenwalker opened this issue 7 years ago • 1 comments

When the editor is opened for an existing metadata doc with no resource map, we should check the system metadata to see if it obsoletes another metadata doc. If so, we can query for the resource map ID of the previous version and open that resource map in the editor, as if the chain were never broken.

An example of where this is useful:

  • Someone opens the editor for an existing package, edits, and clicks Submit
  • While the package is saving, the user leaves the page
  • The resource map is never updated on the server, but the EML is
  • The user opens the updated EML in the editor and sees that the rest of the package is missing because the resource map was never updated previously
  • The improvement described above would grab the most recent resource map for that EML version chain and use that in the editor

See #558

laurenwalker avatar Apr 18 '18 16:04 laurenwalker

The new ResourceMapResolver and VersionTracker classes will make this task a lot easier. If there IS an EML doc with a past resource map, do we always want to revert to that one? are there cases where that would be problematic? @mbjones @jeanetteclark

robyngit avatar Aug 05 '25 17:08 robyngit