|
@@ -1062,10 +1062,7 @@ export default {
|
1062
|
1062
|
name: this.searchForm.name
|
1063
|
1063
|
}).then((data) => {
|
1064
|
1064
|
if (data.code === 0) {
|
1065
|
|
- this.searchForm.list = data.obj.data || [];
|
1066
|
|
- this.searchForm.list.forEach((item) => {
|
1067
|
|
- item._checked = false;
|
1068
|
|
- });
|
|
1065
|
+ this.searchForm.list = data.obj.data;
|
1069
|
1066
|
this.searchForm.total = data.obj.total;
|
1070
|
1067
|
} else {
|
1071
|
1068
|
this.$Message.error(data.msg);
|
|
@@ -1268,6 +1265,16 @@ export default {
|
1268
|
1265
|
},
|
1269
|
1266
|
selectionChange(selection) {
|
1270
|
1267
|
this.tableSelection = selection;
|
|
1268
|
+ let userid_sn = this.tableSelection.map((item) => {
|
|
1269
|
+ return `${item.userid}_${item.sn}`;
|
|
1270
|
+ });
|
|
1271
|
+ this.searchForm.list.forEach((item) => {
|
|
1272
|
+ if (userid_sn.includes(`${item.userid}_${item.sn}`)) {
|
|
1273
|
+ item._checked = true;
|
|
1274
|
+ } else {
|
|
1275
|
+ item._checked = false;
|
|
1276
|
+ }
|
|
1277
|
+ });
|
1271
|
1278
|
},
|
1272
|
1279
|
// 表格行点击
|
1273
|
1280
|
deviceTableRowClick(row, index) {
|
|
@@ -1453,10 +1460,7 @@ export default {
|
1453
|
1460
|
this.$Message.error("推送失败");
|
1454
|
1461
|
}
|
1455
|
1462
|
});
|
1456
|
|
- this.tableSelection.forEach((item) => {
|
1457
|
|
- item._checked = false;
|
1458
|
|
- });
|
1459
|
|
- this.tableSelection = [];
|
|
1463
|
+ this.$refs.deviceTable.selectAll(false);
|
1460
|
1464
|
let form = {
|
1461
|
1465
|
pushType: 6,
|
1462
|
1466
|
pushObj: 1
|
|
@@ -1500,10 +1504,7 @@ export default {
|
1500
|
1504
|
} else {
|
1501
|
1505
|
form.userids = useridList;
|
1502
|
1506
|
}
|
1503
|
|
- this.tableSelection.forEach((item) => {
|
1504
|
|
- item._checked = false;
|
1505
|
|
- });
|
1506
|
|
- this.tableSelection = [];
|
|
1507
|
+ this.$refs.deviceTable.selectAll(false);
|
1507
|
1508
|
this.addPushLog(form);
|
1508
|
1509
|
}
|
1509
|
1510
|
});
|
|
@@ -1523,10 +1524,7 @@ export default {
|
1523
|
1524
|
this.$Message.error("推送失败");
|
1524
|
1525
|
}
|
1525
|
1526
|
});
|
1526
|
|
- this.tableSelection.forEach((item) => {
|
1527
|
|
- item._checked = false;
|
1528
|
|
- });
|
1529
|
|
- this.tableSelection = [];
|
|
1527
|
+ this.$refs.deviceTable.selectAll(false);
|
1530
|
1528
|
let form = {
|
1531
|
1529
|
pushType: 2,
|
1532
|
1530
|
pushObj: 1
|
|
@@ -1549,10 +1547,7 @@ export default {
|
1549
|
1547
|
this.$Message.error("推送失败");
|
1550
|
1548
|
}
|
1551
|
1549
|
});
|
1552
|
|
- this.tableSelection.forEach((item) => {
|
1553
|
|
- item._checked = false;
|
1554
|
|
- });
|
1555
|
|
- this.tableSelection = [];
|
|
1550
|
+ this.$refs.deviceTable.selectAll(false);
|
1556
|
1551
|
let form = {
|
1557
|
1552
|
pushType: 3,
|
1558
|
1553
|
pushObj: 1
|
|
@@ -1575,10 +1570,7 @@ export default {
|
1575
|
1570
|
this.$Message.error("推送失败");
|
1576
|
1571
|
}
|
1577
|
1572
|
});
|
1578
|
|
- this.tableSelection.forEach((item) => {
|
1579
|
|
- item._checked = false;
|
1580
|
|
- });
|
1581
|
|
- this.tableSelection = [];
|
|
1573
|
+ this.$refs.deviceTable.selectAll(false);
|
1582
|
1574
|
let form = {
|
1583
|
1575
|
pushType: 4,
|
1584
|
1576
|
pushObj: 1
|
|
@@ -1601,10 +1593,7 @@ export default {
|
1601
|
1593
|
this.$Message.error("推送失败");
|
1602
|
1594
|
}
|
1603
|
1595
|
});
|
1604
|
|
- this.tableSelection.forEach((item) => {
|
1605
|
|
- item._checked = false;
|
1606
|
|
- });
|
1607
|
|
- this.tableSelection = [];
|
|
1596
|
+ this.$refs.deviceTable.selectAll(false);
|
1608
|
1597
|
let form = {
|
1609
|
1598
|
pushType: 5,
|
1610
|
1599
|
pushObj: 1
|
|
@@ -1627,10 +1616,7 @@ export default {
|
1627
|
1616
|
this.$Message.error("推送失败");
|
1628
|
1617
|
}
|
1629
|
1618
|
});
|
1630
|
|
- this.tableSelection.forEach((item) => {
|
1631
|
|
- item._checked = false;
|
1632
|
|
- });
|
1633
|
|
- this.tableSelection = [];
|
|
1619
|
+ this.$refs.deviceTable.selectAll(false);
|
1634
|
1620
|
let form = {
|
1635
|
1621
|
pushType: 7,
|
1636
|
1622
|
pushObj: 1
|
|
@@ -1653,10 +1639,7 @@ export default {
|
1653
|
1639
|
this.$Message.error("推送失败");
|
1654
|
1640
|
}
|
1655
|
1641
|
});
|
1656
|
|
- this.tableSelection.forEach((item) => {
|
1657
|
|
- item._checked = false;
|
1658
|
|
- });
|
1659
|
|
- this.tableSelection = [];
|
|
1642
|
+ this.$refs.deviceTable.selectAll(false);
|
1660
|
1643
|
let form = {
|
1661
|
1644
|
pushType: 8,
|
1662
|
1645
|
pushObj: 1
|