小程序打广告一闪一闪的

<!-- 在线医生 -->
<view wx:if="{{overflow && overflow1}}" class='pf customer df aic jcsb bsbb pl30 pr30 w' style="">>
<view class='df ml20'>
<view><image mode='widthFix' style='width:70rpx;' src='../images/wx.png' class='bdr20'></image></view>
<view class='fs24 cf ml30'>
<view>医生在线</view>
<view class='mt5'>请问有什么可以帮您?</view>
</view>
</view>
<view wx:if="{{a}}"><button class='fs24 bdr50 bgc cf' open-type='contact'>接受</button></view>
<view wx:elif="{{!a}}"><button class='fs24 bdr50 bgc cf' bindtap='zixun'>接受</button></view>
</view>
 
* 生命周期函数--监听页面显示
*/
onShow: function() {
var that = this
var timer = setInterval(function() {
var overflow = !that.data.overflow
that.setData({
overflow: overflow
})
}, 60000)
var timer1 = setInterval(function() {
var arr = ["rgba(0,0,0,.8)", "rgba(226,113,64,.8)"]
var a = that.data.a
// console.log(a)
if (a == 1) {
a = 0
} else {
a = 1
}
var bgcolor = arr[a]
var overflow1 = !that.data.overflow1
that.setData({
a: a,
bgcolor: bgcolor
})
}, 1000)
that.setData({
timer: timer,
timer1: timer1
})
},

转载于:https://www.cnblogs.com/isuansuan/p/9837363.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值