mirror of
https://gitee.com/bootx/dax-pay-ui.git
synced 2025-09-06 04:09:36 +00:00
fix(table): fix edit-table not work
This commit is contained in:
@@ -148,16 +148,10 @@
|
||||
});
|
||||
|
||||
watchEffect(() => {
|
||||
console.log('======================');
|
||||
console.log(1);
|
||||
console.log('======================');
|
||||
defaultValueRef.value = props.value;
|
||||
});
|
||||
|
||||
watchEffect(() => {
|
||||
console.log('======================');
|
||||
console.log(2);
|
||||
console.log('======================');
|
||||
const { editable } = props.column;
|
||||
if (isBoolean(editable) || isBoolean(unref(getRowEditable))) {
|
||||
isEdit.value = !!editable || unref(getRowEditable);
|
||||
|
@@ -117,7 +117,8 @@ export function useColumns(
|
||||
}
|
||||
const { ellipsis } = unref(propsRef);
|
||||
|
||||
columns.forEach((item) => {
|
||||
const cloneColumns = cloneDeep(columns);
|
||||
cloneColumns.forEach((item) => {
|
||||
const { customRender, slots } = item;
|
||||
|
||||
handleItem(
|
||||
@@ -125,7 +126,7 @@ export function useColumns(
|
||||
Reflect.has(item, 'ellipsis') ? !!item.ellipsis : !!ellipsis && !customRender && !slots
|
||||
);
|
||||
});
|
||||
return columns;
|
||||
return cloneColumns;
|
||||
});
|
||||
|
||||
const getViewColumns = computed(() => {
|
||||
@@ -152,7 +153,7 @@ export function useColumns(
|
||||
column.customRender = renderEditCell(column);
|
||||
}
|
||||
});
|
||||
return viewColumns;
|
||||
return columns;
|
||||
});
|
||||
|
||||
watch(
|
||||
|
Reference in New Issue
Block a user