Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X
Hi,
I try to execute a Thingworx service (Action "Service Execute") with a boolean input value in a Flow. The Boolean input parameter for the executed action is given from the input parameter (also Boolean) from the Flow itself.
The issue is that I cannot bind the Input params (oder params from other actions) to the Boolean input (like I could with any other input type like a String). I only can choose between a fixed true or false; see attached image.
There is a option to not use the "Form" input a apply a JSON, but that does not work either. Because my second input variable (which is a String) is getting ignored somehow.
(i.e. {"BoolVar":{{$Service.BoolInput}},"order":{{$Service.orderNo}}} )
I don't like workarounds like:
- Duplicate the action (one with "true", the other with the "false" input)
- Change the input variable of the Thingworx service from Boolean to String
because this is a fairly simply use case and it just would make things more complicated (or harder to understand for third parties) as they are.
Is this a bug? Or is there a reason why I can't bind Boolean Inputs for the "Service Execute" Action?
Solved! Go to Solution.
Hi danz,
We have checked this now in 9.0.1 and it is working as required with two json inputs
Thank you,
Gautham
Hi DanZ,
Looks like a bug i will dig in if there is a reason why this is disabled.
Thank you,
Gautham
Hi DanZ,
I can confirm it is working that way.
I will find the reason why the boolean input is getting ignored.
In case you want this functionality you can open a ticket with us.
Thank you,
Gautham
Hi DanZ,
This is a bug. We are working on fixing it.
Thank you,
Gautham
Hi Danz,
We created a Nodejs Action that gave a boolean result and appended that result in Service Execute action.
Note: Used option AssignJson
We were able to run it Successfully.
Hi,
have you tried using a second parameter? I had problems when using the Assign JSON input because my second input param was getting ignored. The boolean input itself worked fine.
Danz,
Second parameter works as well.
Can you send me your entity so i can test it.
Thank you,
Gautham
I don't have the flow nor the entity anymore. The fact that the issue will be solved with a new Thingworx version is good enough for me.
Maybe I missed something past then when i tried to use the assignJSON option.
Thank you.
Hi danz,
We have checked this now in 9.0.1 and it is working as required with two json inputs
Thank you,
Gautham
Hi @DanZ.
If you feel your question has been answered, please mark the appropriate response as the Accepted Solution for the benefit of others with the same question.
Regards.
--Sharon