暫存版本

This commit is contained in:
bmy
2024-07-09 00:28:41 +08:00
parent 8acecadd2a
commit da67c9a62b
11 changed files with 379 additions and 177 deletions

View File

@@ -123,9 +123,9 @@
</el-option>
</el-select>
<el-button v-if="showConfigForm" @click="toggleConfigForm" type="primary" style="margin-bottom: 20px;">
<!-- <el-button v-if="showConfigForm" @click="toggleConfigForm" type="primary" style="margin-bottom: 20px;">
{{ showConfigForm ? '关闭' : '打开' }} 配置
</el-button>
</el-button> -->
<el-form v-if="showConfigForm && config" class="config-form">
<div v-for="(section, sectionName) in config" :key="sectionName">
@@ -133,6 +133,14 @@
<el-row :gutter="20">
<el-col v-for="(value, key) in section" :key="key" :xs="24" :sm="12" :md="8" :lg="6">
<el-form-item :label="key">
<el-select v-if="sectionName === 'kick_ass'" v-model="config[sectionName][key]">
<el-option
v-for="item in target_person_options"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
<el-switch
v-if="typeof value === 'boolean'"
v-model="config[sectionName][key]">
@@ -155,6 +163,9 @@
</el-row>
</div>
<el-button @click="saveConfig" type="primary" style="margin-top: 20px;">保存配置</el-button>
<el-button v-if="showConfigForm" @click="toggleConfigForm" type="primary" style="margin-bottom: 20px;">
{{ showConfigForm ? '关闭' : '打开' }} 配置
</el-button>
</el-form>
<h2 class="section-title">Log Display</h2>
@@ -183,7 +194,20 @@
files: {},
ServerLog: "",
showServerLogFlag: false,
timer: null
timer: null,
target_person_options: [{
value: 1,
label: '模式 1'
}, {
value: 2,
label: '模式 2'
}, {
value: 3,
label: '模式 3'
}, {
value: 4,
label: '模式 4'
}],
},
methods: {
loadConfig() {