zhoupeng 1 year ago
parent
commit
3ac61e9279

+ 14 - 1
industry-admin/src/views/device/deviceLedger/itemList.vue

@@ -120,8 +120,21 @@ export default {
                     })
                     return
                 }
+                let arr = res.data.itemList
+                let count = 0
+                for (let a of arr) {
+                    if (!a.itemReadName) {
+                        count++
+                    }
+                }
+                if (count != 0) {
+                    this.$message({
+                        message: '存在数据项在数据组中被删除,请同步删除没有数据项名称的数据项',
+                        type: 'warning'
+                    })
+                }
                 this.tableTotal = res.data.count
-                this.tableData = res.data.itemList
+                this.tableData = arr
             })
         },
         /** 表格操作按钮删除数据项 */

+ 13 - 0
industry-admin/src/views/largeScreen/deviceRunParam/deviceRun.vue

@@ -171,6 +171,19 @@ export default {
                     })
                     return
                 }
+                let arr = res.data.deviceRunItemList
+                let count = 0
+                for (let a of arr) {
+                    if (!a.itemReadName) {
+                        count++
+                    }
+                }
+                if (count != 0) {
+                    this.$message({
+                        message: '存在数据项在数据组中被删除,请同步删除没有数据项名称的数据项',
+                        type: 'warning'
+                    })
+                }
                 this.deviceRunForm = res.data
             })
         },

+ 10 - 0
industry-admin/src/views/largeScreen/mainRunParam/mainRun.vue

@@ -205,7 +205,11 @@ export default {
                 this.mainRunForm = res.data
                 let arr = this.mainRunForm.mainRunItemList
                 let arrF = []
+                let count = 0
                 for (let a of arr) {
+                    if (!a.itemReadName) {
+                        count++
+                    }
                     const b = {}
                     Object.keys(a).forEach(key => {
                         b[key] = a[key]
@@ -221,6 +225,12 @@ export default {
                     }
                     arrF.push(b)
                 }
+                if (count != 0) {
+                    this.$message({
+                        message: '存在数据项在数据组中被删除,请同步删除没有数据项名称的数据项',
+                        type: 'warning'
+                    })
+                }
                 this.mainRunForm.mainRunItemList = arrF
             })
         },

+ 13 - 0
industry-admin/src/views/largeScreen/trafficChartParam/trafficChart.vue

@@ -201,6 +201,19 @@ export default {
                     })
                     return
                 }
+                let arr = res.data.trafficChartItemList
+                let count = 0
+                for (let a of arr) {
+                    if (!a.itemReadName) {
+                        count++
+                    }
+                }
+                if (count != 0) {
+                    this.$message({
+                        message: '存在数据项在数据组中被删除,请同步删除没有数据项名称的数据项',
+                        type: 'warning'
+                    })
+                }
                 this.trafficChartForm = res.data
             })
         },