Skip to main content

I am attempting to set up an Approval Process based on the attached guide.

I do so to the letter. When I hit save, it offers to activate it for me, and I say yes.
 

From this state, any attempt I make to save, even without making changes, shows this error message.
 

I cannot see anything wrong. I have gone through the process several times, always with the same result. As soon as I add a condition/phase, it will no longer save when Active.

I have attached one of the approval processes that I have setup according to the guide, which currently cannot be saved even without making changes. Can someone advise me on what the configuration issue is?

Further digging.

It appears to be due to the fact that there is no reject_next_step value on the step_type = P row.
As far as I can tell, it is impossible to set a reject_next_step through the UI, so it is impossible to pass this condition.

Line 173 in approval_maint.js

    // validate if Approval Process is completed. 
if (m_primaryXML.selectNodes("/root/approval/rowo@status!=2 and @status!=6 and @status!=10 and @status!=14 and step_type = 'P' $and$ (approve_next_step = '' $or$ approve_next_step = 0 $or$ reject_next_step = '' $or$ reject_next_step = 0)]").length > 0)
return ":APPR0005"; // The Approval Process is not set up correctly. Please check it.

If I remove 

reject_next_step = '' $or$ 

Then everything works fine.


A further update. While I was able to get this working this morning, ie. I was able to get a Service Order held for approval, I can no longer get it to work at all despite multiple attempts. I have reverted my JS changes and recreated the approval process from scratch. No dice. Is there potentially an error in the Approval Process Service?


Can you please double check each step to make sure that it has a status set?  This error will occur if the statuses are not defined on each step. (This is so that the approval process doesn’t set an empty status on approve/reject).


Can you please double check each step to make sure that it has a status set?  This error will occur if the statuses are not defined on each step. (This is so that the approval process doesn’t set an empty status on approve/reject).

Hi Andrew. Each step did have a status set. 
I managed to get both issues solved (thanks Ugo)

For posterity:

The issue with not saving was because the Reject step does need a next step. This is fixed by pointing Reject back to the Submitter step:
 


The second issue around jobs not being held for approval was because the user that was invoicing the service order was also in the list of approval users. In this scenario, the approval process will be skipped. I was not aware of this!

Case closed :)​​​​​​​


Reply