Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
W
web-site
Project
Project
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
张冬
web-site
Commits
423884b5
Commit
423884b5
authored
Sep 23, 2020
by
吴冠
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化登录
parent
aec23193
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
10 deletions
+16
-10
header.vue
components/header.vue
+8
-1
index.vue
pages/index/index.vue
+4
-1
user.vue
pages/login/user.vue
+4
-8
No files found.
components/header.vue
View file @
423884b5
...
@@ -44,8 +44,15 @@
...
@@ -44,8 +44,15 @@
}
}
},
},
methods
:
{
methods
:
{
//收藏按钮
addFavo
()
{
addFavo
()
{
this
.
$message
(
'这是一条消息提示'
);
/* let browser = browser||chrome */
window
.
external
.
addFavorite
({
title
:
document
.
title
,
url
:
document
.
URL
}).
then
(
console
.
log
(
'created'
)
)
},
},
admin
()
{
admin
()
{
this
.
$router
.
push
(
"/login/admin"
)
this
.
$router
.
push
(
"/login/admin"
)
...
...
pages/index/index.vue
View file @
423884b5
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
<div
class=
"author"
></div>
<div
class=
"author"
></div>
<div
class=
"login-title"
>
{{
userName
}}
</div>
<div
class=
"login-title"
>
{{
userName
}}
</div>
<div
class=
"login-button"
@
click=
"loginuser"
v-show=
"showDefault"
>
用户登录
</div>
<div
class=
"login-button"
@
click=
"loginuser"
v-show=
"showDefault"
>
用户登录
</div>
<div
class=
"login-button"
>
商家入驻
</div>
<div
class=
"login-button"
@
click=
"Merchant"
>
商家入驻
</div>
<div
class=
"login-button"
@
click=
"checkout"
v-show=
"!showDefault"
>
退出
</div>
<div
class=
"login-button"
@
click=
"checkout"
v-show=
"!showDefault"
>
退出
</div>
</div>
</div>
</div>
</div>
...
@@ -64,6 +64,9 @@ import {getSecond,getCategoryList,getListSite} from '@/common/list.js'
...
@@ -64,6 +64,9 @@ import {getSecond,getCategoryList,getListSite} from '@/common/list.js'
this
.
getListSite
()
this
.
getListSite
()
},
},
methods
:{
methods
:{
Merchant
(){
this
.
$router
.
push
(
'/login/examine'
)
},
async
getCategoryList
(){
async
getCategoryList
(){
const
{
data
}
=
await
getCategoryList
()
const
{
data
}
=
await
getCategoryList
()
this
.
dynamicList
=
data
this
.
dynamicList
=
data
...
...
pages/login/user.vue
View file @
423884b5
...
@@ -98,18 +98,14 @@
...
@@ -98,18 +98,14 @@
},
},
async
submitForm1
()
{
async
submitForm1
()
{
try
{
try
{
const
valid
=
await
this
.
$refs
[
'param
s
'
].
validate
()
const
valid
=
await
this
.
$refs
[
'param'
].
validate
()
if
(
valid
)
{
if
(
valid
)
{
/*
const {
const
{
msg
,
msg
,
code
,
code
,
data
data
} = await powerLogin(this.param) */
}
=
await
powerLogin
(
this
.
param
)
//将手机号和手机验证码发送
//将手机号和密码发送
let
mess
=
{}
mess
.
phone
=
this
.
param
.
account
mess
.
verify
=
this
.
param
.
password
const
{
data
,
code
,
msg
}
=
await
getVerifyPhone
(
mess
)
console
.
log
(
data
,
code
)
console
.
log
(
data
,
code
)
if
(
code
==
200
)
{
if
(
code
==
200
)
{
sessionStorage
.
setItem
(
"token"
,
data
);
sessionStorage
.
setItem
(
"token"
,
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