-
Type: Improvement
-
Status: Resolved
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 2021
-
Component/s: Core
-
Release Notes Summary:You can now make the elements of a multi-valued property non nullable by putting {{nxsv:nillable="false"}} onto the {{xs:list}} xml element.
-
Release Notes Description:
-
Tags:
-
Backlog priority:650
-
Sprint:nxplatform #92, nxplatform #93, nxplatform #94
-
Story Points:5
If a string property is multivalued and required, and the property is being set with a '[null]' value, it should not be valid.
Ex.
curl -n localhost:8080/nuxeo/api/v1/path/default-domain/workspaces/ws1 -d '{"entity-type":"document","name":"fil3","type":"File","properties":{"dc:title":"fil3","mysch:str1":[null]}}' -H content-type:application/json
Attached jar file contains an example schema that is added to the File doctype with an override. To reproduce:
- move hbrown-SANDBOX-20230308-SNAPSHOT.jar to nxserver/plugins and start Nuxeo
- create a new File document with 'mysch:str1' set to '[null]' (not 'null')
- is related to
-
NXS-6915 Add the possibility to make elements in an array of scalar non nullable
- Resolved