Home › Forums › Cascading dropdowns › 3-level cascading works but SP field not populated
- This topic has 6 replies, 2 voices, and was last updated 8 years, 8 months ago by Ashwin Raj.
-
AuthorPosts
-
-
March 8, 2016 at 03:35 #10671
I set up a “lookup” list for populating a 3-level cascading dropdown field set. So, I am able to make a selection in field# 1, and field# 2 shows up and is populated with one or more choices. Then, I make a selection in field# 2, and field# 3 shows up and is populated with one or more choices. So this part works nicely.
The other nice feature is that when any field has only one choice, it is automatically selected. But the anomaly I am encountering is that when any choice is automatically selected in a field, the underlying SharePoint text-field is not populated. Only when I explicitly select a choice in a drop-down, the underlying field is populated with the same value. At first, I didn’t understand what was happening, but when I turned on the debug mode in the script, then I was able to see what was happening. A screenshot of the relevant part of the form is attached. The initialization script is as below:
spjs.casc.init({ lookupList:"Case Types Lookup", lookupListBaseUrl:L_Menu_BaseUrl, lookupListFields:["Title","Case_x0020_Library","Document_x0020_Type"], thisListFields:["Case_x0020_Type","Case_x0020_Library","Document_x0020_Type"], dropDownDefaultvalue:"", hideEmptyDropdowns:true, autoselectSingleOption:true, clearInvalidSelection:true, debug:true });
How do I get the underlying SharePoint field to have the same value as the auto-selected single option in the corresponding drop down field?
Thanks,
AshwinAttachments:
-
March 9, 2016 at 20:02 #10707
Your form in the sceenshow looks a bit strange. Which version of SharePoint are you using?
Alexander
-
March 9, 2016 at 20:11 #10711
MOSS 2007
-
March 9, 2016 at 20:18 #10713
Are you using “publishing features” in the form? – I think I have seen this layout before.
It’s been a while since I used SharePoint 2007 (and I have never used MOSS with publishing features).
Which version of cascading dropdowns are you using.
Alexander
-
March 9, 2016 at 20:50 #10715
/* Cascading Dropdowns v3.525
* —————————–
* Created by Alexander Bautz
* alexander.bautz@gmail.com
* https://spjsblog.com
* Copyright (c) 2009-2015 Alexander Bautz (Licensed under the MIT X11 License)
* ———————————————
*/ -
March 10, 2016 at 23:23 #10726
I haven’t had other reports on this issue so I don’t think this is a bug in the solution.
Unfortunately I don’t have access to a MOSS 2007 site with publishing features so I cannot test it, but I think It could be an incompatibility there.
You can try to update to the latest version – you find it in the plugins folder in the DFFS download package: https://spjsblog.com/dffs/#Download_and_install
If this does not help, I’m afraid you must turn off the “fill single choice automatically”.
Alexander
-
March 11, 2016 at 05:41 #10728
That’s what I ended up doing? When a choice is manually selected, the fields function as expected. I appreciate your quick responses. Thanks!
-
-
AuthorPosts
- You must be logged in to reply to this topic.