Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
7
7-Eleven
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
高淑倩
7-Eleven
Commits
50e8ad4d
Commit
50e8ad4d
authored
Nov 22, 2019
by
谢中龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交版本
parent
314cbc55
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
138 additions
and
29 deletions
+138
-29
point.png
src/assets/imgs/point.png
+0
-0
IntegralMall.wxss
src/pages/IntegralMall/IntegralMall.wxss
+2
-0
coupons.js
src/pages/coupons/coupons.js
+25
-18
integralWater.js
src/pages/integralWater/integralWater.js
+28
-1
integralWater.wxml
src/pages/integralWater/integralWater.wxml
+22
-2
integralWater.wxss
src/pages/integralWater/integralWater.wxss
+60
-7
IntegralMallGoods.wxml
...ckage/page/pages/IntegralMallGoods/IntegralMallGoods.wxml
+1
-1
No files found.
src/assets/imgs/point.png
0 → 100644
View file @
50e8ad4d
1.28 KB
src/pages/IntegralMall/IntegralMall.wxss
View file @
50e8ad4d
...
...
@@ -31,6 +31,8 @@
font-size: 28rpx;
}
/* 卡劵列表 */
.coupon-wrap{
padding: 20rpx;
...
...
src/pages/coupons/coupons.js
View file @
50e8ad4d
...
...
@@ -19,7 +19,7 @@ wxService.page({
}
],
pageNo
:
1
,
pageSize
:
1
0
,
pageSize
:
2
0
,
invalidPageNo
:
1
,
totalPages
:
0
,
totalElements
:
0
,
...
...
@@ -44,10 +44,10 @@ wxService.page({
}
// 可使用
if
(
current
==
0
){
this
.
getCouponList
(
1
,
1
0
,
1
)
this
.
getCouponList
(
1
,
2
0
,
1
)
}
else
if
(
current
==
1
){
// 失效
this
.
getCouponList
(
1
,
1
0
,
0
)
this
.
getCouponList
(
1
,
3
0
,
0
)
}
},
// 点击切换
...
...
@@ -64,10 +64,10 @@ wxService.page({
}
// 可使用
if
(
current
==
0
){
this
.
getCouponList
(
1
,
1
0
,
1
)
this
.
getCouponList
(
1
,
2
0
,
1
)
}
else
if
(
current
==
1
){
// 失效
this
.
getCouponList
(
1
,
1
0
,
0
)
this
.
getCouponList
(
1
,
3
0
,
0
)
}
},
/**
...
...
@@ -79,8 +79,8 @@ wxService.page({
*/
onShow
()
{
// 可使用 已失效
this
.
getCouponList
(
1
,
1
0
,
1
)
this
.
getCouponList
(
1
,
1
0
,
0
)
this
.
getCouponList
(
1
,
2
0
,
1
)
this
.
getCouponList
(
1
,
3
0
,
0
)
},
handelPresentCouponDetail
(
e
)
{
let
{
cardno
}
=
e
.
currentTarget
.
dataset
...
...
@@ -175,17 +175,23 @@ wxService.page({
})
}
}
else
{
if
(
invalidPageNo
<
invalidTotalPages
)
{
this
.
setData
({
invalidPageNo
:
invalidPageNo
+
1
,
})
// status 0
this
.
getCouponList
(
this
.
data
.
invalidPageNo
,
pageSize
,
0
)
}
else
{
this
.
setData
({
noMoreCouponInvalid
:
true
})
}
// if ( invalidPageNo < invalidTotalPages) {
// this.setData({
// invalidPageNo: invalidPageNo + 1,
// })
// // status 0
// this.getCouponList(this.data.invalidPageNo, pageSize, 0)
// } else {
// this.setData({
// noMoreCouponInvalid: true
// })
// }
this
.
setData
({
noMoreCouponInvalid
:
true
})
}
},
})
\ No newline at end of file
src/pages/integralWater/integralWater.js
View file @
50e8ad4d
...
...
@@ -13,7 +13,12 @@ wxService.page({
pageNo
:
1
,
pageSize
:
30
,
integralList
:
[],
noMore
:
false
noMore
:
false
,
memberPoint
:
{
total
:
'--'
,
expirePoint
:
0
,
expireDate
:
''
}
},
/**
* 生命周期函数--监听页面加载
...
...
@@ -23,6 +28,27 @@ wxService.page({
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{},
//查询会员积分信息
getMemberIntegrateInfo
()
{
// wx.showLoading({
// title: '数据请求中..',
// });
const
{
memberId
}
=
wx
.
getStorageSync
(
'_baseUserInfo'
)
if
(
!
memberId
)
{
return
;
}
wxService
.
get
(
`/member/memberPoint/getMemberPointInfo?memberId=
${
memberId
}
`
).
then
(
res
=>
{
let
data
=
res
.
data
.
data
?
res
.
data
.
data
:
{};
this
.
data
.
memberPoint
.
total
=
data
.
point
?
data
.
point
:
0
;
this
.
data
.
memberPoint
.
expirePoint
=
data
.
pointWillExpired
?
data
.
pointWillExpired
:
0
;
let
expireDate
=
data
.
pointExpiredTime
?
data
.
pointExpiredTime
:
''
;
this
.
data
.
memberPoint
.
expireDate
=
expireDate
;
this
.
setData
({
memberPoint
:
this
.
data
.
memberPoint
});
});
},
/**
* 生命周期函数--监听页面显示
*/
...
...
@@ -31,6 +57,7 @@ wxService.page({
this
.
getIntegralList
()
// 查询会员积分信息
this
.
getMemberPointInfo
()
this
.
getMemberIntegrateInfo
();
},
// 查询会员积分信息
getMemberPointInfo
(){
...
...
src/pages/integralWater/integralWater.wxml
View file @
50e8ad4d
<!--pages/integralWater.wxml-->
<view class='integral'>
<view class="integral-detail">
<
!-- <
view class="integral-detail">
<view class="integral-num">
<view class="num-current">{{integralNum}}</view>
<view class="num-title">当前积分</view>
</view>
<view class="integral-vip-rules" bindtap="handleGoMemberRulesRules">积分规则</view>
</view>
</view> -->
<view class='mall-title'>
<view class='title-num-point'>
<view class='title-img-point'>
<view class='img-point'>
<image class="point-img" src='/assets/imgs/point.png' mode="widthFix" />
</view>
<view class='text-point'>
{{memberPoint.total}}
</view>
</view>
<view class='integral-vip-rules' bindtap="handleGoMemberRulesRules">积分规则</view>
</view>
<view class='title-time-point' wx:if="{{memberPoint.expirePoint > 0}}">
{{memberPoint.expirePoint}} 积分将于 {{memberPoint.expireDate}} 清零
</view>
<view class='title-time-point' wx:if="{{memberPoint.expirePoint == 0}}">
暂无将过期积分
</view>
</view>
<view wx:if="{{!integralList.length}}" class="detail-list-no">还没有任何积分记录</view>
<view wx:if="{{integralList.length}}">
...
...
src/pages/integralWater/integralWater.wxss
View file @
50e8ad4d
/* pages/integralWater.wxss */
page{
background: #ffffff;
}
.integral{
margin: 30rpx;
padding-bottom: 50rpx;
border-top: 1px solid rgba(151, 151, 151, 0.1);
}
.detail-left{
width: 50%;
}
.text-point {
color: rgba(51, 51, 51, 1);
font-size: 42rpx;
margin-left: 10rpx;
}
.mall-title {
height: 150rpx;
padding-left: 50rpx;
padding-right: 42rpx;
box-sizing: border-box;
background-color: rgba(255, 255, 255, 1);
box-shadow: 0px 0px 8px 5px rgba(0, 0, 0, 0.05),
0px 0px 3px 0px rgba(0, 0, 0, 0.03);
}
.title-num-point {
padding-top: 30rpx;
display: flex;
justify-content: space-between;
align-items: center;
}
.integral-vip-rules {
width: 133rpx;
height: 42rpx;
line-height: 42rpx;
border-radius: 34rpx;
font-size: 23rpx;
text-align: center;
border: 1px solid rgba(204, 204, 204, 1);
}
.title-time-point {
color: rgba(102, 102, 102, 1);
font-size: 24rpx;
text-align: left;
padding-top: 3rpx;
margin-top: 15rpx;
}
.point-img {
width: 28rpx;
height: 36rpx;
}
.title-img-point {
display: flex;
align-items: center;
}
.integral-detail{
border-radius: 10rpx;
padding-left:
43%
;
padding-left:
30rpx
;
height: 150rpx;
box-shadow: 0 0 10px #ccc ;
background-repeat: no-repeat;
...
...
@@ -21,7 +73,7 @@
text-align:center;
padding-top: 34rpx;
}
.integral-vip-rules{
/*
.integral-vip-rules{
width:100rpx;
height:33rpx;
line-height: 33rpx;
...
...
@@ -37,7 +89,7 @@
vertical-align:top;
margin-top: 25rpx;
margin-bottom: 40rpx;
}
}
*/
.num-current {
font-size: 36rpx;
color: #333;
...
...
@@ -47,11 +99,12 @@
color:#666
}
.integral-tips {
padding: 45rpx
0
padding: 45rpx
30rpx;
}
.tips-detail{
font-size: 24rpx;
color: #333;
margin-bottom: 10rpx;
}
.tips-much {
font-size: 28rpx;
...
...
@@ -75,7 +128,7 @@
.detail-num{
font-size: 25rpx;
text-align: left;
width:
10%
;
width:
auto
;
padding-top:20rpx;
}
.add {
...
...
@@ -87,7 +140,7 @@
.detail-integral{
display: flex;
justify-content: space-between;
padding: 0
60rpx 0 3
0rpx;
padding: 0
4
0rpx;
margin-bottom: 20rpx;
}
.detail-list-no {
...
...
src/subPackage/page/pages/IntegralMallGoods/IntegralMallGoods.wxml
View file @
50e8ad4d
...
...
@@ -5,7 +5,7 @@
<view class='title-num-point'>
<view class='title-img-point'>
<view class='img-point'>
<image class="point-img" src='/assets/imgs/
integral_exchange/
point.png' mode="widthFix" />
<image class="point-img" src='/assets/imgs/point.png' mode="widthFix" />
</view>
<view class='text-point'>
{{memberPoint.total}}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment