Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
NFT
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hanfeng zhang
NFT
Commits
2e27d560
Commit
2e27d560
authored
Jul 05, 2021
by
chenqikuai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修复滑动验证bug
parent
95e7b3c6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
3 deletions
+19
-3
index.vue
src/components/common/SlideValidator/index.vue
+8
-0
Login.vue
src/view/Auth/Login/Login.vue
+9
-1
types.ts
src/view/Auth/Login/types.ts
+2
-2
No files found.
src/components/common/SlideValidator/index.vue
View file @
2e27d560
...
...
@@ -85,6 +85,14 @@ export default {
.
getElementsByTagName
(
"html"
)[
0
]
.
addEventListener
(
"touchend"
,
this
.
moseUpFn
);
},
beforeDestroy
()
{
document
.
getElementsByTagName
(
"html"
)[
0
]
.
removeEventListener
(
"touchmove"
,
this
.
mouseMoveFn
);
document
.
getElementsByTagName
(
"html"
)[
0
]
.
removeEventListener
(
"touchend"
,
this
.
moseUpFn
);
},
};
</
script
>
...
...
src/view/Auth/Login/Login.vue
View file @
2e27d560
...
...
@@ -67,7 +67,12 @@
</div>
<transition
name=
"fade"
mode=
"out-in"
>
<SlideValidator
v-if=
"accountType !== undefined && loginWay !== undefined"
v-if=
"
accountType !== undefined &&
loginWay !== undefined &&
accountType !== eAccountType.NO_REG
"
:key=
"randomNum"
@
confirm=
"handleSlideConfirm"
class=
"my-3"
/>
...
...
@@ -203,6 +208,7 @@ export default Vue.extend({
rememberPwdChecked
:
false
,
btnLoading
:
false
,
slideConfirmed
:
false
,
randomNum
:
Math
.
random
(),
};
},
methods
:
{
...
...
@@ -261,6 +267,8 @@ export default Vue.extend({
}
}
catch
(
err
)
{}
this
.
btnLoading
=
false
;
this
.
randomNum
=
Math
.
random
();
this
.
slideConfirmed
=
false
;
},
handleClickUserAgreement
()
{
// 展示用户协议
...
...
src/view/Auth/Login/types.ts
View file @
2e27d560
...
...
@@ -38,4 +38,5 @@ export interface iLoginCmpProps {
loginByPwdFunc
:
tLoginByPwdFunc
;
sendSmsFunc
:
tSendSmsFunc
,
sendVoiceFunc
:
tSendVoiceFunc
,
}
\ No newline at end of file
}
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