Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
robot-monitor
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
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
汪晓凯
robot-monitor
Commits
a54e2b21
Commit
a54e2b21
authored
Jul 03, 2018
by
wxk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
检测登录
parent
c4ad0ff5
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
4 deletions
+11
-4
preHeader.vue
src/components/preHeader.vue
+1
-0
Login.vue
src/views/Login.vue
+5
-4
container.vue
src/views/container.vue
+5
-0
No files found.
src/components/preHeader.vue
View file @
a54e2b21
...
@@ -21,6 +21,7 @@
...
@@ -21,6 +21,7 @@
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'/'
path
:
'/'
});
});
localStorage
[
"isLogin"
]
=
false
;
this
.
$notify
({
this
.
$notify
({
title
:
'提示'
,
title
:
'提示'
,
message
:
"退出成功"
,
message
:
"退出成功"
,
...
...
src/views/Login.vue
View file @
a54e2b21
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
<span
@
click=
"goShowPanel(3)"
class=
"bluepoint"
>
找回密码
</span>
<span
@
click=
"goShowPanel(3)"
class=
"bluepoint"
>
找回密码
</span>
</span>
</span>
<input
type=
"checkbox"
name=
"记住用户密码"
class=
"rember"
v-model=
"isSaveLoginInfo"
>
<input
type=
"checkbox"
name=
"记住用户密码"
class=
"rember"
v-model=
"isSaveLoginInfo"
>
<span>
记住
用户名
</span>
<span>
记住
密码
</span>
</div>
</div>
<el-button
type=
"primary"
class=
"loginget"
@
click=
"Login"
>
立刻登录
</el-button>
<el-button
type=
"primary"
class=
"loginget"
@
click=
"Login"
>
立刻登录
</el-button>
</div>
</div>
...
@@ -46,7 +46,7 @@
...
@@ -46,7 +46,7 @@
<input
type=
"text"
placeholder=
"请输入验证码"
class=
"usercomyzm"
v-model=
"regist_yzm"
>
<input
type=
"text"
placeholder=
"请输入验证码"
class=
"usercomyzm"
v-model=
"regist_yzm"
>
<el-button
type=
"primary"
class=
"getyzm"
@
click=
"getYZM('regist')"
:disabled=
'!show'
>
<el-button
type=
"primary"
class=
"getyzm"
@
click=
"getYZM('regist')"
:disabled=
'!show'
>
<span
v-show =
"show"
>
获取验证码
</span>
<span
v-show =
"show"
>
获取验证码
</span>
<span
v-show =
"!show"
class=
"count"
>
还剩下
{{
count
}}
s
</span>
<span
v-show =
"!show"
class=
"count"
>
已发送
{{
count
}}
s
</span>
</el-button>
</el-button>
</div>
</div>
<div
class=
"ground"
style=
"margin-bottom:70px;"
>
<div
class=
"ground"
style=
"margin-bottom:70px;"
>
...
@@ -71,7 +71,7 @@
...
@@ -71,7 +71,7 @@
<input
type=
"text"
placeholder=
"请输入验证码"
class=
"usercomyzm"
v-model=
"forget_yzm"
>
<input
type=
"text"
placeholder=
"请输入验证码"
class=
"usercomyzm"
v-model=
"forget_yzm"
>
<el-button
type=
"primary"
class=
"getyzm"
@
click=
"getYZM('forgetpassword')"
:disabled=
'!show'
>
<el-button
type=
"primary"
class=
"getyzm"
@
click=
"getYZM('forgetpassword')"
:disabled=
'!show'
>
<span
v-show =
"show"
>
获取验证码
</span>
<span
v-show =
"show"
>
获取验证码
</span>
<span
v-show =
"!show"
class=
"count"
>
还剩下
{{
count
}}
s
</span>
<span
v-show =
"!show"
class=
"count"
>
已发送
{{
count
}}
s
</span>
</el-button>
</el-button>
</div>
</div>
<div
class=
"groupcom inputpwd"
>
<div
class=
"groupcom inputpwd"
>
...
@@ -319,8 +319,9 @@ export default {
...
@@ -319,8 +319,9 @@ export default {
path
:
'/monitor'
path
:
'/monitor'
})
})
this
.
doAfterlogin
(
res
)
this
.
doAfterlogin
(
res
)
;
localStorage
[
"username"
]
=
this
.
loginBody
.
email
;
localStorage
[
"username"
]
=
this
.
loginBody
.
email
;
localStorage
[
"isLogin"
]
=
true
;
}
else
{
}
else
{
this
.
$notify
({
this
.
$notify
({
title
:
'提示'
,
title
:
'提示'
,
...
...
src/views/container.vue
View file @
a54e2b21
...
@@ -48,6 +48,11 @@
...
@@ -48,6 +48,11 @@
},
},
created
()
{
created
()
{
this
.
getPlatInfo
();
this
.
getPlatInfo
();
if
(
localStorage
.
getItem
(
"isLogin"
)
===
'false'
)
{
this
.
$router
.
push
({
path
:
'/'
});
}
},
},
methods
:
{
methods
:
{
getPlatInfo
()
{
getPlatInfo
()
{
...
...
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