From 7948d340246d9bca6059983a21ffebc60fbd41f2 Mon Sep 17 00:00:00 2001 From: GeDashi <2531216855@qq.com> Date: Tue, 17 Dec 2024 18:19:24 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A41?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/system/goods.js | 44 +++++ src/views/system/goods/index.vue | 307 +++++++++++++++++++++++++++++++ vite.config.js | 2 +- 3 files changed, 352 insertions(+), 1 deletion(-) create mode 100644 src/api/system/goods.js create mode 100644 src/views/system/goods/index.vue diff --git a/src/api/system/goods.js b/src/api/system/goods.js new file mode 100644 index 0000000..e3131bd --- /dev/null +++ b/src/api/system/goods.js @@ -0,0 +1,44 @@ +import request from '@/utils/request' + +// 查询【请填写功能名称】列表 +export function listGoods(query) { + return request({ + url: '/system/goods/list', + method: 'get', + params: query + }) +} + +// 查询【请填写功能名称】详细 +export function getGoods(goodsId) { + return request({ + url: '/system/goods/' + goodsId, + method: 'get' + }) +} + +// 新增【请填写功能名称】 +export function addGoods(data) { + return request({ + url: '/system/goods', + method: 'post', + data: data + }) +} + +// 修改【请填写功能名称】 +export function updateGoods(data) { + return request({ + url: '/system/goods', + method: 'put', + data: data + }) +} + +// 删除【请填写功能名称】 +export function delGoods(goodsId) { + return request({ + url: '/system/goods/' + goodsId, + method: 'delete' + }) +} diff --git a/src/views/system/goods/index.vue b/src/views/system/goods/index.vue new file mode 100644 index 0000000..6b8e52c --- /dev/null +++ b/src/views/system/goods/index.vue @@ -0,0 +1,307 @@ + + + diff --git a/vite.config.js b/vite.config.js index 2b6f847..518c764 100644 --- a/vite.config.js +++ b/vite.config.js @@ -25,7 +25,7 @@ export default defineConfig(({ mode, command }) => { }, // vite 相关配置 server: { - port: 80, + port: 81, host: true, open: true, proxy: {