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
6a11cdd1
Commit
6a11cdd1
authored
Oct 16, 2019
by
李晓兵
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
'附件上传'
parent
a2703204
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
59 additions
and
21 deletions
+59
-21
dev.env.js
config/dev.env.js
+1
-0
uat.env.js
config/uat.env.js
+1
-0
deleteIcon.png
src/assets/userBind/deleteIcon.png
+0
-0
naturePerson.vue
src/pages/userBind/np/naturePerson.vue
+57
-21
No files found.
config/dev.env.js
View file @
6a11cdd1
...
@@ -10,6 +10,7 @@ module.exports = merge(prodEnv, {
...
@@ -10,6 +10,7 @@ module.exports = merge(prodEnv, {
loginPath
:
'"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=" '
,
loginPath
:
'"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=" '
,
basePath
:
'"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="'
,
basePath
:
'"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="'
,
rootPath
:
'"http://180.104.121.66:8088/r/api"'
,
rootPath
:
'"http://180.104.121.66:8088/r/api"'
,
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"'
,
ocrPath
:
'"http://180.104.121.66:8088/r/api"'
,
file_url
:
'"http://hlsapp.hand-china.com/file/"'
,
file_url
:
'"http://hlsapp.hand-china.com/file/"'
,
appId
:
'"com.hls.easy.car"'
,
appId
:
'"com.hls.easy.car"'
,
...
...
config/uat.env.js
View file @
6a11cdd1
...
@@ -7,6 +7,7 @@ module.exports = {
...
@@ -7,6 +7,7 @@ module.exports = {
loginPath
:
'"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=" '
,
loginPath
:
'"http://180.104.121.66:8088/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=" '
,
basePath
:
'"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="'
,
basePath
:
'"http://180.104.121.66:8088/r/api/interface?sysName=XCMG_DEV&apiName="'
,
rootPath
:
'"http://180.104.121.66:8088/r/api"'
,
rootPath
:
'"http://180.104.121.66:8088/r/api"'
,
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"'
,
ocrPath
:
'"http://180.104.121.66:8088/r/api"'
,
file_url
:
'"http://hlsapp.hand-china.com/file/"'
,
file_url
:
'"http://hlsapp.hand-china.com/file/"'
,
appId
:
'"com.hls.easy.car"'
,
appId
:
'"com.hls.easy.car"'
,
...
...
src/assets/userBind/deleteIcon.png
0 → 100644
View file @
6a11cdd1
394 Bytes
src/pages/userBind/np/naturePerson.vue
View file @
6a11cdd1
...
@@ -198,13 +198,19 @@
...
@@ -198,13 +198,19 @@
<span>
{{
list
.
description
}}
</span>
<span>
{{
list
.
description
}}
</span>
<div
class=
"img-content"
>
<div
class=
"img-content"
>
<!--待上传图片列表-->
<!--待上传图片列表-->
<div
v-for=
"(list, index) in upload_list"
:key=
"index"
>
<div
v-for=
"(item, index) in upload_list"
v-if=
"item.check_id==list.check_id"
:key=
"index"
class=
"card-upload"
>
<img
:src=
"list.picture"
>
<img
:src=
"item.picture"
>
<div
class=
"close"
@
click=
"delete_pic(item.attachment_id)"
>
<img
src=
"@/assets/userBind/deleteIcon.png"
>
</div>
</div>
</div>
<!--从服务器上下载的图片-->
<!--从服务器上下载的图片-->
<div
v-for=
"item in dowload_list"
class=
"card-upload"
>
<div
v-for=
"item in dowload_list"
>
<div
v-for=
"(pic, index) in item"
:key=
"index"
>
<div
v-for=
"(pic, index) in item"
:key=
"index"
v-if=
"pic.check_id==list.check_id"
class=
"card-upload"
>
<img
:src=
"item.url"
>
<img
:src=
"pic.url"
>
<div
class=
"close"
@
click=
"delete_pic(pic.attachment_id)"
>
<img
src=
"@/assets/userBind/deleteIcon.png"
>
</div>
</div>
</div>
</div>
</div>
<div
class=
"card-upload"
@
click=
"imgUploadShow(list.check_id)"
>
<div
class=
"card-upload"
@
click=
"imgUploadShow(list.check_id)"
>
...
@@ -431,19 +437,21 @@ export default {
...
@@ -431,19 +437,21 @@ export default {
}
}
})
})
},
},
load_picture
(
check_id
){
load_picture
(
check_id
,
index
)
{
debugger
let
vm
=
this
let
vm
=
this
let
url
=
process
.
env
.
basePath
+
'attachment_list_query'
let
url
=
process
.
env
.
basePath
+
'attachment_list_query'
+
'&index'
+
index
// 附件查询
let
param
=
{
let
param
=
{
check_id
:
check_id
,
check_id
:
check_id
,
}
}
hlsPopup
.
showLoading
(
'请稍候'
)
hlsPopup
.
showLoading
(
'请稍候'
)
vm
.
$post
(
url
,
param
).
then
(
function
(
res
)
{
vm
.
$post
(
url
,
param
).
then
(
function
(
res
)
{
vm
.
hlsPopup
.
hideLoading
()
vm
.
hlsPopup
.
hideLoading
()
console
.
log
(
'%%%%%%%%%%%%'
+
res
)
if
(
res
.
result
===
'S'
)
{
if
(
res
.
result
===
'S'
)
{
console
.
log
(
'**********'
+
res
.
lists
)
res
.
lists
.
forEach
(
item
=>
{
item
[
'url'
]
=
process
.
env
.
filePath
+
'attachment_id='
+
item
.
attachment_id
+
'&access_token='
+
window
.
localStorage
.
access_token
})
vm
.
dowload_list
.
push
(
res
.
lists
)
console
.
log
(
JSON
.
stringify
(
vm
.
dowload_list
))
}
else
{
}
else
{
hlsPopup
.
showLongCenter
(
res
.
message
)
hlsPopup
.
showLongCenter
(
res
.
message
)
}
}
...
@@ -471,8 +479,8 @@ export default {
...
@@ -471,8 +479,8 @@ export default {
if
(
res
.
result
===
'S'
)
{
if
(
res
.
result
===
'S'
)
{
vm
.
cddItemList
=
[...
res
.
lists
]
vm
.
cddItemList
=
[...
res
.
lists
]
// 查询图片
// 查询图片
vm
.
cddItemList
.
forEach
(
item
=>
{
vm
.
cddItemList
.
forEach
(
(
item
,
index
)
=>
{
vm
.
load_picture
(
item
.
check_id
)
vm
.
load_picture
(
item
.
check_id
,
index
)
})
})
}
}
})
})
...
@@ -540,7 +548,7 @@ export default {
...
@@ -540,7 +548,7 @@ export default {
}
}
},
},
// 图片上传入口
// 图片上传入口
imgUploadShow
(
check_id
)
{
imgUploadShow
(
check_id
)
{
let
vm
=
this
let
vm
=
this
hlsPopup
.
showActionSheet
({
hlsPopup
.
showActionSheet
({
titleText
:
'请选择照片'
,
titleText
:
'请选择照片'
,
...
@@ -554,7 +562,7 @@ export default {
...
@@ -554,7 +562,7 @@ export default {
},
},
})
})
},
},
imgUploadOpenCamera
(
check_id
)
{
imgUploadOpenCamera
(
check_id
)
{
let
vm
=
this
let
vm
=
this
let
obj
=
{
let
obj
=
{
'pkvalue'
:
check_id
,
'pkvalue'
:
check_id
,
...
@@ -562,7 +570,7 @@ export default {
...
@@ -562,7 +570,7 @@ export default {
'picture'
:
''
,
'picture'
:
''
,
'filePath'
:
''
,
'filePath'
:
''
,
'attachment_id'
:
''
,
'attachment_id'
:
''
,
'user_id'
:
1
'user_id'
:
1
,
}
}
let
cameraoptions
=
{
let
cameraoptions
=
{
quality
:
100
,
quality
:
100
,
...
@@ -580,12 +588,13 @@ export default {
...
@@ -580,12 +588,13 @@ export default {
}
}
hlsUtil
.
openCamera
(
cameraoptions
,
success
,
error
)
hlsUtil
.
openCamera
(
cameraoptions
,
success
,
error
)
},
},
imgUploadTakePicture
(
check_id
)
{
imgUploadTakePicture
(
check_id
)
{
let
vm
=
this
let
vm
=
this
let
cameraoptions
=
{
let
cameraoptions
=
{
quality
:
100
,
quality
:
100
,
}
}
let
success
=
function
(
imgUrl
)
{
let
success
=
function
(
imgUrl
)
{
var
list
=
[]
for
(
let
i
=
0
;
i
<
imgUrl
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
imgUrl
.
length
;
i
++
)
{
let
obj
=
{
let
obj
=
{
'pkvalue'
:
check_id
,
'pkvalue'
:
check_id
,
...
@@ -593,11 +602,10 @@ export default {
...
@@ -593,11 +602,10 @@ export default {
'picture'
:
''
,
'picture'
:
''
,
'filePath'
:
''
,
'filePath'
:
''
,
'attachment_id'
:
''
,
'attachment_id'
:
''
,
'user_id'
:
1
'user_id'
:
1
,
}
}
obj
.
picture
=
imgUrl
[
i
]
obj
.
picture
=
imgUrl
[
i
]
obj
.
filePath
=
imgUrl
[
i
]
obj
.
filePath
=
imgUrl
[
i
]
var
list
=
[]
list
.
push
(
obj
)
list
.
push
(
obj
)
}
}
// 拍完一张立马执行保存图片逻辑
// 拍完一张立马执行保存图片逻辑
...
@@ -625,7 +633,7 @@ export default {
...
@@ -625,7 +633,7 @@ export default {
for
(
var
i
=
0
;
i
<
list
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
list
.
length
;
i
++
)
{
let
uploadSuccess
=
function
(
res
)
{
let
uploadSuccess
=
function
(
res
)
{
if
(
res
.
result
===
'S'
)
{
if
(
res
.
result
===
'S'
)
{
alert
(
'返回结果 '
+
JSON
.
stringify
(
res
.
response
))
alert
(
'返回结果 '
+
JSON
.
stringify
(
res
.
response
))
alreadyUploadNum
++
alreadyUploadNum
++
for
(
var
j
=
0
;
j
<
list
.
length
;
j
++
)
{
for
(
var
j
=
0
;
j
<
list
.
length
;
j
++
)
{
if
(
list
[
j
].
filePath
===
res
.
response
.
filePath
)
{
if
(
list
[
j
].
filePath
===
res
.
response
.
filePath
)
{
...
@@ -647,6 +655,24 @@ export default {
...
@@ -647,6 +655,24 @@ export default {
hlsPopup
.
hideLoading
()
hlsPopup
.
hideLoading
()
}
}
},
},
// 删除图片
delete_pic
(
attachment_id
){
hlsPopup
.
showLongCenter
(
'接口还没写'
)
/*let vm = this
let url = process.env.basePath + 'attachment_list_query'
let param = {
attachment_id: attachment_id,
}
hlsPopup.showLoading('请稍候')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
} else {
hlsPopup.showLongCenter(res.message)
}
})*/
},
/* uploadIdCardFront () {
/* uploadIdCardFront () {
let vm = this
let vm = this
let url = process.env.basePath + 'attachment_upload'
let url = process.env.basePath + 'attachment_upload'
...
@@ -1217,7 +1243,17 @@ export default {
...
@@ -1217,7 +1243,17 @@ export default {
align-items: center;
align-items: center;
margin-top: 12px;
margin-top: 12px;
margin-left: 12px;
margin-left: 12px;
// float: left;
float: left;
.close {
position: absolute;
color: #F96F68;
margin-top: -45px;
margin-left: 40px;
img{
width: 14px;
height: 14px;
}
}
img {
img {
width: 88px;
width: 88px;
height: 88px;
height: 88px;
...
...
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