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 dd3c009b
authored
Mar 22, 2025
by
Tianqing Liu
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
feat: 增加加载当前页面,所有图片功能
1 parent
2ccbd4b6
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
36 additions
and
1 deletions
src/views/SnapshotCluster/SnapshotRecord/SnapshotRecord.vue
src/views/SnapshotCluster/SnapshotRecord/SnapshotRecord.vue
View file @
dd3c009
...
@@ -151,6 +151,9 @@
...
@@ -151,6 +151,9 @@
<a-form-item
style=
"padding: 5px 0"
>
<a-form-item
style=
"padding: 5px 0"
>
<a-button
type=
"primary"
@
click=
"batchesResultFun"
>
同组客流
</a-button>
<a-button
type=
"primary"
@
click=
"batchesResultFun"
>
同组客流
</a-button>
</a-form-item>
</a-form-item>
<a-form-item
style=
"padding: 5px 0"
>
<a-button
type=
"primary"
:loading=
"allImagesLoading"
@
click=
"loadAllImages"
>
加载当页图片
</a-button>
</a-form-item>
</a-form>
</a-form>
<div
v-loading=
"isLoading"
>
<div
v-loading=
"isLoading"
>
...
@@ -257,6 +260,7 @@ import {computed, reactive, ref, toRaw} from 'vue'
...
@@ -257,6 +260,7 @@ import {computed, reactive, ref, toRaw} from 'vue'
import
snapshotRecordApi
from
'@/views/SnapshotCluster/SnapshotRecord/SnapshotRecordApi'
import
snapshotRecordApi
from
'@/views/SnapshotCluster/SnapshotRecord/SnapshotRecordApi'
import
{
isArray
}
from
'@/PublicUtil/Judgment'
import
{
isArray
}
from
'@/PublicUtil/Judgment'
import
moment
from
'moment'
import
moment
from
'moment'
import
{
flattenDeep
}
from
'lodash'
import
{
filterEmptyValueInObject
,
formatDate
,
formatTime
,
getPagedList
}
from
'@/PublicUtil/PublicUtil'
import
{
filterEmptyValueInObject
,
formatDate
,
formatTime
,
getPagedList
}
from
'@/PublicUtil/PublicUtil'
// import imgDialog from '../imgDialog.vue'
// import imgDialog from '../imgDialog.vue'
import
{
ElMessage
}
from
'element-plus'
import
{
ElMessage
}
from
'element-plus'
...
@@ -1364,7 +1368,15 @@ export default {
...
@@ -1364,7 +1368,15 @@ export default {
// 查询小平台单个图片
// 查询小平台单个图片
const
getDataSourcesImg
=
(
unid
)
=>
{
const
getDataSourcesImg
=
(
unid
)
=>
{
console
.
log
(
'getDataSourcesImg'
,
unid
)
console
.
log
(
'getDataSourcesImg'
,
unid
)
snapshotRecordApi
.
operateGetPics
({
unids
:[
unid
]}).
then
((
r
)
=>
{})
let
targetParams
=
[]
if
(
Array
.
isArray
(
unid
))
{
targetParams
=
unid
}
else
{
targetParams
=
[
unid
]
}
snapshotRecordApi
.
operateGetPics
({
unids
:
targetParams
}).
then
((
r
)
=>
{}).
finally
(()
=>
{
allImagesLoading
.
value
=
false
})
setTimeout
(()
=>
{
setTimeout
(()
=>
{
confirmSearch
()
confirmSearch
()
},
2000
)
},
2000
)
...
@@ -1469,6 +1481,27 @@ export default {
...
@@ -1469,6 +1481,27 @@ export default {
__main
()
__main
()
const
allImagesLoading
=
ref
(
false
)
const
loadAllImages
=
function
()
{
/**
* 1.获取当页的unids,过滤已加载的图片
* 2.调用接口,拉取图片
* 3.刷新列表页面
*/
// console.log('pagedTableDataList', pagedTableDataList)
const
allList
=
flattenDeep
(
pagedTableDataList
.
value
)
const
paramsUnid
=
[]
allList
.
forEach
(
item
=>
{
if
(
!
item
.
picture_url
)
{
paramsUnid
.
push
(
item
.
unid
)
}
})
console
.
log
(
'loadAllImages'
,
allList
,
paramsUnid
)
allImagesLoading
.
value
=
true
getDataSourcesImg
(
paramsUnid
.
slice
(
0
,
2
))
// getDataSourcesImg(paramsUnid)
}
return
{
return
{
// scalar
// scalar
dataSources
,
dataSources
,
...
@@ -1541,6 +1574,8 @@ export default {
...
@@ -1541,6 +1574,8 @@ export default {
childAdultOptions
,
childAdultOptions
,
formatChildAdult
,
formatChildAdult
,
genderOptions
,
genderOptions
,
loadAllImages
,
allImagesLoading
,
}
}
}
}
}
}
...
...
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