New Ranks & Badges For The Community!
Notice something different? The ranks and associated badges have gone "Star Fleet". See what they all mean HERE
Highlighted
Commodore Commodore
Commodore
539 views

New Change Approval Type, Immediate Denial w/ One Approval

Hello,

Currently there are 4 types of Change approvals.  "One must approve", "All must approve," "Quorum", and "All must approve - immediate denial".

I need to create a new one, but can't see how to do it.  The type would be "One Must approve - immediate denial".

The change approval definition get's 3 individuals based on the characteristics of the change record.  These 3 people are not in the same group, so I can't add a group.  Instead I have 3 individuals listed.  When any one of the 3 people approve the change, I need to move on.  When any one of the 3 people deny the change, I need it to move to denial.  And I need to happen on the first action, not wait for multiple people to approve/deny.

Has anyone created a Change approval type like this and can provide some ideas?  Or actually any new Change approval type?

Thanks for any help.
Andy-

0 Likes
3 Replies
Highlighted
Absent Member.
Absent Member.

i am also searching for the same Issue resolution. it should be part of the Approval Type.

Thanks.

0 Likes
Highlighted
Lieutenant Lieutenant
Lieutenant

Has anyone made progress on this one ? I'm interessted as well. 

0 Likes
Highlighted
Fleet Admiral
Fleet Admiral

Add JS code to trigger (filename ApprovalLog, type = After Update), that checks from the ApprovalLog if the approval action was "deny" and approval name the one that is your special "one deny - immediate denial".

if (record.name=="yourapproval" and record.action=="Denied") {
var _ = lib.Underscore.require();
lib.c.$("Approval".select("unique_key=\"" + record.unique_key  + "\" and approval.status~=\"denied\"").iterate(
        function(ApprovalRec) 
	{    
ApprovalRec.doAction("denyall");
}
);
}

The code marks all the approvals as denied after the first denial is done.

I'm not fan of such a code forks as the approval name is hardcoded, so I recommend adding some hints to your approval name that reminds you where all the "auto denials" are actually done.

Did a code as a draft, didn't run it. Some authorization issues might occur, depending on SM version. So please take it as a guideline and give it a go.

---
Moving on, this account is no longer active. Best regards, Kelalek
- So Long, and Thanks for All the Fish
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.