Compare commits

...

2 Commits

Author SHA1 Message Date
785bb81f18 代码格式化 2023-06-28 17:17:09 +08:00
53c01a298b fix table 分页筛选 2023-06-28 17:15:47 +08:00
7 changed files with 26 additions and 23 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -346,7 +346,7 @@ watch(tableDataSource, () => {
tmp.total = tableDataSource.value.length;
emit("update:page", tmp);
// tableDataSource.value = endlist
sxlist.value = [];
sxlist.value = {};
change({
limit: props.page.limit,
current: pagecurrent || props.page.current,
@ -759,7 +759,7 @@ const soultop = ref(0);
const soulleft = ref(0);
const selcolumn = ref<any>({});
const soulkey = ref("");
const sxlist: any = ref([]);
const sxlist: any = ref({});
function showsoul(event: MouseEvent, column: any, key: string) {
console.log(event);
soulleft.value = event.pageX;
@ -782,16 +782,17 @@ function desc(event: any) {
function sx(e: any) {
sxlist.value[e.key] = e.list;
console.log("筛选事件", sxlist.value, sxlist.value.length);
}
watch(sxlist, () => {
console.log("sxlist更新");
});
watch(
[sxlist, () => props.dataSource],
[() => sxlist, () => props.dataSource],
(old, new1) => {
// tableDataSource
// console.log(JSON.stringify(sxlist.value),JSON.stringify(props.dataSource),old[0] == new1[0],old[1] == new1[1])
if (sxlist.value.length == 0) {
if (Object.keys(sxlist.value).length == 0) {
return;
}
let list: any = [...props.dataSource];

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long