DUE TO SPAM, SIGN-UP IS DISABLED. Goto Selfserve wiki signup and request an account.
...
| Code Block |
|---|
Following is the first portlet with its all the associations and details:
<PortletCategory portletCategoryId="PROFILE" description="Profiles"/>
<PortalPortlet portalPortletId="party"
portletName="Party Info"
screenName="Party"
screenLocation="component://party/widget/partymgr/ProfileScreens.xml"
description="General information about a person or party group"
screenshot="/images/portlets/party.png"/>
<PortletPortletCategory portalPortletId="party" portletCategoryId="PROFILE"/>
<PortalPage portalPageId="PartyProfile" sequenceNum="0" portalPageName="Party Profile Portal Page" description="Party profile page using flexible Portal technology" ownerUserLoginId="_NA_"/>
<PortalPageColumn portalPageId="PartyProfile" columnSeqId="00001" columnWidthPercentage="50"/>
<PortalPageColumn portalPageId="PartyProfile" columnSeqId="00002"/><!-- no width in pixels or percent, use the rest of the space available -->
<PortalPagePortlet portalPageId="PartyProfile" portalPortletId="party" portletSeqId="00001" columnSeqId="00001" sequenceNum="0"/>
|
Screen Setup
(OFBiz Trunk)
Now following code works in the screen to have portlets in action:
Trace the screen "viewprofile" from /party/widget/partymgr/PartyScreens.xml. Here we fetch portal page details to show.We need to set portalPageId in parameters and include generic screen PortalPageScreen from component://common/widget/CommonScreens.xml
Which is as follows(Reference commit in OFBiz trunk rev. 900156):
| Code Block |
|---|
<screen name="PortalPageScreen">
<section>
<actions>
<entity-one entity-name="PortalPage" value-field="portalPage"/>
<get-related value-field="portalPage" relation |
| Code Block |
<entity-one value-field="portalPage" entity-name="PortalPage"> <field-map field-name="portalPageId" value="PartyProfile"/> </entity-one> <entity-and entity-name="PortalPageColumn" list="portalPageColumns"/> <field-map field-name="portalPageId" value="PartyProfile"/> <order-by field-name="columnSeqId"/> </entity-and> <entity-and entity-name="PortalPagePortletView" list="portalPagePortlets"> <field-map field-name="portalPageId" valuefrom-field="PartyProfileportalPage.portalPageId"/> <order-by field-name="columnSeqId"/> <order-by field-name="sequenceNum"/> </entity-and> </actions> After this we include generalized showPortalPage.ftl to render the portlets in portal page: <platform-specific><html><html <widgets> <platform-specific> <html><html-template location="component://common/webcommon/portal/showPortalPage.ftl"/></html><html> </platform-specific> </widgets> </section> </screen> |