Keyboard Shortcuts

From Opentaps Wiki
Revision as of 18:48, 6 August 2009 by Sichen (talk | contribs) (Protected "Keyboard Shortcuts": Sysop page [edit=sysop:move=sysop])
Jump to navigationJump to search

Many older mainframe or desktop-based business applications have keyboard shortcuts, or hotkeys, that allow you to navigate the application by using keyboard sequences such as F2, Ctrl-FT, Ctrl-O-E. opentaps supports a similar capability. You can configure keyboard shortcuts for your users, either globally for all the application or for a particular applications such as CRM or purchasing.

Configuring keyboard shortcuts is a two-step process. First, you need to have a JavaScript handler for your shortcuts. Opentaps comes with two default handlers, KB_URL and KB_FOCUS. The first one redirects the browser to a different URL, the second one focuses the browser on an element of the current screen document. These are defined in , and you can define other JavaScript handlers like this:

<KeyboardShortcutHandler actionTypeId="KB_URL" description="Redirects to the target URL" handler="opentaps.addUrlShortcut" />
<KeyboardShortcutHandler actionTypeId="KB_FOCUS" description="Set focus on the target DOM element" handler="opentaps.addFocusShortcut" />

Then, you would define the shortcuts for your applications using the KeyboardShortcut entity, like this:

 <KeyboardShortcut shortcutId="CRMSFA_FIND_OPPRT" sequenceNum="120" shortcut="f6" actionTypeId="KB_URL" actionTarget="findOpportunities" applicationName="crmsfa" description="Find Opportunities" />

If you do not specify an application name, then the shortcut will be valid for all the applications.

Once you have defined the shortcuts, the user can click on the [Shortcuts] link in the upper right-hand corner, and he would see the shortcuts available:

Keyboard Shortcuts.png