The My Calendar portlet provides a full-featured calendar system to let you manage and configure appointments and reminders. The portlet also provides an edit mode to let you set calendar preferences and options.
This Java Page Flow portlet illustrates group collaboration functionality within a portlet. The portlet provides edit mode.
This sample is located in the <BEA_HOME>/<WEBLOGIC_HOME>/samples/portal/portalApp/portalApp.work application.
See Viewing the Samples in Portal Samples.
When this portlet is used in a domain (for example, in the portalApp in the Sample Portal Domain), the EJBs it uses are registered with JNDI names that can be used only once in the domain. That means you can use the following collaboration portlets in only one portal application in a domain: My Mail, My Task List, My Calendar, My Contacts, Discussion Forums, and Discussion Forum Administration. Within that portal application you can create multiple portal Web projects that can each contain multiple portals that reuse these portlets.
For example, to import the harmony_portlets.jar file into the Libraries area of Workshop, Select File > Import Library and then browse to the location of harmony_portlets.jar. When you click Open, Workshop saves the .jar file into the APP-INF/lib directory, and it appears in the “Libraries” folder on the Workshop tree. This makes the process of importing libraries easier because you don’t have to know how Workshop organizes the application directories.
You may need to create the appropriate directories in your application.
Be sure to add the harmony_portlets.jar library first, as shown in the following table.
Import this | into this WebLogic Workshop directory (create if necessary) |
<WEBLOGIC_HOME>/samples/portal/portalApp/APP-INF/lib/ harmony_portlets.jar |
<PORTAL_APP>/Libraries/ |
<WEBLOGIC_HOME>/samples/portal/portalApp/ |
<PORTAL_APP>/Modules/ |
<WEBLOGIC_HOME>/samples/portal/portalApp/ sampleportal/portlets/includes/collaboration/ native_calendar.portlet |
<PORTAL_APP>/<project>/ portlets/includes/collaboration/ |
<WEBLOGIC_HOME>/samples/portal/portalApp/ |
<PORTAL_APP>/<project>/portlets/ collaboration/nativedb/ |
Note: If you ran the create_* database script to set up your database, the collaboration tables already exist. Do not run create_* if, for example, you are using the default PointBase database and have already added records to the database. Follow these instructions instead.
for example
bea/weblogic81/portal/db/pointbase/44/collaboration_create_tables.sql
To run this script for PointBase:
Start the PointBase Console. In a command window, run
<DOMAIN>/startPointBaseConsole.cmd(.sh) Log into the console. The default login is weblogic/weblogic. Choose File-->Open. Open the collaboration_create_tables.sql script. The script opens in the Enter SQL Commands window.- Click the Execute All button. The collaboration tables are created.
- Close the PointBase Console.
<!-- Compoze Collaboration V Calendar Servlet -->
<servlet>
<servlet-name>CompozeNativeCalendarVCalendarServlet</servlet-name>
<servlet-class>com.compoze.calendar.AppointmentVCalendarServlet</servlet-class>
</servlet>
.
.
.
<!-- Compoze Collaboration V Calendar Servlet Mapping -->
<servlet-mapping>
<servlet-name>CompozeNativeCalendarVCalendarServlet</servlet-name>
<url-pattern>*.compozevcalendarservlet</url-pattern>
</servlet-mapping>
.
.
.
<ejb-ref>
<description>Unique ID Generator</description>
<ejb-ref-name>com.compoze.ejb.uniqueid.IUniqueIDGeneratorHome</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>com.compoze.ejb.uniqueid.IUniqueIDGeneratorHome</home>
<remote>com.compoze.ejb.uniqueid.IUniqueIDGenerator</remote>
<ejb-link>UniqueIDGenerator</ejb-link> </ejb-ref> <ejb-ref>
<description>Access Control Manager</description>
<ejb-ref-name>com.compoze.security.acl.IAccessControllerHome</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>com.compoze.security.acl.IAccessControllerHome</home>
<remote>com.compoze.security.acl.IAccessController</remote>
<ejb-link>AccessController</ejb-link> </ejb-ref> <ejb-ref>
<description>Calendar Manager</description>
<ejb-ref-name>com.compoze.calendar.ejb.ICalendarManagerHome</ejb-ref-name>
<ejb-ref-type>Session</ejb-ref-type>
<home>com.compoze.calendar.ejb.ICalendarManagerHome</home>
<remote>com.compoze.calendar.ejb.ICalendarManager</remote>
<ejb-link>CalendarManager</ejb-link> </ejb-ref>
For instructions on using the portlet's features, see Compoze Portlets for BEA WebLogic Portal User's Guide at http://e-docs.bea.com/wlp/docs81/pdf/compoze_portlets_users_guide.pdf.