<wxs src="../../utils/filter.wxs" module="filters" />
<view class="rankingBox">
    <view class="podiumBox invitation">
        <view class="dateBox">
            邀新排行榜
        </view>
        <view class="podiumContent">
            <view class="user first">
                <image src="{{userList[0].avatar}}" class="avatar" bindtap="jumpUserInfo"
                    data-uid='{{userList[0].uid}}' />
                <view class="iconBox">
                    <image src="/static/yx.png" class="icon" />
                    <view class="num">{{userList[0].count}}</view>
                </view>
                <view class="nickName textOver">
                    {{userList[0].nickName||userList[0].eid}}
                </view>
            </view>
            <view class="user second">
                <image src="{{userList[1].avatar}}" class="avatar" bindtap="jumpUserInfo"
                    data-uid='{{userList[1].uid}}' />
                <view class="iconBox">
                    <image src="/static/yx.png" class="icon" />
                    <view class="num">{{userList[1].count}}</view>
                </view>
                <view class="nickName textOver">
                    {{userList[1].nickName||userList[1].eid}}
                </view>
            </view>
            <view class="user third">
                <image src="{{userList[2].avatar}}" class="avatar" bindtap="jumpUserInfo"
                    data-uid='{{userList[2].uid}}' />
                <view class="iconBox">
                    <image src="/static/yx.png" class="icon" />
                    <view class="num">{{userList[2].count}}</view>
                </view>
                <view class="nickName textOver">
                    {{userList[2].nickName||userList[2].eid}}
                </view>
            </view>
        </view>
    </view>
    <view class="podiumList">
        <scroll-view scroll-y="true" enhanced="true" show-scrollbar="{{false}}" class="scrollBox">
            <view class="row" wx:for="{{userList.length-3}}" wx:key="index">
                <view class="left">
                    <view class="num">{{index+4}}</view>
                    <image src="{{userList[index+3].avatar}}" class="avatar" bindtap="jumpUserInfo"
                        data-uid='{{userList[index+3].uid}}' />
                    <view class="nickName textOver">
                        {{userList[index+3].nickName||userList[index+3].eid}}
                    </view>
                </view>
                <view class="right">
                    <image src="/static/yx.png" class="icon" />
                    <view class="num"> {{userList[index+3].count}}</view>
                </view>
            </view>
        </scroll-view>
    </view>
    <view class="footer">
        <view class="detail" wx:if="{{myCount>0}}">
            <view class="left">
                <image src="{{userInfo.avatar}}" class="avatar" />
                <view class="nickName textOver">{{userInfo.nickName}}</view>
            </view>
            <view class="right">
                <view class="info">
                    <view class="i1">第{{ranking?ranking+'名':'100+'}}</view>
                    <view class="i2" wx:if="{{ranking&&ranking!='1'}}">距离上一名还差{{gap}}</view>
                </view>
                <view class="num">
                    {{myCount}}
                </view>
            </view>
        </view>
        <view class="operate">
            <view class="record" bindtap="showTranscript">邀请记录</view>
            <button class="resetBtn share" open-type="share">
                邀请我的同学朋友
            </button>
        </view>
    </view>
    <popUp id="popUp">
        <view class="popBox">
            <view class="header">
                邀请记录
                <image src="/static/lollipop.png" class="close" bindtap="closeTranscript" />
            </view>
            <view class="copywriting" wx:if="{{inviteList.length==0}}">
                <view class="text">别的小伙伴已经拿到大奖啦！</view>
                <view>快去邀请你的小伙伴为你助力！</view>
            </view>
            <scroll-view scroll-y="true" class="list" enhanced show-scrollbar='{{false}}'>
                <view class="item" wx:for="{{inviteList}}" wx:key="eid">
                    <view class="left" bindtap="jumpUserInfo" data-uid='{{item.uid}}'>
                        <view class="num">{{index+1}}</view>
                        <image src="{{item.avatar}}" class="avatar" data-uid="{{item.uid}}" bindtap="jumpUserInfo" />
                        <view class="nickName textOver">{{item.nickName||item.eid}}</view>
                    </view>
                    <view class="time">{{filters.formatDate(item.gmtCreated,1)}}</view>
                </view>

            </scroll-view>
        </view>
    </popUp>
</view>