@@ -479,6 +479,12 @@ const configDialog = reactive({
// 打开配置对话框
const openConfigDialog = (row: IotMaintenanceBomVO) => {
+ // 新增规则校验:至少一个规则开启
+ if (row.mileageRule !== 0 && row.runningTimeRule !== 0 && row.naturalDateRule !== 0) {
+ message.error('请先设置保养规则')
+ return
+ }
+
configDialog.current = row
// 处理日期初始化(核心修改)
@@ -571,6 +571,12 @@ const configDialog = reactive({