diff --git a/components/banner/index.wxss b/components/banner/index.wxss
index 5a5b252..de9cd94 100644
--- a/components/banner/index.wxss
+++ b/components/banner/index.wxss
@@ -16,6 +16,7 @@
border-radius: 16rpx;
overflow: hidden;
position: relative;
+
}
.dots {
diff --git a/components/hot/index.js b/components/hot/index.js
new file mode 100644
index 0000000..b04b0ee
--- /dev/null
+++ b/components/hot/index.js
@@ -0,0 +1,87 @@
+// pages/index/sw/index.js
+let config = require("../../config/config.js");
+let Http = require("../../utils/HttpBasics");
+let app = getApp();
+const imgurl = require("../../utils/imgurl");
+Component({
+ /**
+ * 组件的属性列表
+ */
+ properties: {},
+
+ /**
+ * 组件的初始数据
+ */
+ data: {
+ change: imgurl.change.url,
+ None: imgurl.None.url,
+ jianUrl: imgurl.jian.url,
+ barginicon: imgurl.barginicon.url,
+ wangmeimeibargin: imgurl.wangmeimeibargin.url,
+ list: [],
+ total: ''
+ },
+
+ /**
+ * 组件的方法列表
+ */
+ methods: {
+ gotoBargainList() {
+ wx.navigateTo({
+ url: "/pages/bargain/bargain"
+ })
+ },
+ getList() {
+ let that = this;
+ Http.get({
+ url: config.api.couponChannelList,
+ data: {
+ pageNum: 1,
+ pageSize: 5,
+ targetAd: 6
+ }
+ }).then(res => {
+ console.log(res.data.list)
+ that.setData({
+ list: res.data.list,
+ total: res.data.total
+ });
+ console.log(this.data.list)
+ })
+ .catch(err => {
+ console.log(err)
+ wx.showToast({
+ title: err.errMsg,
+ icon: 'none',
+ duration: 2000,
+ mask: false
+ });
+ })
+ },
+ gotomore: function () {
+ wx.navigateTo({
+ url: "/pages/bargain/bargain"
+ });
+ },
+ gotodetail: function (e) {
+ wx.navigateTo({
+ url: `/pages/coupon/detail/index?couponChannelId=${
+ e.currentTarget.dataset.couponchannelid
+ }&couponId=${
+ e.currentTarget.dataset.couponid
+ }&targetAd=${
+ e.currentTarget.dataset.targetad
+ }`
+ });
+ }
+ },
+ ready() {
+ app.couponChannelListCallback = token => {
+ Http.setToken(token);
+ this.getList();
+ };
+ if (app.globalData.token && app.globalData.token != null) {
+ app.couponChannelListCallback(app.globalData.token);
+ }
+ }
+});
diff --git a/components/hot/index.json b/components/hot/index.json
new file mode 100644
index 0000000..e8cfaaf
--- /dev/null
+++ b/components/hot/index.json
@@ -0,0 +1,4 @@
+{
+ "component": true,
+ "usingComponents": {}
+}
\ No newline at end of file
diff --git a/components/hot/index.wxml b/components/hot/index.wxml
new file mode 100644
index 0000000..ba42a86
--- /dev/null
+++ b/components/hot/index.wxml
@@ -0,0 +1,58 @@
+
+
+
+
+
+ 爆款专区
+
+
+ 换一换
+
+
+
+
+
+
+
+
+
+
+
+ {{item.title}}
+ ¥{{item.priceStr}}
+ ¥{{item.salePriceStr}}
+ 砍价
+
+
+
+
+
+
+
+ 疯狂补货中…
+ 敬请期待
+ 砍价
+
+
+
+
+
+
+
+
+ 日本bilii杯子
+ ¥2.8
+ ¥1.99
+ 拼团
+
+
+
+
+
+ 疯狂补货中...
+ 敬请期待
+ 拼团
+
+
+
+
diff --git a/components/hot/index.wxss b/components/hot/index.wxss
new file mode 100644
index 0000000..b5d4aa4
--- /dev/null
+++ b/components/hot/index.wxss
@@ -0,0 +1,131 @@
+/* components/hot/hot.wxss */
+@import "../../app.wxss";
+.hotBox{
+ width:710rpx;
+ height: 220rpx;
+ margin: 0 auto 20rpx;
+}
+.hotTitle{
+ width: 100%;
+ height: 60rpx;
+ line-height: 60rpx;
+ font-size: 30rpx;
+ display: flex;
+ justify-content: space-between;
+ font-family:PingFangSC-Medium;
+}
+.titleL .titleR{
+ width: 100rpx;
+}
+.titleR text{
+ float: left;
+ margin-right: 10rpx;
+ color: #2C8DFF;
+ font-family:PingFangSC-Regular!important;
+}
+.titleR view{
+ height: 40rpx;
+ width: 40rpx;
+ /* margin-top: 10rpx; */
+ float: left;
+}
+.titleR image{
+ height: 28rpx;
+ width: 28rpx;
+}
+.sql{
+ width:12rpx;
+ height:24rpx;
+ background:linear-gradient(127deg,rgba(252,177,74,1) 0%,rgba(254,70,20,1) 100%);
+ border-radius:8rpx;
+ float: left;
+ margin: 20rpx 10rpx 0 0;
+}
+.hotCon{
+ width: 100%;
+}
+.kanjia, .pintuan{
+ width: 346rpx;
+ height: 156rpx;
+ float: left;
+ border-radius: 12rpx;
+ display: flex;
+ justify-content: space-between;
+ position: relative;
+}
+.kanjia{
+ margin-right: 18rpx;
+ background:linear-gradient(130deg,rgba(50,177,252,1) 0%,rgba(47,108,255,1) 100%);
+}
+.pintuan{
+ background:linear-gradient(127deg,rgba(252,177,74,1) 0%,rgba(254,70,20,1) 100%);
+}
+.hotCon image{
+ width: 86rpx;
+ height: 86rpx;
+ border: 1rpx solid #fff;
+ margin: 24rpx 0 46rpx 16rpx;
+}
+.hotCon .btn{
+ width:80rpx;
+ height:44rpx;
+ line-height: 44rpx;
+ background:rgba(255,255,255,1);
+ border-radius:18rpx;
+ font-size: 24rpx;
+ position: absolute;
+ right: 20rpx;
+ bottom: 20rpx;
+ text-align: center;
+}
+.btnk{
+ color: #2C8DFF;
+}
+.btnp{
+ color: #FD782D;
+}
+.btnNone{
+ width:80rpx;
+ height:44rpx;
+ line-height: 44rpx;
+ border-radius:18rpx;
+ font-size: 24rpx;
+ position: absolute;
+ right: 20rpx;
+ bottom: 20rpx;
+ text-align: center;
+ background:rgba(255,255,255,0.5)
+}
+.kjText,.ptText{
+ color: #FFFFFF;
+ margin: 14rpx 10rpx 20rpx 10rpx;
+}
+
+.title{
+ width: 210rpx;
+ font-size: 30rpx;
+ overflow: hidden;
+ text-overflow:ellipsis;
+ white-space:nowrap;
+ float: left;
+}
+.price{
+ width: 210rpx;
+ font-size: 22rpx;
+ text-decoration:line-through;
+ float: left;
+}
+.expect{
+ width: 210rpx;
+ font-size: 22rpx;
+ float: left;
+}
+.sale{
+ width: 210rpx;
+ font-size: 32rpx;
+ float: left;
+ margin-top: -8rpx;
+}
+.sale text{
+ font-size: 20rpx!important;
+}
diff --git a/dist/tabs/index.wxss b/dist/tabs/index.wxss
index 69fc772..6e228c2 100644
--- a/dist/tabs/index.wxss
+++ b/dist/tabs/index.wxss
@@ -8,7 +8,7 @@
justify-content: space-around;
align-items: center;
-webkit-box-align: center;
- /* background: #fff */
+ background: #fff
}
.i-tabs::after {
diff --git a/pages/main/index.json b/pages/main/index.json
index 5f8d497..52f8b2a 100644
--- a/pages/main/index.json
+++ b/pages/main/index.json
@@ -6,7 +6,8 @@
"c-spellGroup": "./spellGroup/index",
"c-coupons": "./coupons/index",
"g-entry": "../../components/gameentry/gentry",
- "c-rushtobyCard": "./rushtobyCard/index"
+ "c-rushtobyCard": "./rushtobyCard/index",
+ "c-hot": "../../components/hot/index"
},
"navigationBarTitleText": "首页",
"enablePullDownRefresh": true,
diff --git a/pages/main/index.wxml b/pages/main/index.wxml
index 102a124..6b299fb 100644
--- a/pages/main/index.wxml
+++ b/pages/main/index.wxml
@@ -65,14 +65,16 @@
今日好货推荐,满1000减200元…
抢购
+
+
-
-
+
+
-
+
diff --git a/pages/main/index.wxss b/pages/main/index.wxss
index 3dd865c..6547248 100644
--- a/pages/main/index.wxss
+++ b/pages/main/index.wxss
@@ -1,4 +1,4 @@
-@import "../../app.wxss";
+ @import "../../app.wxss";
page{
background: #F4F5F9;
}
@@ -361,13 +361,14 @@ progress{
margin:0 auto;
display: flex;
justify-content: space-between;
+ background: #F4F5F9;
}
.kjBox{
width: 104rpx;
height: 148rpx;
font-size: 24rpx;
color: #A6A6A6;
- margin-top: 50rpx;
+ margin-top: 46rpx;
text-align: center;
}
.kjBox image{
@@ -375,13 +376,15 @@ progress{
height: 104rpx;
}
.toutiao{
- width:688rpx;
+ width:710rpx;
height: 82rpx;
line-height: 82rpx;
margin:0 auto;
background: #FAFBFD;
box-shadow:0px 6rpx 16rpx 0px rgba(236,238,243,1);
border-radius:12rpx;
+ margin-top: 18rpx;
+ margin-bottom:18rpx;
}
.toutiao text{
font-size:26rpx;
@@ -417,4 +420,7 @@ progress{
font-family:PingFangSC-Medium;
font-weight:500;
color:#FD782D;
+}
+i-tabs i-tabs-scroll{
+ background: #F4F5F9!important;
}
\ No newline at end of file
diff --git a/utils/bgColor.js b/utils/bgColor.js
index f58a353..0080d87 100644
--- a/utils/bgColor.js
+++ b/utils/bgColor.js
@@ -3,12 +3,13 @@ module.exports = {
// 我的
"user": {
"banneColor": "linear-gradient(180deg,rgba(253,131,45,1) 0%,rgba(254,74,22,1) 100%))",
+
},
},
colorSecond:{
// 我的
"user": {
- "banneColor": ''
+ "banneColor": 'linear-gradient(180deg,rgba(50,177,252,1) 0%,rgba(47,108,255,1) 100%)',
},
}
diff --git a/utils/imgurl.js b/utils/imgurl.js
index 229deb2..188fc08 100644
--- a/utils/imgurl.js
+++ b/utils/imgurl.js
@@ -637,4 +637,12 @@ module.exports = {
'url': baseUrl + "toutiao.png",
'name': ''
},
+ 'change': {
+ 'url': baseUrl + "change.png",
+ 'name': ''
+ },
+ 'None': {
+ 'url': baseUrl + "None.png",
+ 'name': ''
+ },
}
\ No newline at end of file