🐛(component): 修复 table 工具栏 dropdown 随滚动条滚动
This commit is contained in:
parent
212ce9a599
commit
e05781963d
@ -186,8 +186,8 @@ function diff(arr1: any[], arr2: any[]) {
|
|||||||
var newArr = [];
|
var newArr = [];
|
||||||
arr1 = Array.from(new Set(arr1)); // 去重
|
arr1 = Array.from(new Set(arr1)); // 去重
|
||||||
arr2 = Array.from(new Set(arr2)); // 去重
|
arr2 = Array.from(new Set(arr2)); // 去重
|
||||||
newArr =arr1.concat(arr2);
|
newArr = arr1.concat(arr2);
|
||||||
return newArr.filter(x=>!(arr1.includes(x) && arr2.includes(x)))
|
return newArr.filter((x) => !(arr1.includes(x) && arr2.includes(x)));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -560,7 +560,7 @@ const renderTotalRowCell = (column: any) => {
|
|||||||
<slot name="toolbar"></slot>
|
<slot name="toolbar"></slot>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="defaultToolbar" class="layui-table-tool-self">
|
<div v-if="defaultToolbar" class="layui-table-tool-self">
|
||||||
<lay-dropdown>
|
<lay-dropdown updateAtScroll>
|
||||||
<div class="layui-inline" title="筛选列" lay-event="LAYTABLE_PRINT">
|
<div class="layui-inline" title="筛选列" lay-event="LAYTABLE_PRINT">
|
||||||
<i class="layui-icon layui-icon-cols"></i>
|
<i class="layui-icon layui-icon-cols"></i>
|
||||||
</div>
|
</div>
|
||||||
@ -618,7 +618,12 @@ const renderTotalRowCell = (column: any) => {
|
|||||||
</template>
|
</template>
|
||||||
</colgroup>
|
</colgroup>
|
||||||
<thead>
|
<thead>
|
||||||
<template v-for="(tableHeadColumn, tableHeadColumnIndex) in tableHeadColumns" :key="tableHeadColumnIndex">
|
<template
|
||||||
|
v-for="(
|
||||||
|
tableHeadColumn, tableHeadColumnIndex
|
||||||
|
) in tableHeadColumns"
|
||||||
|
:key="tableHeadColumnIndex"
|
||||||
|
>
|
||||||
<tr>
|
<tr>
|
||||||
<template
|
<template
|
||||||
v-for="(column, columnIndex) in tableHeadColumn"
|
v-for="(column, columnIndex) in tableHeadColumn"
|
||||||
|
Loading…
Reference in New Issue
Block a user