Location (attribute of action)

From JRapid

Jump to: navigation, search

location is an attribute of action.


Contents

Description

The location attribute specifies where to render an action. If location is not defined, listing is taken as the default value.

Available locations are:

listing
Renders the action widget at the bottom of the entity's listing, (right next to the ADD and REMOVE buttons).
local
Listing views that handle this location will render the action somewhere at a record/row level.
Built-in views that support the 'local' location are: 'basic', 'table' and 'thumbnails'.
NOTE: in the case of the thumbnails view, the action widget is rendered inside the info box shown on mouse over of each record.
form
Renders the action at the bottom of the entity's form (right next to the OK and CANCEL buttons).

NOTE: take into account that displayactiongroups may prevent an actiongroup for being present in a listing or form.

Usage

<action label = LABEL 
    type = "javascript | relatedlisting | relatedentity | openentity | report"
    location = "listing | form | local"
/>

Examples

  • "listing" location (widget='button'):
<action name="discardOpportunity" label="Discard" 
    type="relatedentity" entity="Discard" defaultset="defaultForOpportunity" 
    location="listing" widget="button" />
"listing" location with "button" widget


  • "form" location:
<action name="discardOpportunity" label="Discard" 
    type="relatedentity" entity="Discard" defaultset="defaultForOpportunity" 
    location="form" />
"Form" location
  • "Local" location:
<action name="showMap" label="Show property location" 
    type="javascript" function="alert" 
    location="local" />


  • action child of actiongroup with location='listing' and widget='select':
<actiongroup name="exampleGroup" label="More actions..." 
    location="listing" widget="select">
    <action name="discardOpportunity" label="Discard" 
        type="relatedentity" entity="Discard" defaultset="defaultForOpportunity" />
    (...more actions...)
</actiongroup>
actiongroup with "listing" location and "select" widget

See also

Personal tools