Configure the back-end services and gather the required information.
Create the portlet WAR file.
To create the WAR file:
After Portal Server software has been installed, the portlet applications will be under the PortalServer-base/portletapps/portlet directory. If Portal Server has been configured, the portlet application will be in PortalServer-DataDir/portals/portal-ID/portletapps/portlet directory (where portlet refers to SharedEvents and SharedTasks portlets).
Edit the tokens.properties file to specify customizable parameters for the portlet.
See Tokens for SharedEvents Portlet and Tokens for SharedTasks Portlet for more information.
Run ant customize.
Load SSO Adapter Template.
Change directories to PortalServer-DataDir/portals/portal-ID/portletapps/portlet/build/conf directory and type ant -f config.xml to load the SSO Adapter configuration.
Deploy the Portlets.
Create a file containing the password of the amadmin user. For example, type, echo mypassword >/tmp/ampasswd.
Type PortalServer-base/bin/psadmin deploy-portlet -u amadmin -f /tmp/ampassword -p portal-ID -i myInstance -g --userinfofile FULL-PATH-TO-userInfoMapping.properties FULL-PATH-TO-portlet.war-FILE.
Restart the container.
Add the Display Profile data to the templates.
The SharedEvents and SharedTasks portlets must be added to the Community templates to show up in new communities (created after the application has been installed). The template files are located at PortalServer-DataDir/portals/portal-ID/communitytemplates/ by default. The display profile is in the member.xml file in the template's directory.
For the portlets, do the following:
Remove the comment delimiters around the following lines to add your new channel to the available ones.
<Available> .... <Reference value="%COMMUNITY_CONTAINER%/Sharedevents"/> <Reference value="%COMMUNITY_CONTAINER%/Sharedtasks"/> </Available>
Remove the comment delimiters around the following lines to add your new channel to the selected ones.
<Selected> .... <Reference value="%COMMUNITY_CONTAINER%/Sharedevents"/> <Reference value="%COMMUNITY_CONTAINER%/Sharedtasks"/> </Selected>
Add availableDatabase in search channel.
To add, remove the comment delimiters around the following lines:
<Channel name="Search" provider="CommunitySearchProvider"> <Properties> ... <String name="%COMMUNITY_SEARCH_DB_PREFIX%_sharedevents_%PORTAL_ID%.%COMMUNITY_ID%" value="Events"/> <String name="%COMMUNITY_SEARCH_DB_PREFIX%_sharedtasks_%PORTAL_ID%.%COMMUNITY_ID%" value="Tasks"/> ... </Collection>
Remove the comment delimiters around the following lines to add the channel definition.
For SharedEvents portlet:
<Channels> .... <Channel name="Sharedevents" provider="__Portlet__sharedevents.sharedevents"> <Properties> <String name="title" value="Community Calendar Events"/> <String name="description" value="Community Events Portlet"/> <String name="width" value="thick"/> <String name="__Portlet__ps.communityId" value="|DUMMY"/> <String name="__Portlet__community.calendar.config" value="|DUMMY"/> <String name="__Portlet__ps.searchserverurl" value="|%COMMUNITY_SEARCH_URL%"/> <String name="__Portlet__ps.searchdb" value="|%COMMUNITY_SEARCH_DB_PREFIX%_sharedevents_%PORTAL_ID%.%COMMUNITY_ID%"/> <String name="__Portlet__ps.visibleurl" value="?%COMMUNITY_CONTAINER%.setSelected=%COMMUNITY_CONTAINER%/Sharedevents"/> <Collection name="__Portlet__PreferenceProperties"> <Collection name="default"> <String name="ps.communityId" value="|DUMMY"/> <String name="community.calendar.config" value="|DUMMY"/> <String name="ps.searchserverurl" value="|%COMMUNITY_SEARCH_URL%"/> <String name="ps.searchdb" value="|%COMMUNITY_SEARCH_DB_PREFIX%_sharedevents_%PORTAL_ID%.%COMMUNITY_ID%"/> <String name="ps.visibleurl" value="?%COMMUNITY_CONTAINER%.setSelected=%COMMUNITY_CONTAINER%/Sharedevents"/> </Collection> <Collection name="isReadOnly"> <Boolean name="ps.communityId" value="false"/> <Boolean name="community.calendar.config" value="false"/> <Boolean name="ps.searchserverurl" value="false"/> <Boolean name="ps.searchdb" value="false"/> <Boolean name="ps.visibleurl" value="false"/> </Collection> </Collection> <Collection name="userInfoDescriptions"> <Collection name="timezone"> <String name="en-US" value="Preferred User Time Zone"/> </Collection> </Collection> </Properties> </Channel> </Channels> |
For SharedTasks portlet:
<Channels> .... <Channel name="Sharedtasks" provider="_Portlet__sharedtasks.sharedtasks"> <Properties> <String name="title" value="Community Calendar Tasks"/> <String name="description" value="Community Tasks Portlet"/> <String name="width" value="thick"/> <String name="__Portlet__ps.communityId" value="|DUMMY"/> <String name="__Portlet__community.calendar.config" value="|DUMMY"/> <String name="__Portlet__ps.searchserverurl" value="|%COMMUNITY_SEARCH_URL%"/> <String name="__Portlet__ps.searchdb" value="|%COMMUNITY_SEARCH_DB_PREFIX%_sharedtasks_%PORTAL_ID%.%COMMUNITY_ID%"/> <String name="__Portlet__ps.visibleurl" value="?%COMMUNITY_CONTAINER%.setSelected=%COMMUNITY_CONTAINER%/Sharedtasks"/> <Collection name="__Portlet__PreferenceProperties"> <Collection name="default"> <String name="ps.communityId" value="|DUMMY"/> <String name="community.calendar.config" value="|DUMMY"/> <String name="ps.searchserverurl" value="|%COMMUNITY_SEARCH_URL%"/> <String name="ps.searchdb" value="|%COMMUNITY_SEARCH_DB_PREFIX%_sharedtasks_%PORTAL_ID%.%COMMUNITY_ID%"/> <String name="ps.visibleurl" value="?%COMMUNITY_CONTAINER%.setSelected=%COMMUNITY_CONTAINER%/Sharedtasks"/> </Collection> <Collection name="isReadOnly"> <Boolean name="ps.communityId" value="false"/> <Boolean name="community.calendar.config" value="false"/> <Boolean name="ps.searchserverurl" value="false"/> <Boolean name="ps.searchdb" value="false"/> <Boolean name="ps.visibleurl" value="false"/> </Collection> </Collection> <Collection name="userInfoDescriptions"> <Collection name="timezone"> <String name="en-US" value="Preferred User Time Zone"/> </Collection> </Collection> </Properties> </Channel> </Channels>
Add SharedEvents and SharedTasks as searchable databases in the CommunityPortlet.
Log in to Portal Server management console and select the portal where the portlets were deployed.
Choose a community enabled OrgDN (such as CommunitySample or DeveloperSample).
Select the Manage Container and Channels link and select the DP XML Tree view (from the View Type pull down list).
Click on the CommunityPortlet and add sharedevents and sharedtasks to the availableDatabases preference.
Restart the web container.
Login and verify that the service channel is displayed on your desktop.