|
@@ -279,7 +279,8 @@ export default {
|
|
// { key: '看板', value: 17 },
|
|
// { key: '看板', value: 17 },
|
|
// { key: '门禁设备', value: 18 },
|
|
// { key: '门禁设备', value: 18 },
|
|
// { key: '探视机', value: 19 },
|
|
// { key: '探视机', value: 19 },
|
|
- { key: '485转换盒', value: 20 }
|
|
|
|
|
|
+ { key: '485转换盒', value: 20 },
|
|
|
|
+ { key: '紧急按钮', value: 21 }
|
|
],
|
|
],
|
|
deviceStatusTransfer: [
|
|
deviceStatusTransfer: [
|
|
{ key: '启用', value: 1, color: 'green' },
|
|
{ key: '启用', value: 1, color: 'green' },
|
|
@@ -603,11 +604,12 @@ export default {
|
|
},
|
|
},
|
|
/** 设备类型选中变化 **/
|
|
/** 设备类型选中变化 **/
|
|
deviceTypeChange(val) {
|
|
deviceTypeChange(val) {
|
|
- if (val === 12 || val === 13 || val === 14) { // 模拟设备不需要mac地址
|
|
|
|
- // this.deviceRules.eth_mac[0].required = false
|
|
|
|
- this.deviceRules.eth_mac[1].pattern = null
|
|
|
|
|
|
+ if (val === 12 || val === 13 || val === 14 || val === 21) { // 模拟设备不需要mac地址
|
|
|
|
+ this.deviceRules.eth_mac[0].required = false
|
|
|
|
+ // this.deviceRules.eth_mac[1].pattern = null
|
|
} else if (val === 15) {
|
|
} else if (val === 15) {
|
|
this.deviceRules.eth_mac[1].pattern = null
|
|
this.deviceRules.eth_mac[1].pattern = null
|
|
|
|
+ this.deviceRules.eth_mac[0].required = true
|
|
} else {
|
|
} else {
|
|
this.deviceRules.eth_mac[1].pattern = /^([0-9A-Fa-f]{2}:?){6}/gi
|
|
this.deviceRules.eth_mac[1].pattern = /^([0-9A-Fa-f]{2}:?){6}/gi
|
|
this.deviceRules.eth_mac[0].required = true
|
|
this.deviceRules.eth_mac[0].required = true
|