Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yoho-limited-sell-miniapp
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
邱骏
7 years ago
Commit
70b42195a077d3801acb24f4639d8023e87fb6ee
1 parent
08cab3b9
我的排队号,增加助力信息
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
72 additions
and
27 deletions
app/pages/queue/index.wxml
app/pages/queue/myList.js
app/pages/queue/myList.json
app/pages/queue/myList.wxml
app/pages/queue/myList.wxss
app/project.config.json
app/pages/queue/index.wxml
View file @
70b4219
...
...
@@ -49,7 +49,7 @@
<!--悬浮按钮-->
<block wx:if="{{userInfo.isDrawline &&
!activityInfo.isEnd
}}">
<block wx:if="{{userInfo.isDrawline &&
(!activityInfo.isEnd || !activityInfo.isDrawEnd)
}}">
<view class='user-container' bindtap='navigateToMyList'>
<view class='userrank' hidden='{{hidePopup}}'>
<view class='rank-text'>
...
...
app/pages/queue/myList.js
View file @
70b4219
...
...
@@ -125,15 +125,6 @@ Page(Object.assign({
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh
:
function
()
{
let
actId
=
this
.
data
.
activityInfo
.
activityId
;
wx
.
stopPullDownRefresh
();
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom
:
function
()
{
...
...
@@ -222,6 +213,17 @@ Page(Object.assign({
console
.
log
(
res
);
if
(
res
.
data
&&
res
.
data
.
length
>
0
)
{
let
result
=
[];
let
helpIndex
=
0
;
if
(
res
.
data
[
0
].
helpName
&&
res
.
data
[
0
].
helpheadIco
)
{
result
.
push
({
helpInfo
:
'好友"'
+
res
.
data
[
0
].
helpName
+
'"已为你助力'
,
background
:
helper
.
imgView
(
this
.
data
.
bgStyle
[
0
],
340
,
162
,
1
),
helpName
:
res
.
data
[
0
].
helpName
,
helpheadIco
:
res
.
data
[
0
].
helpheadIco
});
helpIndex
=
1
;
}
res
.
data
.
forEach
((
item
,
index
)
=>
{
if
(
!
item
.
headIco
)
{
...
...
@@ -235,7 +237,7 @@ Page(Object.assign({
item
.
vipLevel
=
item
.
vipLevel
||
0
;
item
.
vipImage
=
this
.
data
.
vipImage
[
item
.
vipLevel
];
let
bgStyle
=
this
.
data
.
bgStyle
;
let
bgIndex
=
index
%
bgStyle
.
length
;
let
bgIndex
=
(
index
+
helpIndex
)
%
bgStyle
.
length
;
item
.
background
=
helper
.
imgView
(
bgStyle
[
bgIndex
],
340
,
162
,
1
);
result
.
push
(
item
);
...
...
app/pages/queue/myList.json
View file @
70b4219
{
"navigationBarTitleText"
:
"我的排队号"
,
"enablePullDownRefresh"
:
tru
e
,
"enablePullDownRefresh"
:
fals
e
,
"backgroundColor"
:
"#222"
,
"backgroundTextStyle"
:
"light"
}
\ No newline at end of file
...
...
app/pages/queue/myList.wxml
View file @
70b4219
...
...
@@ -3,7 +3,16 @@
<view class='container'>
<!--排队列表-->
<block class='queue-list' wx:for='{{queueList}}' wx:key='{{item.id}}'>
<view id='item_{{item.uid}}' class='queue-item {{item.uid === userInfo.uid ? "active" : ""}}'>
<view id='item_{{item.uid || 0}}' class='queue-item'>
<block wx:if="{{item.helpInfo}}">
<view class='item-helpinfo-container'>
<view class='item-helpinfo'>
<image src='{{item.helpheadIco}}'></image>
<text>{{item.helpInfo}}</text>
</view>
</view>
</block>
<block wx:else>
<view class='item-head-container'>
<!--headImage-->
<image class='item-head' src='{{item.headIco}}'></image>
...
...
@@ -15,22 +24,25 @@
</view>
<view class='item-info-container'>
<!--itemInfo-->
<view class='item-user-rank'>
<text>{{item.sort}}</text>
<view wx:if="{{item.helpName}}" class='item-user-assist'>
<image src='{{item.helpheadIco}}'></image>
<text>好友助力</text>
<view class='item-user-rank'>
<text>{{item.sort}}</text>
<view wx:if="{{item.helpName}}" class='item-user-assist'>
<image src='{{item.helpheadIco}}'></image>
<text>好友助力</text>
</view>
</view>
</view>
<view class='item-user-name'>{{item.nickName}}</view>
<view class='item-user-time'>
<view class='item-user-time-icon'></view>
<view class='item-user-time-text'>{{item.queueTime}}</view>
<view class='item-user-vip-level' wx:if='{{item.vipLevel}}'>
<image src='{{item.vipImage}}'></image>
<view class='item-user-name'>{{item.nickName}}</view>
<view class='item-user-time'>
<view class='item-user-time-icon'></view>
<view class='item-user-time-text'>{{item.queueTime}}</view>
<view class='item-user-vip-level' wx:if='{{item.vipLevel}}'>
<image src='{{item.vipImage}}'></image>
</view>
</view>
</view>
</view>
</block>
<view class='item-bg'>
<image src='{{item.background}}'></image>
</view>
...
...
app/pages/queue/myList.wxss
View file @
70b4219
...
...
@@ -262,6 +262,10 @@ image {
z-index: 5;
}
.item-helpinfo-container {
width: 410rpx;
}
.item-info-container { /* item用户相关信息 */
display: flex;
flex-flow: column;
...
...
@@ -272,6 +276,27 @@ image {
box-sizing: border-box;
}
.item-helpinfo {
display: flex;
flex-direction: row;
align-items: center;
height: 60rpx;
margin: 0 30rpx;
background-color: rgba(0, 0, 0, 0.3);
font-size: 20rpx;
font-weight: lighter;
color: #fff;
border-radius: 30rpx;
overflow: hidden;
}
.item-helpinfo image {
width: 42rpx;
height: 42rpx;
margin: 0 8rpx;
border-radius: 42rpx;
}
.item-user-rank { /* item 用户排名 */
display: flex;
flex-direction: row;
...
...
app/project.config.json
View file @
70b4219
...
...
@@ -33,7 +33,7 @@
"list"
:
[]
},
"miniprogram"
:
{
"current"
:
0
,
"current"
:
4
,
"list"
:
[
{
"id"
:
0
,
...
...
@@ -114,6 +114,12 @@
"appId"
:
"wx084ab813d88c594b"
,
"extraData"
:
"{}"
}
},
{
"id"
:
-1
,
"name"
:
"我的排队列表"
,
"pathName"
:
"pages/queue/myList"
,
"query"
:
"actId=362"
}
]
}
...
...
Please
register
or
login
to post a comment