2020-01-03 10:00:20 +00:00
|
|
|
<template>
|
2020-02-17 22:19:54 +00:00
|
|
|
<div class="multiple-select-container">
|
2020-01-03 10:00:20 +00:00
|
|
|
<el-select
|
|
|
|
v-if="setting.key === ':backends'"
|
|
|
|
:value="data.value"
|
2020-03-14 22:31:47 +00:00
|
|
|
:data-search="setting.key || setting.group"
|
2020-01-03 10:00:20 +00:00
|
|
|
multiple
|
2020-02-17 22:19:54 +00:00
|
|
|
class="input"
|
2020-01-03 10:00:20 +00:00
|
|
|
@change="updateSetting($event, settingGroup.group, settingGroup.key, setting.key, setting.type)">
|
|
|
|
<el-option value=":console" label="console"/>
|
|
|
|
<el-option value=":ex_syslogger" label="ExSyslogger"/>
|
|
|
|
<el-option value="Quack.Logger" label="Quack.Logger"/>
|
|
|
|
</el-select>
|
|
|
|
<el-select
|
|
|
|
v-if="setting.key === ':args'"
|
|
|
|
:value="data[setting.key]"
|
2020-03-14 22:31:47 +00:00
|
|
|
:data-search="setting.key || setting.group"
|
2020-01-03 10:00:20 +00:00
|
|
|
multiple
|
2020-06-22 00:04:53 +00:00
|
|
|
filterable
|
|
|
|
allow-create
|
2020-02-17 22:19:54 +00:00
|
|
|
class="input"
|
2020-01-03 10:00:20 +00:00
|
|
|
@change="updateSetting($event, settingGroup.group, settingGroup.key, setting.key, setting.type)">
|
2020-08-03 19:31:53 +00:00
|
|
|
<el-option value="strip"/>
|
|
|
|
<el-option value="auto-orient"/>
|
|
|
|
<!-- eslint-disable -->
|
|
|
|
<el-option value='{"implode", "1"}'/>
|
|
|
|
<!-- eslint-enable -->
|
2020-01-03 10:00:20 +00:00
|
|
|
</el-select>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
2020-05-06 17:06:30 +00:00
|
|
|
name: 'SpecificMultipleSelect',
|
2020-01-03 10:00:20 +00:00
|
|
|
props: {
|
|
|
|
data: {
|
|
|
|
type: [Object, Array],
|
|
|
|
default: function() {
|
|
|
|
return {}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
setting: {
|
|
|
|
type: Object,
|
|
|
|
default: function() {
|
|
|
|
return {}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
settingGroup: {
|
|
|
|
type: Object,
|
|
|
|
default: function() {
|
|
|
|
return {}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
updateSetting(value, group, key, input, type) {
|
|
|
|
this.$store.dispatch('UpdateSettings', { group, key, input, value, type })
|
|
|
|
this.$store.dispatch('UpdateState', { group, key, input, value })
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style rel='stylesheet/scss' lang='scss'>
|
|
|
|
@import '../../styles/main';
|
|
|
|
@include settings
|
|
|
|
</style>
|