修改定值

This commit is contained in:
jingna 2026-05-28 18:13:33 +08:00
parent adc57779a4
commit 166b94ec71

View File

@ -26,17 +26,17 @@ const lineTabs = ref([
]) ])
const activeTab = ref('1') const activeTab = ref('1')
const infoList = ref({ const infoList = ref({
line_no:1, line_no: 1,
fault_alarm:[ fault_alarm: [
{category:'PT断线',delay:0,enabled:false,output_node:'',limit:0}, { category: 'PT断线', delay: 0, enabled: false, output_node: '', limit: 0 },
{category:'CT断线',delay:0,enabled:false,output_node:'',limit:0}, { category: 'CT断线', delay: 0, enabled: false, output_node: '', limit: 0 },
], ],
over_limit_alarm:[ over_limit_alarm: [
{category:'电压',delay:0,enabled:false,output_node:'',limit:0}, { category: '电压', delay: 0, enabled: false, output_node: '', limit: 0 },
{category:'电流',delay:0,enabled:false,output_node:'',limit:0}, { category: '电流', delay: 0, enabled: false, output_node: '', limit: 0 },
{category:'差流',delay:0,enabled:false,output_node:'',limit:0}, { category: '差流', delay: 0, enabled: false, output_node: '', limit: 0 },
{category:'功率',delay:0,enabled:false,output_node:'',limit:0}, { category: '功率', delay: 0, enabled: false, output_node: '', limit: 0 },
{category:'频率',delay:0,enabled:false,output_node:'',limit:0}, { category: '频率', delay: 0, enabled: false, output_node: '', limit: 0 },
], ],
}) })
const options = ref([ const options = ref([
@ -104,7 +104,7 @@ const cleardata = () => {
}) })
} }
const currentLine = ref(1) const currentLine = ref(1)
const handleTabClick = (tab:string) => { const handleTabClick = (tab: string) => {
activeTab.value = tab activeTab.value = tab
infoList.value.line_no = Number(tab) infoList.value.line_no = Number(tab)
currentLine.value = Number(tab) currentLine.value = Number(tab)
@ -165,7 +165,7 @@ const handleSave = () => {
ElMessage.error('保存失败') ElMessage.error('保存失败')
} }
}) })
}else{ } else {
isswitch.value = false isswitch.value = false
dialogVisible.value = true dialogVisible.value = true
} }
@ -201,86 +201,115 @@ const handleSave = () => {
<div class="tab-content-item"> <div class="tab-content-item">
<div class="tab-content-item-box box-height">限制</div> <div class="tab-content-item-box box-height">限制</div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[0].limit" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[0].limit" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[1].limit" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[1].limit" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[2].limit" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[2].limit" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[0].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.fault_alarm[0].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[1].limit" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.fault_alarm[1].limit" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height" style="border: none;"> <div class="tab-content-item-box box-color box-height"
<img src="@/assets/images/menuicon/noitem.png" style="width: 100%; height: 100%;" alt=""> style="display: flex;align-items: center;flex-direction: row;border: none;">
<div style="width: 60px;min-width: 60px;">PT变比</div>
<div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[0].limit" style="width: 100%;"
:controls="false" />
</div>
</div>
<div class="tab-content-item-box box-color box-height" style="display: flex;align-items: center;border: none;flex-direction: row;">
<div style="width: 60px;min-width: 60px;">CT变比</div>
<div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[1].limit" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height" style="border: none;">
<img src="@/assets/images/menuicon/noitem.png" style="width: 100%; height: 100%;" alt="">
</div> </div>
</div> </div>
<div class="tab-content-item"> <div class="tab-content-item">
<div class="tab-content-item-box box-height">延时s</div> <div class="tab-content-item-box box-height">延时s</div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[0].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[0].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[1].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[1].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[2].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[2].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[3].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[3].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.over_limit_alarm[4].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.over_limit_alarm[4].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[0].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.fault_alarm[0].delay" style="width: 100%;"
:controls="false" />
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-input-number v-model="infoList.fault_alarm[1].delay" style="width: 100%;" :controls="false" /> <el-input-number v-model="infoList.fault_alarm[1].delay" style="width: 100%;"
:controls="false" />
</div> </div>
</div> </div>
<div class="tab-content-item"> <div class="tab-content-item">
<div class="tab-content-item-box box-height">输出节点</div> <div class="tab-content-item-box box-height">输出节点</div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.over_limit_alarm[0].output_node"> <el-select v-model="infoList.over_limit_alarm[0].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.over_limit_alarm[1].output_node"> <el-select v-model="infoList.over_limit_alarm[1].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.over_limit_alarm[2].output_node"> <el-select v-model="infoList.over_limit_alarm[2].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.over_limit_alarm[3].output_node"> <el-select v-model="infoList.over_limit_alarm[3].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.over_limit_alarm[4].output_node"> <el-select v-model="infoList.over_limit_alarm[4].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.fault_alarm[0].output_node"> <el-select v-model="infoList.fault_alarm[0].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-select v-model="infoList.fault_alarm[1].output_node"> <el-select v-model="infoList.fault_alarm[1].output_node">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in options" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select> </el-select>
</div> </div>
</div> </div>
@ -296,7 +325,7 @@ const handleSave = () => {
<el-switch v-model="infoList.over_limit_alarm[2].enabled"></el-switch> <el-switch v-model="infoList.over_limit_alarm[2].enabled"></el-switch>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-switch v-model="infoList.over_limit_alarm[3].enabled" ></el-switch> <el-switch v-model="infoList.over_limit_alarm[3].enabled"></el-switch>
</div> </div>
<div class="tab-content-item-box box-color box-height"> <div class="tab-content-item-box box-color box-height">
<el-switch v-model="infoList.over_limit_alarm[4].enabled"></el-switch> <el-switch v-model="infoList.over_limit_alarm[4].enabled"></el-switch>
@ -368,6 +397,7 @@ const handleSave = () => {
padding: 20px 20px; padding: 20px 20px;
min-height: max-content; min-height: max-content;
gap: 5px; gap: 5px;
.tab-content-item { .tab-content-item {
width: calc(100% / 6); width: calc(100% / 6);
display: flex; display: flex;
@ -394,7 +424,8 @@ const handleSave = () => {
.box-color { .box-color {
background-color: #ffffff; background-color: #ffffff;
} }
.box-height{
.box-height {
height: 40px; height: 40px;
} }
} }
@ -410,21 +441,24 @@ const handleSave = () => {
} }
} }
} }
:deep(.el-select__wrapper), :deep(.el-select__wrapper),
:deep(.el-input__wrapper) { :deep(.el-input__wrapper) {
border: none !important; border: none !important;
box-shadow: none !important; box-shadow: none !important;
background: transparent !important; background: transparent !important;
text-align: center !important; text-align: center !important;
} }
:deep(.el-select__wrapper.is-hover),
:deep(.el-input__wrapper.is-hover), :deep(.el-select__wrapper.is-hover),
:deep(.el-select__wrapper.is-focused), :deep(.el-input__wrapper.is-hover),
:deep(.el-input__wrapper.is-focused) { :deep(.el-select__wrapper.is-focused),
:deep(.el-input__wrapper.is-focused) {
box-shadow: none !important; box-shadow: none !important;
border: none !important; border: none !important;
} }
:deep(.el-input__inner){
:deep(.el-input__inner) {
text-align: center !important; text-align: center !important;
} }
</style> </style>