WoodWing Help Center

Elvis 6 action plug-ins - configuration

Elvis 6 Action plug-ins - configuration settings

The configuration file of an Action plug-in is named 'action.config.xml' and consists of the following structure:

  • General information is specified between the <info> </info> tags.
  • Generic settings are specified between the <action> </action> tags
  • Specific settings are specified between the <config> </config> tags
<?xml version="1.0" encoding="UTF-8"?>
<plugin>
    <info>
        
    </info>

    <action>
        
    </action>

    <config>
        
    </config>
</plugin>

This article describes the generic settings.

For information about the general information settings and the specific plug-in settings, see Elvis 6 plug-in configuration files.

The generic Action settings

Generic Action settings are considered to be advanced and intended to be configured by plug-in developers.

The action plug-in configuration is quite extensive, this section contains a brief explanation for each setting.

<action>

	<url>...</url>
	
	<icon16Url>...</icon16Url>
	
	<icon24Url>...</icon24Url>
	
	<userInterface>...</userInterface>
	
	<menuAssignments>...</menuAssignments>
	
	<userAgents>...</userAgents>
	
	<enabledExpression>...</enabledExpression>
	
	<filterExpression>...</filterExpression>
	
	<requiredPermissionMask>...</requiredPermissionMask>
	
	<requiredRoles>...</requiredRoles>
	
	<flattenContainersInSelection>...</flattenContainersInSelection>
	
	<removeContainersFromSelection>...</removeContainersFromSelection>
	
	<keyBindings>...</keyBindings>
	
	<messages>...</messages>
	
</action>

Below follows a short description of each option. For full information, click the relevant link.

  • url (Required) Web page that will be loaded when the plug-in is executed. The main page and its resources can be hosted within the plug-in folder, but it can also be on an external server such as HTML, PHP, ASP, and JSP.
  • icon16Url (Required) Plug-in icon image URL, 16x16 pixels (currently not used, defined for future reference).
  • icon24Url (Required) Plug-in icon image URL, 24x24 pixels, used for the plug-in toolbar button.
  • userInterface (Required) Controls where the plug-in URL is opened: in a tab, a dialog or in an external Web browser.
  • menuAssignments (Required) Controls from which menu(s) the plug-in is available. This can be a combination of the application menu, the main button toolbar, the asset context menu and the folder context menu.
  • userAgents (Optional) Platform specific user agent used when loading the URL in a tab or dialog.
  • enabledExpression (Optional) Expression to check if the current asset or folder selection is valid. For example, the plug-in is only available when only one asset selected.
  • filterExpression (Optional) Expression to validate an individual asset or folder. For example, the plug-in exclusively works with video assets.
  • requiredPermissionMask (Optional) Permission mask validation to check if the current asset or folder selection is valid. For example, a user needs EDIT permission on the selection to perform the action.
  • requiredRoles (Optional) Required roles for the plug-in to become visible. Standard and custom roles can be configured. For example, a user needs ROLE_DOWNLOAD or ROLE_CUSTOM_ACTION_MYACTION to perform the action.
  • flattenContainersInSelection (Optional) If true, load container assets (scuh as Collections) and provide a "flat" selection of unique assets in the elvisContext. Default value: true.
  • removeContainersFromSelection (Optional) If true, remove all container assets (such as Collections) from the selection in the elvisContext. Default value: true.
  • keyBindings (Optional) Platform specific keyboard bindings.
  • messages (Required) Button labels, menu labels, tooltips, and so on. Configurable per locale.

Examples

Minimal action plug-in configuration

<action>
    <url>${pluginBaseUrl}l/index.html</url>
    <icon16Url>${pluginBaseUrl}/icon16.png</icon16Url>
    <icon24Url>${pluginBaseUrl}/icon24.png</icon24Url>
    
    <userInterface>
        <tab/>
    </userInterface>
    
    <menuAssignments>
        <menuAssignment id="toolBar" order="5"/>
    </menuAssignments>
    
    <messages>
        <entries locale="en_US">
            <entry key="button.label">My action label</entry>
            <entry key="button.tooltip">My action tooltip info</entry>
            <entry key="title">My action tab or dialog title</entry>
        </entries>
    </messages>
    
</action>

Action plug-in configuration with all options

<action>
    <url>${pluginBaseUrl}/index.html</url>
    <icon16Url>${pluginBaseUrl}/icon16.png</icon16Url>
    <icon24Url>${pluginBaseUrl}/icon24.png</icon24Url>
    
    <userInterface>
        <dialog width="900" height="900"/>
    </userInterface>
    
    <menuAssignments>
        <menuAssignment id="applicationMenu" order="3"/>
        <menuAssignment id="toolBar" order="5"/>
        <menuAssignment id="assetContextMenu" order="1"/>
        <menuAssignment id="folderContextMenu" order="3"/>
    </menuAssignments>
    
    <userAgents>
        <userAgentMacOSX>Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1</userAgentMacOSX>
        <userAgentWindows>Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.835.186 Safari/535.1</userAgentWindows>
    </userAgents>

    <enabledExpression>elvisContext.hasFilteredSelection()</enabledExpression>
    
    <filterExpression>item.hasAssetDomain("video") || item.hasAssetDomain("image")</filterExpression>
    
    <requiredPermissionMask>VP-------</requiredPermissionMask>
    
    <requiredRoles>
        <role>ROLE_DOWNLOAD</role>
        <role>ROLE_CUSTOM_ACTION_MY_DIALOG</role>
    </requiredRoles>

    <keyBindings>
        <keyBinding os="Windows" key="h" modifiers="CTRL,SHIFT,ALT"/>
        <keyBinding os="MacOSX" key="h" modifiers="CMD,SHIFT,ALT"/>
    </keyBindings>
    
    <flattenContainersInSelection>true</flattenContainersInSelection>
    
    <removeContainersFromSelection>true</removeContainersFromSelection>
    
    <messages>
        <entries locale="en_US">
            <entry key="button.label">My action label</entry>
            <entry key="button.tooltip">My action tooltip info</entry>
            <entry key="title">My action tab or dialog title</entry>
        </entries>
        <entries locale="nl_NL">
            <entry key="button.label">Mijn actie dialoog</entry>
            <entry key="button.tooltip">Mijn actie tooltip informatie</entry>
            <entry key="title">Mijn actie tab of dialoog titel</entry>
        </entries>
    </messages>
    
</action>
Was this article helpful?
0 out of 0 found this helpful / Created: / Updated:
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.