Dynamic Picklist in Liferay Forms using Objects
Written By
Madhusudan Sharma
How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!
While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.
Legacy Article
You are viewing an article from our legacy "FastTrack"
publication program, made available for informational purposes. Articles
in this program were published without a requirement for independent
editing or verification and are provided"as is" without
guarantee.
Before using any information from this article, independently verify its
suitability for your situation and project.
Issue
- We have created a Liferay form with Object and used the concept of dynamic picklist (data provider + picklist).
- However, we're facing issues with saving the data (selected from the picklist) upon form submission. The data selected in the picklist is not getting saved.
Resolution
- The reason the data is not being saved for the Picklist is due to incorrect use of the Picklist.
- The current versions of Liferay do not support the integration of Picklist with Data Provider as there is no integration between the Picklist and the Data Provider.
-
Therefore, the picklist needs to be populated manually with values, and it's not possible to do this dynamically.
- Additionally, please note that Picklist is an application for creating standard lists of values that are understood across the Liferay Portal. The process of creating a Picklist includes creating the initial list and adding items to it. Once these values are defined, they can be used in supported applications.
- However, as a workaround, you may leverage the concept of creating custom objects instead of picklists and then create relationships between them. These would be very simple objects, but you would need those relationships.
Did this article resolve your issue ?