From cacd88529fbeb6267f570559eba2f0f9e34bf28f Mon Sep 17 00:00:00 2001 From: wangxiaowei <1121133807@qq.com> Date: Sat, 27 Jul 2024 14:04:36 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=86=E6=96=B0=E5=93=81=E6=8E=A8=E8=8D=90?= =?UTF-8?q?=E5=92=8C=E7=83=AD=E9=94=80=E6=A6=9C=E5=8D=95=E6=94=B9=E4=B8=BA?= =?UTF-8?q?=E4=B8=A4=E4=B8=AA=E5=8A=9F=E8=83=BD=E6=A8=A1=E5=9D=97=E6=9D=A5?= =?UTF-8?q?=E5=81=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/store.js | 11 +++- bundle_b/pages/mall_news/index.vue | 52 +++++++++------- components/active-area/active-area.vue | 17 +++--- components/cate-home/cate-home.vue | 2 +- components/goods-list/goods-list.vue | 24 ++++---- components/index-home/index-home.vue | 11 ++-- components/mall-news/mall-news.vue | 48 ++++++++++++--- pages/active_list/active_list.vue | 82 ++++++++++++++++---------- pages/user/user.vue | 30 +++++++--- 9 files changed, 183 insertions(+), 94 deletions(-) diff --git a/api/store.js b/api/store.js index 13c59c7..6f0df78 100644 --- a/api/store.js +++ b/api/store.js @@ -209,4 +209,13 @@ export function getMallNewsDetail(params) { export function searchGoods(params) { return request.get('goods/searchByName', {params}); -} \ No newline at end of file +} + +export function getHotList(params) { + return request.get('goods/hotList', {params}); +} + +export function getNewGoods(params) { + return request.get('goods/newGoods', {params}); +} + diff --git a/bundle_b/pages/mall_news/index.vue b/bundle_b/pages/mall_news/index.vue index 148cacc..8c7c3a8 100644 --- a/bundle_b/pages/mall_news/index.vue +++ b/bundle_b/pages/mall_news/index.vue @@ -9,24 +9,24 @@ {{item.title}} {{item.desc}} - - - - - - - - - - - - + + + + + + + + + + + + 推荐商品 - + {{item.shop.name}} @@ -43,14 +43,15 @@ - - {{item.title}} - {{item.desc}} + + {{item.title}} + {{item.desc}} + - + @@ -58,7 +59,6 @@ - @@ -82,10 +82,18 @@ }; }, methods: { - preview(url) { - uni.previewImage({ - urls: [url] - }); + preview(current, files) { + console.log(current) + console.log(files) + let f = files.map((item) => { + return item.src + }) + this.$nextTick(() => { + uni.previewImage({ + current, + urls: f + }); + }) }, upCallback(page) { diff --git a/components/active-area/active-area.vue b/components/active-area/active-area.vue index 348f824..3b331c4 100644 --- a/components/active-area/active-area.vue +++ b/components/active-area/active-area.vue @@ -2,21 +2,22 @@ {{title}} - + 更多 - - - - - - + + + + + - + 查看更多 diff --git a/components/cate-home/cate-home.vue b/components/cate-home/cate-home.vue index 9ab98d8..ba92101 100644 --- a/components/cate-home/cate-home.vue +++ b/components/cate-home/cate-home.vue @@ -7,7 +7,7 @@ - + diff --git a/components/goods-list/goods-list.vue b/components/goods-list/goods-list.vue index 39ad067..f05e92a 100644 --- a/components/goods-list/goods-list.vue +++ b/components/goods-list/goods-list.vue @@ -63,6 +63,9 @@ line-through :price="item.market_price || item.price"> --> + + @@ -312,6 +315,10 @@ priceType: { type: Number, default: 0 + }, + showOrder: { + type: Boolean, + default: false } }, data() { @@ -360,6 +367,7 @@ width: 347rpx; border-radius: 10rpx; overflow: hidden; + position: relative; .goods-info { padding: 10rpx; @@ -368,7 +376,6 @@ height: 80rpx; line-height: 40rpx; } - } } } @@ -431,15 +438,12 @@ } } - .goods-row, - .goods-hot { - .paixu { - position: absolute; - top: 0; - left: 20rpx; - width: 48rpx; - height: 60rpx; - } + .paixu { + position: absolute; + top: 0; + left: 20rpx; + width: 48rpx; + height: 60rpx; } } \ No newline at end of file diff --git a/components/index-home/index-home.vue b/components/index-home/index-home.vue index 951140a..ce2b56e 100644 --- a/components/index-home/index-home.vue +++ b/components/index-home/index-home.vue @@ -100,11 +100,12 @@ - + - + +