OO-Designer: Add menu option "Add Decision"

Idea ID 2758875

OO-Designer: Add menu option "Add Decision"

In OO-designer I can add a custom Python operation, but if I need a

custom decision I can not do this from menu.

 

RobertBuerger_0-1580040322906.png

I wrote an own CloudSlang file and uploaded this to my git. After a pull from git I used it in Designer.

The code for a decision is super easy, so it would be great to do this from menu.

 

# Custom decision, RoB, 01.2020
#
########################################################################################################################
#!!
#! @description: Verifies NSO service state.
#!
#! @input service_state: State to compare.
#! Default: ''
#! Optional
#!
#! @result INSYNC: State is in-sync.
#! @result OUTOFSYNC: State is out-of-sync.
#! @result EMPTY: State is something else
#!!#
########################################################################################################################

namespace: wise.int.nso.decisions

decision:
name: check_nso_service_state

inputs:
- service_state:
default: ''
required: false

results:
- INSYNC: ${service_state is not None and service_state == 'true'}
- OUTOFSYNC: ${service_state is not None and service_state == 'false'}
- EMPTY: ${service_state is not None and service_state != 'true' and service_state != 'false'}
- FAILURE

 

1 Comment
Micro Focus Expert
Micro Focus Expert
Status changed to: Waiting for Votes
 
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.