Signed-off-by: Kenji Okimoto <okimoto@clear-code.com>
This commit is contained in:
Kenji Okimoto 2018-06-06 11:28:31 +09:00
parent 59ac41185c
commit 893bafa548
No known key found for this signature in database
GPG Key ID: F9E3E329A5C5E4A1

View File

@ -127,7 +127,13 @@ module SettingsHelper
end
def owned_plugin_type_field(form, key, plugin_type)
plugin_registry = Fluent::Plugin.const_get("#{plugin_type.to_s.upcase}_REGISTRY")
registry_type = case plugin_type
when :parse
"PARSER_REGISTRY"
when :format
"FORMATTER_REGISTRY"
end
plugin_registry = Fluent::Plugin.const_get("#{registry_type}")
html = '<div class="form-group">'
html << form.label(key)
html << " " # NOTE: Adding space for padding