fix tableTransferComponent : modify data error. (#173)
* fix tableTransferComponent : modify data error.
* fix tableTransferComponent : modify data error.
diff --git a/src/routes/System/AppAuth/index.js b/src/routes/System/AppAuth/index.js
index c905255..b97ce97 100644
--- a/src/routes/System/AppAuth/index.js
+++ b/src/routes/System/AppAuth/index.js
@@ -182,7 +182,9 @@
// pageSize: 10
},
callback: datas => {
- datas.dataList = datas.dataList.concat(auth.auth);
+ // remove duplicate elements and add
+ const pathArr = auth.auth.map(e => e.path);
+ datas.dataList = datas.dataList.filter(item=>!pathArr.includes(item.path)).concat(auth.auth);
this.setState({
popup: (
<RelateMetadata