diff --git a/mallplusui-uniapp-app/pages/index/index.vue b/mallplusui-uniapp-app/pages/index/index.vue index 7ee7d76..3e85e0a 100644 --- a/mallplusui-uniapp-app/pages/index/index.vue +++ b/mallplusui-uniapp-app/pages/index/index.vue @@ -1,60 +1,47 @@ @@ -314,6 +300,7 @@ this.getNewProductList(); }, onPullDownRefresh() { + console.log("onPullDownRefresh") this.pageNum = this.pageNum + 1; this.getNewProductList('refresh'); @@ -446,6 +433,7 @@ * 加载首页数据 */ async loadData() { + this.getBanner(); this.getHotGoodsList(); //this.getFlashPromotion(); @@ -453,6 +441,18 @@ this.getStoreList(); this.homeNewProduct(); this.homeRecommendProduct(); + + uni.getSystemInfo({ + success: res => { + console.log("屏幕宽度", res.windowWidth) + } + }) + uni.createSelectorQuery().in(this).select(".carousel-section").boundingClientRect(data => { + console.log("屏幕宽度", data.height) + // {"id":"","dataset":{},"left":12,"right":308,"top":12,"bottom":315,"width":296,"height":303} + }).exec(function(res) { + // 注意:exec方法必须执行,即便什么也不做,否则不会获取到任何数据 + }) }, /** @@ -462,7 +462,7 @@ let params = {}; let groupHotGoodsList = await Api.apiCall('get', Api.index.homeNewProduct, params); if (groupHotGoodsList) { - console.log("新品推荐》》》》》",groupHotGoodsList.records) + console.log("新品推荐》》》》》", groupHotGoodsList.records) this.homeNewProductList = groupHotGoodsList.records; } @@ -474,7 +474,7 @@ async homeRecommendProduct() { let params = {}; let groupHotGoodsList = await Api.apiCall('get', Api.index.homeRecommendProduct, params); - console.log("人气推荐》》》》》",groupHotGoodsList.records) + console.log("人气推荐》》》》》", groupHotGoodsList.records) this.homeRecommendProductList = groupHotGoodsList.records; }, /** @@ -573,7 +573,7 @@ async getHotGoodsList() { let params = {}; let groupHotGoodsList = await Api.apiCall('get', Api.goods.groupHotGoodsList, params); - console.log("团购信息》》》》》",groupHotGoodsList) + console.log("团购信息》》》》》", groupHotGoodsList) this.groupHotGoodsList = groupHotGoodsList; }, diff --git a/mallplusui-uniapp-app/pagesA/product/groupList.vue b/mallplusui-uniapp-app/pagesA/product/groupList.vue index e71e738..832da08 100644 --- a/mallplusui-uniapp-app/pagesA/product/groupList.vue +++ b/mallplusui-uniapp-app/pagesA/product/groupList.vue @@ -18,7 +18,7 @@ {{ item.goods.name }} {{ item.groupPrice }} - 原价 {{ item.goods.price }} + @@ -395,11 +395,11 @@ page, color: $font-color-light; } .price { - font-size: $font-lg; + font-size: 26upx; color: $uni-color-primary; line-height: 1; &:before { - content: '¥'; + content: '惠农团购价¥'; font-size: 26upx; } } diff --git a/mallplusui-uniapp-app/pagesA/product/list.vue b/mallplusui-uniapp-app/pagesA/product/list.vue index e583c02..63b83a8 100644 --- a/mallplusui-uniapp-app/pagesA/product/list.vue +++ b/mallplusui-uniapp-app/pagesA/product/list.vue @@ -19,18 +19,18 @@ {{ item.name }} - + {{ item.price }} - + + @@ -457,12 +457,12 @@ page, color: $font-color-light; } .price { - font-size: $font-lg; + font-size: 26upx; color: $uni-color-primary; line-height: 1; &:before { content: '惠农价¥'; - font-size: $font-lg; + font-size: 26upx; } } } diff --git a/mallplusui-uniapp-app/pagesA/product/product.vue b/mallplusui-uniapp-app/pagesA/product/product.vue index de691be..72870da 100644 --- a/mallplusui-uniapp-app/pagesA/product/product.vue +++ b/mallplusui-uniapp-app/pagesA/product/product.vue @@ -16,7 +16,7 @@ 惠农价¥{{ goods.price }} 县区商超价{{ goods.originalPrice }} ¥{{ goods.price }} - 优惠¥{{ goods.originalPrice- goods.price }} + 优惠¥{{ (goods.originalPrice- goods.price) | formatNumber}} 会员折扣{{ goods.memberRate }}折 @@ -376,6 +376,10 @@ export default { formatCreateTime(time) { let date = new Date(time); return formatDate(date, 'yyyy-MM-dd hh:mm:ss'); + }, + + formatNumber(number) { + return new Number(number).toFixed(2); } }, methods: { diff --git a/mallplusui-uniapp-app/static/njfw_icon.png b/mallplusui-uniapp-app/static/njfw_icon.png new file mode 100644 index 0000000..8dbd953 Binary files /dev/null and b/mallplusui-uniapp-app/static/njfw_icon.png differ diff --git a/mallplusui-uniapp-app/static/nywz_icon.png b/mallplusui-uniapp-app/static/nywz_icon.png new file mode 100644 index 0000000..af6502c Binary files /dev/null and b/mallplusui-uniapp-app/static/nywz_icon.png differ diff --git a/mallplusui-uniapp-app/static/shwz_icon.png b/mallplusui-uniapp-app/static/shwz_icon.png new file mode 100644 index 0000000..b0d547f Binary files /dev/null and b/mallplusui-uniapp-app/static/shwz_icon.png differ