- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2021 07:39 AM
Hi all,
we want to give the possibility to Change Author of KB article and since this field is read-only (OOB), to do this,
I created an ui action "Change author" which calls a ui page that lists the active users as shown below :
the problem is that I can not modify the KB with Published Retired and Outdated status (the Save doesn't work),
the operation works very well for the rest of the cases : Draft, Review, Sheduled for publish and Pending retirement
my ui page Client script :
uBest regards,
Solved! Go to Solution.
- Labels:
-
Multiple Versions
-
Team Development
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2021 09:57 PM
Thank you for marking my response as helpful.
If my response helped you please mark it correct to close the question so that it benefits future readers as well.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2021 05:26 AM
Hi,
either use GlideAjax or update the record using GlideRecord in client script itself
see this link where I shared solution; enhance as per your need
Ensure you send record sys_id from UI action to UI page so that you can get that in client script and query that record
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2021 09:57 PM
Thank you for marking my response as helpful.
If my response helped you please mark it correct to close the question so that it benefits future readers as well.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2021 07:51 AM
If you right click author and configure dictionary, I'd see if it's set to read only at the dictionary level. If so, you could do a dictionary override for each of the templates. They each create an extension of kb_knowledge. Items that are only read only in the form, and not dictionary, can be edited just fine through scripts.
You could also try setting value and display value, it could be updating the value but not display since it's read only.
https://developer.servicenow.com/dev.do#!/reference/api/quebec/client/c_GlideFormAPI#r_GlideFormSetValue_String_String_String