Browse Source

fix:告警逻辑修改页面 修改必选 不可更改问题

temp
zhaohy 3 months ago
parent
commit
1aa6ebdd45
  1. 24
      hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/editeEnergyAlarm.vue
  2. 23
      hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editeEquipmentAlarm.vue

24
hx-ai-intelligent/src/view/alarmManagement/alarmSettings/energyAlarm/editeEnergyAlarm.vue

@ -51,7 +51,8 @@
placeholder="请选择优先级"
style="width: 100%"
allowClear
:options="PriorityEnum" />
:options="PriorityEnum"
@change="handleChangePriority" />
</a-form-item>
<a-form-item label="监测频率" name="monitorFrequency">
<a-select
@ -72,7 +73,9 @@
@change="changeSwitch" />
</a-form-item>
<a-form-item label="是否创建工单" name="createWorkOrder">
<a-radio-group v-model:value="infoObject.createWorkOrder">
<a-radio-group
v-model:value="infoObject.createWorkOrder"
:disabled="infoObject.priority === 1">
<a-radio value="1"> </a-radio>
<a-radio value="0"> </a-radio>
</a-radio-group>
@ -215,6 +218,12 @@
break;
}
};
//
const handleChangePriority = () => {
if (infoObject.value.priority === 1) {
infoObject.value.createWorkOrder = '1';
}
};
const btnClick = () => {
//
formRef.value.validate().then(() => {
@ -308,4 +317,15 @@
text-align: right;
width: 23%;
}
//
:deep(.ant-radio-disabled .ant-radio-inner::after) {
background-color: #2778ff !important;
border-color: #2778ff !important;
}
:deep(.ant-radio-checked .ant-radio-inner) {
border-color: #2778ff !important;
}
:deep(.ant-radio-disabled + span) {
color: rgba(51, 51, 51, 1);
}
</style>

23
hx-ai-intelligent/src/view/alarmManagement/alarmSettings/equipmentAlarm/editeEquipmentAlarm.vue

@ -75,7 +75,8 @@
placeholder="请选择优先级"
style="width: 100%"
allowClear
:options="PriorityEnum" />
:options="PriorityEnum"
@change="handleChangePriority" />
</a-form-item>
<a-form-item label="启用规则">
<a-switch
@ -88,7 +89,9 @@
@change="changeSwitch" />
</a-form-item>
<a-form-item label="是否创建工单" name="createWorkOrder">
<a-radio-group v-model:value="infoObject.createWorkOrder">
<a-radio-group
v-model:value="infoObject.createWorkOrder"
:disabled="infoObject.priority === 1">
<a-radio value="1"> </a-radio>
<a-radio value="0"> </a-radio>
</a-radio-group>
@ -258,6 +261,12 @@
break;
}
};
//
const handleChangePriority = () => {
if (infoObject.value.priority === 1) {
infoObject.value.createWorkOrder = '1';
}
};
const btnClick = () => {
//
formRef.value.validate().then(() => {
@ -394,4 +403,14 @@
text-align: right;
width: 23%;
}
//
:deep(.ant-radio-disabled .ant-radio-inner::after) {
background-color: #2778ff !important;
}
:deep(.ant-radio-checked .ant-radio-inner) {
border-color: #2778ff !important;
}
:deep(.ant-radio-disabled + span) {
color: rgba(51, 51, 51, 1);
}
</style>

Loading…
Cancel
Save