how to add tree_picker attribute in ui_reference field in ui page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-16-2016 03:38 AM
Hi,
I am trying to add a hierarchy view in ui page ui_reference field of cmdb location table but not able to add attribute tree_picker . Couldn't find any reference for adding tree picker attribute in <g:ui_reference name="QUERY:city=San Diego" id="${jvar_service_name}" table="cmn_location"/>.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-03-2016 05:45 AM
+1 I'm trying to do this as well. Any word on this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-04-2017 07:20 AM
Found a way to get tree-picker to work in UI page. Tree picker is activated only if url parameter "sysparm_target" is exactly the full name of the field e.g. sysparm_target=your_table_name.location.
Here is an example using "location" field:
1. Set tree_picker attribute to true for location filed.
2. Set name attribute in ui_reference tag as shown: <g:ui_reference name="your_table_name.location" table="cmn_location" show_lookup="true"/>.
3. Client side - get the value from html node with id="your_table_name.location", do not forget to escape the dot if using JQuery e.g. "#your_table_name\\.location"
4. Server side value should be available as request.getParameter("your_table_name.location"), but I haven't verified that yet;
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-31-2017 05:58 AM
If I do what you do, the value changes on the actual form and not on the UI Page... The reference field on the UI Page stays empty, while the location field on the form changes... So that's not ideal either.