Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
jml0128
/
xrk-bi
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 750f8b6f
authored
May 17, 2022
by
web
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修改变量名,完善数据
1 parent
8c7157c1
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
43 additions
and
16 deletions
src/App.vue
src/packages/bi/src/components/photo-wall/images.vue
src/packages/bi/src/components/photo-wall/index.vue
src/packages/bi/src/components/photo-wall/select.vue
src/packages/bi/src/main.vue
src/packages/bi/src/project/20-configurable.vue
src/App.vue
View file @
750f8b6
...
...
@@ -348,16 +348,19 @@ export default {
data
:
{
data
:
[],
message
:
'操作成功'
,
status
:
'1'
}
};
},
// 当期BI-
保持选择的图片
// 当期BI-
任务记录图片列表
getTaskPicList
()
{
return
{
data
:
{
data
:
{
imageStyle
:
1
,
//展示样式 1 流式 2平铺
imageSize
:
2
,
//图片大小 1 大 2中 3小
taskImages
:
[
{
biInfoId
:
123
,
//BI主键
taskId
:
123
,
//任务记录ID
imageUrl
:
'图片地址'
imageUrl
:
'http://yiyang.oss-cn-beijing.aliyuncs.com/WEB/SaaS/images/2103251844.png'
}
]
},
...
...
src/packages/bi/src/components/photo-wall/images.vue
View file @
750f8b6
<
template
>
<div
:style=
"
{ columnCount }">
<img
v-for=
"(item, index) in imageUrl"
:key=
"index"
:src=
"setUrl(item)"
/>
<img
v-for=
"(item, index) in imageUrl
s
"
:key=
"index"
:src=
"setUrl(item)"
/>
</div>
</
template
>
...
...
@@ -22,7 +22,7 @@ const IMG_MAPPING = {
export
default
{
name
:
'bi-photo-wall-images'
,
props
:
{
imageUrl
:
{
imageUrl
s
:
{
type
:
Array
,
default
()
{
return
[];
...
...
src/packages/bi/src/components/photo-wall/index.vue
View file @
750f8b6
...
...
@@ -8,12 +8,12 @@
<template
#
handler
>
<div
class=
"bi-title-photo-btn"
>
<SelectStyle
:layout=
"layout"
@
handleSave=
"selectStyleSave"
/>
<SelectImages
:imageUrl
=
"imageUrl
"
@
handleSave=
"selectImgSave"
/>
<SelectImages
:imageUrl
s=
"imageUrls
"
@
handleSave=
"selectImgSave"
/>
<Del
@
del=
"onDel"
/>
</div>
</
template
>
</BiTitle>
<BiImages
:imageUrl
=
"imageUrl
"
:layout=
"layout"
/>
<BiImages
:imageUrl
s=
"imageUrls
"
:layout=
"layout"
/>
</div>
</template>
...
...
@@ -36,7 +36,7 @@ export default {
},
props
:
{
name
:
String
,
data
:
{
initUrl
:
{
default
:
()
=>
[],
type
:
Array
},
...
...
@@ -47,7 +47,7 @@ export default {
},
data
()
{
return
{
imageUrl
:
[],
imageUrl
s
:
[],
layout
:
{
imageStyle
:
2
,
// 1流式 2平铺 流式不限制高度,但是有max-height,平铺为正方形
imageSize
:
2
// 1大548px 2中355px 3小262px
...
...
@@ -57,7 +57,7 @@ export default {
methods
:
{
// 选择图片的保存
selectImgSave
(
e
)
{
this
.
imageUrl
=
e
;
this
.
imageUrl
s
=
e
;
},
// 选择样式的保存
selectStyleSave
(
e
)
{
...
...
@@ -67,9 +67,14 @@ export default {
this
.
$refs
[
'bi-photo'
].
style
.
display
=
'none'
;
}
},
mounted
()
{},
watch
:
{
data
:
{
initUrl
:
{
immediate
:
true
,
handler
(
v
)
{
this
.
imageUrls
=
[...
v
];
}
},
imageUrls
:
{
handler
()
{
this
.
$nextTick
(()
=>
{
this
.
$emit
(
'page'
,
heightToPage
(
this
.
$refs
[
'bi-photo'
].
offsetHeight
));
...
...
src/packages/bi/src/components/photo-wall/select.vue
View file @
750f8b6
...
...
@@ -71,7 +71,7 @@ export default {
name
:
'select-img'
,
props
:
{
// 已勾选数据 [url,url]
imageUrl
:
{
imageUrl
s
:
{
type
:
Array
,
default
()
{
return
[];
...
...
src/packages/bi/src/main.vue
View file @
750f8b6
...
...
@@ -3,7 +3,7 @@
* @Author: jml
* @Date: 2021-02-26 15:38:10
* @LastEditors: Please set LastEditors
* @LastEditTime: 202
1-09-08 15:00:42
* @LastEditTime: 202
2-05-17 11:46:23
-->
<
template
>
<div
class=
"xrk-components-bi bi"
:class=
"
{ 'bi-print': print }">
...
...
@@ -82,6 +82,18 @@ export default {
getTemplateList
:
{
type
:
Function
,
default
:
()
=>
{}
},
saveBiPicList
:
{
type
:
Function
,
default
:
()
=>
{}
},
getTaskPicList
:
{
type
:
Function
,
default
:
()
=>
{}
},
getImageList
:
{
type
:
Function
,
default
:
()
=>
{}
}
},
components
:
{
...
...
src/packages/bi/src/project/20-configurable.vue
View file @
750f8b6
...
...
@@ -66,6 +66,7 @@
<BiPhoto
class=
"bi-block"
name=
"照片集合"
:initUrl=
"photoUrls"
@
page=
"setPage(arguments, 'page4')"
/>
<BiCoverEnd
title=
"奇正藏药医学沙龙推广项目数据报告"
></BiCoverEnd>
...
...
@@ -134,7 +135,8 @@ export default {
projectName
:
''
,
baseInfo
:
[],
textData
:
[],
biInfo
:
{}
biInfo
:
{},
photoUrls
:
[]
};
},
computed
:
{
...
...
@@ -510,7 +512,8 @@ export default {
this
.
Bi
.
getFixedInfo
(),
this
.
Bi
.
getTopicInfo
(),
this
.
Bi
.
getGroupInfo
(),
this
.
Bi
.
getTemplateList
()
this
.
Bi
.
getTemplateList
(),
this
.
Bi
.
getTaskPicList
()
])
.
then
(
([
...
...
@@ -518,13 +521,17 @@ export default {
fixedInfo
,
topicInfo
,
topicMixinInfo
,
tempaletList
=
{
data
:
{
data
:
[]
}
}
tempaletList
=
{
data
:
{
data
:
[]
}
},
photoInfo
])
=>
{
this
.
dealBaseInfo
(
baseInfo
.
data
.
data
[
0
]
||
{});
this
.
dealFixedInfo
(
fixedInfo
.
data
.
data
||
[]);
this
.
dealChoice
(
topicInfo
.
data
.
data
||
[]);
this
.
dealChoiceMixin
(
topicMixinInfo
.
data
.
data
||
[]);
this
.
coverList
=
tempaletList
.
data
.
data
||
[];
this
.
photoUrls
=
photoInfo
.
data
.
data
.
taskImages
.
map
(
item
=>
item
.
imageUrl
);
this
.
$nextTick
(
async
()
=>
{
await
this
.
preloadImg
(
this
.
coverUrl
);
window
.
status
=
'1'
;
...
...
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