function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Konica Bhateja 9Konica Bhateja 9 

Add Custom Button/Action in Approval Page

I have a requirement to add a Custom button on Approval page which is used by Approver to approve or reject a request raised through Approval Process. I am unable to add any Custom button to that page or edit the page layout. Is there a way to customize that page layout and add Custom Button to that page?

I am getting following error while try to create a Custom Action on Approval Request Object - "There were custom validation error(s) encountered while saving the affected record(s). The first validation error encountered was Object Name: bad value for restricted picklist field: ProcessInstanceWorkItem".

Can anyone guide me how to resolve this issue?
ShirishaShirisha (Salesforce Developers) 
Hi Konica,

Greetings!

As per the error message,I can see that you are trying to use or update the Restricted Picklist field values.

I would suggest you to have a look at the below document on the root cause of the error:

https://help.salesforce.com/HTViewSolution?id=000250168&language=en_US

Kindly mark it as best answer if it helps so that it can help others in the future.

Warm Regards,
Shirisha Pathuri
 
RituSharmaRituSharma
You can't add custom button to the approval page layout. Regarding picklist error, it seems that you are trying to set an invalid picklist value. If you have record types, just see is the picklist is enabled for the applicable record types.