From 5b7e8f7b52acb055bd30613aa49d70d9ac4f6df8 Mon Sep 17 00:00:00 2001 From: Net <93821485+somnetsak123@users.noreply.github.com> Date: Tue, 11 Jun 2024 15:02:17 +0700 Subject: [PATCH] =?UTF-8?q?fix:=20=E0=B9=81=E0=B8=81=E0=B9=89=E0=B8=A3?= =?UTF-8?q?=E0=B8=B1=E0=B8=9A=E0=B8=84=E0=B9=88=E0=B8=B2=20createProductSe?= =?UTF-8?q?rvice?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/stores/product-service/index.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/stores/product-service/index.ts b/src/stores/product-service/index.ts index 59deabeb..6547c2b1 100644 --- a/src/stores/product-service/index.ts +++ b/src/stores/product-service/index.ts @@ -58,8 +58,12 @@ const useProductServiceStore = defineStore('api-product-service', () => { return false; } - async function createProductService() { - const res = await api.post('/product-group'); + async function createProductService(data: ProductGroupCreate) { + const { code, ...payload } = data; + + const res = await api.post('/product-group', { + ...payload, + }); if (!res) return false;