14 Integrating the Documents Service

Oracle WebCenter enables content integration through:

This chapter describes how to integrate the Documents service in custom WebCenter applications to provide end users with a user-friendly interface to manage, display, and search documents at runtime. For more information about managing and including content in your custom WebCenter applications, see:

This chapter includes the following sections:

14.1 Introduction to the Documents Service

The Documents service provides features for accessing, adding, and managing files and folders; configuring file and folder properties; searching file and folder content in your organization's content repositories; and displaying content from a content repository on a page in a predefined template using the Content Presenter task flow.

The Documents service allows end users of your application to manage folders and documents from your company's content repositories in two ways:

  • Add any single folder or file in a content repository to a page. Individual files can be added to a page as links, images, or inline frames (depending on the file type).

  • Add a Documents service task flow to a page:

    • Content Presenter task flow

    • Document Manager task flow

    • Document List View task flow

    • Recent Documents task flow

For detailed information about each Documents service task flow and what capabilities they provide to end users of your application, see "What You Should Know About the Documents Service Task Flows" in Oracle Fusion Middleware User's Guide for Oracle WebCenter.

Note:

You can see the Documents service in action in the sample application, as described in Chapter 2, "Introduction to the WebCenter Sample Application."

To use the Documents service, you must have a content repository that contains the documents you want to manage. If the content repository you wish to use requires authentication, ensure that you set up an external application when you configure the connection to your content repository, as discussed in Section 14.2.1, "Setting Up Connections."

14.2 Basic Configuration for the Documents Service

This section describes the steps to add the Documents service to your application:

14.2.1 Setting Up Connections

Before you can use the Documents service, you must first set up the connection to your content repository. You can reuse connections you've created or create new ones. For information on creating a connection, refer to Section 13.2, "Configuring Content Repository Connections."

Once you set up a connection to a content repository, you can set the connection as active for the Documents service by selecting Set as primary connection for Documents service. You can only set one active connection at a time. If you create another connection and set the new connection as active, the first connection will no longer be active. You can always return to the Properties of the connection (in the Application Resources pane, under Connections, right-click the connection name and choose Properties) to toggle whether the connection is active.

Note:

While you can set up the connections to back-end servers at design time in Oracle JDeveloper, you can later add, delete, or modify connections in your deployed environment using Enterprise Manager Fusion Middleware Control. For more information, refer to the Oracle Fusion Middleware Administrator's Guide for Oracle WebCenter.

When you use Oracle Content Server as your content repository, the security settings depend on the connection configuration. If the connection uses External Application Service Public Credentials, there is no need to set up application security.

If the connection uses Identity Propagation, follow the steps in Section 4.1.1.1, "Implementing Security for Services."

For information on installing the back-end content repository, see Section 4.3.1 "Oracle Content Server Requirements" in the Oracle Fusion Middleware Installation Guide for Oracle WebCenter.

14.2.2 Adding the Documents Service to the Oracle Composer Catalog

Once you have set up content repository connections for using the Documents service in your application, you may also wish to enable the display of the Documents service in the Oracle Composer Catalog for use by end users of your application (as described in the chapter "Working with the Documents Service" in the Oracle Fusion Middleware User's Guide for Oracle WebCenter). The default Oracle Composer Catalog definition file has the entries for the Documents service commented out. To expose the Documents service and its task flows in the Oracle Composer Catalog at runtime, you must uncomment these entries. Refer to Section 12.2.1.4, "Enabling Documents in the Resource Catalog".

14.2.3 Adding Documents Service Task Flows at Design Time

In addition to adding the Documents service to your application to provide end users with the functionality described in Section 14.1, "Introduction to the Documents Service", you can also add Documents service task flows to your application during design time to provide these task flows built into the application for end users.

For detailed information about each Documents service task flow, see "What You Should Know About the Documents Service Task Flows" in Oracle Fusion Middleware User's Guide for Oracle WebCenter.

This section describes how to include Documents service task flows in your application in the following subsections:

14.2.3.1 How to Add a Documents Service Task Flow at Design Time

To add a Documents service task flow to your custom WebCenter application:

  1. Follow the steps in Section 4.1.1, "How to Prepare Your Application to Consume Services" to implement security.

  2. Add the Documents service to your application (see Section 14.2.1, "Setting Up Connections").

  3. Create or open a JSF page in your application where you want the task flow to be added.

  4. Choose a method for adding a Documents service task flow to the page, depending on the requirements of your application:

Note:

By default, the task flow displays as full screen at runtime. You can use ADF layout components to modify this layout. To learn more about ADF layout components, refer to the Oracle Fusion Middleware Web User Interface Developer's Guide for Oracle Application Development Framework.
14.2.3.1.1 Adding Selected Folders and Files in a Documents Service Task Flow to a Page

To add individual files or the content of folders from a content repository connection to your page:

  1. In the Application Resources panel, navigate to Connections, then Content Repository.

  2. Locate the name of your connection, then expand it if desired to navigate to a specific folder or file.

  3. Drag the folder or file to the page, and release the mouse button to display a menu of available task flows, as shown in Figure 14-1 and Figure 14-2.

    Other selections shown in the menu are additional ways to add the content to your page, as discussed in Section 13.3, "Adding Content to a JSF Page."

    Figure 14-1 Adding Content Repository Root Folder to JSF Page

    Adding Content Repository Root Folder to JSF Page
    Description of "Figure 14-1 Adding Content Repository Root Folder to JSF Page"

    Figure 14-2 Adding Subfolder to JSF Page

    Adding Subfolder to JSF Page
  4. Choose the Documents service task flow that you wish to use. If the folder or file you are adding to your page does not support a particular task flow, the task flow does not display in this menu. Refer to Table 14-1 and Table 14-2 for information on Documents service task flow support by content type and by repository type, respectively.

    Table 14-1 Documents Service Task Flow Support by Content Types

    Content Type Documents Service Task Flows Supported

    Content repository root folder

    Document Manager, Document List View, Recent Documents

    Subfolders

    Document Manager, Document List View, Content Presenter

    Documents of various types (XML, PDF, JAVA, TXT, DOC, XLS, HTM) and images (PNG, JPG, GIF)

    Content Presenter


  5. In the Edit Task Flow Binding dialog that displays, click OK to accept the default task flow parameters, or modify the parameters as desired. For more information, see Section 14.2.4, "Documents Service Task Flows and Task Flow Parameters."

  6. Save your page and the page definition file, then run your page to your browser. You can do this by right-clicking the page (not the page definition file) and choosing Run.

14.2.3.1.2 Adding Documents Service Task Flows to a Page Using the Resource Palette

To add a Documents service task flow onto your page, where you specify the initial parameters for the task flow (for example, in cases where you do not have a content repository connection, or want to use an EL expression as a parameter to dynamically bind to a target item):

  1. In the Resource Palette, expand the WebCenter Services Catalog. Under Task Flows, select the desired Documents service task flow and drag it onto your page (Figure 14-7).

    Figure 14-3 Adding Documents Service Task Flow to JSF Page

    Adding Documents Service Task Flow to JSF Page
  2. From the menu that displays, choose Region to open the Edit Task Flow Binding dialog (Figure 14-4).

    Figure 14-4 Specifying Parameters for Content Presenter Task Flow

    Specifying Parameters for Content Presenter Task Flow
  3. In the Edit Task Flow Binding dialog, specify parameter settings for the task flow. For more information, see Section 14.2.4, "Documents Service Task Flows and Task Flow Parameters."

    Note:

    For a Content Presenter task flow:
    • If you want to allow end users of your application to select the content and display template using the Content Presenter Configuration dialog at runtime, you can leave all parameter values blank except for taskFlowInstId. Enter a task flow instance ID that is unique to your application (for example, contentPresenterInstance1).

    • If you specify the content and a display template, note that Content Presenter does not support non-ASCII characters in files that are encoded using the non-UTF-8 character encoding. When users preview such files in Content Presenter, non-ASCII characters appear garbled.

  4. Save your page and the page definition file, then run your page to your browser. You can do this by right-clicking the page (not the page definition file) and choosing Run.

After you add a Documents service task flow to a page, you can subsequently modify the parameters as desired (see Section 14.2.3.2, "How to Modify Documents Service Task Flow Parameters"). End users of your application, with appropriate privileges, can also modify the task flow parameters at runtime (see Section 14.2.3.4, "How End Users Can Modify Content Presenter Task Flow Parameters at Runtime").

14.2.3.2 How to Modify Documents Service Task Flow Parameters

To modify the parameters of a Documents Service task flow after you have created the region:

  1. Go to the Bindings view of your page (click the Bindings tab next to the Source tab).

  2. Under Executables, you'll see the task flow you added. Select this task flow. Figure 14-5 shows an example of a Document List View task flow in the Executables section.

    Figure 14-5 Document List View Task Flow in the Bindings View

    Document List View Task Flow in the Bindings View
    Description of "Figure 14-5 Document List View Task Flow in the Bindings View"

  3. Next to the Executables heading, click the pencil icon to display the Edit Task Flow Binding dialog box

  4. Next to the connectionName parameter, enter the value for your connection. For example, ${'MyContentServer'}.

  5. Next to the startFolderPath parameter, enter the value for your starting path. For example, ${'/'}.

    Figure 14-6 Task Flow Binding Parameters

    Task Flow Binding Parameters
    Description of "Figure 14-6 Task Flow Binding Parameters"

  6. Click OK to add the parameters.

14.2.3.3 How to Allow End Users to Customize Documents Service Task Flows at Runtime

When you add a Content Presenter or Document List View task flow to a page in your custom WebCenter application, you can optionally allow end users who have edit privileges on the page to customize the task flow through a user-friendly interface. To provide this capability, you add an Edit action to the task flow's chrome (shown as a wrench icon) or to the Actions menu (Figure 14-7).

Figure 14-7 Documents Service Task Flow Actions Menu in Edit Mode

Documents service task flow Actions menu

To add the Edit action for use by end users of your application:

  1. Open the application's adf-config.xml file, located in the ADF META-INF folder under Descriptors in the Application Resources panel.

  2. If it is not already declared, add the cust namespace prefix, as shown in Example 14-1:

    Example 14-1 Adding cust Namespace Prefix in the adf-config.xml File

    <adf-config xmlns="http://xmlns.oracle.com/adf/config"
                xmlns:cust="http://xmlns.oracle.com/adf/faces/customizable/config"
                xmlns:adf="http://xmlns.oracle.com/adf/config/properties"> 
    
  3. Define the Edit action using the <customActions> element, as shown in Example 14-2.

    Example 14-2 Adding Edit Action in the adf-config.xml File

    <cust:customizableComponentsSecurity
    xmlns="http://xmlns.oracle.com/adf/faces/customizable/config"> 
       <customActions> 
          <customAction action="advancedEdit" location="both" 
                        rendered="#{composerContext.inEditMode}" 
                        icon="/adf/webcenter/configureheader_ena.png" 
                        text="Edit" 
                        shortDesc="Edit"/> 
       </customActions> 
    </cust:customizableComponentsSecurity> 
    

    Note:

    The location attribute specifies whether to add a wrench icon, an Edit action on the Actions menu, or both:
    • location="chrome" adds a wrench icon on the task flow chrome.

    • location="menu" adds an Edit item on the Actions menu.

    • location="both" adds both a wrench icon and an Edit item.

  4. Save the adf-config.xml file.

When you implement this functionality, the end users of your application who have appropriate edit privileges have access to user-friendly interfaces to perform task flow customization:

Note:

For more information about adding custom actions to task flows, see Section 9.3, "Enabling Custom Actions on a Show Detail Frame Enclosing a Task Flow."

14.2.3.4 How End Users Can Modify Content Presenter Task Flow Parameters at Runtime

At runtime, the parameters of a Content Presenter task flow on an editable page can be edited in two ways:

  • If you add an Edit action to the Content Presenter task flow, as described in Section 14.2.3.3, "How to Allow End Users to Customize Documents Service Task Flows at Runtime", end users can click the Edit (wrench) icon and/or select Edit from the Actions menu to display the Content Presenter Configuration dialog, where they can specify content and a display template. For end user information about the Content Presenter Configuration dialog, see "Displaying Content Using the Content Presenter Task Flow" in Oracle Fusion Middleware User's Guide for Oracle WebCenter.

  • In Oracle Composer, an end user of your application can click the properties Edit (pencil) icon for the task flow to display the Component Properties dialog. Parameters set in this way are generally intended for use at design time by developers creating a custom application, or for advanced users who want to bind a parameter to an EL expression. If an end user modifies a property value in the Component Properties dialog, the new value overrides the value specified in the Content Presenter Configuration dialog.

14.2.4 Documents Service Task Flows and Task Flow Parameters

Each Documents service task flow has its own set of parameters. You configure these values when you add the task flow to your page.

Table 14-2 specifies the task flow name that displays in the WebCenter Services Resource Palette, the content repository with which you can use the task flow, and parameters required to configure the task flow for your application.

Table 14-2 Documents Service Task Flows

Task Flow Content Repository Parameters (* = required) Description

Content Presenter

  • Oracle Content Server

datasource

datasourceType

maxResults

taskFlowInstId

templateCategoryId

templateViewId

Shows selected documents in pre-defined templates. Section 14.2.4.1, "Content Presenter Task Flow Parameters and Out-of-the-Box Display Templates" describes the parameters.

Document Manager

  • Oracle Content Server

  • Oracle Portal (read and search only)

  • File system (read and write only)

connectionName

startFolderPath

Provides comprehensive document management functionalities, such as copying, moving, pasting, and deleting files and folders. Section 14.2.4.2, "Document Manager Task Flow Parameters" describes the parameters.

Document List View

  • Oracle Content Server

  • Oracle Portal

  • File system (read and write only)

connectionName

createdAfter

createdBefore

creator

lastModifiedAfter

lastModifiedBefore

lastModifier

showFolders

startFolderPath

taskFlowInstId

Shows a simple list view of folders and documents, allows users to navigate a folder hierarchy, and enables users to customize search queries. Section 14.2.4.3, "Document List View Task Flow Parameters" describes the parameters.

Recent Documents

  • Oracle Content Server

connectionName

groupSpace

lastModifier

lastModifiedAfter

lastModifiedBefore

maxDocuments

mostRecentFirst

Shows the most recently created or modified documents by the current user. Section 14.2.4.4, "Recent Documents Task Flow Parameters" describes the parameters.


14.2.4.1 Content Presenter Task Flow Parameters and Out-of-the-Box Display Templates

Table 14-3 describes the Content Presenter task flow parameters. Table 14-4 and Table 14-5 describe the out-of-the-box display templates for single and multiple content items, which can be specified as values for the templateViewId and templateCategoryId parameters.

If an end user of your application has permissions to edit the page on which you have included a Content Presenter task flow, and opens the Content Presenter Configuration dialog for that task flow, the values shown in the dialog for the content and display template are read-only, reflecting the parameters you specify in the Task Flow Bindings dialog for the Content Presenter task flow at design time. The end user cannot modify these task flow parameters in the Content Presenter Configuration dialog.

However, an end user with permissions to edit the page can open the Component Properties dialog (if the page is managed by Oracle Composer) for the Content Presenter task flow and modify Content Presenter properties on the Parameters tab. The new values specified in the Component Properties dialog override the values specified at design time.

Table 14-3 Content Presenter Task Flow Parameters

Task Flow Parameter Type Description Default Value

datasource

string

Optional. The data source of the content. The value depends on the value of datasourceType:

When datasourceType=dsTypeSingleNode: set datasource to a single node identifier in the format: connection_name#dDocName:content_id

When datasourceType= dsTypeFolderContents: set datasource to a single node identifier in the format: connection_name#dCollectionID:collection_id

When datasourceType= dsTypeQueryExpression: set datasource to a search expression.

When datasourceType= dsTypeMultiNode: set datasource to a set of comma-delimited node identifiers in the format: connection_name#dDocName:content_id, connection_name#dDocName:content_id, ...

where:

connection_name = the name of the content repository connection

content_id = the Content ID for the content specified on the content information page for the item in the Oracle Content Server.

collection_id = the dCollectionID found in the URL for the folder information page in Oracle Content Server.

Examples:

When datasourceType=dsTypeSingleNode: myconnection.us.oracle.com#dDocName:STANL18_IDC-007619

When datasourceType= dsTypeFolderContents: myconnection.us.oracle.com#dCollectionID:45535

When datasourceType= dsTypeQueryExpression: cm_objectClass == \'IDC:GlobalProfile\' && dDocTitle like \'Big\'

When datasourceType= dsTypeMultiNode: myconn#dDocName:DOCUMENT_ID_12345,myconn#dDocName:DOCUMENT_ID_56789

None

datasourceType

string

Optional. The data source type of the content. Valid values are:

  • dsTypeSingleNode: A single content item.

  • dsTypeFolderContents: The contents of a folder.

  • dsTypeQueryExpression: The results of a query.

  • dsTypeMultiNode: An ordered list of content items.

None

maxResults

long

Optional. The maximum number of results to display when datasourceType is dsTypeQueryExpression. This value can be null.

null

taskFlowInstId

string

The unique identifier of the task flow, used internally to maintain the association of the task flow instance with its customization and personalization settings. The value is generated automatically when you add individual files or the content of folders to your page from the Application Resources Panel, displaying the content in Content Presenter task flow. The value is blank when you add a Content Presenter task flow onto your page from the Resource Palette. Enter or edit this value to set the unique identifier for the task flow.

None

templateCategoryId

long

Optional. The display template category ID to use in rendering results for multiple content items. Enter the category ID of a template that is configured in the <content-list-templates> section of templates-registry.xml. This ID may reference one of the out-of-the-box display templates listed in Table 14-5, or a custom display template that has been defined as described in Section 13.4, "Creating Custom Templates for Displaying Content Using Content Presenter".

None

templateViewId

long

Optional. The display template view ID to use in rendering results for single content items. Enter the view ID of a template that is configured in the <content-templates> section of templates-registry.xml. This ID may reference one of the out-of-the-box display templates listed in Table 14-4, or a custom display template that has been defined as described in Section 13.4, "Creating Custom Templates for Displaying Content Using Content Presenter".

None


The out-of-the-box display templates provided by Oracle WebCenter are listed in Table 14-4 and Table 14-5.

Table 14-4 Out-of-the-Box Templates for Displaying Single Content Items

Single Content Item Display Templates View ID in templates-registry.xml Description

Default Document Details View

oracle.webcenter.content.templates.default.document.details

Displays detailed information about any single content item including creation date, modification date, created by username, modified by username, path and any comments.

Default List Item View

oracle.webcenter.content.templates.default.list.item

Used by multiple content item views to display each individual item. Displays a single line with an icon and item name as a link that either displays or downloads the item when clicked.

Default View (default when no template is selected)

oracle.webcenter.content.templates.default.detail

Displays any single content item, either directly in the browser (images, HTML) or as a link that downloads the associated file when clicked.

Default List Item View for Folders

oracle.webcenter.content.templates.default.list.item

Not available for selection at runtime in the Content Presenter Configuration dialog, but used by other multiple content item templates to display folders as they process their content nodes. Displays a single line with a folder icon and the folder name.


Table 14-5 Out-of-the-Box Templates for Displaying Multiple Content Items

Multiple Content Item Display Templates View ID in templates-registry.xml Description

Accordion View

oracle.webcenter.content.templates.default.list.panel.accordion

Displays multiple content items in an accordion format, where each item can be expanded to display its details.

Bulleted View

oracle.webcenter.content.templates.default.list.bulleted

Displays multiple content items in a bulleted list format. Only content items will be displayed; folder items will be omitted.

Bulleted with Folder Label View

oracle.webcenter.content.templates.default.list.bulleted.label

Displays multiple content items in a bulleted list format. The name of the folder containing the first item in the list will display as a label above the list. This template is intended to be used with Content Source set to Contents Under a Folder to ensure that all items have the same parent folder. Only content items will be displayed; folder items will be omitted.

Carousel View

oracle.webcenter.content.templates.default.list.carousel

Displays multiple content items in a carousel format, where items can be browsed by moving a slider left or right.

Icon View

oracle.webcenter.content.templates.default.list.tile

Displays multiple content items in a tiled format with large icons and file names.

List View (default when no template is selected)

oracle.webcenter.content.templates.default.list.simple

Displays multiple content items in a simple list.

List with Details Panel View

oracle.webcenter.content.templates.default.list.details.panel

Displays multiple content items in a list on the left, with a panel to the right displaying the details of a selected item.

Sortable Table View

oracle.webcenter.content.templates.default.list.tabular

Displays multiple content items in a sortable table that includes the document name, date created, and date modified.

Tabbed View

oracle.webcenter.content.templates.default.list.panel.tabbed

Displays multiple content items as tabs that can be selected to display item details. content items in a simple list.


14.2.4.2 Document Manager Task Flow Parameters

Table 14-6 describes the Document Manager task flow parameters.

Table 14-6 Document Manager Task Flow Parameters

Task Flow Parameter Type Description Default Value

connectionName

String

Optional. The name of the connection to your content repository. If no value is entered, the default connection is used.

For example:

${'MyContent'}

The connection you selected as default in the Create Content Repository Connection dialog box. To select a default, check the Set as primary connection for Documents service checkbox.

startFolderPath

String

Optional. The name of the folder to use as the root folder for the task flow.

For example:

${'/Manuals'}

The root folder of the content repository configured with the specified connection


14.2.4.3 Document List View Task Flow Parameters

Table 14-7 describes the Document List View task flow parameters.

Table 14-7 Document List View Task Flow Parameters

Task Flow Parameter Type Description Default Value

connectionName

String

Optional. Connection Name. The name of the connection to your content repository.

The connection you selected as default in the Create Content Repository Connection dialog box. To select a default, check the Set as primary connection for Documents Service checkbox.

createdAfter

String

Optional. Limit the display of task flow content to files and folders created after a specified date and time. If no value is entered, then no "after" filtering using the creation date is applied.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}Foot 1 

For example:

${'2009-11-14T06:08:02.000+01:00'}

None

createdBefore

String

Optional. Limit the display of task flow content to files and folders created before a specified date and time. If no value is entered, then no "before" filtering using the creation date is applied.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}

For example:

${'2009-11-14T06:08:02.000+01:00'}

None

creator

String

Optional. Limit the display of task flow content to files and folders created by a particular user. Enter the user name as specified by the user's login credentials (for example, monty). If no value is entered, then documents created by any user are shown.

For example:

${'monty'}

None

lastModifiedAfter

String

Optional. Limit the display of task flow content to files and folders modified after a specified date and time.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}

For example:

${'2009-11-14T18:24:36.000Z'}

None

lastModifiedBefore

String

Optional. Limit the display of task flow content to files and folders modified before a specified date and time. If no value is entered, then no "before" filtering using the last modification date is applied.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}

For example:

${'2009-11-14T18:24:36.000Z'}

None

lastModifier

String

Optional. Limit the display of task flow content to files and folders last modified by the specified user(s). Enter the user name(s) as specified by the user login credentials, separated by a space. If no value is entered, then all modified documents are shown.

For example:

${'monty' 'monica'}

None

rootFolderPath

String

Optional. The name of the folder to use as the root folder for the task flow.

For example:

  • ${'/PersonalSpaces/monty/Public'}

  • ${'/WebCenterB5/Proj_X/Specs'}

The root folder of the content repository configured with the specified connection

showFolders

Boolean

Specifies whether to display documents and folders, or documents only:

  • ${true}: folders are shown along with files.

  • ${false} (default): folders are hidden and only files appear in the task flow.

${false}

taskFlowInstId

String

The unique identifier of the task flow, used internally to maintain the association of the task flow instance with its customization and personalization settings. The value is generated automatically when you add individual files or the content of folders to your page from the Application Resources Panel, displaying the content in Document List View task flow. The value is blank when you add a Document List View task flow onto your page from the Resource Palette. Enter or edit this value to set the unique identifier for the task flow.

None


Footnote 1 "TZ" is the time zone indicator. If the time being described is in UTC (Coordinated Universal Time), then the time zone indicator is "Z". If the time is from any other time zone, then TZ describes the offset from UTC of the time zone. For example, if the time is in California in December (Pacific Standard Time, PST), then the TZ indicator would be "-08:00".

14.2.4.4 Recent Documents Task Flow Parameters

Table 14-8 describes the Recent Documents task flow parameters.

Table 14-8 Recent Documents Task Flow Parameters

Task Flow Parameter Type Description Default Value

connectionName

String

Optional. The name of the connection to your content repository. If no value is entered, the default connection is used.

The connection you selected as default in the Create Content Repository Connection dialog box. To select a default, check the Set as primary connection for Documents service check box.

groupSpace

String

(used in WebCenter Spaces only) Optional. The name of a group space for which to display the documents recently modified or created.

None

lastModifier

String

Optional. Limit the display of task flow content to files and folders last modified by any of the specified users. Enter the user name(s) as specified by the user login credentials, separated by a space. If no value is entered, then all modified documents are shown.

For example:

${'monty monica'}

To display recent documents for only the currently authenticated user:

${securityContext.userName}

None

lastModifiedAfter

String

Optional. Limit the display of task flow content to files and folders modified after a specified date and time. If no value is entered, then documents modified in the last three months are shown.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}

For example:

${'2009-11-14T18:24:36.000Z'}

3 months prior to the current date

lastModifiedBefore

String

Optional. Limit the display of task flow content to files and folders modified before a specified date and time. If no value is entered, then no "before" filtering using the last modification date is applied.The value uses the ISO 8601 format:

${'yyyy-mm-ddThh:mm:ss.zzzTZ'}

For example:

${'2009-11-14T18:24:36.000Z'}

None

maxDocuments

Long

Optional. Limit the number of files displayed to the specified maximum. If no value is entered, then all matching files are shown.

For example: ${10}. Note that there is no single quote surrounding the value.

${null}

mostRecentFirst

Boolean

Optional. The default sort order of files in the task flow:

  • $(true) (default): the most recent documents are listed first.

  • $(false): the oldest documents are listed first.

Note that there is no single quote surrounding the value.

${true}


14.2.5 Setting Security for the Documents Service

The Documents service task flows support the same security options that are supported by the content repository connections. This service can also use an external application with dedicated user accounts to access remote content repositories, such as an Oracle Content Server or Oracle Portal. For more information about using security with content repositories, see Section 13.1, "Introduction to Content Integration." For information about using external applications, see Section 37.2, "Working with External Applications."

If you are using a content repository that handles its own authentication, such as Oracle Portal or Oracle Content Server, you can associate that content repository with an external application definition to allow for credential provisioning. You can modify your connection to your content repository to use an external application without shared or public credentials. When you do this, the External Application - Change Password task flow is automatically integrated to allow your end users to provide their credentials.

To register an external application for an existing content repository connection:

  1. In the Application Resources pane, right-click your connection name and choose Properties.

  2. In the Edit Content Repository Connection dialog box, under Authentication, select External Application.

    Figure 14-8 Selecting External Application in the Content Repository Connection Dialog

    Selecting External Application
    Description of "Figure 14-8 Selecting External Application in the Content Repository Connection Dialog"

  3. Click the green + (plus) sign to start the Register External Application wizard.

  4. On the Name page, enter an application name and application display name, then click Next.

    Figure 14-9 Naming the External Application

    Naming the External Application
    Description of "Figure 14-9 Naming the External Application"

  5. On the General page, under Authentication Details, choose BASIC from the Authentication Method list, then click Next.

    Figure 14-10 Choosing the BASIC Authentication Method

    Choosing the BASIC Authentication Method
    Description of "Figure 14-10 Choosing the BASIC Authentication Method"

  6. On the Additional Fields page, click Next.

  7. On the Shared Credentials page, click Next.

  8. On the Public Credentials page, select Specify Public Credentials, then enter the username and password for the content repository.

    Figure 14-11 Specifying the Public Credentials

    Specifying the Public Credentials
    Description of "Figure 14-11 Specifying the Public Credentials"

  9. Click Finish. You'll notice that your connection now uses the external application for authentication.

    Figure 14-12 Using the New External Application

    Using the New External Application
    Description of "Figure 14-12 Using the New External Application"

  10. In the Edit Content Repository Connection dialog box, click OK. In the Application Resources panel, you'll notice the external application now displays.

    Figure 14-13 External Application in the Application Resources Panel

    External Application in the Application Resources Panel
    Description of "Figure 14-13 External Application in the Application Resources Panel"

If you do not apply security, and the content repository requires a login to access the content, the user will not be able to authenticate, and thus will not see any content at runtime.

14.3 Advanced Information for the Documents Service

This section describes the following advanced uses of the Documents service:

14.3.1 Using the Documents Service with Other WebCenter Services

You can use the Documents service with a variety of other WebCenter services. For example, you can add tags to documents in your content repository, search across your application and retrieve documents in the results, and track recent changes to the content repository.

Note:

You can use the Tags service with the Document Manager task flow only.

You can see an example of how to use the Documents service with the Tags service in Section 23.3.1, "Optional Way to Show Tags on Pages."

To learn more about how you can use these services together, refer to Section 1.1.4, "Introduction to Oracle WebCenter Services."

Note:

When you integrate the Documents service with the Search service, the Search service returns results from all content repository connections.

14.3.2 Setting Parameters to Upload Files to Content Repositories

The Document Manager task flow allows users to upload files into content repositories. Oracle WebCenter Framework uses Apache MyFaces Trinidad to handle file upload from a browser to the application server.

To change the default settings of Apache MyFacesTrinidad, you can add three parameters to the web.xml file. To edit this file, open the ViewController project of your application. Under Web Content, open the web.xml file. In the Overview, navigate to Application > Context Initialization Parameters, then click the green plus (+) sign to add the parameters and their values (as described in Table 14-9) or simply update the code in the Source view. After you've made your changes, save the web.xml file, then restart Oracle JDeveloper

Table 14-9 Apache MyFaces Trinidad Parameters

Parameter Description
UPLOAD_MAX_MEMORY

The maximum amount of memory in kilobytes that a single file can use when uploaded.

UPLOAD_MAX_DISK_SPACE

The maximum amount of disk space in kilobytes that a single file can use when uploaded.

UPLOAD_TEMP_DIR

The directory in which the file being uploaded is temporarily stored.


For more information, see the Apache MyFaces Trinidad documentation, located at http://myfaces.apache.org/trinidad/devguide/fileUpload.html.

Note:

An attempt to upload a file displays an error in JDeveloper applications that are based on one of the following templates:
  • Generic Application

  • Java Desktop Application

  • Java Desktop Application (ADF)

  • Java EE Web Application

  • Portlet Producer Application

After you add a Document Manager task flow onto a JSF page in an application based on one of these templates, then attempt to use the task flow to upload a file into a content repository, the Upload Document page displays the message Error: A value is required.

This issue does not occur in applications created based on the following templates:

  • WebCenter Application

  • Fusion Web Application

To work around this issue and successfully upload a file using a Document Manager task flow, add the attribute usesUpload="true" to the af:form component on the JSP page.

14.3.3 Using Adapters with the Documents Service

To learn more about using existing adapters for the content repository connections, see Chapter 13, "Integrating Content."