Dashboards & Visualizations
Highlighted

Dropdown menu with sourcetypes

Communicator

Hello, I would like to populate a dropdown in a form with all sourcetypes I have indexed. I remember something like "| metadata = sourcetype", but I am not sure. Any help would be appreciated. Thanks in advance

Tags (1)
0 Karma
Highlighted

Re: Dropdown menu with sourcetypes

Influencer

The search you're looking for is:

| metadata type=sourcetypes

And to get a dropdown, you can use a SearchSelectLister:

<module name="SearchSelectLister">
  <param name="settingToCreate">sourcetype</param>
  <param name="search">| metadata type=sourcetypes</param>
  <param name="label">sourcetype</param>
  <param name="searchWhenChanged">True</param>
  <param name="searchFieldsToDisplay">
    <list>
      <param name="label">sourcetype</param>
      <param name="value">sourcetype</param>
    </list>
  </param>
  ....

View solution in original post