Difference between revisions of "Keyboard Shortcuts"

From Opentaps Wiki
Jump to navigationJump to search
m (Protected "Keyboard Shortcuts": Sysop page [edit=sysop:move=sysop])
 
Line 1: Line 1:
 
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.
 
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 <tt> </tt>, and you can define other JavaScript handlers like this:
+
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 <tt>hot-deploy/opentaps-common/data/CommonSeedData.xml</tt>, 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_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" />
 
  <KeyboardShortcutHandler actionTypeId="KB_FOCUS" description="Set focus on the target DOM element" handler="opentaps.addFocusShortcut" />
Line 13: Line 13:
  
 
[[Image:Keyboard Shortcuts.png]]
 
[[Image:Keyboard Shortcuts.png]]
 +
 +
There are sample shortcuts already defined in opentaps.  In each application's <tt>data/<tt> directory, you will find a file called <tt>DemoKeyboardShortcuts.xml</tt> with these predefined shortcuts.

Latest revision as of 18:51, 6 August 2009

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 hot-deploy/opentaps-common/data/CommonSeedData.xml, 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

There are sample shortcuts already defined in opentaps. In each application's data/ directory, you will find a file called DemoKeyboardShortcuts.xml with these predefined shortcuts.