make mandatory additional comments in approval

armanoj
Mega Sage

Hi , 

in approval table make comments mandatory when they get approve , but get another error message along with custom error message  as "Invalid value on Update". Usinge BR I tried to make comments mandatory.

if (gs.nil(comments)) {

        current.setAbortAction(true);
        gs.addErrorMessage('Comments are mandatory when approving or rejecting.');
        return;
    }


is it possible remove that error message.
armanoj_0-1781694154871.png

 



8 REPLIES 8

Anurag Tripathi
Mega Patron

You should do this using a ui policy, on client side.

 

-Anurag

Here is an oob sample 

AnuragTripathi_0-1781694672106.png

 

-Anurag

attachment mandatory , also possible?

Where do you want to make the attachment mandatory?

-Anurag