Field set to readonly does not pass it's value
I have a task list that I have appearing on my form using the Related Items object in FD.
I use the following code to automatically associate a new task with the parent item on the form:
var parentID = fd.getSourceID();
if (parentID) {
fd.field('ProjectName').control().value(parentID);
fd.field('ProjectName').readonly(true);
}
I set the value to readonly on the task list form so that the user cannot modify the association, but when I do this, it doesn't appear to save that value (it chooses the first item in the list instead each time). When I disable the readonly line, everything works as expected.
Is there a way for me to disable the value while having the selection saved?
Thanks in advance
I use the following code to automatically associate a new task with the parent item on the form:
var parentID = fd.getSourceID();
if (parentID) {
fd.field('ProjectName').control().value(parentID);
fd.field('ProjectName').readonly(true);
}
I set the value to readonly on the task list form so that the user cannot modify the association, but when I do this, it doesn't appear to save that value (it chooses the first item in the list instead each time). When I disable the readonly line, everything works as expected.
Is there a way for me to disable the value while having the selection saved?
Thanks in advance
- Dmitry Kozlov
- Site Admin
- Posts: 1524
- Joined: Thu Jun 07, 2012
Please, read the following thread:
viewtopic.php?f=1&t=397
viewtopic.php?f=1&t=397
-
- Information
-
Who is online
Users browsing this forum: No registered users and 7 guests