Enable/disable associated triggers

Build 1501 on 14/Nov/2017  This topic last edited on: 13/Sep/2015, at 15:04

In version 1.4 (starting from build 1.4.1411.0) it is possible to enable/disable triggers associated with the logged user directly from the 'Settings' form:

notificationstousers

These triggers are typically notifications - hence the label 'Notifications' instead than 'Triggers' in the form.

At the moment, it is possible to access to such triggers only from Web interface.

The list of triggers appearing in the personal settings is defined in the new 'UserTriggers' section of the portal configuration files (BasePortalConfig, PortaCofig, gnpcXXXX_Config):

  <GNPortalConfiguration

    xmlns="http://www.teradp.com/schemas/GN4/1/GNPortalConfiguration.xsd"

    xmlns:xp ="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:l="http://www.teradp.com/schemas/GN4/1/WinUI"

    xmlns:cs="clr-namespace:TeraDP.GN4.Common.Search;assembly=Common"

    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

    xmlns:gn4="urn:schemas-teradp-com:gn4tera"

    xmlns:ve="http://www.teradp.com/schemas/GN4/1/ObjectValidationErrors.xsd"

    xmlns:msxsl="urn:schemas-microsoft-com:xslt">

 

    <tabsOrder>

      <tab pageName="home" />

    </tabsOrder>

 

    <userTriggers>

      <userTrigger

        label="UserTriggerTaskAssigned"

        attrName="task.userRef" 

        wfName="assignedToNotification"

        priority="0"

        profile="">

        <pars>

          <add key="applicationUrl" value="http://localhost/GN4"/>

        </pars>

      </userTrigger>

    </userTriggers>

  

    . . . 

 

  </GNPortalConfiguration>

The value of 'label' is the text that appears in the user settings form - translated using scope 'Default'. The other values describe the trigger - that is always a workflow execution triggered by the current user as a referencing object.

In the example above the workflow 'assignedToNotification' (wf_assignedToNotification.xml) will be scheduled for immediate execution with priority 0 and no execution profile every time a task is assigned or unassigned to the current user.

The workflow receives the additional parameter 'applicationUrl' with value 'http://localhost/GN4'.

The list of triggers displayed in the user settings form is obtained merging the lists in BasePortalConfig.xml, PortalConfig.xml and the application-specific gnpcXXX_Config.xml.

Triggers with the same attribute and workflow ('attrName' and 'wfName' respectively) override each other, whereas trigger with either a different attribute or a different workflow are added to the list.

See also

http://forum.teradp.com/topic.asp?whichpage=1&TOPIC_ID=701

http://forum.teradp.com/topic.asp?whichpage=1&TOPIC_ID=750

Associate trigger to user