From c8be545ef808e5eaa864a2d97544113ca015f629 Mon Sep 17 00:00:00 2001 From: Thanaphon Frappet Date: Mon, 2 Dec 2024 10:38:22 +0700 Subject: [PATCH] refactor: handle action edit --- src/components/05_quotation/TableQuotation.vue | 2 ++ src/components/shared/KebabAction.vue | 3 ++- src/pages/05_quotation/MainPage.vue | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/components/05_quotation/TableQuotation.vue b/src/components/05_quotation/TableQuotation.vue index 5cc97d46..395f0e81 100644 --- a/src/components/05_quotation/TableQuotation.vue +++ b/src/components/05_quotation/TableQuotation.vue @@ -15,6 +15,7 @@ const props = withDefaults( columns: QTableProps['columns']; grid?: boolean; visibleColumns?: string[]; + hideEdit?: boolean; }>(), { row: () => [], @@ -151,6 +152,7 @@ defineEmits<{ :idName="`btn-kebab-${props.row.firstName}`" status="'ACTIVE'" hide-toggle + :hide-edit="hideEdit" @view="$emit('view', props.row)" @edit="$emit('edit', props.row)" @delete="$emit('delete', props.row.id)" diff --git a/src/components/shared/KebabAction.vue b/src/components/shared/KebabAction.vue index f6aedecf..633ed998 100644 --- a/src/components/shared/KebabAction.vue +++ b/src/components/shared/KebabAction.vue @@ -11,6 +11,7 @@ const props = withDefaults( hideToggle?: boolean; useLink?: boolean; useUpload?: boolean; + hideEdit?: boolean; disableDelete?: boolean; }>(), @@ -73,7 +74,7 @@ watch(