discovery.wxml
1.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<view class="layout">
<view class="sticky">
<tab openScroll tab="{{tab}}" bindclick="changeTab"></tab>
</view>
<view class="box {{count != 0 && list.length ?'waterfall':''}}">
<block wx:if="{{flag}}">
<block wx:if="{{list.length}}">
<block wx:for="{{list}}" wx:key="index">
<block wx:if="{{count == 0}}">
<!-- 101: 直播中, 102: 未开始, 103: 已结束, 104: 禁播, 105: 暂停中, 106: 异常,107:已过期 -->
<view class="live" bindtap="intoLiveRoom" data-item="{{item}}">
<view class="title">
<view class="text text-hide">{{item.name}}</view>
<view class="status">
<block wx:if="{{item.liveStatus == 102}}">未开始</block>
<block wx:if="{{item.liveStatus == 101}}">直播中</block>
<block wx:else>已结束</block>
</view>
</view>
<view class="preview">
<image webp src="{{item.shareImgUrl}}"></image>
<view class="play box-center">
<image webp src="/images/play.png?v={{img_version}}"></image>
</view>
</view>
<view class="info">
<view class="description text-hide"></view>
<view class="zb">主播:{{item.anchorName}}</view>
<view class="btn y-center text-center">观看</view>
</view>
</view>
</block>
<block wx:else>
<view class="posts">
<posts item="{{item}}" bindclick="jump"></posts>
</view>
</block>
</block>
</block>
<block wx:else>
<view class="list-nothing">
暂无相关内容
</view>
</block>
</block>
</view>
</view>