| @@ -5,6 +5,7 @@ | |||||
| top:0px; | top:0px; | ||||
| background:rgba(0,0,0,0.8); | background:rgba(0,0,0,0.8); | ||||
| overflow: hidden; | overflow: hidden; | ||||
| z-index: 1000; | |||||
| } | } | ||||
| .t_w{ | .t_w{ | ||||
| position:relative; | position:relative; | ||||
| @@ -1,6 +1,7 @@ | |||||
| { | { | ||||
| "navigationBarTitleText": "砍价专场", | "navigationBarTitleText": "砍价专场", | ||||
| "enablePullDownRefresh": true, | "enablePullDownRefresh": true, | ||||
| "navigationBarBackgroundColor": "#F13C42", | |||||
| "usingComponents": { | "usingComponents": { | ||||
| "c-banner": "../../components/banner/index", | "c-banner": "../../components/banner/index", | ||||
| "i-tab": "../../../dist/tab/index", | "i-tab": "../../../dist/tab/index", | ||||
| @@ -1,5 +1,7 @@ | |||||
| page{ | page{ | ||||
| height: auto!important; | height: auto!important; | ||||
| background:#f89132; | |||||
| background-image:url('https://s3.cn-northwest-1.amazonaws.com.cn/iformall-net/cimg/spell-bg.png'); | |||||
| } | } | ||||
| .banner .bg { | .banner .bg { | ||||
| display: block; | display: block; | ||||
| @@ -77,12 +79,14 @@ page{ | |||||
| } | } | ||||
| .listitem{ | .listitem{ | ||||
| position: relative; | position: relative; | ||||
| padding: 21rpx 0; | |||||
| border-bottom: 1rpx solid #ededed; | |||||
| } | |||||
| padding: 21rpx; | |||||
| background: #fff; | |||||
| border-radius: 20rpx; | |||||
| margin-bottom: 20rpx; | |||||
| } | |||||
| .botton{ | .botton{ | ||||
| position: absolute; | position: absolute; | ||||
| right: 0; | |||||
| right: 18rpx; | |||||
| text-align: center; | text-align: center; | ||||
| bottom: 40rpx; | bottom: 40rpx; | ||||
| width:186rpx; | width:186rpx; | ||||
| @@ -419,4 +423,7 @@ page{ | |||||
| } | } | ||||
| .banner{ | .banner{ | ||||
| margin-bottom: 20rpx; | margin-bottom: 20rpx; | ||||
| background:#F13C42; | |||||
| position: relative; | |||||
| z-index: 100; | |||||
| } | } | ||||
| @@ -25,7 +25,7 @@ Component({ | |||||
| methods: { | methods: { | ||||
| gotomore: function() { | gotomore: function() { | ||||
| wx.navigateTo({ | wx.navigateTo({ | ||||
| url: "/pages/rushToBuy/index" | |||||
| url: "/pages/bargain/bargain" | |||||
| }); | }); | ||||
| }, | }, | ||||
| gotodetail: function(e) { | gotodetail: function(e) { | ||||
| @@ -48,7 +48,7 @@ Component({ | |||||
| data: { | data: { | ||||
| pageNum: 1, | pageNum: 1, | ||||
| pageSize: 5, | pageSize: 5, | ||||
| targetAd: 2 | |||||
| targetAd: 6 | |||||
| } | } | ||||
| }).then(res => { | }).then(res => { | ||||
| this.setData({ | this.setData({ | ||||
| @@ -0,0 +1,16 @@ | |||||
| <view class="index-rushToBuy"> | |||||
| <view wx:if="{{list.length!=0}}" class="index-rushToBuy-title">砍价专场<text bindtap="gotomore">更多砍价</text><image src='{{jianUrl}}' mode="widthFix"></image></view> | |||||
| <scroll-view scroll-x class="index-scroll-view"> | |||||
| <view class="commodity" wx:for="{{list}}" wx:key="unique"> | |||||
| <view bindtap="gotodetail" data-couponChannelId="{{item.id}}" data-couponId="{{item.couponId}}" data-targetAd="{{item.targetAd}}"> | |||||
| <image mode='aspectFill' lazy-load='true' class="commodity-img" src="{{item.coverImg}}" /> | |||||
| <view class="commodity-info"> | |||||
| <view class="commodity-info-name">{{item.title}}</view> | |||||
| <view class="commodity-info-price"> | |||||
| <text class='useprice'>可砍至</text><text class="commodity-info-price-p">{{item.salePriceStr}}元</text> | |||||
| </view> | |||||
| </view> | |||||
| </view> | |||||
| </view> | |||||
| </scroll-view> | |||||
| </view> | |||||
| @@ -0,0 +1,92 @@ | |||||
| .index-rushToBuy { | |||||
| width: 100%; | |||||
| font-family: PingFangSC-Semibold; | |||||
| } | |||||
| .index-rushToBuy-title { | |||||
| position: relative; | |||||
| font-size: 34rpx; | |||||
| color: #000000; | |||||
| letter-spacing: 1.16rpx; | |||||
| padding-top: 34rpx; | |||||
| padding-left: 30rpx; | |||||
| } | |||||
| .useprice{ | |||||
| font-size: 28rpx; | |||||
| } | |||||
| .index-rushToBuy-title text{ | |||||
| float: right; | |||||
| margin-right: 53rpx; | |||||
| color: #a8adb4; | |||||
| font-size: 28rpx; | |||||
| margin-top: 8rpx; | |||||
| } | |||||
| .index-rushToBuy-title image{ | |||||
| position: absolute; | |||||
| right: 18rpx; | |||||
| width: 20px; | |||||
| top: 44rpx; | |||||
| } | |||||
| .index-scroll-view { | |||||
| width: 100%; | |||||
| white-space: nowrap; | |||||
| } | |||||
| .index-scroll-view .commodity { | |||||
| display: inline-block; | |||||
| margin: 16rpx 30rpx 16rpx; | |||||
| margin-right: 0; | |||||
| position: relative; | |||||
| background: #fff; | |||||
| /* border: 1rpx solid #dddee1; */ | |||||
| width: 263rpx; | |||||
| box-shadow: 0 0 10px 0 rgba(211,211,211,0.30); | |||||
| border-radius: 10rpx; | |||||
| overflow: hidden; | |||||
| } | |||||
| .index-scroll-view .commodity:last-child{ | |||||
| margin-right: 30rpx; | |||||
| } | |||||
| .commodity-img{ | |||||
| display: block; | |||||
| width: 100%; | |||||
| height:200rpx; | |||||
| } | |||||
| .index-scroll-view .commodity-info { | |||||
| padding:10rpx 20rpx; | |||||
| overflow: hidden; | |||||
| } | |||||
| .index-scroll-view .commodity-info-name { | |||||
| font-size: 30rpx; | |||||
| color: #000000; | |||||
| letter-spacing: 0.7rpx; | |||||
| overflow: hidden; | |||||
| } | |||||
| .index-scroll-view .commodity-info-time { | |||||
| font-size: 22rpx; | |||||
| color: #B4B4B4; | |||||
| letter-spacing: 0.7rpx; | |||||
| line-height: 42rpx; | |||||
| } | |||||
| .index-scroll-view .commodity-info-price-p { | |||||
| font-size: 30rpx; | |||||
| color: #f96563; | |||||
| line-height: 36rpx; | |||||
| } | |||||
| .index-scroll-view .commodity-info-price-o { | |||||
| display: inline-block; | |||||
| padding-left: 20rpx; | |||||
| font-size: 24rpx; | |||||
| color: #B4B4B4; | |||||
| letter-spacing: 0.96rpx; | |||||
| text-decoration:line-through; | |||||
| line-height: 36rpx; | |||||
| } | |||||
| .commodity-info-price{ | |||||
| line-height: 36rpx; | |||||
| } | |||||
| @@ -5,7 +5,7 @@ const QR = require("../../utils/memberqrcode.js"); | |||||
| let app = getApp(); | let app = getApp(); | ||||
| Page({ | Page({ | ||||
| data: { | data: { | ||||
| newUrl: imgurl.new1.url, | |||||
| newUrl: "", | |||||
| icon0001: imgurl.icon0001.url, | icon0001: imgurl.icon0001.url, | ||||
| icon0002: imgurl.icon0002.url, | icon0002: imgurl.icon0002.url, | ||||
| icon0003: imgurl.icon0003.url, | icon0003: imgurl.icon0003.url, | ||||
| @@ -332,7 +332,8 @@ Page({ | |||||
| }).then(res => { | }).then(res => { | ||||
| if (res.data.id) { | if (res.data.id) { | ||||
| _this.setData({ | _this.setData({ | ||||
| showIf: true | |||||
| showIf: true, | |||||
| newUrl: res.data.imgUrl | |||||
| }) | }) | ||||
| }else{ | }else{ | ||||
| _this.setData({ | _this.setData({ | ||||
| @@ -2,7 +2,8 @@ | |||||
| "usingComponents": { | "usingComponents": { | ||||
| "c-banner": "../../components/banner/index", | "c-banner": "../../components/banner/index", | ||||
| "discount-card": "../../components/discountCard/index", | "discount-card": "../../components/discountCard/index", | ||||
| "c-rushToBuy": "./rushToBuy/index", | |||||
| "c-bargain": "./bargain/index", | |||||
| "c-spellGroup": "./spellGroup/index", | |||||
| "c-coupons": "./coupons/index", | "c-coupons": "./coupons/index", | ||||
| "g-entry": "../../components/gameentry/gentry" | "g-entry": "../../components/gameentry/gentry" | ||||
| }, | }, | ||||
| @@ -2,22 +2,22 @@ | |||||
| <c-banner wx:key="unique" list="{{list}}" /> | <c-banner wx:key="unique" list="{{list}}" /> | ||||
| <!-- 折扣卡 --> | <!-- 折扣卡 --> | ||||
| <view class='section'> | <view class='section'> | ||||
| <view bindtap='gotoRushBuy'> | |||||
| <!-- <view bindtap='gotoRushBuy'> | |||||
| <image src='{{icon0001}}'></image> | <image src='{{icon0001}}'></image> | ||||
| <text>限时抢购</text> | |||||
| </view> | |||||
| <view bindtap='gotodiscountCardList'> | |||||
| <text>限时秒杀</text> | |||||
| </view> --> | |||||
| <!-- <view bindtap='gotodiscountCardList'> | |||||
| <image src='{{icon0002}}'></image> | <image src='{{icon0002}}'></image> | ||||
| <text>消费卡</text> | <text>消费卡</text> | ||||
| </view> | |||||
| <view bindtap='gotoSpellGroup'> | |||||
| </view> --> | |||||
| <!-- <view bindtap='gotoSpellGroup'> | |||||
| <image src='{{icon0003}}'></image> | <image src='{{icon0003}}'></image> | ||||
| <text>拼团专场</text> | <text>拼团专场</text> | ||||
| </view> | |||||
| <view bindtap='gotoBargain'> | |||||
| </view> --> | |||||
| <!-- <view bindtap='gotoBargain'> | |||||
| <image src='{{icon0004}}'></image> | <image src='{{icon0004}}'></image> | ||||
| <text>砍价专场</text> | <text>砍价专场</text> | ||||
| </view> | |||||
| </view> --> | |||||
| <view bindtap='searchbar'> | <view bindtap='searchbar'> | ||||
| <image src='{{icon0005}}'></image> | <image src='{{icon0005}}'></image> | ||||
| <text>品牌门店</text> | <text>品牌门店</text> | ||||
| @@ -37,12 +37,17 @@ | |||||
| <text>我的券包</text> | <text>我的券包</text> | ||||
| </view> | </view> | ||||
| </view> | </view> | ||||
| <!-- 砍价专场 --> | |||||
| <c-bargain/> | |||||
| <!-- 拼团专场 --> | |||||
| <c-spellGroup/> | |||||
| <!-- 小游戏暂时注释 --> | <!-- 小游戏暂时注释 --> | ||||
| <view class='game' bindtap="gotogame" wx-if="{{showIf}}"> | <view class='game' bindtap="gotogame" wx-if="{{showIf}}"> | ||||
| <view class='game-entry'> | <view class='game-entry'> | ||||
| <image src="{{newUrl}}" class='gameimg' mode='widthFix'></image> | <image src="{{newUrl}}" class='gameimg' mode='widthFix'></image> | ||||
| </view> | </view> | ||||
| </view> | </view> | ||||
| <c-coupons id="lists" bind:myevent="onGetCode" loadingtext="{{loadingtext}}" loading="{{loading}}" /> | <c-coupons id="lists" bind:myevent="onGetCode" loadingtext="{{loadingtext}}" loading="{{loading}}" /> | ||||
| <g-entry id="listss" wx:if="{{showGame&&!played&&!havePlayEd}}" gamedata="{{gamedata}}" bind:myevent="" /> | <g-entry id="listss" wx:if="{{showGame&&!played&&!havePlayEd}}" gamedata="{{gamedata}}" bind:myevent="" /> | ||||
| </view> | </view> | ||||
| @@ -35,14 +35,17 @@ page { | |||||
| } | } | ||||
| .game-entry { | .game-entry { | ||||
| width: 690rpx; | |||||
| position: fixed; | |||||
| right: 0; | |||||
| top:300rpx; | |||||
| width: 170rpx; | |||||
| margin: 37rpx auto 0; | margin: 37rpx auto 0; | ||||
| z-index: 10; | |||||
| } | } | ||||
| .gameimg { | .gameimg { | ||||
| display: block; | display: block; | ||||
| width: 100%; | width: 100%; | ||||
| height: 140rpx; | |||||
| } | } | ||||
| .section { | .section { | ||||
| @@ -0,0 +1,73 @@ | |||||
| // pages/index/sw/index.js | |||||
| let config = require("../../../config/config.js"); | |||||
| let Http = require("../../../utils/HttpBasics"); | |||||
| // let Http = require("../../../utils/HttpBasics"); | |||||
| const app = getApp(); | |||||
| const imgurl = require("../../../utils/imgurl"); | |||||
| Component({ | |||||
| /** | |||||
| * 组件的属性列表 | |||||
| */ | |||||
| properties: {}, | |||||
| /** | |||||
| * 组件的初始数据 | |||||
| */ | |||||
| data: { | |||||
| jianUrl: imgurl.jian.url, | |||||
| list: [], | |||||
| total:'' | |||||
| }, | |||||
| /** | |||||
| * 组件的方法列表 | |||||
| */ | |||||
| methods: { | |||||
| gotomore: function() { | |||||
| wx.navigateTo({ | |||||
| url: "/pages/spellGroup/spellGroup" | |||||
| }); | |||||
| }, | |||||
| gotodetail: function(e) { | |||||
| wx.navigateTo({ | |||||
| url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${ | |||||
| e.currentTarget.dataset.couponchannelid | |||||
| }&couponId=${ | |||||
| e.currentTarget.dataset.couponid | |||||
| }&targetAd=${ | |||||
| e.currentTarget.dataset.targetad | |||||
| }` | |||||
| }); | |||||
| } | |||||
| }, | |||||
| ready() { | |||||
| app.couponChannelListCallback = token => { | |||||
| Http.setToken(token); | |||||
| Http.get({ | |||||
| url: config.api.couponChannelList, | |||||
| data: { | |||||
| pageNum: 1, | |||||
| pageSize: 5, | |||||
| targetAd: 2 | |||||
| } | |||||
| }).then(res => { | |||||
| this.setData({ | |||||
| list: res.data.list, | |||||
| total:res.data.total | |||||
| }); | |||||
| }) | |||||
| .catch(err => { | |||||
| console.log(err) | |||||
| wx.showToast({ | |||||
| title: err.errMsg, | |||||
| icon: 'none', | |||||
| duration: 2000, | |||||
| mask: false | |||||
| }); | |||||
| }) | |||||
| }; | |||||
| if (app.globalData.token && app.globalData.token != null) { | |||||
| app.couponChannelListCallback(app.globalData.token); | |||||
| } | |||||
| } | |||||
| }); | |||||
| @@ -0,0 +1,6 @@ | |||||
| { | |||||
| "component": true, | |||||
| "usingComponents": { | |||||
| "i-card": "../../../dist/card/index" | |||||
| } | |||||
| } | |||||
| @@ -1,9 +1,9 @@ | |||||
| <view class="index-rushToBuy"> | <view class="index-rushToBuy"> | ||||
| <view wx:if="{{list.length!=0}}" class="index-rushToBuy-title">限时抢购<text bindtap="gotomore">查看全部</text><image src='{{jianUrl}}' mode="widthFix"></image></view> | |||||
| <view wx:if="{{list.length!=0}}" class="index-rushToBuy-title">拼团专场<text bindtap="gotomore">更多拼团</text><image src='{{jianUrl}}' mode="widthFix"></image></view> | |||||
| <scroll-view scroll-x class="index-scroll-view"> | <scroll-view scroll-x class="index-scroll-view"> | ||||
| <view class="commodity" wx:for="{{list}}" wx:key="unique"> | <view class="commodity" wx:for="{{list}}" wx:key="unique"> | ||||
| <view bindtap="gotodetail" data-couponChannelId="{{item.id}}" data-couponId="{{item.couponId}}" data-targetAd="{{item.targetAd}}"> | <view bindtap="gotodetail" data-couponChannelId="{{item.id}}" data-couponId="{{item.couponId}}" data-targetAd="{{item.targetAd}}"> | ||||
| <image mode='aspectFill' class="commodity-img" src="{{item.coverImg}}" /> | |||||
| <image mode='aspectFill' lazy-load='true' class="commodity-img" src="{{item.coverImg}}" /> | |||||
| <view class="commodity-info"> | <view class="commodity-info"> | ||||
| <view class="commodity-info-name">{{item.title}}</view> | <view class="commodity-info-name">{{item.title}}</view> | ||||
| <!-- <view class="commodity-info-name">{{item.subTitle}}</view> --> | <!-- <view class="commodity-info-name">{{item.subTitle}}</view> --> | ||||