Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
jcy2004x
ShopXO
提交
7c62f2dd
ShopXO
项目概览
jcy2004x
/
ShopXO
与 Fork 源项目一致
Fork自
纵之格 / ShopXO
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
ShopXO
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
7c62f2dd
编写于
1月 10, 2020
作者:
D
devil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
小程序开发,细节优化
上级
74f7e231
变更
18
隐藏空白更改
内联
并排
Showing
18 changed file
with
437 addition
and
77 deletion
+437
-77
application/tags.php
application/tags.php
+14
-12
extend/base/FileUtil.php
extend/base/FileUtil.php
+4
-0
public/appmini/old/alipay/pages/user/user.js
public/appmini/old/alipay/pages/user/user.js
+6
-1
public/appmini/old/baidu/pages/user/user.js
public/appmini/old/baidu/pages/user/user.js
+6
-1
public/appmini/old/qq/pages/user/user.js
public/appmini/old/qq/pages/user/user.js
+6
-1
public/appmini/old/toutiao/pages/user/user.js
public/appmini/old/toutiao/pages/user/user.js
+6
-1
public/appmini/old/weixin/app.json
public/appmini/old/weixin/app.json
+2
-1
public/appmini/old/weixin/images/plugins/membershiplevelvip/user-center-shouye-icon.png
...es/plugins/membershiplevelvip/user-center-shouye-icon.png
+0
-0
public/appmini/old/weixin/images/plugins/membershiplevelvip/user-center-tuandui-icon.png
...s/plugins/membershiplevelvip/user-center-tuandui-icon.png
+0
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/buy/buy.js
...ni/old/weixin/pages/plugins/membershiplevelvip/buy/buy.js
+1
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.js
...eixin/pages/plugins/membershiplevelvip/tuandui/tuandui.js
+147
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.json
...xin/pages/plugins/membershiplevelvip/tuandui/tuandui.json
+5
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxml
...xin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxml
+40
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxss
...xin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxss
+29
-0
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.js
.../old/weixin/pages/plugins/membershiplevelvip/user/user.js
+107
-24
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.wxml
...ld/weixin/pages/plugins/membershiplevelvip/user/user.wxml
+55
-33
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.wxss
...ld/weixin/pages/plugins/membershiplevelvip/user/user.wxss
+3
-2
public/appmini/old/weixin/pages/user/user.js
public/appmini/old/weixin/pages/user/user.js
+6
-1
未找到文件。
application/tags.php
浏览文件 @
7c62f2dd
...
...
@@ -32,6 +32,20 @@ return array (
'log_write'
=>
array
(
),
'plugins_service_users_center_left_menu_handle'
=>
array
(
0
=>
'app\\plugins\\wallet\\Hook'
,
1
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
2
=>
'app\\plugins\\coupon\\Hook'
,
3
=>
'app\\plugins\\distribution\\Hook'
,
),
'plugins_service_header_navigation_top_right_handle'
=>
array
(
0
=>
'app\\plugins\\wallet\\Hook'
,
1
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
2
=>
'app\\plugins\\coupon\\Hook'
,
3
=>
'app\\plugins\\distribution\\Hook'
,
),
'plugins_css'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
...
...
@@ -95,18 +109,6 @@ return array (
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
),
'plugins_service_users_center_left_menu_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
1
=>
'app\\plugins\\coupon\\Hook'
,
2
=>
'app\\plugins\\distribution\\Hook'
,
),
'plugins_service_header_navigation_top_right_handle'
=>
array
(
0
=>
'app\\plugins\\membershiplevelvip\\Hook'
,
1
=>
'app\\plugins\\coupon\\Hook'
,
2
=>
'app\\plugins\\distribution\\Hook'
,
),
'plugins_js'
=>
array
(
0
=>
'app\\plugins\\coupon\\Hook'
,
...
...
extend/base/FileUtil.php
浏览文件 @
7c62f2dd
...
...
@@ -331,6 +331,10 @@ class FileUtil
//这里设置客户端的弹出对话框显示的文件名
Header
(
"Content-Disposition: attachment; filename="
.
$show_name
);
// 清除前面输出的内容
ob_clean
();
flush
();
//一次性将数据传输给客户端
//echo fread($file, filesize($file_path));
//一次只传输1024个字节的数据给客户端
...
...
public/appmini/old/alipay/pages/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -64,6 +64,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -106,7 +111,7 @@ Page({
user_order_status_list
:
temp_user_order_status_list
,
customer_service_tel
:
data
.
customer_service_tel
||
null
,
common_user_center_notice
:
data
.
common_user_center_notice
||
null
,
avatar
:
(
data
.
avatar
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
avatar
:
(
(
data
.
avatar
||
null
)
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
nickname
:
(
data
.
nickname
!=
null
)
?
data
.
nickname
:
this
.
data
.
nickname
,
message_total
:
((
data
.
common_message_total
||
0
)
==
0
)
?
0
:
data
.
common_message_total
,
head_nav_list
:
temp_head_nav_list
,
...
...
public/appmini/old/baidu/pages/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -62,6 +62,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -104,7 +109,7 @@ Page({
user_order_status_list
:
temp_user_order_status_list
,
customer_service_tel
:
data
.
customer_service_tel
||
null
,
common_user_center_notice
:
data
.
common_user_center_notice
||
null
,
avatar
:
data
.
avatar
!=
null
?
data
.
avatar
:
(
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
,
avatar
:
(
data
.
avatar
||
null
)
!=
null
?
data
.
avatar
:
(
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
,
nickname
:
data
.
nickname
!=
null
?
data
.
nickname
:
this
.
data
.
nickname
,
message_total
:
(
data
.
common_message_total
||
0
)
==
0
?
0
:
data
.
common_message_total
,
head_nav_list
:
temp_head_nav_list
,
...
...
public/appmini/old/qq/pages/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -57,6 +57,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -99,7 +104,7 @@ Page({
user_order_status_list
:
temp_user_order_status_list
,
customer_service_tel
:
data
.
customer_service_tel
||
null
,
common_user_center_notice
:
data
.
common_user_center_notice
||
null
,
avatar
:
(
data
.
avatar
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
avatar
:
(
(
data
.
avatar
||
null
)
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
nickname
:
(
data
.
nickname
!=
null
)
?
data
.
nickname
:
this
.
data
.
nickname
,
message_total
:
((
data
.
common_message_total
||
0
)
==
0
)
?
0
:
data
.
common_message_total
,
head_nav_list
:
temp_head_nav_list
,
...
...
public/appmini/old/toutiao/pages/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -56,6 +56,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -98,7 +103,7 @@ Page({
user_order_status_list
:
temp_user_order_status_list
,
customer_service_tel
:
data
.
customer_service_tel
||
null
,
common_user_center_notice
:
data
.
common_user_center_notice
||
null
,
avatar
:
(
data
.
avatar
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
avatar
:
(
(
data
.
avatar
||
null
)
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
nickname
:
(
data
.
nickname
!=
null
)
?
data
.
nickname
:
this
.
data
.
nickname
,
message_total
:
((
data
.
common_message_total
||
0
)
==
0
)
?
0
:
data
.
common_message_total
,
head_nav_list
:
temp_head_nav_list
,
...
...
public/appmini/old/weixin/app.json
浏览文件 @
7c62f2dd
...
...
@@ -37,7 +37,8 @@
"pages/plugins/membershiplevelvip/shouyi-detail/shouyi-detail"
,
"pages/plugins/membershiplevelvip/shouyi/shouyi"
,
"pages/plugins/membershiplevelvip/tongji/tongji"
,
"pages/plugins/membershiplevelvip/tuiguang/tuiguang"
"pages/plugins/membershiplevelvip/tuiguang/tuiguang"
,
"pages/plugins/membershiplevelvip/tuandui/tuandui"
],
"window"
:
{
"navigationBarTitleText"
:
"{{application_title}}"
,
...
...
public/appmini/old/weixin/images/plugins/membershiplevelvip/user-center-shouye-icon.png
0 → 100644
浏览文件 @
7c62f2dd
2.1 KB
public/appmini/old/weixin/images/plugins/membershiplevelvip/user-center-tuandui-icon.png
0 → 100644
浏览文件 @
7c62f2dd
5.5 KB
public/appmini/old/weixin/pages/plugins/membershiplevelvip/buy/buy.js
浏览文件 @
7c62f2dd
...
...
@@ -118,6 +118,7 @@ Page({
// 请求生成支付订单
var
self
=
this
;
self
.
setData
({
submit_disabled_status
:
true
});
wx
.
showLoading
({
title
:
"
处理中...
"
});
wx
.
request
({
url
:
app
.
get_request_url
(
"
create
"
,
"
buy
"
,
"
membershiplevelvip
"
),
...
...
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.js
0 → 100644
浏览文件 @
7c62f2dd
const
app
=
getApp
();
Page
({
data
:
{
data_list
:
[],
data_page_total
:
0
,
data_page
:
1
,
data_list_loding_status
:
1
,
data_bottom_line_status
:
false
,
params
:
null
,
},
onLoad
(
params
)
{
this
.
setData
({
params
:
params
,
});
this
.
init
();
},
onShow
()
{
},
init
()
{
var
user
=
app
.
get_user_info
(
this
,
'
init
'
);
if
(
user
!=
false
)
{
// 用户未绑定用户则转到登录页面
if
(
app
.
user_is_need_login
(
user
))
{
wx
.
redirectTo
({
url
:
"
/pages/login/login?event_callback=init
"
});
return
false
;
}
else
{
// 获取数据
this
.
get_data_list
();
}
}
else
{
this
.
setData
({
data_list_loding_status
:
0
,
data_bottom_line_status
:
false
,
});
}
},
// 获取数据
get_data_list
(
is_mandatory
)
{
// 分页是否还有数据
if
((
is_mandatory
||
0
)
==
0
)
{
if
(
this
.
data
.
data_bottom_line_status
==
true
)
{
return
false
;
}
}
// 加载loding
wx
.
showLoading
({
title
:
"
加载中...
"
});
this
.
setData
({
data_list_loding_status
:
1
});
// 获取数据
wx
.
request
({
url
:
app
.
get_request_url
(
"
index
"
,
"
team
"
,
"
membershiplevelvip
"
),
method
:
"
POST
"
,
data
:
{
page
:
this
.
data
.
data_page
,
},
dataType
:
"
json
"
,
success
:
res
=>
{
wx
.
hideLoading
();
wx
.
stopPullDownRefresh
();
if
(
res
.
data
.
code
==
0
)
{
if
(
res
.
data
.
data
.
data
.
length
>
0
)
{
if
(
this
.
data
.
data_page
<=
1
)
{
var
temp_data_list
=
res
.
data
.
data
.
data
;
}
else
{
var
temp_data_list
=
this
.
data
.
data_list
;
var
temp_data
=
res
.
data
.
data
.
data
;
for
(
var
i
in
temp_data
)
{
temp_data_list
.
push
(
temp_data
[
i
]);
}
}
this
.
setData
({
data_list
:
temp_data_list
,
data_total
:
res
.
data
.
data
.
total
,
data_page_total
:
res
.
data
.
data
.
page_total
,
data_list_loding_status
:
3
,
data_page
:
this
.
data
.
data_page
+
1
,
});
// 是否还有数据
if
(
this
.
data
.
data_page
>
1
&&
this
.
data
.
data_page
>
this
.
data
.
data_page_total
)
{
this
.
setData
({
data_bottom_line_status
:
true
});
}
else
{
this
.
setData
({
data_bottom_line_status
:
false
});
}
}
else
{
this
.
setData
({
data_list_loding_status
:
0
,
data_list
:
[],
data_bottom_line_status
:
false
,
});
}
}
else
{
this
.
setData
({
data_list_loding_status
:
0
,
});
if
(
app
.
is_login_check
(
res
.
data
,
this
,
'
get_data_list
'
))
{
app
.
showToast
(
res
.
data
.
msg
);
}
}
},
fail
:
()
=>
{
wx
.
hideLoading
();
wx
.
stopPullDownRefresh
();
this
.
setData
({
data_list_loding_status
:
2
,
});
app
.
showToast
(
"
服务器请求出错
"
);
}
});
},
// 下拉刷新
onPullDownRefresh
()
{
this
.
setData
({
data_page
:
1
});
this
.
get_data_list
(
1
);
},
// 滚动加载
scroll_lower
(
e
)
{
this
.
get_data_list
();
},
// 头像查看
avatar_event
(
e
)
{
var
value
=
e
.
currentTarget
.
dataset
.
value
||
null
;
if
(
value
!=
null
)
{
wx
.
previewImage
({
current
:
value
,
urls
:
[
value
]
});
}
else
{
app
.
showToast
(
'
头像地址有误
'
);
}
},
});
\ No newline at end of file
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.json
0 → 100644
浏览文件 @
7c62f2dd
{
"enablePullDownRefresh"
:
true
,
"navigationBarBackgroundColor"
:
"#1d1611"
,
"navigationBarTitleText"
:
"我的团队"
}
\ No newline at end of file
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxml
0 → 100644
浏览文件 @
7c62f2dd
<scroll-view scroll-y="{{true}}" class="scroll-box" bindscrolltolower="scroll_lower" lower-threshold="30">
<view class="data-list">
<view class="item bg-white spacing-mb" wx:if="{{data_list.length > 0}}" wx:for="{{data_list}}" wx:key="key">
<view class="base oh br-b">
<image src="{{item.avatar}}" class="avatar dis-block fl" mode="widthFix" bindtap="avatar_event" data-value="{{item.avatar}}" />
<text class="fr nickname cr-888">{{item.user_name_view || ''}}</text>
</view>
<view class="content">
<view class="multi-text">
<text class="title cr-666">消费金额</text>
<text class="value">{{item.order_total}}</text>
<text class="unit cr-888">元</text>
</view>
<view class="multi-text">
<text class="title cr-666">下级消费</text>
<text class="value">{{item.find_order_total}}</text>
<text class="unit cr-888">元</text>
</view>
<view class="multi-text">
<text class="title cr-666">下级用户</text>
<text class="value">{{item.referrer_count}}</text>
<text class="unit cr-888">人</text>
</view>
<view class="multi-text">
<text class="title cr-666">加入时间</text>
<text class="value">{{item.add_time_time}}</text>
</view>
</view>
</view>
<view wx:if="{{data_list.length == 0}}">
<import src="/pages/common/nodata.wxml" />
<template is="nodata" data="{{status: data_list_loding_status}}">
</template>
</view>
<import src="/pages/common/bottom_line.wxml" />
<template is="bottom_line" data="{{status: data_bottom_line_status}}"></template>
</view>
</scroll-view>
\ No newline at end of file
public/appmini/old/weixin/pages/plugins/membershiplevelvip/tuandui/tuandui.wxss
0 → 100644
浏览文件 @
7c62f2dd
.scroll-box {
height: 100vh;
}
.data-list .item .base {
padding: 15rpx 10rpx;
}
.data-list .item .base .avatar {
width: 60rpx;
height: 60rpx;
border-radius: 50%;
}
.data-list .item .base .nickname {
margin-top: 10rpx;
}
.data-list .item .content {
padding: 20rpx 10rpx;
}
.data-list .item .content .multi-text {
line-height: 50rpx;
}
.data-list .item .content .multi-text .title {
margin-right: 30rpx;
}
.data-list .item .content .multi-text .value {
font-weight: 500;
}
.data-list .item .content .multi-text .unit {
margin-left: 10rpx;
}
\ No newline at end of file
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -8,30 +8,10 @@ Page({
user_vip
:
null
,
avatar
:
app
.
data
.
default_user_head_src
,
nickname
:
"
用户名
"
,
submit_disabled_status
:
false
,
// 导航
nav_list
:
[
{
icon
:
"
/images/plugins/membershiplevelvip/user-center-order-icon.png
"
,
title
:
"
开通订单
"
,
url
:
"
/pages/plugins/membershiplevelvip/order/order
"
,
},
{
icon
:
"
/images/plugins/membershiplevelvip/user-center-tuiguang-icon.png
"
,
title
:
"
推广返利
"
,
url
:
"
/pages/plugins/membershiplevelvip/tuiguang/tuiguang
"
,
},
{
icon
:
"
/images/plugins/membershiplevelvip/user-center-shouyi-icon.png
"
,
title
:
"
收益明细
"
,
url
:
"
/pages/plugins/membershiplevelvip/shouyi/shouyi
"
,
},
{
icon
:
"
/images/plugins/membershiplevelvip/user-center-tongji-icon.png
"
,
title
:
"
数据统计
"
,
url
:
"
/pages/plugins/membershiplevelvip/tongji/tongji
"
,
}
],
nav_list
:
[],
},
onLoad
(
params
)
{
...
...
@@ -65,6 +45,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -83,13 +68,67 @@ Page({
wx
.
stopPullDownRefresh
();
if
(
res
.
data
.
code
==
0
)
{
var
data
=
res
.
data
.
data
;
var
data_base
=
data
.
base
||
null
;
var
user_vip
=
data
.
user_vip
||
null
;
self
.
setData
({
data_base
:
data
.
base
||
null
,
user_vip
:
data
.
user_vip
||
null
,
data_base
:
data_base
,
user_vip
:
user_vip
,
avatar
:
(
user_vip
!=
null
&&
(
user_vip
.
icon
||
null
)
==
null
)
?
self
.
data
.
avatar
:
user_vip
.
icon
,
data_list_loding_msg
:
''
,
data_list_loding_status
:
0
,
data_bottom_line_status
:
false
,
});
// 导航处理
var
nav_list
=
[];
if
(
data_base
!=
null
)
{
// 开启会员购买
if
((
data_base
.
is_user_buy
||
0
)
==
1
)
{
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-order-icon.png
"
,
title
:
"
开通订单
"
,
url
:
"
/pages/plugins/membershiplevelvip/order/order
"
,
});
// 开启返佣
if
((
data_base
.
is_commission
||
0
)
==
1
)
{
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-shouyi-icon.png
"
,
title
:
"
收益明细
"
,
url
:
"
/pages/plugins/membershiplevelvip/shouyi/shouyi
"
,
});
}
// 开启推广
if
((
data_base
.
is_propaganda
||
0
)
==
1
)
{
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-tuandui-icon.png
"
,
title
:
"
我的团队
"
,
url
:
"
/pages/plugins/membershiplevelvip/tuandui/tuandui
"
,
});
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-tuiguang-icon.png
"
,
title
:
"
推广返利
"
,
url
:
"
/pages/plugins/membershiplevelvip/tuiguang/tuiguang
"
,
});
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-tongji-icon.png
"
,
title
:
"
数据统计
"
,
url
:
"
/pages/plugins/membershiplevelvip/tongji/tongji
"
,
});
}
nav_list
.
push
({
icon
:
"
/images/plugins/membershiplevelvip/user-center-shouye-icon.png
"
,
title
:
"
会员首页
"
,
url
:
"
/pages/plugins/membershiplevelvip/index/index
"
,
});
}
}
self
.
setData
({
nav_list
:
nav_list
});
}
else
{
self
.
setData
({
data_bottom_line_status
:
false
,
...
...
@@ -134,4 +173,48 @@ Page({
this
.
setData
({
avatar
:
app
.
data
.
default_user_head_src
});
},
// 连续开通会员事件
uservip_renew_event
(
e
)
{
var
self
=
this
;
wx
.
showModal
({
title
:
'
温馨提示
'
,
content
:
'
按照原时长和费用续费,确定继续吗?
'
,
confirmText
:
'
确认
'
,
cancelText
:
'
暂不
'
,
success
:
(
result
)
=>
{
if
(
result
.
confirm
)
{
// 请求生成支付订单
self
.
setData
({
submit_disabled_status
:
true
});
wx
.
showLoading
({
title
:
"
处理中...
"
});
wx
.
request
({
url
:
app
.
get_request_url
(
"
renew
"
,
"
buy
"
,
"
membershiplevelvip
"
),
method
:
"
POST
"
,
data
:
{},
dataType
:
"
json
"
,
header
:
{
'
content-type
'
:
'
application/x-www-form-urlencoded
'
},
success
:
res
=>
{
wx
.
hideLoading
();
self
.
setData
({
submit_disabled_status
:
false
});
if
(
res
.
data
.
code
==
0
)
{
// 进入以后会员中心并发起支付
wx
.
redirectTo
({
url
:
'
/pages/plugins/membershiplevelvip/order/order?is_pay=1&order_id=
'
+
res
.
data
.
data
.
id
,
});
}
else
{
if
(
app
.
is_login_check
(
res
.
data
,
self
,
'
uservip_renew_event
'
))
{
app
.
showToast
(
res
.
data
.
msg
);
}
}
},
fail
:
()
=>
{
self
.
setData
({
submit_disabled_status
:
false
});
wx
.
hideLoading
();
app
.
showToast
(
"
服务器请求出错
"
);
}
});
}
},
});
},
});
\ No newline at end of file
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.wxml
浏览文件 @
7c62f2dd
...
...
@@ -5,43 +5,61 @@
<text class="item-name dis-block cr-888">{{nickname}}</text>
</view>
<view class="head-base fl">
<view class="single-text level-name">VIP1</view>
<view class="single-text">
<block wx:if="{{user_vip.is_permanent == 1}}">
<text class="title">有效期</text>
<text class="value cr-fff">{{user_vip.permanent_value}}</text>
<text class="unit">{{user_vip.permanent_unit}}</text>
</block>
<block wx:else>
<block wx:if="{{user_vip.surplus_time_number == 0}}">
<view class="cr-888">会员已过期或未开通</view>
<navigator url="/pages/plugins/membershiplevelvip/buy/buy" hover-class="none">
<button wx:if="{{(data_base.is_user_buy || null) == 1}}" size="mini" type="default" hover-class="none" class="submit-buy">开通会员</button>
</navigator>
</block>
<block wx:else>
<text class="title">有效期</text>
<text class="value cr-fff">{{user_vip.surplus_time_number}}</text>
<text class="unit">{{user_vip.surplus_time_unit}}</text>
<block wx:if="{{(user_vip.is_supported_renew || null) == null || user_vip.is_supported_renew != 1}}">
<block wx:if="{{(plugins_base.is_supported_renew_old_order || null) == 1}}">
<button size="mini" type="default" hover-class="none" class="renew-buy">续费会员</button>
</block>
<block wx:else>
<block wx:if="{{(user_vip || null) != null}}">
<block wx:if="{{(user_vip.user_vip_model || null) == 'pay'}}">
<view class="single-text level-name">{{user_vip.level_name}}</view>
<view class="single-text">
<block wx:if="{{(user_vip.is_permanent || 0) == 1}}">
<text class="title">有效期</text>
<text class="value cr-fff">{{user_vip.permanent_value}}</text>
<text class="unit">{{user_vip.permanent_unit}}</text>
</block>
<block wx:else>
<block wx:if="{{(user_vip.surplus_time_number || 0) == 0}}">
<view class="cr-888">会员已过期或未开通</view>
<navigator url="/pages/plugins/membershiplevelvip/buy/buy" hover-class="none">
<button
size="mini" type="default" hover-class="none" class="submit-buy">连续开通
</button>
<button
wx:if="{{(data_base.is_user_buy || null) == 1}}" size="mini" type="default" hover-class="none" class="submit-buy">开通会员
</button>
</navigator>
</block>
<block wx:else>
<text class="title">有效期</text>
<text class="value cr-fff">{{user_vip.surplus_time_number}}</text>
<text class="unit">{{user_vip.surplus_time_unit}}</text>
<block wx:if="{{(user_vip.is_supported_renew || null) == null || user_vip.is_supported_renew != 1}}">
<block wx:if="{{(plugins_base.is_supported_renew_old_order || null) == 1}}">
<button size="mini" type="default" hover-class="none" class="renew-buy" bindtap="uservip_renew_event" disabled="{{submit_disabled_status}}">续费会员</button>
</block>
<block wx:else>
<block wx:if="{{(data_base || null) != null && (data_base.is_user_buy || 0) == 1}}">
<navigator url="/pages/plugins/membershiplevelvip/buy/buy" hover-class="none">
<button size="mini" type="default" hover-class="none" class="submit-buy">连续开通</button>
</navigator>
</block>
</block>
</block>
</block>
</block>
</view>
</block>
<block wx:else>
<view class="single-text level-name spacing-mt">{{user_vip.level_name}}</view>
</block>
</block>
<block wx:else>
<block wx:if="{{(user_vip.user_vip_model || null) == 'pay'}}">
<block wx:if="{{(data_base || null) != null && (data_base.is_user_buy || 0) == 1}}">
<navigator url="/pages/plugins/membershiplevelvip/buy/buy" hover-class="none">
<button size="mini" type="default" hover-class="none" class="submit-buy">开通会员</button>
</navigator>
</block>
</block>
</
view
>
</
block
>
</view>
</view>
<!-- 导航 -->
<view class="nav spacing-mt oh bg-white">
<view
wx:if="{{nav_list.length > 0 && data_base != null && (data_base.is_user_buy || 0) == 1}}"
class="nav spacing-mt oh bg-white">
<block wx:for="{{nav_list}}" wx:key="key">
<navigator url="{{item.url}}" hover-class="none">
<view class="item fl tc">
...
...
@@ -55,13 +73,17 @@
<!-- 通知 -->
<view class="tips-container spacing-mb">
<!-- 未开通会员介绍 -->
<view wx:if="{{(user_vip || null) == null && (data_base.not_opening_vip_desc || null) != null && data_base.not_opening_vip_desc.length > 0}}" class="tips-item spacing-mt">
<view class="not-opening-vip-desc">
<view wx:for="{{data_base.not_opening_vip_desc}}" wx:key="key" class="item">
{{item}}
<block wx:if="{{(data_base.is_user_buy || 0) == 1}}">
<block wx:if="{{((user_vip || null) == null) || ((user_vip || null) == null && (user_vip.surplus_time_number || 0) == 0)}}">
<view wx:if="{{(data_base.not_opening_vip_desc || null) != null && data_base.not_opening_vip_desc.length > 0}}" class="tips-item spacing-mt">
<view class="not-opening-vip-desc">
<view wx:for="{{data_base.not_opening_vip_desc}}" wx:key="key" class="item">
{{item}}
</view>
</view>
</view>
</
view
>
</
view
>
</
block
>
</
block
>
<!-- 会员中心通知 -->
<view wx:if="{{(data_base.user_vip_center_notice || null) != null && data_base.user_vip_center_notice.length > 0}}" class="tips-item spacing-mt">
...
...
public/appmini/old/weixin/pages/plugins/membershiplevelvip/user/user.wxss
浏览文件 @
7c62f2dd
...
...
@@ -11,8 +11,9 @@
padding-bottom: 30rpx;
}
.head-item .avatar {
width: 160rpx;
height: 160rpx;
width: 140rpx;
height: 140rpx;
padding: 20rpx;
border-radius: 50%;
border: 1px solid #3d3c3c;
}
...
...
public/appmini/old/weixin/pages/user/user.js
浏览文件 @
7c62f2dd
...
...
@@ -57,6 +57,11 @@ Page({
},
});
}
else
{
self
.
setData
({
avatar
:
user
.
avatar
||
app
.
data
.
default_user_head_src
,
nickname
:
user
.
user_name_view
||
'
用户名
'
,
});
self
.
get_data
();
}
}
...
...
@@ -99,7 +104,7 @@ Page({
user_order_status_list
:
temp_user_order_status_list
,
customer_service_tel
:
data
.
customer_service_tel
||
null
,
common_user_center_notice
:
data
.
common_user_center_notice
||
null
,
avatar
:
(
data
.
avatar
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
avatar
:
(
(
data
.
avatar
||
null
)
!=
null
)
?
data
.
avatar
:
((
this
.
data
.
avatar
||
null
)
==
null
?
app
.
data
.
default_user_head_src
:
this
.
data
.
avatar
),
nickname
:
(
data
.
nickname
!=
null
)
?
data
.
nickname
:
this
.
data
.
nickname
,
message_total
:
((
data
.
common_message_total
||
0
)
==
0
)
?
0
:
data
.
common_message_total
,
head_nav_list
:
temp_head_nav_list
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录