From bd730d5946f0ebc1c561dde5936156a71625e778 Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Thu, 14 May 2020 19:42:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/scriptManage/scriptRecord/addRole.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/views/scriptManage/scriptRecord/addRole.vue b/src/views/scriptManage/scriptRecord/addRole.vue index 60fc97434..f8a3af218 100644 --- a/src/views/scriptManage/scriptRecord/addRole.vue +++ b/src/views/scriptManage/scriptRecord/addRole.vue @@ -97,7 +97,9 @@ export default { }); lastData = JSON.parse(lastData); lastData.forEach(each=>{ - each.name = each.role + (each.name == undefined ? '' : each.name); + const name = each.name == undefined ? '' : '-' + each.name; + const deviceName = each.deviceName == undefined ? '' : '-' + each.deviceName; + each.name = each.role + name + deviceName; }); return lastData; },