From 68c11b79a93e1fe266a828fe48a9d9359eefe0ad Mon Sep 17 00:00:00 2001 From: ch Date: Tue, 12 Apr 2022 19:01:04 +0800 Subject: [PATCH 1/9] =?UTF-8?q?=E7=A7=92=E6=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/api/seckill.js | 25 ++ common/utils/requset.js | 6 +- components/BsChoiceGoods.vue | 4 +- components/UiRadioPicker.vue | 88 +++++++ manifest.json | 11 +- pages.json | 4 +- .../goods/detail/components/SeckillPrice.vue | 109 ++++++++ pages/goods/detail/index.vue | 3 +- pages/goods/list/index.vue | 4 +- pages/goods/search.vue | 4 +- pages/index/components/Banner.vue | 7 +- pages/index/components/Pick.vue | 45 ++-- pages/index/components/Seckill.vue | 234 ++++++++++++++++++ pages/index/components/Sekill.vue | 190 -------------- pages/index/index.vue | 28 ++- .../order/saleAfter/saleAfterApplication.vue | 52 +++- pages/{sekill.vue => seckill.vue} | 126 +++++++--- static/goods/seckill.png | Bin 0 -> 7207 bytes static/{sekill => seckill}/banner.png | Bin static/{sekill => seckill}/btn.png | Bin static/{sekill => seckill}/btn2.png | Bin static/{sekill => seckill}/jz.png | Bin 22 files changed, 656 insertions(+), 284 deletions(-) create mode 100644 common/api/seckill.js create mode 100644 components/UiRadioPicker.vue create mode 100644 pages/goods/detail/components/SeckillPrice.vue create mode 100644 pages/index/components/Seckill.vue delete mode 100644 pages/index/components/Sekill.vue rename pages/{sekill.vue => seckill.vue} (51%) create mode 100644 static/goods/seckill.png rename static/{sekill => seckill}/banner.png (100%) rename static/{sekill => seckill}/btn.png (100%) rename static/{sekill => seckill}/btn2.png (100%) rename static/{sekill => seckill}/jz.png (100%) diff --git a/common/api/seckill.js b/common/api/seckill.js new file mode 100644 index 0000000..99b7958 --- /dev/null +++ b/common/api/seckill.js @@ -0,0 +1,25 @@ +/* + * @Author: ch + * @Date: 2022-04-12 13:56:24 + * @LastEditors: ch + * @LastEditTime: 2022-04-12 16:06:34 + * @Description: file content + */ +import {ToAsyncAwait, MsbRequestTk} from '@/common/utils'; + +const BASE_URL = '/mall/marketing'; + + export const ApiGetHomeSeckill = () => + ToAsyncAwait(MsbRequestTk.get(`${BASE_URL}/app/activity/home`)); + +/** + * 获取当天秒杀时段 + */ + export const ApiGetSeckillTimes = () => + ToAsyncAwait(MsbRequestTk.get(`${BASE_URL}/app/activity/time`)); +/** + * 获取当天秒杀时段 + */ + export const ApiGetSeckillGoods = (params) => + ToAsyncAwait(MsbRequestTk.get(`${BASE_URL}/app/activity/product`, params)); + diff --git a/common/utils/requset.js b/common/utils/requset.js index 4397fea..a05c706 100644 --- a/common/utils/requset.js +++ b/common/utils/requset.js @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-17 17:42:32 * @LastEditors: ch - * @LastEditTime: 2022-04-12 09:19:05 + * @LastEditTime: 2022-04-12 09:28:17 * @Description: 项目接口请求统一处理器,返回一个需要token和不需要token的请求封装方法 */ @@ -11,8 +11,8 @@ import $store from '@/common/store'; const ENV = 'test'; const BASE_URL = { - // 'test' : 'http://39.103.236.147/api', - 'test' : 'http://k8s-horse-gateway.mashibing.cn', + // 'test' : 'http://k8s-horse-gateway.mashibing.cn', + 'test' : '', 'release' : '', 'prod' : '' }; diff --git a/components/BsChoiceGoods.vue b/components/BsChoiceGoods.vue index 0c2f32d..a546e42 100644 --- a/components/BsChoiceGoods.vue +++ b/components/BsChoiceGoods.vue @@ -2,13 +2,13 @@ * @Author: ch * @Date: 2022-03-20 16:45:27 * @LastEditors: ch - * @LastEditTime: 2022-04-08 09:59:33 + * @LastEditTime: 2022-04-12 16:47:49 * @Description: file content --> + \ No newline at end of file diff --git a/manifest.json b/manifest.json index bc54951..ff39ef5 100644 --- a/manifest.json +++ b/manifest.json @@ -78,16 +78,7 @@ "/uc/" : { "target" : "http://192.168.10.52:8090/" }, - "/mall/trade/" : { - "target" : "http://192.168.10.52:8090/" - }, - "/mall/base/" : { - "target" : "http://192.168.10.52:8090/" - }, - "/pay/" : { - "target" : "http://192.168.10.52:8090/" - }, - "/mall/product/" : { + "/mall/" : { "target" : "http://192.168.10.52:8090/" } } diff --git a/pages.json b/pages.json index ac88bdf..e18f5f8 100644 --- a/pages.json +++ b/pages.json @@ -18,8 +18,8 @@ } }, { - "path": "pages/sekill", - "aliasPath" : "/sekill", + "path": "pages/seckill", + "aliasPath" : "/seckill", "style": { "navigationStyle" : "custom", "navigationBarTitleText": "uni-app" diff --git a/pages/goods/detail/components/SeckillPrice.vue b/pages/goods/detail/components/SeckillPrice.vue new file mode 100644 index 0000000..e5734be --- /dev/null +++ b/pages/goods/detail/components/SeckillPrice.vue @@ -0,0 +1,109 @@ + + + + \ No newline at end of file diff --git a/pages/goods/detail/index.vue b/pages/goods/detail/index.vue index 0c63c97..bfc9e95 100644 --- a/pages/goods/detail/index.vue +++ b/pages/goods/detail/index.vue @@ -2,7 +2,7 @@ * @Author: ch * @Date: 2022-03-23 17:27:21 * @LastEditors: ch - * @LastEditTime: 2022-04-11 10:22:17 + * @LastEditTime: 2022-04-12 17:35:22 * @Description: file content -->