diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue index 49d0f96..812966e 100644 --- a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue index 49d0f96..812966e 100644 --- a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue index fd0c082..4449430 100644 --- a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue @@ -104,11 +104,11 @@ const validateHighValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -118,11 +118,11 @@ const validateLowValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue index 49d0f96..812966e 100644 --- a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue index fd0c082..4449430 100644 --- a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue @@ -104,11 +104,11 @@ const validateHighValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -118,11 +118,11 @@ const validateLowValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 diff --git a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue index 66dc1e0..ddd9433 100644 --- a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue index 49d0f96..812966e 100644 --- a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue index fd0c082..4449430 100644 --- a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue @@ -104,11 +104,11 @@ const validateHighValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -118,11 +118,11 @@ const validateLowValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 diff --git a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue index 66dc1e0..ddd9433 100644 --- a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editO2Level.vue b/src/views/systemConfig/alarmLevel/components/editO2Level.vue index 41a22c4..6879ec5 100644 --- a/src/views/systemConfig/alarmLevel/components/editO2Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editO2Level.vue @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 @@ -161,6 +161,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue index f98a3f4..a1d39b1 100644 --- a/src/views/systemConfig/alarmLevel/components/editCOLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editCOLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue index 769be20..717c30b 100644 --- a/src/views/systemConfig/alarmLevel/components/editCh4Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editCh4Level.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue index 5cb5c54..84271be 100644 --- a/src/views/systemConfig/alarmLevel/components/editDigLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editDigLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue index 2cfe393..b890225 100644 --- a/src/views/systemConfig/alarmLevel/components/editGasLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editGasLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue index 49d0f96..812966e 100644 --- a/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editH2sLevel.vue @@ -93,8 +93,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -112,6 +112,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue index fd0c082..4449430 100644 --- a/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editHumiLevel.vue @@ -104,11 +104,11 @@ const validateHighValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -118,11 +118,11 @@ const validateLowValue = (rule, value, callback) => { if (value !== '') { if ((/^[+]{0,1}(\d+)$|^[+]{0,1}(\d+\.\d+)$/).test(value) === false) { - callback(new Error('请填写0~100以内的数字')) + callback(new Error('请填写0~120以内的数字')) } else { const float = parseFloat(value) - if (float > 100) { - callback(new Error('请填写0~100以内的数字')) + if (float > 120) { + callback(new Error('请填写0~120以内的数字')) } callback() } @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 diff --git a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue index 66dc1e0..ddd9433 100644 --- a/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editLiquidLevel.vue @@ -91,8 +91,8 @@ form: { name: '', // 指标名称 deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 secondHighValue: '', // 二级告警上限 thirdHighValue: '' // 三级告警上限 @@ -110,6 +110,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editO2Level.vue b/src/views/systemConfig/alarmLevel/components/editO2Level.vue index 41a22c4..6879ec5 100644 --- a/src/views/systemConfig/alarmLevel/components/editO2Level.vue +++ b/src/views/systemConfig/alarmLevel/components/editO2Level.vue @@ -136,8 +136,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 @@ -161,6 +161,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) { diff --git a/src/views/systemConfig/alarmLevel/components/editTempLevel.vue b/src/views/systemConfig/alarmLevel/components/editTempLevel.vue index 76f43bb..2f557a4 100644 --- a/src/views/systemConfig/alarmLevel/components/editTempLevel.vue +++ b/src/views/systemConfig/alarmLevel/components/editTempLevel.vue @@ -135,8 +135,8 @@ loading: true, // 是否开启加载效果 form: { deviceType: '', // 报警规则id - openAlarm: true, // 开启报警 - openJob: true, // 开启工单 + openAlarm: '1', // 开启报警 + openJob: '1', // 开启工单 firstHighValue: '', // 一级告警上限 firstLowValue: '', // 一级告警下限 secondHighValue: '', // 二级告警上限 @@ -160,6 +160,19 @@ } // 前端校验规则 } }, + watch: { + 'form.openAlarm': function(val) { + debugger + if (val === '0') { + this.form.openJob = '0' + } + }, + 'form.openJob': function(val) { + if (val === '1') { + this.form.openAlarm = '1' + } + } + }, methods: { // 初始化对话框 initDialog: function(dialogStatus, dialogFormVisible, tenantId, row = null) {