- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 01:00 AM
Hi Team,
I am creating a knowledge article record producer
Please let me know that how to set a knowledge article state to review instead of draft stage as soon as its gets created. witch means with stage as review and it should ask for publish workflow approvals by default.
(means knowledge article creation itself asking for publishing)
please help..
Thanks,
Asish
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 02:47 AM
Hi @Asish17,
It does seem simple but its not since the version control on Knowledge Management is put to move articles in the draft state only on creation.
So there are few approaches you can take in this case.
1st approach (preferred)
1. Submit the knowledge article mentioning the created by as a unique service account
2. Create a BR/Flow (async) on Knowledge to take these knowledge article from draft state and created by the unique account and use the OOTB "global.KnowledgeUIAction().publish(current)" function to publish it.
Another approach (less preferred)
1. modify the BR which is stopping the articles to be created in other states then draft but restrict it to the unique service account only.
2. push the articles in review state and trigger the publish flow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 01:15 AM
@Asish17 Add below code to record producer script
current.workflow_state = "review";
Please mark as correct answer if this solves your issue.
ServiceNow Community Rising Star, Class of 2023
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 03:38 AM
Thanks for the reply!!!
Yes I followed the same but its not going to review whenever I submitted the RP..
Thanks,
Asish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 02:47 AM
Hi @Asish17,
It does seem simple but its not since the version control on Knowledge Management is put to move articles in the draft state only on creation.
So there are few approaches you can take in this case.
1st approach (preferred)
1. Submit the knowledge article mentioning the created by as a unique service account
2. Create a BR/Flow (async) on Knowledge to take these knowledge article from draft state and created by the unique account and use the OOTB "global.KnowledgeUIAction().publish(current)" function to publish it.
Another approach (less preferred)
1. modify the BR which is stopping the articles to be created in other states then draft but restrict it to the unique service account only.
2. push the articles in review state and trigger the publish flow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-01-2023 06:45 AM
Hi @kamal_s
Thanks for the reply!!!
If you had time can you please explain it clear...
what we have done is we have created new knowledge base and a record producer and mapped to new knowledge article form fields, so the data will be redirected to knowledge article page and we have modified the OOB Approval publish workflow according to our requirements and called in our newly created KB so whenever a article is raised its going to draft state after its get publish its going for review so our requirement is to have control on this so it can be automatically goes to approvers without publishing.... so whenever a article is submitted it should goes to approvers which we have given in our workflow with stage Review..
can you please help..
Thanks,
Asish