diff --git a/src/views/warehouseManage/warehousing/Inventory/index.vue b/src/views/warehouseManage/warehousing/Inventory/index.vue index 90a151e..6efa5cf 100644 --- a/src/views/warehouseManage/warehousing/Inventory/index.vue +++ b/src/views/warehouseManage/warehousing/Inventory/index.vue @@ -68,7 +68,7 @@ " /> - + /> --> @@ -552,7 +559,7 @@ :show-overflow-tooltip="true" > @@ -1147,7 +1160,10 @@ export default { this.codeForm.codeSuffixStart = this.codeForm.codeSuffixStart.replace(/[^\d]/g, '') } - if (isNaN(this.codeForm.codeSuffixStart) || this.codeForm.codeSuffixStart.includes('.')) { + if ( + isNaN(this.codeForm.codeSuffixStart) || + this.codeForm.codeSuffixStart.includes('.') + ) { this.$message.error('后缀范围请输入整数类型') this.codeForm.codeSuffixStart = '' } @@ -1156,7 +1172,10 @@ export default { if (!this.codeForm.codeSuffixStart) { this.$message.error('请输入后缀范围起始值') this.codeForm.codeSuffixEnd = '' - } else if (isNaN(this.codeForm.codeSuffixEnd) || this.codeForm.codeSuffixEnd.includes('.')) { + } else if ( + isNaN(this.codeForm.codeSuffixEnd) || + this.codeForm.codeSuffixEnd.includes('.') + ) { this.$message.error('后缀范围请输入整数类型') this.codeForm.codeSuffixEnd = this.codeForm.codeSuffixStart.replace(/[^\d]/g, '') @@ -1415,24 +1434,28 @@ export default { } const res = await getDeviceTypeTree(params) if (type) { - this.disableNodes(res.data, '1'); + this.disableNodes(res.data, '1') } else { - this.disableNodes(res.data, '0'); + this.disableNodes(res.data, '0') } this.deviceTypeTree = res.data }, // 递归禁用节点 disableNodes(nodes, manageType, level = 1) { - nodes.forEach(node => { + nodes.forEach((node) => { node.level = level if (node.children) { - this.disableNodes(node.children, manageType, level + 1); + this.disableNodes(node.children, manageType, level + 1) } else if (!node.children && node.level < 4) { node.disabled = true - } else if(node.manageType && node.level == 4 && node.manageType != manageType) { + } else if ( + node.manageType && + node.level == 4 && + node.manageType != manageType + ) { node.disabled = true } - }); + }) }, /////// 设备类型树 切换 deviceTypeChange(val) { @@ -1571,7 +1594,10 @@ export default { }, // 校验检验日期 changeCheckTime() { - if (this.codeForm.nextCheckTime && this.codeForm.thisCheckTime > this.codeForm.nextCheckTime) { + if ( + this.codeForm.nextCheckTime && + this.codeForm.thisCheckTime > this.codeForm.nextCheckTime + ) { this.codeForm.nextCheckTime = '' this.$message.warning('下次检验日期不能早于检验日期!') } else if (!this.codeForm.thisCheckTime) { @@ -1600,4 +1626,4 @@ export default { ::v-deep .el-input-number.is-without-controls .el-input__inner { text-align: start; } - \ No newline at end of file +