Making 'Pending retirement' visible at Knowledge Portal

Mussie
ServiceNow Employee
ServiceNow Employee

Hi Guys,

I have got a requirement from a client where I need to make knowledge articles which are in 'Penning Retirement' state/stage visible to users just like those which are published. Anybody has any idea how I can address this?

Thank you,

Mussie

1 ACCEPTED SOLUTION

Mussie
ServiceNow Employee
ServiceNow Employee

Hi Guys,


We resolved this using the following method:


- Added a new field called u_pending_retirement


- Edited the 'Retire' UI Action script as follows:


        commented out the below code:


        current.workflow_state = 'pending_retirement';


        and added the following:


        current.u_pending_retirement = true;    


Now, what happens is when the retire button is clicked, instead of changing the workflow to 'pending_retirement', it remains in published and the u_pending_retirement checkbox is checked. And once the request for retirement is approved, the workflow will be changed to retired. However, if the request is rejected, it will remain in published and the u_pending_retirement is unchecked (we needed to edited the rejection script on the workflow)


find_real_file.png



Regards,


Mussie


View solution in original post

9 REPLIES 9

Ohh, so it the knowledge homepage



find_real_file.png



If you see the screenshot, this home page is collecting list of arguments via "knowledge_home_launcher.do" UI Page.


I tried to find this page in the UI page modules, but it is not present there. So I guess this is hidden out from us.



In this case, you will not be able to change anything.


Thanks Deepak, I will check with the project team. I will update incase if it gets resolved.


Mussie
ServiceNow Employee
ServiceNow Employee

Hi Guys,


We resolved this using the following method:


- Added a new field called u_pending_retirement


- Edited the 'Retire' UI Action script as follows:


        commented out the below code:


        current.workflow_state = 'pending_retirement';


        and added the following:


        current.u_pending_retirement = true;    


Now, what happens is when the retire button is clicked, instead of changing the workflow to 'pending_retirement', it remains in published and the u_pending_retirement checkbox is checked. And once the request for retirement is approved, the workflow will be changed to retired. However, if the request is rejected, it will remain in published and the u_pending_retirement is unchecked (we needed to edited the rejection script on the workflow)


find_real_file.png



Regards,


Mussie


Hi


Is there any other way to achieve this without creating the check box field   and want to show the state as Pending Retirement state only ?



Thanks


Snehal


Mussie
ServiceNow Employee
ServiceNow Employee

No, not to my knowledge. In my case, we dropped the idea as the client didn't like how this was implemented.