-
Bug
-
Resolution: Won't Fix
-
Neutral
-
None
-
5.7
-
None
-
None
When setting names of the newly created nodes programatically there is a conflict if jcrName is also configured (e.g. you want to show your editors real name of the node, but in read only mode so that they can't change it and it is set according to predefined rules).
To reproduce (in contacts app):
#1 observe that upon creation of new contact, node is saved with name consisting of first letter of first name and full last name
#2 in editor form add extra text field with name=jcrName
#3 try to create new contact leaving newly created jcrName field empty
#4 observe failure to save the dialog (btw save button stays blocked even after correcting the error. not very nice)
#5 try to create new contact filling newly created jcrName field with some value (different than normally autogenerated value for contact node name)
#6 observe that upon saving of the contact, value set in jcrName field is discarded and replaced with autogenerated value.
Expected behavior:
Either autogeneration always wins and thus it should not be required to fill such field with a value
or
existence of field (in rw mode) takes precedence over generated value and thus should not be overwritten.
In RO mode on the other hand (i.e. when field has set readOnly==true) it's value should be only displayed and not considered when saving the dialog at all (i.e. autogenerated node name mechanism wins).
Also when saving fails, it fails with very counterproductive error:
info.magnolia.ui.api.action.ActionExecutionException: javax.jcr.PathNotFoundException: firstName at info.magnolia.ui.form.action.SaveFormAction.execute(SaveFormAction.java:92) at info.magnolia.ui.api.action.AbstractActionExecutor.execute(AbstractActionExecutor.java:62) ....
- caused by
-
MGNLUI-4081 readOnly checkbox doesn't appear in JCR data
- Closed