fix: table actions
parent
c264945d8f
commit
a063d8e81e
|
|
@ -237,7 +237,7 @@ function getTooltipProps(tooltip: any | string) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleMenuClick(e: any) {
|
function handleMenuClick(e: any) {
|
||||||
const action = unref(getDropdownList)[e.key];
|
const action = getDropdownList.value[e.key];
|
||||||
if (action.onClick && isFunction(action.onClick)) {
|
if (action.onClick && isFunction(action.onClick)) {
|
||||||
action.onClick();
|
action.onClick();
|
||||||
}
|
}
|
||||||
|
|
@ -294,10 +294,7 @@ function getActionKey(action: ActionItem, index: number) {
|
||||||
</slot>
|
</slot>
|
||||||
<template #overlay>
|
<template #overlay>
|
||||||
<Menu @click="handleMenuClick">
|
<Menu @click="handleMenuClick">
|
||||||
<Menu.Item
|
<Menu.Item v-for="(action, index) in getDropdownList" :key="index">
|
||||||
v-for="(action, index) in getDropdownList"
|
|
||||||
:key="`dropdown-${index}`"
|
|
||||||
>
|
|
||||||
<template v-if="action.popConfirm">
|
<template v-if="action.popConfirm">
|
||||||
<Popconfirm v-bind="getPopConfirmProps(action.popConfirm)">
|
<Popconfirm v-bind="getPopConfirmProps(action.popConfirm)">
|
||||||
<template v-if="action.popConfirm.icon" #icon>
|
<template v-if="action.popConfirm.icon" #icon>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue