Read Plugin Settings in Snippet

Which IIQ version are you inquiring about?

[8.3]

Hi

I have created a plugin that displays a message on an existing page in IIQ based on the value in Plugin Configuration using a snippet. I have two files mainly for this update:

  1. manifest.xml : Added the below setting
      <entry key="settings">
       <value>
         <List>
           <Setting dataType="int" helpText="The maximum number of objects to search. If there are 1000s or more objects of the type to search, the server could get overloaded" label="Max Objects to Search" name="maxSearchObjectCount" defaultValue="200"/>
         </List>
       </value>
    </entry>
  1. snippet.js

Question: 1. How can I read the value of “maxSearchObjectCount” in snippet.js?
2. If the value of “maxSearchObjectCount” is updated in plugin configuration, would snippet.js be able to read the updated value automatically or the value would be cached and a server restart would be needed?

Thank you!

Hi @mahima,

I assume snippet.js is the JS you are injecting in the UI, And you are trying the access the settings & values from the plugin settings page in the JS.

Unfortunately you cannot do this directly, The plugin settings and their values are not exported to the UI layer.

You have to write a Java class that exposes your setting as API. And, you have to make an API call to the backend and retrieve your settings.

If you are looking for references I would recommend you to check-out one of my Plugin - IdentityIQ Announcement Plugin

Thank you Shandeep! The reference helped.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.