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
4eb9b87c
Commit
4eb9b87c
authored
Dec 17, 2019
by
李晓兵
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
''
parent
aed29c50
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
90 additions
and
81 deletions
+90
-81
uat.env.js
config/uat.env.js
+1
-1
main.js
src/main.js
+2
-2
body-check.vue
src/pages/contractSigning/body-check.vue
+44
-25
my-info.vue
src/pages/myInfo/my-info.vue
+2
-2
pwd-forgotten.vue
src/pages/pwd-forgotten.vue
+3
-24
regiester2.vue
src/pages/regiester2.vue
+3
-25
accessory-info.vue
src/pages/userBindNew/np/accessory-info.vue
+2
-2
hlsUtil.js
src/scripts/hlsUtil.js
+33
-0
No files found.
config/uat.env.js
View file @
4eb9b87c
...
...
@@ -10,5 +10,5 @@ module.exports = {
filePath
:
'"http://180.104.121.66:8088/r/api/app/fileViewSvc?sysName=XCMG_DEV&apiName=file_view&"'
,
ocrPath
:
'"http://180.104.121.66:8088/r/api"'
,
appId
:
'"com.xcmg.app"'
,
currentVersion
:
'"1.1.
1
"'
currentVersion
:
'"1.1.
3
"'
}
src/main.js
View file @
4eb9b87c
...
...
@@ -59,8 +59,8 @@ import Jpush from './scripts/jpushService'
import
Jmessage
from
'./scripts/jmessageService'
// if (process.env.CONFIG_ENV === 'uat') {
//
const VConsole = require('vconsole')
//
new VConsole() // eslint-disable-line
const
VConsole
=
require
(
'vconsole'
)
new
VConsole
()
// eslint-disable-line
// }
Vue
.
use
(
componentInstall
)
...
...
src/pages/contractSigning/body-check.vue
View file @
4eb9b87c
...
...
@@ -79,9 +79,11 @@ export default {
let
vm
=
this
let
onSuccess
=
function
(
mediaFiles
)
{
// 遍历获取录制的文件(iOS 只支持一次录制一个视频)
for
(
let
i
=
0
;
i
<
mediaFiles
.
length
;
i
++
)
{
/*
for (let i = 0; i < mediaFiles.length; i++) {
alert('录制成功!\n\n' + '文件名:' + mediaFiles[i].name + '\n' + '大小:' + mediaFiles[i].size + '\n\n' + 'localURL地址:' + mediaFiles[i].localURL + '\n\n' + 'fullPath地址:' + mediaFiles[i].fullPath)
}
}*/
console
.
log
(
'录制成功!
\
n
\
n'
+
'文件名:'
+
mediaFiles
[
0
].
name
+
'
\
n'
+
'大小:'
+
mediaFiles
[
0
].
size
+
'
\
n
\
n'
+
'localURL地址:'
+
mediaFiles
[
0
].
localURL
+
'
\
n
\
n'
+
'fullPath地址:'
+
mediaFiles
[
0
].
fullPath
)
vm
.
succesCall
(
mediaFiles
[
0
].
fullPath
)
}
let
onError
=
function
(
error
)
{
hlsPopup
.
showLongcenter
(
'录制失败,请重新录制'
)
...
...
@@ -89,7 +91,7 @@ export default {
hlsUtil
.
captureVideo
(
onSuccess
,
onError
)
},
/* vm.videoCapture = function () {
/* vm.videoCapture = function () {
document.addEventListener("deviceready", function () {
var options = {};
//平台判断
...
...
@@ -130,44 +132,56 @@ export default {
}
}, false);
};*/
}; */
succesCall
()
{
// 录制成功后进行检测
succesCall
(
fileUrl
)
{
// 录制成功后进行检测
let
vm
=
this
console
.
log
(
'fileUrl '
+
fileUrl
)
console
.
log
(
'sessionId '
+
vm
.
sessionId
)
let
url
=
process
.
env
.
ocrPath
+
'/baidu/ocr/videoFaceliveness'
let
param
=
{
file
:
vm
.
file
,
file
Url
:
fileUrl
,
sessionId
:
vm
.
sessionId
,
}
vm
.
hlsPopup
.
showLoading
(
'数据加载中'
)
vm
.
hlsHttp
.
post
(
url
,
param
).
then
(
function
(
res
)
{
vm
.
hlsPopup
.
showLoading
(
'正在检测'
)
hlsUtil
.
baiduOcrVideo
(
param
,
url
,
function
(
res
)
{
hlsPopup
.
hideLoading
()
console
.
log
(
'##########res '
+
JSON
.
stringify
(
res
))
if
(
res
.
result
.
result
.
thresholds
.
frr_1e
-
2
<
0.9
)
{
vm
.
hlsPopup
.
showLongcenter
(
'检测失败,请重新尝试'
)
}
else
{
vm
.
hlsPopup
.
showLongcenter
(
'检测成功'
)
}
})
/* vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
// eslint-disable-next-line space-infix-ops
if (res.result.thresholds.frr_1e-2 < 0.9) {
vm.hlsPopup.showLongcenter('检测失败,请重新尝试')
} else {
vm.hlsPopup.showLongcenter('检测成功')
}
})
})
*/
},
getCode
()
{
// 获取验证码
this
.
downNum
=
true
//
this.downNum = true
this
.
computeTime
()
this
.
time
=
60
this
.
lastTime
=
3
let
vm
=
this
// let url = process.env.ocrPath + '/baidu/ocr/videoSessioncode'
// let param = {}
// // vm.hlsPopup.showLoading('数据加载中')
// vm.hlsHttp.post(url, param).then(function (res) {
// // vm.hlsPopup.hideLoading()
// if (res.result === 'S') {
// vm.codeList = [...res.result.code]
// vm.sessionId = res.result.sessionId
// }
// })
vm
.
codeList
=
[
1
,
4
,
3
,
5
]
let
url
=
process
.
env
.
ocrPath
+
'/baidu/ocr/videoSessioncode'
let
param
=
{}
vm
.
hlsPopup
.
showLoading
(
'请稍后'
)
vm
.
hlsHttp
.
post
(
url
,
param
).
then
(
function
(
res
)
{
vm
.
hlsPopup
.
hideLoading
()
if
(
res
.
success
)
{
vm
.
codeList
=
[...
res
.
result
.
result
.
code
]
vm
.
sessionId
=
res
.
result
.
result
.
session_id
vm
.
downNum
=
true
}
})
/*let str = '098672'
vm.codeList = [...str]*/
},
computeTime
()
{
// 倒计时
let
vm
=
this
...
...
@@ -280,8 +294,12 @@ export default {
line-height: 40px;
}
}
.content{
display: flex;
flex-direction: column;
}
.top {
height:
60%
;
height:
340px
;
background-color: #f4f4f4;
display: flex;
justify-content: center;
...
...
@@ -293,6 +311,7 @@ export default {
flex-wrap: wrap;
img {
width: 80%;
height: 100%;
margin-top: 10px;
}
span {
...
...
@@ -304,7 +323,7 @@ export default {
}
}
.bottom {
height: 40%
;
flex: 1
;
background-color: #fff;
box-shadow: 0 -4px 10px 0 #e8e8e8;
display: flex;
...
...
src/pages/myInfo/my-info.vue
View file @
4eb9b87c
...
...
@@ -418,12 +418,12 @@ export default {
if
(
vum
.
Platform
.
isAndroid
())
{
this
.
hote_update_version
(
'发现新版本是否更新'
,
'http://hlsapp.hand-china.com/file/XCMG/www/android/www.zip'
'http://hlsapp.hand-china.com/file/XCMG/www
_myself
/android/www.zip'
)
}
else
{
this
.
hote_update_version
(
'发现新版本是否更新'
,
'http://hlsapp.hand-china.com/file/XCMG/www/android/www.zip'
'http://hlsapp.hand-china.com/file/XCMG/www
_myself
/android/www.zip'
)
}
},
...
...
src/pages/pwd-forgotten.vue
View file @
4eb9b87c
...
...
@@ -186,14 +186,13 @@ export default {
},
getVerifiedCode
()
{
let
vm
=
this
let
url
=
process
.
env
.
basePath
+
'sms_verify_post'
hlsPopup
.
showLongCenter
(
'测试验证码为123456'
)
/*let url = process.env.basePath + 'sms_verify_post'
let signcode = ('000000' + Math.floor(Math.random() * 999999)).slice(-6)
vm.captchaKey = signcode
let param = {
'info'
:
{
'phone': vm.phone_number,
'signcode': signcode,
},
}
vm.hlsPopup.showLoading('请稍候')
vm.hlsHttp.post(url, param).then(function (res) {
...
...
@@ -203,27 +202,7 @@ export default {
} else {
vm.hlsPopup.showLongCenter(res.message)
}
})
/* let url = process.env.rootPath + '/aliyun/sms'
let params = {
phoneNumber: vm.phone_number,
signName: '车租易',
templateCode: 'SMS_154585462',
}
hlsHttp.post(url, params).then(function (res) {
if (res.code == 'OK') {
vm.captchaKey = res.captchaKey
vm.phoneCodeTimeOut = false
setTimeout(function () {
vm.captchaKey = ''
vm.phoneCodeTimeOut = true
}, 300000)
hlsPopup.showLongBottom('验证码发送成功!')
} else {
hlsPopup.showLongBottom(res.message)
}
}
) */
})*/
},
},
}
...
...
src/pages/regiester2.vue
View file @
4eb9b87c
...
...
@@ -218,15 +218,13 @@ export default {
},
getVerifiedCode
()
{
let
vm
=
this
//
hlsPopup.showLongCenter('测试验证码为123456')
let
url
=
process
.
env
.
basePath
+
'sms_verify_post'
hlsPopup
.
showLongCenter
(
'测试验证码为123456'
)
/*
let url = process.env.basePath + 'sms_verify_post'
let signcode = ('000000' + Math.floor(Math.random() * 999999)).slice(-6)
vm.captchaKey = signcode
let param = {
'info'
:
{
'phone': vm.phone_number,
'signcode': signcode,
},
}
vm.hlsPopup.showLoading('请稍候')
vm.hlsHttp.post(url, param).then(function (res) {
...
...
@@ -236,27 +234,7 @@ export default {
} else {
vm.hlsPopup.showLongCenter(res.message)
}
})
/* let url = process.env.rootPath + '/aliyun/sms'
let params = {
phoneNumber: vm.phone_number,
signName: '车租易',
templateCode: 'SMS_154585462',
}
hlsHttp.post(url, params).then(function (res) {
if (res.code == 'OK') {
vm.captchaKey = res.captchaKey
vm.phoneCodeTimeOut = false
setTimeout(function () {
vm.captchaKey = ''
vm.phoneCodeTimeOut = true
}, 300000)
hlsPopup.showLongBottom('验证码发送成功!')
} else {
hlsPopup.showLongBottom(res.message)
}
}
) */
})*/
},
},
}
...
...
src/pages/userBindNew/np/accessory-info.vue
View file @
4eb9b87c
...
...
@@ -9,7 +9,7 @@
<h-content>
<div
class=
"userInfo"
>
附件信息
</div>
<div
v-for=
"(list, index) in cddItemList"
:key=
"index"
class=
"card"
>
<span
style=
"color:#1D3FFF"
>
{{
list
.
description
}}
</span>
<span
class=
"card-desc"
style=
"color:#1D3FFF"
>
{{
list
.
description
}}
</span>
<div
class=
"img-content"
>
<!--待上传图片列表-->
<div
...
...
@@ -825,7 +825,7 @@ export default {
display: flex;
flex-direction: column;
span
{
.card-desc
{
color: #656464;
font-size: 13px;
line-height: 18px;
...
...
src/scripts/hlsUtil.js
View file @
4eb9b87c
...
...
@@ -524,6 +524,39 @@ export default {
ft
.
upload
(
path
,
url
,
uploadSuccess
,
error
,
options
)
},
/**
* 百度OCR活体检测
* @param file
* @param url
* @param success
*/
baiduOcrVideo
:
function
(
file
,
postUrl
,
success
)
{
let
path
=
file
.
fileUrl
let
name
=
path
.
substr
(
path
.
lastIndexOf
(
'/'
)
+
1
)
let
url
=
encodeURI
(
postUrl
)
let
options
=
new
FileUploadOptions
()
// eslint-disable-line
options
.
headers
=
{
'Authorization'
:
'Bearer '
+
window
.
localStorage
.
access_token
,
}
options
.
fileKey
=
'file'
options
.
fileName
=
name
options
.
mimeType
=
'multipart/form-date'
options
.
params
=
{
'sessionId'
:
file
.
sessionId
,
}
let
ft
=
new
FileTransfer
()
// eslint-disable-line
function
uploadSuccess
(
message
)
{
let
res
=
JSON
.
parse
(
message
.
response
)
success
(
res
)
}
function
error
(
e
)
{
this
.
hlsPopup
.
showLongCenter
(
'识别失败'
)
}
ft
.
upload
(
path
,
url
,
uploadSuccess
,
error
,
options
)
},
/**
*
* @param x 输入的数字
...
...
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