From a901838aa284d7c26ab38d13795376886dbc032f Mon Sep 17 00:00:00 2001 From: Wayne Date: Wed, 17 Jan 2024 09:43:01 +0800 Subject: [PATCH] release v1 --- admin/package.json | 3 +- admin/src/api/product.js | 5 +- admin/src/main.js | 12 +- admin/src/pages/Contact/email/Index.vue | 2 +- admin/src/pages/Contact/map/Index.vue | 43 ++- admin/src/pages/Index/banner/Index.vue | 48 +++- admin/src/pages/Index/supplier/Index.vue | 50 +++- .../pages/Index/supplier/components/Form.vue | 10 +- admin/src/pages/News/activity/Index.vue | 12 +- .../pages/News/activity/components/Form.vue | 14 +- admin/src/pages/News/list/form.vue | 8 +- admin/src/pages/Product/group/Index.vue | 49 +++- .../pages/Product/list/components/Form.vue | 251 ------------------ admin/src/pages/Product/list/index.vue | 118 +++++++- admin/vite.config.js | 5 +- .../controller/ActivityController.php | 8 +- .../adminapi/controller/BranchController.php | 8 +- .../adminapi/controller/CateController.php | 5 +- .../adminapi/controller/IndexController.php | 16 +- .../adminapi/controller/NewsController.php | 2 +- .../adminapi/controller/ProductController.php | 36 ++- .../controller/SupplierController.php | 109 ++++---- .../appapi/controller/ContactController.php | 1 + app/app/appapi/controller/IndexController.php | 48 ++-- .../appapi/controller/ProductController.php | 3 +- .../appapi/controller/SocialController.php | 36 ++- web/package.json | 3 +- web/pages/index.vue | 19 +- web/pages/social.vue | 2 +- web/pages/social/news/detail/[id].vue | 11 +- web/pages/social/news/index.vue | 2 +- 31 files changed, 513 insertions(+), 426 deletions(-) delete mode 100644 admin/src/pages/Product/list/components/Form.vue diff --git a/admin/package.json b/admin/package.json index 67accf3..bba7a43 100644 --- a/admin/package.json +++ b/admin/package.json @@ -6,7 +6,8 @@ "scripts": { "dev": "vite", "build": "vite build", - "preview": "vite preview" + "preview": "vite preview", + "postbuild": "scp -r ./dist/* root@207.148.89.145:/www/wwwroot/prodio.zltest.com.tw/public/admin" }, "dependencies": { "@ckeditor/ckeditor5-vue": "^5.1.0", diff --git a/admin/src/api/product.js b/admin/src/api/product.js index 18f0a88..04090f2 100644 --- a/admin/src/api/product.js +++ b/admin/src/api/product.js @@ -1,7 +1,8 @@ import ajax from "@/utils/request"; -export const getProductList = async () => - ajax(`/product/getProductList`, "GET"); +export const getProductList = async (params) => { + return ajax(`/product/getProductList`, "POST", params); +} export const getProduct = async (id) => ajax(`/product/getProduct`, "GET" , { id }); diff --git a/admin/src/main.js b/admin/src/main.js index 3374841..4ae0ecb 100644 --- a/admin/src/main.js +++ b/admin/src/main.js @@ -6,9 +6,19 @@ import CKEditor from '@ckeditor/ckeditor5-vue'; import "./assets/css/normalize.css"; import "./assets/css/common.less"; - + const app = createApp(App); +app.directive('focus', { + // 將el-input的下的input元素聚焦 + + mounted(el) { + const inputElement = el.querySelector('input'); + // Focus the element + inputElement.focus() + } +}) + app.use(router); app.use(store); app.use(CKEditor); diff --git a/admin/src/pages/Contact/email/Index.vue b/admin/src/pages/Contact/email/Index.vue index af94ec0..4e2f228 100644 --- a/admin/src/pages/Contact/email/Index.vue +++ b/admin/src/pages/Contact/email/Index.vue @@ -104,7 +104,7 @@ const handleShowContent = (row) => { - + --> - - + + + + + + + + diff --git a/admin/src/pages/News/activity/Index.vue b/admin/src/pages/News/activity/Index.vue index ea31523..a020e88 100644 --- a/admin/src/pages/News/activity/Index.vue +++ b/admin/src/pages/News/activity/Index.vue @@ -108,8 +108,8 @@ const handleCloseFormDraw = (val) => { @@ -140,8 +140,10 @@ const handleCloseFormDraw = (val) => { - - + + + +