grokking the paradigm quickie configurations
DESCRIPTION
Grokking the Paradigm Quickie Configurations. Dennis Dawson Principal Technical Writer EMC/Documentum. Here’s what I’m gonna talk about: Webtop Configuration Adding an Action Link Removing an Action Link. Fifteen Minutes’ Worth of Stuff. Which Files Should I Fiddle Around With?. - PowerPoint PPT PresentationTRANSCRIPT
© 2006 EMC Corporation. All rights reserved.
Grokking the ParadigmQuickie ConfigurationsDennis Dawson
Principal Technical Writer
EMC/Documentum
Grokking the Paradigm 2© 2006 EMC Corporation. All rights reserved.
Fifteen Minutes’ Worth of Stuff
• Here’s what I’m gonna talk about:– Webtop Configuration– Adding an Action Link– Removing an Action Link
Grokking the Paradigm 3© 2006 EMC Corporation. All rights reserved.
Which Files Should I Fiddle Around With?
• All of the files you need to fiddle with are in the <application root>/webtop directory
• Copy files to /webtop/custom to modify them
• Do not modify any of the files in place – only modify copies you have created in your custom directory
Grokking the Paradigm 4© 2006 EMC Corporation. All rights reserved.
Webtop/WDK Layers
“Ogres are like onions – they have layers.”- Shrek
wdk – app.xml
Grokking the Paradigm 5© 2006 EMC Corporation. All rights reserved.
Webtop/WDK Layers
“Ogres are like onions – they have layers.”- Shrek
wdk – app.xmlwdk – app.xml
webcomponent – app.xml
Grokking the Paradigm 6© 2006 EMC Corporation. All rights reserved.
Webtop/WDK Layers
“Ogres are like onions – they have layers.”- Shrek
wdk – app.xmlwdk – app.xml
webcomponent – app.xml
webtop – app.xml
Grokking the Paradigm 7© 2006 EMC Corporation. All rights reserved.
Webtop/WDK Layers
“You know what else everybody likes? Parfaits.”
- Donkey
wdk – app.xml
webcomponent – app.xml
webtop – app.xml
custom – app.xml
Grokking the Paradigm 8© 2006 EMC Corporation. All rights reserved.
Tweaking WebtopSelecting a document
• Clicking a checkbox to select one document in a list sets off an interesting chain of events in and of itself.
• Consider if you had to code by hand not only the decision tree to determine which commands should be available but also the ones that should be disabled
Grokking the Paradigm 9© 2006 EMC Corporation. All rights reserved.
The Magic Behind the Scenes
• When the multiselect object is rendered, the table multiselectActionIdTbl stores Boolean values used to manage which dynamic commands are available
Doc1.htmDoc2.htmDoc3.htmDoc4.xmlDoc5.htmDoc6.htm. . .
checkout checkin cancelco . . .
001111
110000
110000
Grokking the Paradigm 10© 2006 EMC Corporation. All rights reserved.
Simple Configurations Have High Value
• The most elaborate, complex behavior is pretty much handled for you
• As a result, the only thing you really need to do is reference a control and action on the JSP, and leave the “work” to the server at runtime
Grokking the Paradigm 11© 2006 EMC Corporation. All rights reserved.
Adding an Action LinkCopying toolbar.jsp
• In unstripped.jar, locate toolbar.jsp and copy it to the /custom/toolbar directory
Grokking the Paradigm 12© 2006 EMC Corporation. All rights reserved.
Adding an Action LinkCopying toolbar_component.xml
• Locate the /webtop/config/toolbar_component.xml configuration file and copy it to the custom/config directory
Grokking the Paradigm 13© 2006 EMC Corporation. All rights reserved.
Adding an Action LinkConfiguration
• Reconfigure the toolbar component to look for our custom page
...<pages> <start>/custom/toolbar/toolbar.jsp</start></pages>...
Grokking the Paradigm 14© 2006 EMC Corporation. All rights reserved.
Adding an Action LinkModifying toolbar.jsp
• Note the script calls at the top of toolbar.jsp.
• These provide access to the utility scripts that support common form behaviors and dynamic actions
<dmf:webform/>
<script
language="JavaScript1.2"
src='<%=Form.makeUrl(request,
"/wdk/include/dynamicAction.js")%>'
/>
Grokking the Paradigm 15© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the Rename command
• To add the Rename command to the toolbar, I can add another cell to the HTML table and insert this minimal code:
<td nowrap> <dmfx:actionlink action="rename" dynamic="multiselect" label="Rename" /></td>
Grokking the Paradigm 16© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the Rename command
• Here’s the Rename action link we just added:
Grokking the Paradigm 17© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the Rename command
We can add more attributes to improve the look and feel
<td nowrap> <dmfx:actionlink action="rename" dynamic="multiselect" label="Rename" cssclass="toolbaractions" src="icons/toolbar/icon_checkout_16.gif" srcdisabled= "icons/toolbar/icon_checkout_disabled_16.gif" linkspacer="10" /></td>
Grokking the Paradigm 18© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the Rename command
• Here’s the Rename action link with formatting:
Grokking the Paradigm 19© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the History command
<td nowrap> <dmfx:actionlink dynamic="singleselect" label="History" action="history"
cssclass="toolbaractions" src="icons/toolbar/icon_checkout_16.gif" srcdisabled= "icons/toolbar/icon_checkout_disabled_16.gif" /></td>
Grokking the Paradigm 20© 2006 EMC Corporation. All rights reserved.
Adding an Action Linkfor the History command
• Here is the new History action link. Note that when multiple objects are selected, Rename is active, but History is not
Grokking the Paradigm 21© 2006 EMC Corporation. All rights reserved.
Removing an Action Link
• You can remove an action link from the interface by commenting out its code
<!-- DD 11/16/06 td nowrap>
<dmfx:actionlink
cssclass="toolbaractions" dynamic="multiselect" name="add" action="addtoclipboard" nlsid="MSG_ADD_TO_CLIPBOARD" src="icons/toolbar/icon_copy_16.gif" srcdisabled="icons/toolbar/icon_copy_disabled_16.gif" linkspacer="10" showifdisabled="true" showifinvalid="true"/>
</td -->
Grokking the Paradigm 22© 2006 EMC Corporation. All rights reserved.
Removing an Action Link
• Here is the toolbar with the Add to Clipboard command removed:
© 2006 EMC Corporation. All rights reserved.
Clarifications/comments?Please send them to:
WDK Questions? Please visit:http://developer.emc.com/developer/