I know there is a way to hide/show input parameters to the user depending on another value by using the following, which it's pretty useful and i use it a lot.
we enter someting like this in the pencil field : #input_variable == "expected value"
But now i need to find also when when a substring is found!
something like :
#input_variable == "*substring*"
#input_variable == ".*substring.*"
Tried all that, but nothing works :smileyplain:
Does this really can be done in some way??
There's probably an OGNL expression that can give you the result of String.substring or String.indexOf but you could just create an action which does the comparison and returns the boolean you want? If you click the purple Jigsaw piece on the far right you'll get an Action selector view and you can choose the action there.
The Show/Hide presentation modifiers both require a boolean result for their evaluation so make sure the action returns boolean
I've used some of that OGNL syntax before too, like you for fixed values e.g.
#vmType.toLowerCase() == "managed"
I'm not sure if wildcard characters will work but an alternative is to make a simple action that does the job and use that:
GetAction("com.mycompany.vropresentationlogic","checkForSubstring").call( #input_variable , "substring" )
The action would just need to return a boolean
OGNL expression should be
#input_variable.indexOf("substring") != -1
The above will evaluate to true if the input_variable value contains substring (assuming input_variable is input parameter/attribute of type string).