Selaa lähdekoodia

upoad

newCard
HolyKnightIX 2 vuotta sitten
vanhempi
commit
e507a2ede9
4 muutettua tiedostoa jossa 54 lisäystä ja 40 poistoa
  1. +4
    -4
      pages/cardorder/index/index.wxml
  2. +15
    -14
      pages/topicDetail/index.js
  3. +4
    -4
      pages/topicDetail/index.wxml
  4. +31
    -18
      pages/topicDetail/index.wxss

+ 4
- 4
pages/cardorder/index/index.wxml Näytä tiedosto

@@ -19,11 +19,11 @@
<view class='section' wx:for='{{list}}' wx:key="index"> <view class='section' wx:for='{{list}}' wx:key="index">


<!-- <view class='mms' style='background:{{item.background}}'> --> <!-- <view class='mms' style='background:{{item.background}}'> -->
<view class='mms'>
<view class="gray-bg" style="background-image: url({{item.coverImg}});"></view>
<view class='mms'>
<view class="gray-bg" style="background-image: url({{item.coverImg}});"></view>
<!-- <image class="cover-img" src="{{item.coverImg}}" /> --> <!-- <image class="cover-img" src="{{item.coverImg}}" /> -->
<view class="cover-img" > </view>
<image src="{{canTransferred}}" wx-if='{{item.supportTransfer==1&&!item.showImg}}' class='cantransferred' mode="aspectFill" />
<view class="cover-img"> </view>
<image src="{{canTransferred}}" wx-if='{{item.supportTransfer==1&&!item.showImg}}' class='cantransferred' mode="aspectFill" />
<view class='detail_msg'> <view class='detail_msg'>
<view class='info'> <view class='info'>
<view class='clearfix' data-id='{{item.id}}' data-showImg='{{item.showImg? "0":"1"}}' bindtap='gotoConsumeDetail'> <view class='clearfix' data-id='{{item.id}}' data-showImg='{{item.showImg? "0":"1"}}' bindtap='gotoConsumeDetail'>


+ 15
- 14
pages/topicDetail/index.js Näytä tiedosto

@@ -10,7 +10,7 @@ Page({
mouldConfig: {}, mouldConfig: {},
navigationBarHeight, navigationBarHeight,
data: { data: {
bgColor:"#fff"
bgColor: "#fff"
}, },
wmhome: imgurl.wmhome.url, wmhome: imgurl.wmhome.url,
couponId: null, couponId: null,
@@ -19,30 +19,31 @@ Page({
hour: "", hour: "",
minute: "", minute: "",
nodes: '', nodes: '',
id:'',
goHomeUrl:""
id: '',
goHomeUrl: "",
winHeight: "100%"
}, },
onLoad(options){
onLoad(options) {
this.setData({ this.setData({
mouldType: app.globalData.mouldType, mouldType: app.globalData.mouldType,
mouldConfig: app.globalData.mouldConfig, mouldConfig: app.globalData.mouldConfig,
goHomeUrl: app.globalData.goHomeUrl, goHomeUrl: app.globalData.goHomeUrl,
}) })
console.log(options) console.log(options)
if(options&&options.id){
if (options && options.id) {
this.setData({ this.setData({
id:options.id
id: options.id
}) })
this.topicShow(options.id) this.topicShow(options.id)
} }
}, },
goback: function () {
goback: function () {
let this_ = this let this_ = this
wx.switchTab({ wx.switchTab({
url: this_.data.goHomeUrl, url: this_.data.goHomeUrl,
}) })
}, },
topicShow(id){
topicShow(id) {
let that = this; let that = this;
Http.get({ Http.get({
url: config.api.topicFindById, url: config.api.topicFindById,
@@ -51,7 +52,7 @@ Page({
} }
}).then(res => { }).then(res => {
console.log(res) console.log(res)
if (res&&res.data) {
if (res && res.data) {
that.setData({ that.setData({
data: res.data data: res.data
}); });
@@ -65,9 +66,9 @@ Page({
query.exec((res) => { query.exec((res) => {
let listHeight = res[0].height; // 获取list高度 let listHeight = res[0].height; // 获取list高度
let windowHeight = wx.getSystemInfoSync().windowHeight; let windowHeight = wx.getSystemInfoSync().windowHeight;
if (windowHeight >= listHeight){
if (windowHeight >= listHeight) {
that.setData({ that.setData({
winHeight:'100%'
winHeight: '100%'
}) })
} }
}) })
@@ -81,13 +82,13 @@ Page({
}); });
}) })
}, },
gotoDetail:function(e){
if (e.currentTarget.dataset.type == 9){
gotoDetail: function (e) {
if (e.currentTarget.dataset.type == 9) {
console.log("平团") console.log("平团")
wx.navigateTo({ wx.navigateTo({
url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${e.currentTarget.dataset.couponchannelid}`, url: `/pages/spellGroup/mySpellGroup/index?couponChannelId=${e.currentTarget.dataset.couponchannelid}`,
}) })
}else{
} else {
console.log("优惠卷") console.log("优惠卷")
wx.navigateTo({ wx.navigateTo({
url: `/pages/coupon/detail/index?couponChannelId=${e.currentTarget.dataset.couponchannelid}&couponId=${e.currentTarget.dataset.couponid}`, url: `/pages/coupon/detail/index?couponChannelId=${e.currentTarget.dataset.couponchannelid}&couponId=${e.currentTarget.dataset.couponid}`,


+ 4
- 4
pages/topicDetail/index.wxml Näytä tiedosto

@@ -14,7 +14,7 @@
<text>{{data.content}}</text> <text>{{data.content}}</text>
</view> </view>
</view> </view>
</view>
</view>


<view class='contain clearfix'> <view class='contain clearfix'>
<!-- 优惠券 --> <!-- 优惠券 -->
@@ -37,11 +37,11 @@
</view> </view>
</view> </view>
</view> </view>
<!-- <view class="coupons1-info-name subtitle sy">剩余{{item.remainInventory}}</view> -->
<!-- <view class="coupons1-info-name subtitle sy">剩余{{item.remainInventory}}</view> -->
<view class="coupons1-btn"> <view class="coupons1-btn">
<!-- 优惠券价格 --> <!-- 优惠券价格 -->
<i-button class="buy" hover-class='active' wx:if="{{item.salePriceStr==0}}" data-date='{{data}}'>免费领</i-button>
<i-button class="buy" hover-class='active' wx:if="{{item.salePriceStr==0}}" data-date='{{data}}'>免费领</i-button>
<i-button class="buy" hover-class='active' wx:elif="{{item.salePriceStr!=0}}" data-date='{{data}}'>马上购</i-button> <i-button class="buy" hover-class='active' wx:elif="{{item.salePriceStr!=0}}" data-date='{{data}}'>马上购</i-button>
</view> </view>
<!-- <view class="coupons1-border"></view> --> <!-- <view class="coupons1-border"></view> -->


+ 31
- 18
pages/topicDetail/index.wxss Näytä tiedosto

@@ -1,8 +1,13 @@
@import "../../app.wxss"; @import "../../app.wxss";

page {
padding: 0;
}

.coupons { .coupons {
width: 100%; width: 100%;
position: relative; position: relative;
padding-bottom:57rpx;
padding-bottom: 57rpx;
} }


.coupons-body { .coupons-body {
@@ -66,7 +71,7 @@
letter-spacing: 0; letter-spacing: 0;
line-height: 42rpx; line-height: 42rpx;
margin-bottom: 20rpx; margin-bottom: 20rpx;
text-align: left!important;
text-align: left !important;
/* width: 60rpx; */ /* width: 60rpx; */
/* height: 64rpx; */ /* height: 64rpx; */
} }
@@ -76,7 +81,7 @@
/* width: 498rpx; */ /* width: 498rpx; */
/* height: 63rpx; */ /* height: 63rpx; */
/* overflow: hidden; */ /* overflow: hidden; */
word-wrap:break-word;
word-wrap: break-word;
/* text-overflow: ellipsis; */ /* text-overflow: ellipsis; */
font-size: 22rpx; font-size: 22rpx;
color: #6f6f6f; color: #6f6f6f;
@@ -172,14 +177,16 @@
width: 344rpx; width: 344rpx;
} }


.navigator-hover{
opacity: 1!important;
background: #fff!important;
border-radius:16rpx;
.navigator-hover {
opacity: 1 !important;
background: #fff !important;
border-radius: 16rpx;
} }
.active{

.active {
opacity: .6; opacity: .6;
} }

.navigator:nth-of-type(2n) { .navigator:nth-of-type(2n) {
float: right; float: right;
} }
@@ -311,7 +318,7 @@


.buy { .buy {
display: block; display: block;
background: linear-gradient(127deg,rgba(252,177,74,1) 0%,rgba(254,70,20,1) 100%);
background: linear-gradient(127deg, rgba(252, 177, 74, 1) 0%, rgba(254, 70, 20, 1) 100%);
border-radius: 30rpx; border-radius: 30rpx;
height: 48rpx; height: 48rpx;
width: 112rpx; width: 112rpx;
@@ -515,7 +522,7 @@ scroll-view {
width: 90%; width: 90%;
height: 300rpx; height: 300rpx;
margin: 20rpx auto; margin: 20rpx auto;
background: brown;
background: #a52a2a;
overflow: hidden; overflow: hidden;
} }


@@ -530,24 +537,30 @@ scroll-view {
display: block; display: block;
margin: 30rpx auto; margin: 30rpx auto;
} }

.description { .description {
font-size: 26rpx; font-size: 26rpx;
line-height: 15rpx; line-height: 15rpx;
} }
button::after{ border: none; }
.goback{

button::after {
border: none;
}

.goback {
position: fixed; position: fixed;
right: 50rpx; right: 50rpx;
bottom: 60rpx; bottom: 60rpx;
width:100rpx!important;
height:100rpx;
width: 100rpx !important;
height: 100rpx;
z-index: 100; z-index: 100;
background:rgba(255,255,255,1);
background: rgba(255, 255, 255, 1);
line-height: 95rpx; line-height: 95rpx;
border:1rpx solid rgba(227,227,227,1);
border-radius:50%;
border: 1rpx solid rgba(227, 227, 227, 1);
border-radius: 50%;
} }
.goback image{

.goback image {
position: absolute; position: absolute;
width: 60rpx; width: 60rpx;
left: 0; left: 0;


Ladataan…
Peruuta
Tallenna