The CreatorCon Call for Content is officially open! Get started here.

Issue Updating Request State

Rayan45
Tera Contributor

Hi all, I created a subflow to check if all RITMs attached to a request are closed complete. If that's the case, it should update the request's state to 'Closed Complete.' If the state of any RITM is 'Closed Skipped' or 'Closed Incomplete,' it should update the request state to 'Closed Incomplete.' However, my flow only updates the state to 'Closed Complete,' and it doesn’t work for 'Closed Incomplete.' When I test it in Flow Designer, it works fine. What could be the issue?

Rayan45_1-1730712100857.png

 

4 REPLIES 4

Mark Manders
Mega Patron

Check on existing logic that changes the state. It can very well be that an old BR/Workflow is setting the stage as well, making it impossible for your flow to override it.


Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark

Uncle Rob
Kilo Patron

If it works fine in Flow Designer but not outside Flow Designer there's two probable causes.
1)  Your flow isn't actually active, and so your test scenario didn't actually trigger it (which is why I usually throw a work_note update while I'm developing)
2)  Some existing logic (most likely a business rule) is interfering with the flow.  Possibly executing before or after.

Knowing how firm REQ state functionality is OOB, I'm guessing its the latter.

Colleen Mathis
Tera Contributor

Take a look at the Business Rule 'Close Parent if Required'

Moedeb
Tera Guru

This is covered here:

Request is not closing when all RITM & SCTASK tickets under it are closed - Support and Troubleshoot...

 

Ultimately like other have suggested it is because there is an OOTB business rule that closes the Request once all RITM's are closed, however it requires the stage of the RITM's to exactly match what it is looking for.

 

As @Colleen Mathis mentioned it is the "Close Parent if Required" business rule and the conditions are where you get what you need to set your stage to in the RITM:

current.stage.changes() && (current.stage=='complete' || current.stage=='Request Cancelled' || current.stage == "closed_incomplete" || current.stage=="closed_skipped")