Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
J
jd-vx-app
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
Administrator
jd-vx-app
Commits
632eb1db
Commit
632eb1db
authored
May 08, 2022
by
肖健
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
扫码逻辑调整
parent
cc64f8b0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
47 additions
and
35 deletions
+47
-35
main.vue
pages/main.vue
+47
-35
No files found.
pages/main.vue
View file @
632eb1db
...
@@ -59,10 +59,12 @@ export default {
...
@@ -59,10 +59,12 @@ export default {
uni
.
scanCode
({
uni
.
scanCode
({
success
:
function
(
res
)
{
success
:
function
(
res
)
{
let
path
=
res
.
path
let
path
=
res
.
path
console
.
log
(
path
+
"123"
)
let
token
=
uni
.
getStorageSync
(
'userToken'
);
if
(
path
)
{
if
(
token
){
let
xcxIndexPath
=
uni
.
getStorageSync
(
'xcxIndexPath'
)
let
opts
=
{
url
:
'/app/user/info'
,
method
:
'get'
}
console
.
info
(
xcxIndexPath
);
that
.
http
.
httpTokenRequest
(
opts
,
{}).
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
)
{
let
xcxIndexPath
=
res
.
data
.
data
.
xcxIndexPath
if
(
xcxIndexPath
)
{
if
(
xcxIndexPath
)
{
xcxIndexPath
=
path
.
replace
(
xcxIndexPath
,
''
).
replace
(
"?"
,
''
)
xcxIndexPath
=
path
.
replace
(
xcxIndexPath
,
''
).
replace
(
"?"
,
''
)
if
(
xcxIndexPath
.
indexOf
(
'scene'
)
>=
0
)
{
if
(
xcxIndexPath
.
indexOf
(
'scene'
)
>=
0
)
{
...
@@ -74,9 +76,7 @@ export default {
...
@@ -74,9 +76,7 @@ export default {
url
:
'/app/user/check/move/code'
,
url
:
'/app/user/check/move/code'
,
method
:
'post'
method
:
'post'
}
}
console
.
log
(
param
);
that
.
http
.
httpTokenRequest
(
opts
,
param
).
then
(
res
=>
{
that
.
http
.
httpTokenRequest
(
opts
,
param
).
then
(
res
=>
{
console
.
info
(
res
)
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
code
==
200
)
{
if
(
res
.
data
.
data
.
bindFlag
)
{
if
(
res
.
data
.
data
.
bindFlag
)
{
that
.
gotoMoveCar
(
scene
)
that
.
gotoMoveCar
(
scene
)
...
@@ -85,8 +85,20 @@ export default {
...
@@ -85,8 +85,20 @@ export default {
}
}
}
}
})
})
}
else
{
uni
.
showToast
({
title
:
'扫码失败'
,
icon
:
'none'
,
})
}
}
else
{
uni
.
showToast
({
title
:
'扫码失败'
,
icon
:
'none'
,
})
}
}
}
}
})
}
else
{
}
else
{
uni
.
showToast
({
uni
.
showToast
({
title
:
'扫码失败'
,
title
:
'扫码失败'
,
...
...
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