Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Page vpath in component
cybervimal
Hi all,
I have a component which has a dropdown list populated from DB through a java class.
When the component is used in a page, I want to be able to default the selection of the dropdown in that component (during new page creation) to a particular value which depends on the vpath of the page.
So, the default selection of this dropdown changes for different category (content types) of pages.
In my custom generator java class, I get a handle only to the PropertyContext object.
With PropertyContext object, there seems to be no way to get the page vpath as PropertyContext is tied to the "Design time" rather than "run-time"
Is there any way that I can get a handle to the RequestContext object when I generate the dropdown list for the component?
Is there a way to create a drop down list in component using External rather than Generator?
Thanks,
Vimal.
Find more posts tagged with
Comments
Stokes
Vimal,
Good question. Just to clarify, at runtime on the page, does your component have a drop down list exposed to the user?
Or does the drop-down only appear at design-time and the page author's selection (only) is used in the runtime rendering?
Stokes.
cybervimal
Hi Stokes,
This drop down field is part of about 6 to 7 properties that this component exposes to the user.
So, at run-time, when this component is added to a new page, and when the user brings up the properties of the component, this drop down field is one of the properties that the user has to fill in (fill in , as in, select a value from the drop down values that the component has pulled from the DB).
Now, the problem I'am trying to solve here is , I want this dropdown to show a default value selected (from all the values it has populated from DB) - and this default value should be based on the vpath of the page the user is currently creating.