Commit a2faf2df authored by yaqizhang's avatar yaqizhang

管道管理

parent 0de38c9b
...@@ -479,11 +479,17 @@ ...@@ -479,11 +479,17 @@
handleDelete(row) { handleDelete(row) {
row.isDel = "1"; row.isDel = "1";
var devices = " "; var devices = " ";
var tip = '';
if (row.deviceInfoList != null){
for(var i = 0; i < row.deviceInfoList.length; i++){ for(var i = 0; i < row.deviceInfoList.length; i++){
var obj = row.deviceInfoList[i]; var obj = row.deviceInfoList[i];
devices = devices + obj.deviceName + " "; devices = devices + obj.deviceName + " ";
} }
this.$confirm('请确认是否删除管道名称为"' + row.pipeName + '"的数据项,该管道下包含的设备(' + devices + ')将一并被删除', "警告", { tip = '请确认是否删除管道名称为"' + row.pipeName + '"的数据项,该管道下包含的设备(' + devices + ')将一并被删除', "警告"
}else{
tip ='请确认是否删除管道名称为"' + row.pipeName + '"的数据项';
}
this.$confirm(tip , {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
type: "warning" type: "warning"
......
...@@ -332,11 +332,18 @@ ...@@ -332,11 +332,18 @@
handleDelete(res) { handleDelete(res) {
res.isDel = "1"; res.isDel = "1";
var devices = " "; var devices = " ";
var tip = '';
if(res.deviceInfoList != null){
for (var i = 0; i < res.deviceInfoList.length; i++) { for (var i = 0; i < res.deviceInfoList.length; i++) {
var obj = res.deviceInfoList[i]; var obj = res.deviceInfoList[i];
devices = devices + obj.deviceName + " "; devices = devices + obj.deviceName + " ";
} }
this.$confirm('请确认是否删除管道名称为"' + res.pipeName + '"的数据项,该管道下包含的设备(' + devices + ')将一并被删除', "警告", { tip = '该管道下包含的设备(' + devices + ')将一并被删除', "警告"
}else{
tip = '请确认是否删除管道名称为"' + res.pipeName + '"的数据项'
}
this.$confirm(tip, {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
type: "warning" type: "warning"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment