-
Notifications
You must be signed in to change notification settings - Fork 3
Description
https://weexapp.com/zh/docs/components/recycle-list.html#%E7%A4%BA%E4%BE%8B



`
<div class="r-realname-box" :style="{backgroundColor:i.tag999?'#'+i.tag999:{orange}}"
@longpress="onLongPress" @touchstart="touchStart(i,index)">
{{i.realname}}
{{i.num}}
<view class="r-box-right" @touchend="navChat(i,index)"
:style="{width:i.rightWidth?i.rightWidth+'px':{}}" @appear="onappear(i,index)">
{{i.title}}
{{i.time}}
置顶
{{i.tag1.planStr}}
<text class="r-content-tag r-color-grey r-padd-left" v-if="i.tags[0]">
{{i.tags[0]}}
</text>
<text class="r-content-tag r-color-grey r-padd-left" v-if="i.tags[1]">
{{i.tags[1]}}
</text>
<text class="r-content-tag r-color-grey r-padd-left" v-if="i.tags[2]">
{{i.tags[2]}}
</text>
<text class="r-content-tag r-color-grey r-padd-left" v-if="i.tags[3]">
{{i.tags[3]}}
</text>
<text class="r-content-tag r-color-grey" v-if="i.tags[4]">
...
</text>
<text class="r-content-tag r-color-red r-padd-left"
v-if="i.inspectDay">{{i.inspectDay}}无指标</text>
</view>
<view class="n-just-bet">
<view class="" v-if="i.lastMsgTimeStr"
:style="{width:i.rightContentWidth?i.rightContentWidth+'px':{}}">
<text class="r-content-tag r-padd r-color-grey n-omit"
v-if="i.nickname||i.desc">{{i.nickname}}:{{i.desc}}</text>
</view>
<view class="" :style="{width:i.rightWidth?i.rightWidth+'px':{}}" v-else>
<text class="r-content-tag r-padd r-color-grey n-omit"
v-if="i.nickname||i.desc">{{i.nickname}}:{{i.desc}}</text>
</view>
<view class=" flex-row flex-ali-center">
<text class="r-content-tag r-color-grey"
v-if="i.lastMsgTimeStr">回复:{{i.lastMsgTimeStr}}</text>
</view>
</view>
</view>
</view>
</transition>
</cell-slot>
</recycle-list>`
navChat(item, index) { let that = this; var dialogId = item.dialogId; var extend = getApp().G.getExtend(); if (item.num > 0) { that.$set(that.dbClick, dialogId, 0); that.noReadNum = that.noReadNum - item.num; that.chatListType[that.currentIndex].num = that.chatListType[that.currentIndex].num - item.num; if (that.noReadNum < 1) { that.noReadNum = 0; uni.removeTabBarBadge({ index: 1 }); } else { uni.setTabBarBadge({ index: 1, text: that.noReadNum + "" }) } } if (extend.p === 'win') { uni.$emit('showChat', { dialogId: dialogId }); } else { uni.navigateTo({ url: '/pages/im/dialog/chat?dialogId=' + dialogId + '&status=' + item.status }) that.closeShade(); } },