Set KB Workflow State to certain value through Business Rule/script impossible?

AdamUMC
Giga Guru

Hi there,

Through a SelfServicePortal (SSP) form ("Record Producer"), I want to create or edit an Knowledge Article.
Creating one works, although the Workflow State keeps being "Draft"; it won't become "Published".

I have tried several options to solve this problem;
- Put Workflow State value in script as tekst without capital letter "P".
- Same, but with capital "P".
- Put Workflow State value in script as "sys_id" (the "sys_id" of the Workflow State "Published").
- Made a (for now) hidden field in the Record Producer (SSP form), which is mapped to the field "Workflow" as type "Reference" within Record Producer table "kb_knowledge" and as reference (tab "Type Specifications") to the "sys_dictionary". I have also tried to setup an Default Value within that tab ("sys_id" of the Workflow State, textual variant, etc.).

Sadly, the Workflow State keeps being "Draft". Is it possible to solve this problem and how?
Thanks!

1 ACCEPTED SOLUTION

AdamUMC
Giga Guru

I fixed this by using the Flow Designer. You can change the Workflow States per article by executing the flow/change as "System User", but keep in mind you will need a good trigger condition.

If you are good enough with Javascript and know how to process a certain user with sufficient rights to change the workflow in the script, you can do it that way. In any case, I solved it for myself by using the Flow Designer.

View solution in original post

5 REPLIES 5

AdamUMC
Giga Guru

I fixed this by using the Flow Designer. You can change the Workflow States per article by executing the flow/change as "System User", but keep in mind you will need a good trigger condition.

If you are good enough with Javascript and know how to process a certain user with sufficient rights to change the workflow in the script, you can do it that way. In any case, I solved it for myself by using the Flow Designer.