Only change CO -> catNum for new COs when COT changes#6300
Conversation
Triggered by 3f7ba75 on branch refs/heads/issue-6299
emenslin
left a comment
There was a problem hiding this comment.
- Ensure that when the CollectionObjectType changes, the catalogNumber changes accordingly to match the CollectionObjectType's format
- Save the CollectionObject with a Type which has an auto-incrementing portion and ensure that it is auto-incremented properly (does not save with any
#placeholders from the format) - Ensure that changing the CollectionObjectType for the CollectionObject does not change the CollectionObject's CatalogNumber
Looks good, cat # is not changed when COT is changed after save
Areyes42
left a comment
There was a problem hiding this comment.
- Ensure that when the CollectionObjectType changes, the catalogNumber changes accordingly to match the CollectionObjectType's format
- Save the CollectionObject with a Type which has an auto-incrementing portion and ensure that it is auto-incremented properly (does not save with any
#placeholders from the format) - Ensure that changing the CollectionObjectType for the CollectionObject does not change the CollectionObject's CatalogNumber
Looks good!
combs-a
left a comment
There was a problem hiding this comment.
-
Ensure that when the CollectionObjectType changes, the catalogNumber changes accordingly to match the CollectionObjectType's format
-
Save the CollectionObject with a Type which has an auto-incrementing portion and ensure that it is auto-incremented properly (does not save with any
#placeholders from the format) -
Ensure that changing the CollectionObjectType for the CollectionObject does not change the CollectionObject's CatalogNumber
Everything looks pretty good to me!
Switching to a different type and back will trigger unload protect even if no other changes were made--I doubt that this will have any serious ramifications, but if there's any concerns I'm potentially missing those should be brought up. I doubt people will be switching to a different COT and back most of the time as well, so user experience most likely won't be too affected.
Fixes #6299
From #6261 (comment)
This PR implements the third suggestion of the above; that is, the Catalog Number will not change for existing CollectionObjects whenever the CollectionObjectType changes.
Checklist
self-explanatory (or properly documented)
Testing instructions
For a Collection which has more than one CollectionObjectType with differing CatalogNumberFormatNames, and at least one CollectionObjectType with an auto-incrementing numeric Formatter:
Go to a new CollectionObject DataEntry Form
Ensure that when the CollectionObjectType changes, the catalogNumber changes accordingly to match the CollectionObjectType's format
Save the CollectionObject with a Type which has an auto-incrementing portion and ensure that it is auto-incremented properly (does not save with any
#placeholders from the format)Go to an existing CollectionObject's DataEntry form
Change the CollectionObjectType to the type which has an auto-incrementing numeric portion
Ensure that changing the CollectionObjectType for the CollectionObject does not change the CollectionObject's CatalogNumber