提交 16b7bd10 作者: 毛细亚

Merge branch 'release' into 7.2

......@@ -108,7 +108,7 @@
<el-tabs v-model="form.gift_type" class="tabStyle" @tab-click="tabChange">
<el-tab-pane
v-for="(item, index) in giftTypeList"
:key="index"
:key="`${item.active_title}-${index}`"
:label="item.label"
:name="item.value"
></el-tab-pane>
......@@ -510,10 +510,9 @@ export default {
res.data.data.map((item, index) => {
item.showDetails = false;
});
this.emailGiftList = this.removeDp(
res.data.data,
this.emailGiftList,
res.data.data,
"id"
);
},
......@@ -526,9 +525,12 @@ export default {
this.isCollapsed = !this.isCollapsed;
},
removeDp(arr1, arr2, id) {
console.log(arr1, arr2, "合并");
let arr;
arr2 ? (arr = arr1.concat(arr2)) : (arr = arr1);
const obj = {};
console.log(arr, "合并前");
const newArray = arr.reduce((pre, cur) => {
if (!obj[cur[id]]) {
obj[cur[id]] = true;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论