mirror of
https://github.com/fluent/fluentd-ui.git
synced 2025-08-11 16:57:11 +02:00
Apply snakeCase method to camel case string
This is for Rails convention. Signed-off-by: Kenji Okimoto <okimoto@clear-code.com>
This commit is contained in:
parent
54ed8037d4
commit
ddadba931e
@ -69,15 +69,14 @@ const ConfigField = {
|
|||||||
if (pluginType === "output") {
|
if (pluginType === "output") {
|
||||||
return `setting_${option.name}`
|
return `setting_${option.name}`
|
||||||
} else {
|
} else {
|
||||||
return `setting_${pluginType}_0__${option.name}`
|
return `setting_${_.snakeCase(pluginType)}_0__${option.name}`
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
inputName: function(pluginType, option) {
|
inputName: function(pluginType, option) {
|
||||||
if (pluginType === "output") {
|
if (pluginType === "output") {
|
||||||
return `setting[${option.name}]`
|
return `setting[${option.name}]`
|
||||||
} else {
|
} else {
|
||||||
return `setting[${pluginType}[0]][${option.name}]`
|
return `setting[${_.snakeCase(pluginType)}[0]][${option.name}]`
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
checked: function(checked) {
|
checked: function(checked) {
|
||||||
|
Loading…
Reference in New Issue
Block a user