Skip to content
Stand with Ukraine flag

Short Right Drain Pipe

Short right drain pipe SCADA symbol

The Short right drain pipe widget represents a short horizontal pipe segment with the drain outlet directed to the lower right. It indicates leak conditions based on real-time device data.

This widget belongs to the Traditional SCADA fluid system bundle — a collection of pipe segments, fittings, valves, pumps, and gauges designed for building fluid system diagrams on ThingsBoard dashboards. It connects to a device and indicates leak conditions through its SCADA symbol.

  • Indicate leak conditions on a drain pipe segment in real time.
  • Trigger a dashboard action when the symbol is clicked.
  • Apply custom colors to fluid and pipe elements independently.
  • Receive leak state data from device attributes, time series, alarm status, or dashboard state.

The widget connects to a single data source: either a Device or an Entity alias that resolves to a device. This device provides the telemetry or attribute values used to drive the widget’s visual state.

The SCADA symbol defines the visual shape of the widget. Each drain pipe widget has a pre-selected symbol from the Traditional SCADA fluid system bundle. To use a different symbol, click Browse SCADA symbol from gallery and choose one from the library, or upload your own.

Behavior parameters define what the widget displays and how it reacts to user interaction.

Defines what happens when the user clicks the SCADA symbol on the dashboard. Select one action type from the list below.

  • Do nothing

    The symbol is clickable but performs no action. Use while testing styles or as a placeholder.

  • Navigate to new dashboard state

    Switches to a different view within the same dashboard, like opening a device details screen.

    ParameterDescription
    Target dashboard stateThe state to open (required).
    Open right dashboard layout (mobile view)Opens a side panel instead of replacing the view (mobile only).
    Set entity from widgetPasses the current entity to the target state.
    State entity parameter nameThe key the entity is passed under.
    Dashboard state display optionNormal (same view), In separate dialog (popup), or In popover (inline overlay).
  • Update current dashboard state

    Updates the context of the current view, like switching the selected device, without navigating away.

    ParameterDescription
    Target dashboard stateThe state to switch to (optional).
    Open right dashboard layout (mobile view)Opens a side panel on mobile.
    Set entity from widgetPasses the current entity to the updated state.
    State entity parameter nameThe key the entity is passed under.
  • Navigate to other dashboard

    Opens a completely different dashboard, like jumping from this system view to a global alarms view.

    ParameterDescription
    Target dashboardThe dashboard to open (required).
    Target dashboard stateThe specific view to open within that dashboard.
    Open in a new browser tabOpens the dashboard without leaving the current page.
    Set entity from widgetPasses the current entity to the other dashboard.
    State entity parameter nameThe key the entity is passed under.
  • Custom action

    Runs custom JavaScript on click to implement any behavior not covered by the built-in options. Use it to make HTTP requests, open custom dialogs, call other widget APIs, or interact with external services. The function receives: $event, widgetContext, entityId, entityName, additionalParams, entityLabel.

  • Custom action (with HTML template)

    Same as Custom action, but also renders a custom HTML panel or dialog when the symbol is clicked. The function receives an additional htmlTemplate parameter: $event, widgetContext, entityId, entityName, htmlTemplate, additionalParams, entityLabel.

    ParameterDescription
    ResourcesExternal scripts and styles loaded before the action runs.
    CSSStyling for the HTML template.
    HTMLLayout of the rendered dialog or panel.
    JSAction logic.
  • Mobile action

    Triggers a native device feature inside a ThingsBoard mobile app, like the camera or QR scanner.

    ParameterDescription
    Mobile action typeTake picture from gallery, Take photo, Open map directions, Open map location, Scan QR Code, Make phone call, Get phone location, Take screenshot, or Device provision.
  • Open URL

    Opens a website or external link when clicked.

    ParameterDescription
    URLThe address to open (required).
    Open in a new browser tabKeeps the current dashboard open while opening the link.

Controls when the leak visual appears on the drain pipe symbol. Select one action type from the list below.

  • Do nothing

    Set the leak state manually. No live data needed.

    ParameterDescription
    ValueTrue — always show the leak; False — always hide it.
  • Execute RPC

    Detect a leak based on an RPC response from the device.

    ParameterDescription
    MethodThe RPC method to call, like getLeakState or getStatus.
    Action result converterNone — leak is shown when the result matches the value you specify; Function — leak is shown when your f(data) returns true.
    ‘Leak present’ when result isThe value or condition that triggers the leak visual.
    RPC request timeout (ms)How long to wait for a device response before timing out (Advanced settings).
    RPC request persistentStores and retries the command until the device comes online (Advanced settings).
  • Get attribute

    Show the leak based on a device attribute, like a leakDetected or sensorState flag.

    ParameterDescription
    Attribute scopeWhere the attribute is stored: Any, Client, Server, or Shared.
    Attribute keyThe attribute name to read, like leakDetected or state.
    Action result converterNone — leak is shown when the attribute equals the value you specify; Function — leak is shown when your f(data) returns true.
    ‘Leak present’ when result isThe value or condition that triggers the leak visual.
  • Get time series

    Show the leak based on the latest telemetry reading from the device.

    ParameterDescription
    Time series keyThe telemetry key to monitor, like leakSensor or state.
    Action result converterNone — leak is shown when the value equals what you specify; Function — leak is shown when your f(data) returns true.
    ‘Leak present’ when result isThe value or condition that triggers the leak visual.
  • Get alarm status

    Show the leak when a specific alarm is active on the device, like a critical pipe fault.

    ParameterDescription
    Alarm severityWhich severity levels trigger the leak: Critical, Major, Minor, Warning, or Indeterminate.
    Alarm typesAny alarm, or a specific alarm type.
  • Get dashboard state id

    Show the leak based on which dashboard state is currently open.

    ParameterDescription
    Action result converterNone — leak is shown when the state name matches the text you enter; Function — leak is shown when your f(data) returns true.
    ‘Leak present’ when result isThe state name or condition that triggers the leak visual.
  • Get dashboard state object

    Show the leak using the full dashboard state context; use this when you need to evaluate multiple state parameters at once.

    ParameterDescription
    Parse value functionWrite a f(data) function that returns true to show the leak.

The Appearance section controls the widget title and element colors.

SettingDescription
TitleWidget title displayed in the header. Supports entityName and entityLabel variables.
Card iconIcon shown in the widget header. Configure its size and color.
Fluid colorColor of the fluid rendered at the drain outlet.
Pipe colorColor of the pipe structure itself.

The Card appearance section controls the widget container style.

SettingDefaultDescription
BackgroundTransparentCard background color.
Show card buttonsFullscreenButtons shown on the card when hovered.
Card border radius0pxRounding of card corners.
Card padding12pxInner spacing between the card edge and widget content.

Widget shows no leak state or incorrect state

CauseSolution
Action is set to Do nothingOpen the Leak parameter edit dialog, set the correct Action, and specify the attribute or time-series key.
Attribute or telemetry key mismatchVerify that the key name in the behavior configuration matches exactly what the device reports.
Target device is not connectedConfirm that the selected device is online and actively sending data.

These widgets are used in the following ready-made solution templates built on the Traditional SCADA fluid system bundle:

  • SCADA Swimming pool — a complete swimming pool monitoring dashboard built with pipe, pump, valve, and gauge widgets from the Traditional SCADA fluid system bundle.