Many customers want to leverage existing NSF components in composite applications without any or minimal design changes. Especially they don't want to do any LotusScript programming to provide generic actions that every NSF component could provide out of the box. Because of this we've introduced in the first public beta of Lotus Notes 8.0 a first so called 'built-in action' that is provided by the Notes container. We identified a very common use case where an existing Notes view in a composite application is displayed but filtered by a certain category which is a property that other components pass in at runtime. Essentially this built-in action allows filtering the current UI view in a rectangle in the UI to show only certain entries that match the first sorted column in the view.
Let's take a look how you can use this feature. I've modified our simple tutorial again. Here is how the application looks after my changes. The component view at the bottom shows a Notes view that is categorized and only shows documents with the category selected in the component view at the top.
First I added another component view to the application to display the view 'by category' from the discussion database.
Then I updated the WSDL. Just download this file, rename it to sample.wsdl and refresh it into the discussion NSF using Domino Designer. The important pieces that I had to add to the WSDL are these:
<part name="CategoryPart" type="xsd:string"/>
<portlet:action name="FilterCurrentUIViewViaCategory" caption="Filter current UI view via category" description="..."/>
<portlet:param name="Category" partname="CategoryPart" caption="Filter via built-in action" description="..."/>
You can use whatever captions and descriptions you want. The important parts are that the action is called 'FilterCurrentUIViewViaCategory' and that it has an input property of the type 'xsd:string'.
After this you need to define the two wires in the CAE. One from the top component view to the old component view with the embedded view and a second wire from the component view at the top to the new component view at the bottom that uses the built-in action.
I think this concept of built-in actions is very powerful. For 8.0.1 we're trying to provide two more built-in actions:
1. full text search action that performs full text search in NSF
2. action to open any arbitrary Notes URL in a rectangle with a NSF component
Additionally we're thinking about a way to avoid having to add or update the WSDLs in the NSFs. Every NSF component could define via preference in the CA XML (through the CAE) whether it wants to register the built-in actions. We would then just read the WSDL with the built-in actions from the Notes plugin Java code so that the registration can be done by the Notes container without any changes to existing NSFs.