|
@@ -1,23 +1,12 @@
|
|
|
<template>
|
|
|
<div class="message-wrapper">
|
|
|
- <!-- <div class="tab-bar">
|
|
|
- <div
|
|
|
- class="tab-item"
|
|
|
- :class="{ active: currentTabIndex == index }"
|
|
|
- v-for="(item, index) in tabList"
|
|
|
- :key="index"
|
|
|
- @click="clickTab(item, index)"
|
|
|
- >
|
|
|
- {{ item.label }}
|
|
|
- </div>
|
|
|
- </div> -->
|
|
|
<div class="tab-content" ref="pageWrapperDom" @scroll="pageScroll">
|
|
|
<div class="list-wrapper" ref="pageGiveListDom">
|
|
|
<div class="give-list" v-if="currentTabIndex == 0">
|
|
|
<template v-if="giveList.length">
|
|
|
<div
|
|
|
class="cell"
|
|
|
- :class="{ 'cell-center': item.type == 1 }"
|
|
|
+ :class="{ 'cell-center': item.type == 1 || item.type == 3 }"
|
|
|
v-for="(item, index) in giveList"
|
|
|
:key="index"
|
|
|
@click="clickListItem(item, index)"
|
|
@@ -29,7 +18,7 @@
|
|
|
|
|
|
<div class="img-wrapper">
|
|
|
<!-- 收到红包 -->
|
|
|
- <template v-if="item.type == 1">
|
|
|
+ <template v-if="item.type == 1 || item.type == 3">
|
|
|
<img class="icon-avatar" :src="item.userInfo.avatarUrl" />
|
|
|
<img
|
|
|
class="icon-give"
|
|
@@ -50,7 +39,15 @@
|
|
|
>
|
|
|
<div class="left">
|
|
|
<div class="nickname">
|
|
|
- {{ item.type == 1 ? "Get Giveaway" : "Send Giveaway" }}
|
|
|
+ <template v-if="item.type == 1">
|
|
|
+ Get Giveaway
|
|
|
+ </template>
|
|
|
+ <template v-else-if="item.type == 2">
|
|
|
+ {{ item.postTaskLuckdrop.luckdropType === 1 ? 'Send Giveaway' : 'Lottery Giveaway' }}
|
|
|
+ </template>
|
|
|
+ <template v-else-if="item.type == 3">
|
|
|
+ Lottery
|
|
|
+ </template>
|
|
|
</div>
|
|
|
<div class="time">
|
|
|
{{ moment(item.timestamp).format("MM-DD HH:mm:ss") }}
|
|
@@ -275,7 +272,7 @@ const clickListItem = (params) => {
|
|
|
}
|
|
|
let twitterUrl = "https://twitter.com/";
|
|
|
let nickName = "";
|
|
|
- if (params.type == 1) {
|
|
|
+ if (params.type == 1 || params.type == 3) {
|
|
|
nickName = params.userInfo.nickName;
|
|
|
} else if (params.type == 2) {
|
|
|
nickName = userInfo.value.nickName;
|