Digging Webcenter Services Part II : Document Services – Part I

By rajesh | October 13, 2013 | 1 Comment

I am hoping, you have gone through the other posts as well on webcenter services.

I am here again to give you feel about Webcenter Document Services. I my early post, I explore Content Presenter service.

The Documents service task flows provide a variety of formats to display folders and files, including wikis and blogs, on a page in a Framework application. You can choose the task flows appropriate for your application to provide features for accessing, adding, and managing folders and files; configuring and viewing file and folder properties; and searching file and folder content in Content Server.

In this, I will configure other available services as well, like Document Explorer, Manager, Navigator,  document upload, document viewer, Folder View, List Viewer, Mini Properties, Properties, Recent Documents, and Document Version History.

Okay, To start with, a few prerequisites to follow.

You need to have a Content Server[repository].

A successful connection to this content server through your jdeveloper. Follow this published post to configure such :

http://smconsultant.com/configure-web-center-content-in-jdeveloper-to-leverage-out-of-box-web-center-functionality-part-i#comment-4993

 

You need to install oracle webcenter extension in jdeveloper. Follow this published post to achieve the same :

http://smconsultant.com/installing-webcenter-extension-for-jdeveloper11g

 

After completing all these prerequisites, you will be good to explore these document services.

Let’s choose few of the document services to start with and I will leave rest to configure as per your business requirement and your interest or I will cover those remaining in my next post :

For this post, I will configure following services :

1)      Document Explorer

2)      Document Manager

3)      Folder View

4)      Document Properties and

5)      Document Version History

 

Let’s take one by one, to start with, Document Explorer:

What all you can do with this service.

Displays folders and files in two panes,

combining the functionality of the Document Navigator and Folder Viewer task flows.

It provides in-place previewing and editing, and robust management capabilities with an interface that should be familiar to users of Windows Explorer.

You will see this in Size: medium to full page width.

Let’s configure it.

Go to your resource palette in jdeveloper.

Explore the webcenter services or taskflow section and scroll down to find all available document services.

Create a JSF page and drag and drop document explorer service on  the page like this :

1

It will ask you to choose region, so like I said, we will stick to the static region.

And it will ask you to fill up few parameters, see this screen shot and I will explain these :

2

 

Let’s take it one by one then :

Connection Name : The name of the connection to your repository in jdeveloper. This parameter is optional and if you want you can keep it blank.

What will happen in that case, it will find out the primary connection in the application and pick it by itself.

StartFolderPath : This parameter is your source for the content. You need to set it to your contribution folder, for which you want to configure document explorer.

ResourceID is something unique number for this resource.

Readonly parameter will make your content read only and you would not be able to modify it after you have configured it once, if you make it true. So, better make it false as one should wish to modify the documents at runtime.

ShowDocument parameter will make your taskflow capable to show only documents.

What this is, let’s take an example, suppose you have set a startfolderpath to a folder which further contains folders along with documents.

By making this parameter true, your explorer will only show the documents, not the sub-folders.

Now, take a look at other parameters in this screen shot :

3

 

FeaturesOff parameter deals with the attributes which you do not want to offer your end user with this taskflow.

Like, if you do not want your end user to be able to search in this explorer, you can enter your attribute values in this parameter.

ShowFolders parameter will be similar like showdocuments, making it true will only show folders with in your startFolderPath destination.

treenavCollapsed parameter will be responsible to show a tree like structure in your document explorer or not.

If you make it true, all the content with in your document explorer, will comes as a tree like structure.

PageSize, parameter will deal with the page size on which you are exposing your taskflow. You can set it to a numeric value and only that much documents will comes in your container.

So, let’s fill up this dialog to show all the contents with in a folder.

4

 

So, I am setting it to fetch all the contents with in “test” folder under contribution folder.

Yes, that is it. So, just run your page to see the outcome.

5

 

You will be good to go with your document explorer then.

As name suggest, you could play with this as per your business requirements.

 

Let’s take another one : Document Manager:

For your ease of use, I am putting all these services taskflows in panel tabbed component.

So  that you will be able to see all the services on one single page.

Needless to say, go to your resource palette in jdeveloper.

Drag and drop your document manager service on your jsf page to get the parameter dialog box.

Just remember to drop it as a static region.

See this screen shot to get a view at options you will have to  fill up :

6

 

You see all the parameters are similar like document explorer services, other then just one.

Refer earlier service details, one add on is layout parameter, you can set it to change the look and feel of the taskflow or you can keep it blank to have a default view.

Like here, I set it to explorer view, lets fill up other parameters and save the page.

7

 

Time to run the page.

To see the outcome.

Refer this screen shot :

8

 

So, you see there is no any difference between these two services, but one parameter, layout.

Output of both the document services is similar.

Plat with this, and do not forget to play in conjunction with the ADF security.

Let’s take another one, Folder View

Add another tab in your panel tabbed component on jsf page and name it folder view.

Go to resource palette to drab one and drag and drop this as a static region on the page, like this :

9

 

After this, you will come up with a parameter dialog for this folder view service.

Refer this screen shot :

10

 

All the parameters are similar other than the two,

_contentPresneter and _stateManager.

These two additional parameter are related to play with the dynamic region.

By using which you can pass through parameters to this taskflow at runtime.

Which we are not dealing with in this post, so fill up the other parameters like connectionNAme and statFolderPath to start with.

Your parameter window will look something like this then :

11

 

I have set this to my Contribution Folder.

Click Ok and save your page.

Finally run this to see the outcome of this service.

12

 

Now, we have left with two options for this post, Document Properties and Version History.

Let’s implement these in one go.

Document Properties and Document Version History :

Same old steps, drag and drop Document property taskflow on jsf page as a static region.

Refer this screen shot for parameter dialog :

13

 

Like clearly in screen shot, IF at all you want to show properties for any specific document, you may want to utilize this service.

I am setting it to one of the document from contribution folders.

Format to set ResourceID will be something like this :

[Connection name to repository]#[metadata in UCM]:[Content ID in content server for this document]

Keep readonly parameter as false to keep your taskflow interactive to end user.

Say ok and save the page,

Configure your document version history as well , here only.

Follow the same steps to get the Parameter dialog.

Something like this will come up :

14

 

Now, only work left is to set these parameters based on your business requirements.

Like, I am going to set this to a particular document from content server.

But In need to see this service full at working,

I first need to create two versions of a document in my repository.

Let me do it on my own and you could ask your repository administrator.

After creation of multiple versions of a document in my oracle content server, I will come in jdeveloper to fill up these values and will need to connect this service to that specific document.

Follow this :

15

 

We are done with this now.

Let’s save the page and run it to see the outcome of both the services we have just configured.

Output for the version history :

16

 

You see, you will be able to track your document with all the versions present in against of that document in the content server.

Let’s have a look at the output of document properties :

17

 

See that, you will be able see all the meta data related to this particular document.

Even you will be able to edit the properties of this document from here itself.

Utilize these services as per your requirements.

Here you will be able to find the sample application :

DocumentServices

 

1 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *