<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Jelly Scripting in Developer forum</title>
    <link>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2987519#M1129745</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to add an error message on the top of the Article for the users which has been expired.&lt;/P&gt;&lt;P&gt;I got the UI Page where I need to do the changes but as I am new to Jelly and doesn't have much knowledge on it, Can anyone help me how to put that error message only for expired KB articles.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have added the error message which has to be displayed but it is displaying for all the KB Articles even for published ones.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached is the screenshot for your reference.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Rooma&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jul 2024 13:46:40 GMT</pubDate>
    <dc:creator>Rooma1</dc:creator>
    <dc:date>2024-07-11T13:46:40Z</dc:date>
    <item>
      <title>Jelly Scripting</title>
      <link>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2987519#M1129745</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to add an error message on the top of the Article for the users which has been expired.&lt;/P&gt;&lt;P&gt;I got the UI Page where I need to do the changes but as I am new to Jelly and doesn't have much knowledge on it, Can anyone help me how to put that error message only for expired KB articles.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have added the error message which has to be displayed but it is displaying for all the KB Articles even for published ones.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached is the screenshot for your reference.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Rooma&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jul 2024 13:46:40 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2987519#M1129745</guid>
      <dc:creator>Rooma1</dc:creator>
      <dc:date>2024-07-11T13:46:40Z</dc:date>
    </item>
    <item>
      <title>Re: Jelly Scripting</title>
      <link>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2987951#M1129844</link>
      <description>&lt;P&gt;I don't understand why you need jelly for this.&amp;nbsp; You could just use a onLoad client script that adds the error to the top of the page with&amp;nbsp;&lt;SPAN&gt;g_form.addErrorMessage("This article has expired.") based on the state of the record. g_form.getValue("state")&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jul 2024 22:18:31 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2987951#M1129844</guid>
      <dc:creator>Jim Myrah</dc:creator>
      <dc:date>2024-07-11T22:18:31Z</dc:date>
    </item>
    <item>
      <title>Re: Jelly Scripting</title>
      <link>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2988358#M1129944</link>
      <description>&lt;P&gt;Hi Jim,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The error message which I want needs to be on the view mode not on the edit view of the Article.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Rooma&lt;/P&gt;</description>
      <pubDate>Fri, 12 Jul 2024 08:32:18 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2988358#M1129944</guid>
      <dc:creator>Rooma1</dc:creator>
      <dc:date>2024-07-12T08:32:18Z</dc:date>
    </item>
    <item>
      <title>Re: Jelly Scripting</title>
      <link>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2990530#M1130522</link>
      <description>&lt;P&gt;I understand you want to modify the kb_view UI Page.&amp;nbsp; I would suggest going to the script tag in the html and add logic to check state and then use JQuery ($j) to insert your HTML.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;		
		$j("title").html('${knowledgeRecord.kb_knowledge_base.getDisplayValue()}'+ " - " + '${knowledgeRecord.number}');
	
		if ('${knowledgeRecord.workflow_state}' != 'published'){
			alert("This article is not publshed!!!");
		}
		&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2024 18:57:24 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/jelly-scripting/m-p/2990530#M1130522</guid>
      <dc:creator>Jim Myrah</dc:creator>
      <dc:date>2024-07-15T18:57:24Z</dc:date>
    </item>
  </channel>
</rss>

