Module: structure/pure/InfoAction

The infoaction widget is a combination of an info/text widget and an "action"-widget, e.g. switch or trigger.

Use case: if you have a group of lights, you can show the number of lights currently switched on
and control the whole group in one widget.

Since:
  • 0.10.0 (as widget), 0.9.2 (as plugin)
Author:
  • Tobias Br√§utigam
Source:

Example

Example combines an info widget to show the number of lights currently switched on, and an Switch to control them

 ...
<meta>
 <mappings>
   <mapping name="OnOff">
     <entry value="0">Off</entry>
     <entry value="1">On</entry>
   </mapping>
 </mappings>
 <stylings>
   <styling name="GreyGreen">
     <entry value="0">grey</entry>
     <entry value="1">green</entry>
   </styling>
 </stylings>
</meta>
...
<infoaction>
 <layout colspan="4"/>
 <label>Lights</label>
	<widgetinfo>
   <info>
    <address transform="DPT:9.001">0/0/0</address>
   </info>
 </widgetinfo>
 <widgetaction>
  <switch mapping="OnOff" styling="GreyGreen">
   <layout colspan="3"/>
   <address transform="DPT:1.001" mode="readwrite">0/0/1</address>
  </switch>
 </widgetaction>
</infoaction>

Requires

Methods


<inner> create(element, path, flavour, type)

Creates the InfoAction widget

Parameters:
Name Type Description
element
path
flavour
type
Source:
Returns:

String - HTML representation if the widget as string


<inner> createWidget(isInfo, element, path, flavour, type)

Creates the InfoAction widget

Parameters:
Name Type Description
isInfo
element
path
flavour
type
Source:
Returns:

String - HTML representation if the widget as string


<inner> getWidgetElements(xmlElement, path, flavour, type)

Description

Parameters:
Name Type Description
xmlElement
path
flavour
type
Source:
Returns:

ret_val