Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hls-xcmg-vue-app
Project
Project
Details
Activity
Releases
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
xugong
hls-xcmg-vue-app
Commits
f4384277
Commit
f4384277
authored
Jan 19, 2021
by
Jennie Shi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
认证逻辑修改
parent
3185e20c
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
68 additions
and
39 deletions
+68
-39
uat.env.js
config/uat.env.js
+1
-1
my-info.vue
src/pages/myInfo/my-info.vue
+67
-38
No files found.
config/uat.env.js
View file @
f4384277
...
...
@@ -11,5 +11,5 @@ module.exports = {
ocrPath
:
'"http://180.104.121.66:8088/r/api"'
,
fileUploadSvcPath
:
'"http://180.104.121.66:8088/r/api/app/fileUploadSvc?sysName=XCMG_UAT&apiName="'
,
appId
:
'"com.xcmg.app.dev"'
,
currentVersion
:
'"2.9.
3
"'
currentVersion
:
'"2.9.
4
"'
}
src/pages/myInfo/my-info.vue
View file @
f4384277
...
...
@@ -229,6 +229,7 @@ export default {
bp_type_n
:
''
,
approveBtn
:
false
,
elecStatus
:
false
,
authFlag
:
false
,
roleSwitchFlag
:
false
,
// 选择角色模态框显示标志
multiRoleList
:
[],
// 查到的多角色
type
:
[
...
...
@@ -1034,6 +1035,8 @@ export default {
// 认证入口
async
certification
()
{
let
vm
=
this
let
authFlag
=
await
vm
.
getNpCertificationUrl
()
if
(
authFlag
===
true
)
{
if
(
vm
.
bp_id
)
{
if
(
vm
.
bp_identity
===
'NP_NO'
||
vm
.
bp_identity
===
'ORG_L_NO'
||
vm
.
bp_identity
===
'ORG_AUTH_NO'
)
{
let
url
=
process
.
env
.
basePath
+
'bp_query'
...
...
@@ -1054,7 +1057,7 @@ export default {
function
(
suc
)
{
let
success
=
JSON
.
parse
(
suc
)
if
(
success
.
code
===
1
)
{
vm
.
getNpCertificationUrl
()
vm
.
userQuery
()
}
},
function
(
reason
)
{
...
...
@@ -1072,7 +1075,10 @@ export default {
hlsPopup
.
showLongCenter
(
'您已认证通过'
)
}
}
else
{
hlsPopup
.
showLongCenter
(
'请先进行用户绑定'
)
hlsPopup
.
showLongCenter
(
'请先进行用户绑定!'
)
}
}
else
if
(
authFlag
===
false
)
{
hlsPopup
.
showLongCenter
(
'用户已绑定!'
)
}
},
async
getNpCertificationUrl
()
{
...
...
@@ -1085,14 +1091,37 @@ export default {
let
res
=
await
vm
.
$post
(
url
,
param
)
hlsPopup
.
hideLoading
()
if
(
res
.
info
.
code
===
0
&&
res
.
info
.
data
.
authUrl
)
{
hlsPopup
.
showLongCenter
(
'绑定失败!'
)
// hlsPopup.showLongCenter('绑定失败!')
return
true
}
else
if
(
res
.
info
.
code
===
0
&&
res
.
info
.
data
.
openId
)
{
// hlsPopup.showLongCenter('绑定成功!')
// vm.userQuery()
return
false
}
else
{
hlsPopup
.
showLongCenter
(
res
.
info
.
msg
)
return
''
}
},
// 获取企业认证url
async
getOrgCertificationUrl
()
{
let
vm
=
this
let
url
=
$config
.
basePath
+
'auth_company_sign'
let
param
=
{
phone
:
vm
.
user_phone
,
}
hlsPopup
.
showLoading
(
'请稍候'
)
let
res
=
await
vm
.
$post
(
url
,
param
)
hlsPopup
.
hideLoading
()
if
((
res
.
info
.
code
===
0
)
&&
(
res
.
info
.
data
.
authUrl
))
{
hlsPopup
.
showLongCenter
(
'绑定失败!'
)
}
else
if
((
res
.
info
.
code
===
0
)
&&
(
res
.
info
.
data
.
openId
))
{
hlsPopup
.
showLongCenter
(
'绑定成功!'
)
vm
.
userQuery
()
}
else
{
hlsPopup
.
show
LongCente
r
(
res
.
info
.
msg
)
hlsPopup
.
show
Erro
r
(
res
.
info
.
msg
)
}
},
goAbout
()
{
this
.
$router
.
push
({
name
:
'About'
,
...
...
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