Instance: Alternative Title Should Be Required When Type is Specified
Description
CSP Request Details
CSP Rejection Details
Potential Workaround
Attachments
Checklist
hideTestRail: Results
Activity

Anya August 8, 2019 at 7:41 PM
Both bugs are resolved in snap-shot

Charlotte Whitt June 3, 2019 at 10:42 AMEdited
Hi - In Inventory we have implemented the UX behavior recommended by Kimie Ou-Yang, but this behavior might have changed.
Will you confirm, that the wanted UX behavior is like the button is in the Order app - see:
I this behavior in the UX guideline? I might have missed it.
Thanks!
Btw - another question. Are we using red asteriks, or black asteriks to indicate a required element?

Cate Boerema May 28, 2019 at 2:52 PM
Just assigning to and putting in draft until expected behavior is worked out. Charlotte, once you've got the behavior clarified, please unassign, put this in Open.
Lisa Sjögren May 24, 2019 at 2:02 PMEdited
The instance record with a null value in alternativeTitleTypeId.
If alternativeTitleTypeId is mandatory under the condition that there is an alternativeTitle element, as a user I would not expect it to be possible to save the instance without selecting a value (other than null).
{
"instances" : [ {
"@context" : "http://localhost:8082/inventory/instances/context",
"id" : "c1e5c869-2184-4e95-87d4-0ad2eef9288a",
"hrid" : "in00239307",
"source" : "manual",
"title" : "A wonderful book","alternativeTitles" : [ {
"alternativeTitleTypeId" : null,
"alternativeTitle" : "Or is it?"
} ],
"editions" : [ ],
"series" : [ ],
"identifiers" : [ ],
"contributors" : [ ],
"subjects" : [ ],
"classifications" : [ ],
"publication" : [ ],
"publicationFrequency" : [ ],
"publicationRange" : [ ],
"electronicAccess" : [ ],
"instanceTypeId" : "526aa04d-9289-4511-8866-349299592c18",
"instanceFormatIds" : [ ],
"physicalDescriptions" : [ ],
"languages" : [ ],
"notes" : [ ],
"statisticalCodeIds" : [ ],
"metadata" : {
"createdDate" : "2019-05-23T08:46:01.320+0000",
"createdByUserId" : "e6e0fc2c-6e39-4888-9998-2de36841f2cb",
"updatedDate" : "2019-05-23T08:46:01.320+0000",
"updatedByUserId" : "e6e0fc2c-6e39-4888-9998-2de36841f2cb"
},
"links" : {
"self" : "http://localhost:8082/inventory/instances/c1e5c869-2184-4e95-87d4-0ad2eef9288a"
}
} ],
"totalRecords" : 1
}
Lisa Sjögren May 23, 2019 at 4:29 PMEdited
Hi !
That is what I expected. But since I was able to save the instance after adding an alternative title with a title value but no type value (see altTitleType2.JPG). So it appears it is not actually mandatory to fill in the type element.
Details
Assignee
Matt ConnollyMatt ConnollyReporter
Lisa SjögrenLisa SjögrenPriority
P2Story Points
5Sprint
NoneDevelopment Team
ProkopovychFix versions
TestRail: Cases
Open TestRail: CasesTestRail: Runs
Open TestRail: Runs
Details
Details
Assignee

Steps to reproduce:
1. Go to Inventory, click New to create a new instance
2. Fill in fields: Resource title, Resource type
3. Click Add alternative title and fill in field Alternative title type, but leave field Alternative title untouched. Note the red asterisks, indicative of mandatory fields, next to the Alternative title and Type.
4. Click Create instance
5. Record saves without error (this is a bug)
6. Now edit the record and delete the alternative title row and create a new empty alternative title row
7. Switch it around this time and populate the Alternative title without populating the Alternative title type
8. Click create instance
9. This time save is prevented (this is good) BUT, the Alternative title field is getting a red border and "Please fill this in to continue" message even though it is populated (this is a bug)
Expected result:
Bug 1: When Alternative title type IS filled in and Alternative title is not, record save should be prevented. Alternative title field should get red box and "Please fill this in to continue" message
Bug 2: When Alternative title type is NOT filled in and Alternative title IS, record save should be prevented (this is working) and only Alternative title type field should have red border and required message
Actual result:
Bugs described in repro steps
NOTE: Ideally, if you open an alternative title row and don't populate any data (type or title), you should be able to save the record without validation message and the blank row should just be removed. This would be better from a usability perspective, but if it's not easy to do, we shouldn't let it hold up this bug fix.