diff --git a/app/views/helpers/InputHelper.java b/app/views/helpers/InputHelper.java new file mode 100644 index 000000000..62a6a8747 --- /dev/null +++ b/app/views/helpers/InputHelper.java @@ -0,0 +1,16 @@ +package views.helpers; + +import org.graylog2.restclient.models.ClusterEntity; +import org.graylog2.restclient.models.Radio; + +/** + * @author Dennis Oelkers + */ +public class InputHelper { + public static String sourceFieldForNode(ClusterEntity clusterEntity) { + if (clusterEntity instanceof Radio) + return "gl2_source_radio_input"; + else + return "gl2_source_input"; + } +} diff --git a/app/views/system/inputs/partials/input_action_menu.scala.html b/app/views/system/inputs/partials/input_action_menu.scala.html index 30401e2c3..1d6663c0d 100644 --- a/app/views/system/inputs/partials/input_action_menu.scala.html +++ b/app/views/system/inputs/partials/input_action_menu.scala.html @@ -4,6 +4,7 @@ @import views.helpers.Permissions._ @import lib.security.RestPermissions._ @import org.graylog2.restclient.models.Radio +@import views.helpers.InputHelper.sourceFieldForNode
@@ -24,7 +25,7 @@ } @if(isPermitted(SEARCHES_RELATIVE)) { -
  • Messages from this input
  • +
  • Messages from this input
  • }