Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mayi-mp-shop
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
程默
mayi-mp-shop
Commits
e4a976fe
Commit
e4a976fe
authored
Feb 23, 2022
by
李嘉林
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
登录页面协议显示优化
parent
6a8983ba
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
6 deletions
+17
-6
src/pages/login/index.vue
+17
-6
No files found.
src/pages/login/index.vue
View file @
e4a976fe
...
...
@@ -84,6 +84,7 @@ export default {
ossLink
:
''
,
//第三方点击进入链接
wxUserInfo
:{},
queryOptions
:{},
isOnLoad
:
false
,
};
},
computed
:
{
...
...
@@ -93,6 +94,11 @@ export default {
}
},
onShow
()
{
if
(
!
this
.
isOnLoad
){
this
.
getShopUserProtocol
();
}
console
.
log
(
'----------------------login-onShow'
)
log
.
info
(
'----------------------login-onShow'
)
wx
.
checkSession
({
success
:
()
=>
{
//session_key 未过期,并且在本生命周期一直有效
...
...
@@ -117,13 +123,10 @@ export default {
})
},
onLoad
(
options
)
{
this
.
isOnLoad
=
true
;
console
.
log
(
'----------------------login-onload'
)
log
.
info
(
options
,
'----------------------login-onload-options'
)
login
.
getShopUserProtocol
().
then
(
res
=>
{
log
.
info
(
'获取用户协议'
,
res
)
if
(
res
.
data
.
code
==
'200'
)
{
this
.
content
=
res
.
data
.
data
;
}
});
this
.
getShopUserProtocol
();
Object
.
assign
(
this
.
$data
,
this
.
$options
.
data
());
//mpvue 的混合周期 使用小程序生命周期数据未初始化
options
.
scene
&&
(
this
.
scene
=
options
.
scene
)
if
(
options
.
back
)
{
...
...
@@ -566,6 +569,14 @@ export default {
wx
.
navigateBack
({
delta
:
1
});
},
getShopUserProtocol
()
{
login
.
getShopUserProtocol
().
then
(
res
=>
{
log
.
info
(
'获取用户协议'
,
res
)
if
(
res
.
data
.
code
==
'200'
)
{
this
.
content
=
res
.
data
.
data
;
}
});
}
}
};
...
...
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