Add parent cat num to empty child cat num if pref true in QB#6419
Conversation
39ded2b to
c134943
Compare
|
! todo: |
pashiav
left a comment
There was a problem hiding this comment.
- Verify that two CO records are returned with the parent cat num for the cat num column value
- Verify that the primary cat num fill the column for the empty ones
- Verify that the additional filter is applied
Bugs
1. Adding a child CO then Saving causes IntegrityError Column 'PrepTypeID' cannot be null. Children with cat nums are still saved, while children without cat nums are not.
Workflow:
- Go to a CO and add a child with/without cat num (https://calvertmarinemuseum20250210migration6410-issue-6410.test.specifysystems.org/specify/view/collectionobject/33058/)
- Save record
- See error
- Refresh and see that the child is saved/not saved
Child with catnum:
Specify 7 Crash Report - 2025-04-24T16_28_14.904Z.txt
Screen.Recording.2025-04-24.at.11.28.09.AM.mov
Child without catnum:
Specify 7 Crash Report - 2025-04-24T16_32_08.006Z.txt
Screen.Recording.2025-04-24.at.11.31.59.AM.mov
System information:
Specify 7 System Information - 2025-04-24T16_37_23.633Z.txt
|
@pashiav, |
pashiav
left a comment
There was a problem hiding this comment.
- Verify that two CO records are returned with the parent cat num for the cat num column value
- Verify that the primary cat num fill the column for the empty ones
- Verify that the additional filter is applied
Looks good! Preference is working as expected.

Fixes #6410
Warning
This PR affects database migrations. See migration testing instructions.
Checklist
self-explanatory (or properly documented)
Testing instructions
A) Change the inheritance pref in collection app resource
In your "collection preference" app resource add this snippet of code:
C) Test the inheritance in QB with pref true