CA Service Management

  • 1.  Comments while approval in Service Catalog

    Posted May 09, 2018 09:05 AM

    Dear All,

     

        We have a five level of approval in Service Catalog. Approval assignment is getting done via PAM. 

    While approving first level approver should provide a comment. Next level approver should see previous comment but can't update the same and also he can provide some comment while approving and so on..

     

    Can any one provide a suggestion to achieve the same.

     

    Thanks in Advance,

    Vikash



  • 2.  Re: Comments while approval in Service Catalog

    Posted May 09, 2018 06:24 PM

    Hello Vikash,

     

    Is the Notes feature on the Catalog request form not appropriate in this case (this seems to be the easiest way to accomplish this)?

     

    An alternative that comes to mind, if approvers/groups are static, would be to create a hidden and required field for a comment for each tier of approval and add some JavaScript to the form script (for onLoad function) that checks for logged-in user (or group membership) and if it matches the approver/group it would enable/disable and show the field/s needed.

     

    Here's a quick example for a form script (will only show added comments fields for approvers in this case, in Catalog form):

     

    {

     

    forApproverComments : function() {
        var groups = _.user.groups;
        if (groups.indexOf("Approval Group 1") >= 0) {
            ca_fdShowFields(ca_fd.formId, ['field_1']);
            ca_fdHideFields(ca_fd.formId, ['field_2', 'field_3', 'field_4', 'field_5']);
            ca_fdEnableFields(ca_fd.formId, ['field_1']);
            ca_fdDisableFields(ca_fd.formId, ['field_2', 'field_3', 'field_4', 'field_5']);
        } else if (groups.indexOf("Approval Group 2") >= 0 {
            ca_fdShowFields(ca_fd.formId, ['field_1', 'field_2']);
            ca_fdHideFields(ca_fd.formId, ['field_3', 'field_4', 'field_5']);
            ca_fdEnableFields(ca_fd.formId, ['field_2']);
            ca_fdDisableFields(ca_fd.formId, ['field_1', 'field_3', 'field_4', 'field_5']);
        } else if (groups.indexOf("Approval Group 3") >= 0 {
            ca_fdShowFields(ca_fd.formId, ['field_1', 'field_2', 'field_3']);
            ca_fdHideFields(ca_fd.formId, ['field_4', 'field_5']);
            ca_fdEnableFields(ca_fd.formId, ['field_3']);
            ca_fdDisableFields(ca_fd.formId, ['field_1', 'field_2', 'field_4', 'field_5']);
        } else if (groups.indexOf("Approval Group 4") >= 0 {
            ca_fdShowFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_4']);
            ca_fdHideFields(ca_fd.formId, ['field_5']);
            ca_fdEnableFields(ca_fd.formId, ['field_4']);
            ca_fdDisableFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_5']);
        } else if (groups.indexOf("Approval Group 5") >= 0 {
            ca_fdShowFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_4', 'field_5']);
            ca_fdEnableFields(ca_fd.formId, ['field_5']);
            ca_fdDisableFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_4']);
        } else {
            ca_fdHideFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_4', 'field_5']);
            ca_fdDisableFields(ca_fd.formId, ['field_1', 'field_2', 'field_3', 'field_4', 'field_5']);
        }
    },

     

    onLoad : function() {
        ca_fd.js.forApproverComments();
    },

     

    }

     

    Some more complicated options in PAM of course...

     

    Steve



  • 3.  Re: Comments while approval in Service Catalog

    Posted May 10, 2018 01:52 AM

    Thank you Shomer for your quick reply.

    Approvers are not static. We are getting it from web service query. So they are not present in catalog form. 

     

    Please suggest any other alternative.

     

    Thank & Regards,

    Vikash



  • 4.  Re: Comments while approval in Service Catalog

    Posted May 10, 2018 04:25 AM

    Apart from this can we pick up comments entered by approver in next approval notification?

    Please suggest how can we do this.

     

    Thanks & Regards,

    Vikash



  • 5.  Re: Comments while approval in Service Catalog

    Posted May 10, 2018 03:08 PM

    Hi Vikash,

     

    We had a similar scenario. We came up with letting the users use the comment field for approval and fulfillment comments. We created a process that is called right after the pending action is completed to move the comments to the notes section, then clearing out the comments. We are passing the workitem_id from the pending action so we can go back to the DB and get the user who completed the task and prefix the note with the user Id (we are changing this to actually proxy as the user so that it shows under their name and not the WS account)