Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation
This project
Loading...
Sign in
罗鑫霖
/
vion-tools
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit ff23185a
authored
May 25, 2023
by
李君
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
优化
1 parent
b4bfa343
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
44 additions
and
45 deletions
src/Request/PublicAxiosInstance.js
src/views/FeatureMatchingAccuracy/FeatureMatchingAccuracy.vue
src/views/FeatureMatchingAccuracy/FeatureMatchingAccuracyApi.js
src/views/FeatureMatchingAccuracy/addPerson.vue
src/views/FeatureMatchingAccuracy/editPerson.vue
src/views/SnapshotCluster/ClusterResult/ClusterResult.vue
src/views/SnapshotCluster/SnapshotRecord/SnapshotRecord.vue
src/Request/PublicAxiosInstance.js
View file @
ff23185
...
...
@@ -14,7 +14,7 @@ const axiosInstance = axios.create(
// 请求拦截器
axiosInstance
.
interceptors
.
request
.
use
(
config
=>
{
// Cookies.set('atoken','
57ac28e0-c2d9-4287-8d20-bc0332372dad
')
// Cookies.set('atoken','
33b0df7a-e5c6-49c3-b549-959179cd5904
')
if
(
!
Cookies
.
get
(
'atoken'
)){
ElMessage
({
message
:
`登录过期,请重新登录`
,
...
...
src/views/FeatureMatchingAccuracy/FeatureMatchingAccuracy.vue
View file @
ff23185
This diff is collapsed.
Click to expand it.
src/views/FeatureMatchingAccuracy/FeatureMatchingAccuracyApi.js
View file @
ff23185
...
...
@@ -96,6 +96,16 @@ class FeatureMatchingAccuracy {
}
)
}
addMatchReg
(
data
){
return
axiosInstance
.
request
(
{
method
:
'POST'
,
url
:
`/feature/match/reg`
,
data
:
data
}
)
}
}
const
FeatureMatchingAccuracyApi
=
new
FeatureMatchingAccuracy
()
...
...
src/views/FeatureMatchingAccuracy/addPerson.vue
View file @
ff23185
This diff is collapsed.
Click to expand it.
src/views/FeatureMatchingAccuracy/editPerson.vue
View file @
ff23185
<
template
>
<a-modal
title=
"
编辑注册人员
"
title=
"
添加注册样本图
"
v-model:visible=
"isVisible"
width=
"1500px"
:dialog-style=
"
{ top: '20px',height:'90%' }"
class="detail-modal"
@cancel = 'onCancel()'
>
<div
style=
"height: 700px;"
>
<a-form
:model=
"formObj"
layout=
"inline"
:label-col=
"
{ style: { width: '100px' } }">
<a-form-item
label=
"姓名:"
>
<a-input
v-model:value=
"formObj.name"
style=
"width: 500px"
>
</a-input>
</a-form-item>
<a-form-item
label=
"描述:"
>
<a-input
v-model:value=
"formObj.dec"
style=
"width: 500px"
>
</a-input>
</a-form-item>
<a-form-item
label=
"选择样本图:"
class=
"pictures"
>
<a-form-item
class=
"pictures"
>
<a-tabs
type=
"card"
v-model:activeKey=
"activeKey"
>
<a-tab-pane
key=
"1"
tab=
"本地上传"
>
<a-upload
...
...
@@ -85,11 +78,12 @@
<el-row
v-for=
"row in getPagedList(person.perrsonList, 8)"
>
<el-col
:span=
"3"
v-for=
"item in row"
>
<div
style=
"margin: 0 5px"
class=
"picBox"
>
<
el-checkbox
class=
"checkBox"
v-model=
"item.checked"
></el-checkbox
>
<
!--
<el-checkbox
class=
"checkBox"
v-model=
"item.checked"
></el-checkbox>
--
>
<el-image
:src=
"item.picture_url"
:fit=
"'fill'"
class=
"single-image"
>
</el-image>
<el-button
type=
"primary"
:disabled=
"item.checked?true:false"
class=
"checkBox"
@
click=
"onConfirm(item)"
>
选中
</el-button>
</div>
</el-col>
</el-row>
...
...
@@ -116,7 +110,7 @@
</div>
<
template
#
footer
>
<a-button
@
click=
"onCancel"
>
返回
</a-button>
<
a-button
@
click=
"onConfirm"
type=
"primary"
>
确定
</a-button
>
<
!--
<a-button
@
click=
"onConfirm"
type=
"primary"
>
确定
</a-button>
--
>
</
template
>
</a-modal>
</template>
...
...
@@ -184,57 +178,42 @@ export default {
}
)
}
const
disabledPicList
=
ref
([])
const
initDialog
=
function
(
parmas
)
{
accountId
.
value
=
parmas
.
accountId
;
mallId
.
value
=
parmas
.
mallId
;
formObj
.
name
=
parmas
.
name
;
formObj
.
dec
=
parmas
.
description
;
formObj
.
id
=
parmas
.
id
;
// checkGateList.value = parmas.faceIds
getGateList
()
disabledPicList
.
value
=
parmas
.
faceIds
||
[]
isVisible
.
value
=
true
;
};
const
onCancel
=
()
=>
{
if
(
isAdd
.
value
){
refreshParentTable
()
}
isVisible
.
value
=
false
;
};
const
refreshParentTable
=
function
(){
context
.
emit
(
'refreshParentTable'
)
}
const
onConfirm
=
function
(){
let
faceIds
=
[]
dataList
.
value
.
forEach
((
itemPerson
)
=>
{
itemPerson
.
perrsonList
.
forEach
((
item
)
=>
{
if
(
item
.
checked
)
{
faceIds
.
push
(
item
.
id
)
}
})
})
if
(
faceIds
.
length
<
1
&&
checkGateList
.
length
<
1
){
ElMessage
({
message
:
`请选择图片`
,
type
:
'warning'
})
return
false
;
}
const
isAdd
=
ref
(
false
)
const
onConfirm
=
function
(
resData
){
const
data
=
filterEmptyValueInObject
(
{
// accountId: accountId.value,
// mallId: mallId.value,
name
:
formObj
.
name
,
description
:
formObj
.
dec
,
faceIds
:
faceIds
.
length
<
1
?
checkGateList
.
value
:
faceIds
,
faceIds
:[
resData
.
id
],
id
:
formObj
.
id
}
)
FeatureMatchingAccuracyApi
.
editMatch
(
data
).
then
(
FeatureMatchingAccuracyApi
.
addMatchReg
(
data
).
then
(
(
r
)
=>
{
if
(
r
.
msg_code
==
200
){
ElMessage
({
message
:
r
.
msg_info
,
type
:
'success'
})
refreshParentTable
()
isVisible
.
value
=
false
isAdd
.
value
=
true
;
disabledPicList
.
value
.
push
(
resData
.
id
)
clickSearch
()
}
else
{
ElMessage
({
message
:
r
.
msg_info
,
...
...
@@ -300,7 +279,7 @@ export default {
r
.
data
.
persons
.
forEach
((
itemPerson
)
=>
{
itemPerson
.
expand
=
false
itemPerson
.
perrsonList
.
forEach
((
item
)
=>
{
if
(
checkGate
List
.
value
.
includes
(
item
.
id
)){
if
(
disabledPic
List
.
value
.
includes
(
item
.
id
)){
item
.
checked
=
true
;
}
else
{
item
.
checked
=
false
;
...
...
@@ -362,7 +341,8 @@ export default {
expandChange
,
clickCheck
,
refreshParentTable
,
picSearch
picSearch
,
disabledPicList
};
},
};
...
...
@@ -419,9 +399,18 @@ export default {
.picBox
{
position
:
relative
;
}
.picBox
:hover
.checkBox
{
display
:
block
;
}
.checkBox
{
display
:
none
;
width
:
80px
;
height
:
30px
;
position
:
absolute
;
left
:
5
px
;
left
:
0
px
;
top
:
0
;
right
:
0
;
bottom
:
0
;
margin
:
auto
;
}
</
style
>
src/views/SnapshotCluster/ClusterResult/ClusterResult.vue
View file @
ff23185
...
...
@@ -142,7 +142,7 @@
</el-image>
<div>
时间:
{{
item
.
counttime
}}
</div>
<div>
人员类型:
{{
item
.
person_type
==
1
?
'店员'
:(
item
.
person_type
==
0
?
'顾客'
:
'未知'
)
}}
</div>
<div>
性别:
{{
formatGender
(
item
.
gender
)
}}
</div>
<div>
性别:
{{
formatGender
(
item
.
gender
)
}}
(
{{
item
.
age
}}
)
</div>
<div
class=
"direction"
:class=
"'direction'+item.direction"
>
方向:
{{
formatDirection
(
item
.
direction
)
}}
</div>
<div>
地点:
{{
item
.
gate_name
}}
</div>
</div>
...
...
src/views/SnapshotCluster/SnapshotRecord/SnapshotRecord.vue
View file @
ff23185
...
...
@@ -118,7 +118,7 @@
</el-image>
<div>
时间:
{{
item
.
counttime
}}
</div>
<div>
人员类型:
{{
item
.
person_type
==
1
?
'店员'
:(
item
.
person_type
==
0
?
'顾客'
:
'未知'
)
}}
</div>
<div>
性别:
{{
formatGender
(
item
.
gender
)
}}
</div>
<div>
性别:
{{
formatGender
(
item
.
gender
)
}}
(
{{
item
.
age
}}
)
</div>
<div
class=
"direction"
:class=
"'direction'+item.direction"
>
方向:
{{
formatDirection
(
item
.
direction
)
}}
</div>
<div>
地点:
{{
item
.
gate_name
}}
</div>
</div>
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment