Basic-Widgets

basic.checkbox basic.color basic.flip basic.glue basic.icon basic.input basic.listview basic.offset basic.print basic.select basic.shutter basic.slider basic.roundslider basic.stateswitch basic.symbol basic.tank basic.trigger basic.window basic.shifter


basic.trigger

A widget to trigger a logic (e. g. in SmartHome.py)

Parameters
{{ basic.trigger(id, name, txt, icon, val, type, event) }}
id
unique id for this widget (optional)
name
the name of the trigger (logic)
txt
text printed on the button (optional)
icon
icon to show on the button (optional)
val
value to send if the button is pressed (optional, default 1)
type
type: 'micro', 'mini', 'midi' (optional, default: mini)
event
trigger event: 'button', 'page', 'both' (optional, default: button)
This widget triggers a logic on the backend given by the parameter 'name'. The default function will show a button for manual triggering.
NEW: with the parameter 'event' set to 'page', the logic is being triggered automatically during page create (button is hidden) while 'both' enables both triggenring methods.
Examples
{{ basic.trigger('trigger1', 'Dev', '', 'check') }}
{{ basic.trigger('trigger2', 'Dev', 'Trigger', '', 1) }}

Author: Martin Gleiss and others

Widgets

Design

Misc