Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
E
exhibition_page
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
龙菲
exhibition_page
Commits
011391ed
提交
011391ed
authored
9月 16, 2022
作者:
龙菲
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
布展详情模板完善
上级
e4bf2144
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
753 行增加
和
867 行删除
+753
-867
BlueStyle.vue
src/views/display/components/BlueStyle.vue
+5
-43
ChStyle-unit.vue
src/views/display/components/ChStyle-unit.vue
+1
-1
ChStyle.vue
src/views/display/components/ChStyle.vue
+571
-591
ChStyleUnit.vue
src/views/display/components/ChStyleUnit.vue
+0
-63
RedStyle.vue
src/views/display/components/RedStyle.vue
+2
-2
detail-dialog.vue
src/views/display/components/detail-dialog.vue
+174
-167
没有找到文件。
src/views/display/components/BlueStyle.vue
浏览文件 @
011391ed
...
@@ -156,8 +156,8 @@
...
@@ -156,8 +156,8 @@
<svg-icon
icon-class=
"jianjie"
></svg-icon>
<svg-icon
icon-class=
"jianjie"
></svg-icon>
<span>
展览简介
</span>
<span>
展览简介
</span>
</div>
</div>
<div
class=
"intro-content-container"
>
<div
class=
"intro-content-container"
v-html=
"displayDetail.intro"
>
{{
displayDetail
.
intro
}}
</div>
</div>
</div>
</div>
<div
<div
...
@@ -415,8 +415,6 @@ import Card from "@/views/personal/components/Card";
...
@@ -415,8 +415,6 @@ import Card from "@/views/personal/components/Card";
import
Video
from
"@/components/Video"
;
import
Video
from
"@/components/Video"
;
import
{
previewFile
}
from
"@/utils/index"
;
import
{
previewFile
}
from
"@/utils/index"
;
import
ChStyleUnit
from
"./ChStyleUnit.vue"
;
import
ChStyleUnit
from
"./ChStyleUnit.vue"
;
import
{
swiper
,
swiperSlide
}
from
"vue-awesome-swiper"
;
import
"swiper/dist/css/swiper.css"
;
import
MenuList
from
"@/components/MenuList"
;
import
MenuList
from
"@/components/MenuList"
;
export
default
{
export
default
{
...
@@ -427,8 +425,6 @@ export default {
...
@@ -427,8 +425,6 @@ export default {
Video
,
Video
,
Card
,
Card
,
ChStyleUnit
,
ChStyleUnit
,
swiper
,
swiperSlide
,
MenuList
,
MenuList
,
"el-image-viewer"
:
()
=>
"el-image-viewer"
:
()
=>
import
(
"element-ui/packages/image/src/image-viewer"
),
import
(
"element-ui/packages/image/src/image-viewer"
),
...
@@ -453,43 +449,8 @@ export default {
...
@@ -453,43 +449,8 @@ export default {
dotImg
:
require
(
"@/assets/imgs/display/normal/mz-dot.png"
),
dotImg
:
require
(
"@/assets/imgs/display/normal/mz-dot.png"
),
dotImgS
:
require
(
"@/assets/imgs/display/normal/mz-dot-s.png"
),
dotImgS
:
require
(
"@/assets/imgs/display/normal/mz-dot-s.png"
),
page
:
null
,
page
:
null
,
swiperOption
:
{
// autoplay: false,
effect
:
"fade"
,
pagination
:
{
el
:
".swiper-pagination"
,
type
:
"custom"
,
clickable
:
true
,
renderCustom
:
function
(
swiper
,
current
,
total
)
{
var
customPaginationHtml
=
""
;
for
(
var
i
=
0
;
i
<
total
;
i
++
)
{
//判断哪个分页器此刻应该被激活
if
(
i
==
current
-
1
)
{
customPaginationHtml
+=
`<img class="page-item" src="
${
vm
.
dotImgS
}
" />`
;
}
else
{
customPaginationHtml
+=
`<img class="page-item" src="
${
vm
.
dotImg
}
" />`
;
}
}
return
`<span id="page">`
+
customPaginationHtml
+
`</span>`
;
},
},
on
:
{
click
:
function
(
e
)
{
let
page
=
document
.
getElementById
(
"page"
);
var
item
=
e
.
target
;
var
lists
=
Array
.
from
(
page
.
querySelectorAll
(
"img"
));
let
index
=
lists
.
indexOf
(
item
);
vm
.
swiper
.
slideTo
(
index
);
},
},
},
};
};
},
},
computed
:
{
swiper
()
{
return
this
.
$refs
.
mySwiper
.
swiper
;
},
},
async
mounted
()
{
async
mounted
()
{
this
.
loadDetail
();
this
.
loadDetail
();
},
},
...
@@ -781,12 +742,13 @@ export default {
...
@@ -781,12 +742,13 @@ export default {
.basic-info
{
.basic-info
{
.body-item
{
.body-item
{
display
:
flex
;
display
:
flex
;
align-items
:
center
;
.label
{
.label
{
display
:
flex
;
display
:
flex
;
align-items
:
center
;
align-items
:
center
;
width
:
140px
;
width
:
140px
;
margin-right
:
26px
;
//
margin-right: 26px;
margin-bottom
:
10px
;
//
margin-bottom: 10px;
font-weight
:
bold
;
font-weight
:
bold
;
color
:
#858585
;
color
:
#858585
;
.svg-icon
{
.svg-icon
{
...
...
src/views/display/components/ChStyle-unit.vue
浏览文件 @
011391ed
...
@@ -36,7 +36,7 @@
...
@@ -36,7 +36,7 @@
<div
class=
"unit-content"
>
<div
class=
"unit-content"
>
<div
class=
"unit-title"
>
{{
item
.
title
}}
</div>
<div
class=
"unit-title"
>
{{
item
.
title
}}
</div>
<div
class=
"unit-intro"
>
{{
item
.
intro
}}
</div>
<div
class=
"unit-intro"
v-html=
"item.intro"
>
</div>
</div>
</div>
</div>
</div>
<div
class=
"units-title"
>
<div
class=
"units-title"
>
...
...
src/views/display/components/ChStyle.vue
浏览文件 @
011391ed
<
template
>
<
template
>
<div
class=
"display-detail"
>
<div
class=
"display-detail"
>
<div
class=
"content"
id=
"content"
>
<div
class=
"content"
id=
"content"
>
<div
<div
class=
"
class=
"
content-item
content-item
sliders
sliders
wow
wow
animate__animated animate__fadeInRightBig
animate__animated animate__fadeInRightBig
"
"
ref=
"imgs"
v-if=
"displayDetail.imagesVo && displayDetail.imagesVo.length > 0"
>
ref=
"imgs"
v-if=
"displayDetail.imagesVo && displayDetail.imagesVo.length > 0"
>
<div
class=
"view-box"
>
<div
class=
"view-box"
>
<div
<div
class=
"slide-group"
:style=
"
{
class=
"slide-group"
:style=
"
{
width: sildeGroupWidth,
width: sildeGroupWidth,
left: slideGroupleft + 'px',
left: slideGroupleft + 'px',
}"
}">
>
<div
class=
"slide-item"
v-for=
"(item, index) in displayDetail.imagesVo"
:key=
"index"
>
<div
class=
"slide-item"
v-for=
"(item, index) in displayDetail.imagesVo"
:key=
"index"
>
<img
:src=
"$getFullUrl(item.pressUrl || item.url)"
alt=
""
/>
<img
:src=
"$getFullUrl(item.pressUrl || item.url)"
alt=
""
/>
<div
class=
"modal"
></div>
<div
class=
"modal"
></div>
</div>
</div>
...
@@ -69,7 +58,7 @@
...
@@ -69,7 +58,7 @@
<div
class=
"label"
>
展览性质:
</div>
<div
class=
"label"
>
展览性质:
</div>
<div
class=
"value"
>
<div
class=
"value"
>
{{
{{
dicts
.
displayCharacter
[
displayDetail
.
displayCharacter
]
dicts
.
displayCharacter
[
displayDetail
.
displayCharacter
]
}}
}}
</div>
</div>
</el-col>
</el-col>
...
@@ -80,67 +69,40 @@
...
@@ -80,67 +69,40 @@
</el-row>
</el-row>
</div>
</div>
<div
class=
"tools wow animate__animated animate__fadeIn"
>
<div
class=
"tools wow animate__animated animate__fadeIn"
>
<ReaderOperations
<ReaderOperations
:loveCount=
"displayDetail.loveCount"
:loveCount=
"displayDetail.loveCount"
:loveCountStatus=
"Boolean(displayDetail.loveCountStatus)"
:collectCount=
"displayDetail.collectCount"
:loveCountStatus=
"Boolean(displayDetail.loveCountStatus)"
:collectCountStatus=
"Boolean(displayDetail.collectCountStatus)"
:sourceId=
"displayDetail.exhibitionId"
:collectCount=
"displayDetail.collectCount"
:title=
"displayDetail.title"
:sourceType=
"'biz_exhibition'"
@
reload=
"reload"
:selectColor=
"'#892325'"
/>
:collectCountStatus=
"Boolean(displayDetail.collectCountStatus)"
:sourceId=
"displayDetail.exhibitionId"
:title=
"displayDetail.title"
:sourceType=
"'biz_exhibition'"
@
reload=
"reload"
:selectColor=
"'#892325'"
/>
</div>
</div>
</div>
</div>
<div
class=
"divider"
></div>
<div
class=
"divider"
></div>
<div
class=
"intro-and-video"
>
<div
class=
"intro-and-video"
>
<div
class=
"intro-container"
>
<div
class=
"intro-container"
>
<div
<div
class=
"intro-title wow animate__animated animate__fadeInLeft"
>
class=
"intro-title wow animate__animated animate__fadeInLeft"
>
展览简介
展览简介
</div>
</div>
<div
<div
class=
"intro-content wow animate__animated animate__fadeInLeft"
v-html=
"displayDetail.intro"
>
class=
"intro-content wow animate__animated animate__fadeInLeft"
>
{{
displayDetail
.
intro
}}
</div>
</div>
</div>
</div>
<div
<div
v-if=
"displayDetail.videosVo && displayDetail.videosVo.length > 0"
v-if=
"displayDetail.videosVo && displayDetail.videosVo.length > 0"
class=
"videos wow animate__animated animate__fadeInRight"
>
class=
"videos wow animate__animated animate__fadeInRight"
>
<el-carousel>
<el-carousel>
<el-carousel-item
<el-carousel-item
v-for=
"item in displayDetail.videosVo"
:key=
"item.fileId"
>
v-for=
"item in displayDetail.videosVo"
:key=
"item.fileId"
>
<Video
:url=
"$getFullUrl(item.url)"
/>
<Video
:url=
"$getFullUrl(item.url)"
/>
</el-carousel-item>
</el-carousel-item>
</el-carousel>
</el-carousel>
</div>
</div>
</div>
</div>
<div
<div
class=
"audio"
:style=
"
{ animationPlayState: audioPlaying ? 'running' : 'paused' }"
class=
"audio"
@click="handleClickAudio" v-if="displayDetail.audiosVo
&&
displayDetail.audiosVo.length > 0">
:style=
"
{ animationPlayState: audioPlaying ? 'running' : 'paused' }"
@click="handleClickAudio"
v-if="displayDetail.audiosVo
&&
displayDetail.audiosVo.length > 0"
>
<!--
<svg-icon
icon-class=
"music"
></svg-icon>
-->
<!--
<svg-icon
icon-class=
"music"
></svg-icon>
-->
<img
src=
"@/assets/imgs/display/normal/music-red.png"
alt=
""
/>
<img
src=
"@/assets/imgs/display/normal/music-red.png"
alt=
""
/>
<AudioPlayer
<AudioPlayer
style=
"display: none"
:url=
"$getFullUrl(displayDetail.audiosVo[0].url)"
ref=
"AudioPlayer"
/>
style=
"display: none"
:url=
"$getFullUrl(displayDetail.audiosVo[0].url)"
ref=
"AudioPlayer"
/>
</div>
</div>
</div>
</div>
</div>
</div>
<div
<div
class=
"content-item units"
v-if=
"displayDetail.exhibitionUnits.length > 0"
>
class=
"content-item units"
v-if=
"displayDetail.exhibitionUnits.length > 0"
>
<div
class=
"wrapper"
>
<div
class=
"wrapper"
>
<div
class=
"custom-title wow animate__animated animate__fadeInLeft"
>
<div
class=
"custom-title wow animate__animated animate__fadeInLeft"
>
<div
class=
"custom-title-prefix"
>
<div
class=
"custom-title-prefix"
>
...
@@ -154,16 +116,12 @@
...
@@ -154,16 +116,12 @@
<div
class=
"right"
>
<div
class=
"right"
>
<a
class=
"clearfix"
@
click=
"unitVisible = true"
>
<a
class=
"clearfix"
@
click=
"unitVisible = true"
>
<svg-icon
icon-class=
"book"
></svg-icon>
<svg-icon
icon-class=
"book"
></svg-icon>
详情
</a
详情
>
</a
>
</div>
</div>
</div>
</div>
<ChStyleUnit
<ChStyleUnit
:units=
"node"
v-for=
"node in displayDetail.exhibitionUnits"
:key=
"node.euId"
/>
:units=
"node"
v-for=
"node in displayDetail.exhibitionUnits"
:key=
"node.euId"
/>
</div>
</div>
</div>
</div>
<div
class=
"content-item lts"
>
<div
class=
"content-item lts"
>
...
@@ -179,41 +137,18 @@
...
@@ -179,41 +137,18 @@
</div>
</div>
</div>
</div>
<div
<div
class=
"lts-content"
v-if=
"
class=
"lts-content"
v-if=
"
displayDetail.literatureVo && displayDetail.literatureVo.length > 0
displayDetail.literatureVo && displayDetail.literatureVo.length > 0
"
"
>
>
<div
class=
"wrapper wow animate__animated animate__fadeInUp"
>
<div
class=
"wrapper wow animate__animated animate__fadeInUp"
>
<el-table
<el-table
:data=
"displayDetail.literatureVo"
:header-cell-style=
"
{
:data=
"displayDetail.literatureVo"
:header-cell-style=
"
{
background: '#eeeeee',
background: '#eeeeee',
color: '#333',
color: '#333',
}"
}" :row-style="tableRowStyle">
:row-style="tableRowStyle"
<el-table-column
prop=
"name"
label=
"名称"
align=
"center"
></el-table-column>
>
<el-table-column
prop=
"authors"
label=
"作者"
align=
"center"
></el-table-column>
<el-table-column
<el-table-column
prop=
"date"
label=
"出版时间"
align=
"center"
></el-table-column>
prop=
"name"
<el-table-column
align=
"center"
prop=
"source"
label=
"出版所在刊物"
></el-table-column>
label=
"名称"
align=
"center"
></el-table-column>
<el-table-column
prop=
"authors"
label=
"作者"
align=
"center"
></el-table-column>
<el-table-column
prop=
"date"
label=
"出版时间"
align=
"center"
></el-table-column>
<el-table-column
align=
"center"
prop=
"source"
label=
"出版所在刊物"
></el-table-column>
<el-table-column
label=
"阅读"
align=
"center"
>
<el-table-column
label=
"阅读"
align=
"center"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<div
class=
"pdf-img"
@
click=
"handleViewLt(scope.row)"
>
<div
class=
"pdf-img"
@
click=
"handleViewLt(scope.row)"
>
...
@@ -226,594 +161,638 @@
...
@@ -226,594 +161,638 @@
</div>
</div>
</div>
</div>
</div>
</div>
<el-image-viewer
<el-image-viewer
v-if=
"imgViewerVisible"
:on-close=
"closeImgViewer"
:url-list=
"imgList"
/>
v-if=
"imgViewerVisible"
:on-close=
"closeImgViewer"
:url-list=
"imgList"
/>
<div
class=
"unit-detail-full"
v-if=
"unitVisible"
>
<div
class=
"unit-detail-full"
v-if=
"unitVisible"
>
<i
class=
"el-icon-close"
@
click=
"unitVisible = false"
></i>
<i
class=
"el-icon-close"
@
click=
"unitVisible = false"
></i>
<transition
name=
"el-fade-in-linear"
>
<transition
name=
"el-fade-in-linear"
>
<detail-dialog
<detail-dialog
:data=
"displayDetail.exhibitionUnits"
:title=
"displayDetail.title"
:data=
"displayDetail.exhibitionUnits"
:img=
"displayDetail.faceImageUrl"
v-if=
"unitVisible"
></detail-dialog>
:title=
"displayDetail.title"
:img=
"displayDetail.faceImageUrl"
v-if=
"unitVisible"
></detail-dialog>
</transition>
</transition>
</div>
</div>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
AudioPlayer
from
"@/components/AudioPlayer"
;
import
AudioPlayer
from
"@/components/AudioPlayer"
;
import
ReaderOperations
from
"@/components/ReaderOperations"
;
import
ReaderOperations
from
"@/components/ReaderOperations"
;
import
Card
from
"@/views/personal/components/Card"
;
import
Card
from
"@/views/personal/components/Card"
;
import
Video
from
"@/components/Video"
;
import
Video
from
"@/components/Video"
;
import
MenuList
from
"@/components/MenuList"
;
import
MenuList
from
"@/components/MenuList"
;
import
{
previewFile
}
from
"@/utils/index"
;
import
{
previewFile
}
from
"@/utils/index"
;
// import ChStyleUnit from "./ChStyleUnit.vue";
// import ChStyleUnit from "./ChStyleUnit.vue";
import
ChStyleUnit
from
"./ChStyle-unit.vue"
;
import
ChStyleUnit
from
"./ChStyle-unit.vue"
;
import
DetailDialog
from
"./detail-dialog.vue"
;
import
DetailDialog
from
"./detail-dialog.vue"
;
export
default
{
export
default
{
components
:
{
components
:
{
AudioPlayer
,
AudioPlayer
,
ReaderOperations
,
ReaderOperations
,
MenuList
,
MenuList
,
Video
,
Video
,
Card
,
Card
,
ChStyleUnit
,
ChStyleUnit
,
DetailDialog
,
DetailDialog
,
"el-image-viewer"
:
()
=>
"el-image-viewer"
:
()
=>
import
(
"element-ui/packages/image/src/image-viewer"
),
import
(
"element-ui/packages/image/src/image-viewer"
),
},
props
:
{
displayDetail
:
{
type
:
Object
,
default
:
()
=>
({}),
},
},
dicts
:
{
props
:
{
type
:
Object
,
displayDetail
:
{
default
:
()
=>
({}),
type
:
Object
,
default
:
()
=>
({}),
},
dicts
:
{
type
:
Object
,
default
:
()
=>
({}),
},
},
},
},
data
()
{
data
()
{
return
{
return
{
slideImageWidth
:
0
,
//单个图片的宽度
slideImageWidth
:
0
,
//单个图片
的宽度
sildeGroupWidth
:
0
,
//整个轮播
的宽度
sildeGroupWidth
:
0
,
//整个轮播的宽度
slideGroupleft
:
0
,
//整个轮播距离父亲盒子的距离(中间view区域)
slideGroupleft
:
0
,
//整个轮播距离父亲盒子的距离(中间view区域)
imgViewerVisible
:
false
,
imgViewerVisible
:
false
,
relateRelics
:
[]
,
relateRelics
:
[]
,
imgsDom
:
null
,
imgsDom
:
null
,
moveLeft
:
true
,
moveLef
t
:
true
,
moveRigh
t
:
true
,
moveRight
:
true
,
audioPlaying
:
true
,
audioPlaying
:
tru
e
,
unitVisible
:
fals
e
,
unitVisible
:
false
,
};
}
;
}
,
},
async
mounted
()
{
async
mounted
()
{
this
.
loadDetail
();
this
.
loadDetail
();
},
},
destroyed
()
{
destroyed
()
{
//同时在destroyed回调中移除监听:
//同时在destroyed回调中移除监听:
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"firefox"
)
>=
0
)
{
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"firefox"
)
>=
0
)
{
//firefox支持onmousewheel
//firefox支持onmousewheel
removeEventListener
(
"DOMMouseScroll"
,
firefoxListenFun
);
removeEventListener
(
"DOMMouseScroll"
,
firefoxListenFun
);
}
}
}
,
},
methods
:
{
methods
:
{
async
loadDetail
()
{
async
loadDetail
()
{
processUnit
(
this
.
displayDetail
.
exhibitionUnits
);
processUnit
(
this
.
displayDetail
.
exhibitionUnits
);
function
processUnit
(
list
)
{
function
processUnit
(
list
)
{
for
(
let
o
of
list
||
[]
)
{
for
(
let
o
of
list
||
[]
)
{
if
(
o
.
children
)
{
if
(
o
.
children
)
{
if
(
o
.
children
.
length
==
0
)
{
if
(
o
.
children
.
length
==
0
)
{
o
.
children
=
null
;
o
.
children
=
null
;
}
else
{
}
else
{
processUnit
(
o
.
children
);
processUnit
(
o
.
children
);
}
}
}
}
}
}
}
}
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
this
.
loadWidth
();
this
.
loadWidth
();
if
(
this
.
displayDetail
.
videosVo
&&
this
.
displayDetail
.
videosVo
.
length
>
0
)
{
this
.
$message
.
info
(
"正在播放当前文物讲解音频,点击按钮可关闭"
);
this
.
$refs
.
AudioPlayer
.
play
();
}
});
},
loadWidth
()
{
if
(
if
(
this
.
displayDetail
.
video
sVo
&&
this
.
displayDetail
.
image
sVo
&&
this
.
displayDetail
.
video
sVo
.
length
>
0
this
.
displayDetail
.
image
sVo
.
length
>
0
)
{
)
{
this
.
$message
.
info
(
"正在播放当前文物讲解音频,点击按钮可关闭"
);
let
slideImage
=
document
.
getElementsByClassName
(
"slide-item"
)[
0
];
this
.
$refs
.
AudioPlayer
.
play
();
this
.
slideImageWidth
=
slideImage
.
offsetWidth
;
this
.
sildeGroupWidth
=
this
.
slideImageWidth
*
this
.
displayDetail
.
imagesVo
.
length
;
this
.
slideGroupleft
=
-
3
*
this
.
slideImageWidth
;
}
}
});
},
},
loadWidth
()
{
handleImgsSlide
(
e
)
{
if
(
this
.
addImgsEventListener
(
e
);
this
.
displayDetail
.
imagesVo
&&
this
.
throttle
(
this
.
pageUpOrDown
,
500
)(
e
);
this
.
displayDetail
.
imagesVo
.
length
>
0
},
)
{
let
slideImage
=
document
.
getElementsByClassName
(
"slide-item"
)[
0
];
this
.
slideImageWidth
=
slideImage
.
offsetWidth
;
this
.
sildeGroupWidth
=
this
.
slideImageWidth
*
this
.
displayDetail
.
imagesVo
.
length
;
this
.
slideGroupleft
=
-
3
*
this
.
slideImageWidth
;
}
},
handleImgsSlide
(
e
)
{
this
.
addImgsEventListener
(
e
);
this
.
throttle
(
this
.
pageUpOrDown
,
500
)(
e
);
},
addImgsEventListener
(
e
)
{
addImgsEventListener
(
e
)
{
e
=
e
||
window
.
event
;
e
=
e
||
window
.
event
;
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"msie"
)
>=
0
)
{
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"msie"
)
>=
0
)
{
// IE
// IE
e
.
returnValue
=
false
;
e
.
returnValue
=
false
;
}
else
{
}
else
{
// Chrome
// Chrome
e
.
preventDefault
();
e
.
preventDefault
();
}
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"firefox"
)
>=
0
)
{
//firefox支持onmousewheel
addEventListener
(
"DOMMouseScroll"
,
this
.
firefoxListenFun
,
false
);
}
},
firefoxListenFun
(
e
)
{
var
obj
=
e
.
target
;
var
onmousewheel
;
while
(
obj
)
{
onmousewheel
=
obj
.
getAttribute
(
"onmousewheel"
)
||
obj
.
onmousewheel
;
if
(
onmousewheel
)
break
;
if
(
obj
.
tagName
==
"BODY"
)
break
;
obj
=
obj
.
parentNode
;
}
if
(
onmousewheel
)
{
if
(
e
.
preventDefault
)
e
.
preventDefault
();
//禁止页面滚动
if
(
typeof
obj
.
onmousewheel
!=
"function"
)
{
//将onmousewheel转换成function
eval
(
"window._tmpFun = function(event){"
+
onmousewheel
+
"}"
);
obj
.
onmousewheel
=
window
.
_tmpFun
;
window
.
_tmpFun
=
null
;
}
}
// 不直接执行是因为若onmousewheel(e)运行时间较长的话,会导致锁定滚动失效,使用setTimeout可避免
setTimeout
(
function
()
{
obj
.
onmousewheel
(
e
);
},
1
);
}
},
pageUpOrDown
(
e
)
{
if
(
navigator
.
userAgent
.
toLowerCase
().
indexOf
(
"firefox"
)
>=
0
)
{
let
detail
=
e
.
wheelDelta
||
e
.
detail
||
e
.
wheelDeltaY
;
//firefox支持onmousewheel
let
direction
=
detail
>
0
?
"left"
:
"right"
;
addEventListener
(
"DOMMouseScroll"
,
this
.
firefoxListenFun
,
false
);
if
(
direction
==
"left"
&&
this
.
moveLeft
)
{
}
this
.
slideGroupleft
+=
this
.
slideImageWidth
;
},
this
.
moveRight
=
true
;
firefoxListenFun
(
e
)
{
}
var
obj
=
e
.
target
;
if
(
direction
==
"right"
&&
this
.
moveRight
)
{
var
onmousewheel
;
this
.
slideGroupleft
+=
this
.
slideImageWidth
*
-
1
;
while
(
obj
)
{
this
.
moveLeft
=
true
;
onmousewheel
=
obj
.
getAttribute
(
"onmousewheel"
)
||
obj
.
onmousewheel
;
}
if
(
onmousewheel
)
break
;
if
(
obj
.
tagName
==
"BODY"
)
break
;
obj
=
obj
.
parentNode
;
}
if
(
onmousewheel
)
{
if
(
e
.
preventDefault
)
e
.
preventDefault
();
//禁止页面滚动
if
(
typeof
obj
.
onmousewheel
!=
"function"
)
{
//将onmousewheel转换成function
eval
(
"window._tmpFun = function(event){"
+
onmousewheel
+
"}"
);
obj
.
onmousewheel
=
window
.
_tmpFun
;
window
.
_tmpFun
=
null
;
}
// 不直接执行是因为若onmousewheel(e)运行时间较长的话,会导致锁定滚动失效,使用setTimeout可避免
setTimeout
(
function
()
{
obj
.
onmousewheel
(
e
);
},
1
);
}
},
if
(
this
.
slideGroupleft
==
0
)
{
pageUpOrDown
(
e
)
{
this
.
moveLeft
=
false
;
let
detail
=
e
.
wheelDelta
||
e
.
detail
||
e
.
wheelDeltaY
;
this
.
moveRight
=
true
;
let
direction
=
detail
>
0
?
"left"
:
"right"
;
}
if
(
direction
==
"left"
&&
this
.
moveLeft
)
{
this
.
slideGroupleft
+=
this
.
slideImageWidth
;
this
.
moveRight
=
true
;
}
if
(
direction
==
"right"
&&
this
.
moveRight
)
{
this
.
slideGroupleft
+=
this
.
slideImageWidth
*
-
1
;
this
.
moveLeft
=
true
;
}
if
(
if
(
this
.
slideGroupleft
==
0
)
{
this
.
slideGroupleft
==
this
.
moveLeft
=
false
;
4
*
this
.
slideImageWidth
-
this
.
sildeGroupWidth
this
.
moveRight
=
true
;
)
{
}
this
.
moveRight
=
false
;
this
.
moveLeft
=
true
;
}
},
//节流函数
if
(
throttle
(
fn
,
gapTime
)
{
this
.
slideGroupleft
==
let
_this
=
this
;
4
*
this
.
slideImageWidth
-
this
.
sildeGroupWidth
return
function
()
{
)
{
let
_nowTime
=
+
new
Date
();
this
.
moveRight
=
false
;
if
(
_nowTime
-
_this
.
_lastTime
>
gapTime
||
!
_this
.
_lastTime
)
{
this
.
moveLeft
=
true
;
fn
(...
arguments
);
// 函数可以带参数
_this
.
_lastTime
=
_nowTime
;
}
}
};
},
},
// 关联文献的行样式调整
//节流函数
tableRowStyle
({
row
,
rowIndex
}
)
{
throttle
(
fn
,
gapTime
)
{
if
(
rowIndex
%
2
==
0
)
{
let
_this
=
this
;
return
{
return
function
()
{
background
:
"#f9f9f9 !important"
,
let
_nowTime
=
+
new
Date
();
};
if
(
_nowTime
-
_this
.
_lastTime
>
gapTime
||
!
_this
.
_lastTime
)
{
}
else
{
fn
(...
arguments
);
// 函数可以带参数
return
{
_this
.
_lastTime
=
_nowTime
;
background
:
"#fff !important"
,
}
};
};
}
},
},
// 预览关联文献
// 关联文献的行样式调整
handleViewLt
(
item
)
{
tableRowStyle
({
row
,
rowIndex
})
{
previewFile
(
item
.
files
[
0
].
url
,
item
.
files
[
0
].
name
);
if
(
rowIndex
%
2
==
0
)
{
},
return
{
background
:
"#f9f9f9 !important"
,
};
}
else
{
return
{
background
:
"#fff !important"
,
};
}
},
// 点击音频
// 预览关联文献
handleClickAudio
()
{
handleViewLt
(
item
)
{
this
.
audioPlaying
=
!
this
.
audioPlaying
;
previewFile
(
item
.
files
[
0
].
url
,
item
.
files
[
0
].
name
);
if
(
this
.
audioPlaying
)
{
},
this
.
$refs
[
"AudioPlayer"
].
play
();
// console.log(this.$refs['audioContainer']);
// 点击音频
}
else
{
handleClickAudio
()
{
this
.
$refs
[
"AudioPlayer"
].
pause
();
this
.
audioPlaying
=
!
this
.
audioPlaying
;
}
if
(
this
.
audioPlaying
)
{
},
this
.
$refs
[
"AudioPlayer"
].
play
();
// console.log(this.$refs['audioContainer']);
}
else
{
this
.
$refs
[
"AudioPlayer"
].
pause
();
}
},
reload
()
{
reload
()
{
this
.
$emit
(
"reload"
);
this
.
$emit
(
"reload"
);
},
},
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
// 中国风主题样式
// 中国风主题样式
/**公共样式开始 */
/**公共样式开始 */
.wrapper
{
.wrapper
{
// width: 1200px;
// width: 1200px;
width
:
calc
(
100%
-
26%
);
//左右两边各自留13%
width
:
calc
(
100%
-
26%
);
//左右两边各自留13%
}
.custom-title
{
display
:
flex
;
align-items
:
center
;
position
:
relative
;
.custom-title-prefix
,
.custom-title-suffix
{
width
:
27px
;
height
:
27px
;
margin
:
15px
;
img
{
width
:
100%
;
height
:
100%
;
}
}
}
.custom-title-text
{
font-size
:
40px
;
.custom-title
{
font-family
:
KaiTi
;
display
:
flex
;
font-weight
:
400
;
align-items
:
center
;
color
:
#0f0f0f
;
position
:
relative
;
line-height
:
114px
;
.custom-title-prefix
,
.custom-title-suffix
{
width
:
27px
;
height
:
27px
;
margin
:
15px
;
img
{
width
:
100%
;
height
:
100%
;
}
}
.custom-title-text
{
font-size
:
40px
;
font-family
:
KaiTi
;
font-weight
:
400
;
color
:
#0f0f0f
;
line-height
:
114px
;
}
}
}
}
/**公共样式结束 */
/**样式开始 */
/**公共样式结束 */
.display-detail
{
overflow
:
hidden
;
/**样式开始 */
.content
{
.display-detail
{
width
:
100%
;
overflow
:
hidden
;
overflow
:
hidden
;
.content-item
{
.content
{
width
:
100%
;
width
:
100%
;
}
overflow
:
hidden
;
.content-item
{
width
:
100%
;
}
/**轮播图 */
/**轮播图 */
.sliders
{
.sliders
{
height
:
434px
;
height
:
434px
;
// margin: 52px 0 84px 0;
// margin: 52px 0 84px 0;
margin-top
:
52px
;
margin-top
:
52px
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
position
:
relative
;
.view-box
{
position
:
relative
;
position
:
relative
;
width
:
1200px
;
.slide-group
{
.view-box
{
display
:
flex
;
position
:
relative
;
width
:
1200px
;
.slide-group
{
display
:
flex
;
position
:
absolute
;
height
:
100%
;
transition
:
all
0
.8s
cubic-bezier
(
0
.25
,
0
.1
,
0
.25
,
1
);
/**保证能够最开始刚好有四格卡在中间*/
// transform: translateX(-900px);
.slide-item
{
width
:
300px
;
height
:
100%
;
position
:
relative
;
margin-right
:
1px
;
img
{
width
:
300px
;
height
:
100%
;
object-fit
:
cover
;
// filter: grayscale(14);
}
}
}
}
.modal-layer
{
position
:
absolute
;
position
:
absolute
;
display
:
flex
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
transition
:
all
0
.8s
cubic-bezier
(
0
.25
,
0
.1
,
0
.25
,
1
);
justify-content
:
center
;
/**保证能够最开始刚好有四格卡在中间*/
// transform: translateX(-900px);
.center-img
{
.slide-item
{
width
:
1200px
;
width
:
300px
;
transform
:
translateY
(
-25px
);
height
:
100%
;
position
:
relative
;
position
:
relative
;
margin-right
:
1px
;
filter
:
drop-shadow
(
2px
4px
6px
#f8f8f8
);
img
{
img
{
width
:
300px
;
transform
:
translateX
(
-10px
);
height
:
100%
;
width
:
1230px
;
object-fit
:
cover
;
// filter: grayscale(14);
}
}
}
}
.left-layer
,
.right-layer
{
flex
:
1
;
height
:
100%
;
background-color
:
rgba
(
#f8f8f8
,
0
.8
);
}
}
}
}
}
.modal-layer
{
/**展览信息 */
position
:
absolute
;
.intro
{
margin-top
:
55px
;
display
:
flex
;
display
:
flex
;
width
:
100%
;
height
:
100%
;
justify-content
:
center
;
justify-content
:
center
;
.center-img
{
width
:
1200px
;
.wrapper
{
transform
:
translateY
(
-25px
);
background
:
url("@/assets/imgs/display/ch/intro-bg.png")
;
background-repeat
:
no-repeat
;
background-size
:
100%
100%
;
padding
:
50px
;
position
:
relative
;
position
:
relative
;
filter
:
drop-shadow
(
2px
4px
6px
#f8f8f8
);
border
:
1px
solid
#d3d3d3
7a
;
img
{
transform
:
translateX
(
-10px
);
width
:
1230px
;
}
}
.left-layer
,
.right-layer
{
flex
:
1
;
height
:
100%
;
background-color
:
rgba
(
#f8f8f8
,
0
.8
);
}
}
}
/**展览信息 */
.title
{
.intro
{
font-size
:
50px
;
margin-top
:
55px
;
font-family
:
KaiTi
;
display
:
flex
;
font-weight
:
bold
;
justify-content
:
center
;
color
:
#0f0f0f
;
margin-bottom
:
60px
;
.wrapper
{
display
:
flex
;
background
:
url("@/assets/imgs/display/ch/intro-bg.png")
;
justify-content
:
space-between
;
background-repeat
:
no-repeat
;
align-items
:
center
;
background-size
:
100%
100%
;
padding
:
50px
;
.view-count
{
position
:
relative
;
font-size
:
18px
;
border
:
1px
solid
#d3d3d3
7a
;
margin-top
:
10px
;
.title
{
color
:
#999
;
font-size
:
50px
;
font-weight
:
normal
;
font-family
:
KaiTi
;
font-weight
:
bold
;
.svg-icon
{
color
:
#0f0f0f
;
margin-right
:
10px
;
margin-bottom
:
60px
;
}
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
.view-count
{
font-size
:
18px
;
margin-top
:
10px
;
color
:
#999
;
font-weight
:
normal
;
.svg-icon
{
margin-right
:
10px
;
}
}
}
}
}
.desc-and-tools
{
.desc-and-tools
{
display
:
flex
;
justify-content
:
space-between
;
.desc
{
display
:
flex
;
display
:
flex
;
.item
{
justify-content
:
space-between
;
.desc
{
display
:
flex
;
display
:
flex
;
margin-right
:
16px
;
.label
,
.item
{
.value
{
display
:
flex
;
font-size
:
18px
;
margin-right
:
16px
;
color
:
#0f0f0f
;
line-height
:
36px
;
.label
,
}
.value
{
.label
{
font-size
:
18px
;
margin-left
:
8px
;
color
:
#0f0f0f
;
line-height
:
36px
;
}
.label
{
margin-left
:
8px
;
}
}
}
}
}
.tools
{
width
:
280px
;
}
}
}
.tools
{
width
:
280px
;
.divider
{
width
:
100%
;
height
:
2px
;
border
:
1px
dashed
#b1b0af
;
margin
:
42px
0
;
}
}
}
.divider
{
.intro-and-video
{
width
:
100%
;
display
:
flex
;
height
:
2px
;
border
:
1px
dashed
#b1b0af
;
.intro-container
{
margin
:
42px
0
;
flex
:
1
;
}
.intro-and-video
{
.intro-title
{
display
:
flex
;
font-size
:
40px
;
.intro-container
{
font-family
:
KaiTi
;
flex
:
1
;
font-weight
:
400
;
.intro-title
{
color
:
#0f0f0f
;
font-size
:
40px
;
margin-bottom
:
43px
;
font-family
:
KaiTi
;
position
:
relative
;
font-weight
:
400
;
color
:
#0f0f0f
;
&
:
:
after
{
margin-bottom
:
43px
;
content
:
""
;
position
:
relative
;
display
:
inline-block
;
&
:
:
after
{
width
:
60px
;
content
:
""
;
height
:
2px
;
display
:
inline-block
;
background-color
:
#caad91
;
width
:
60px
;
position
:
absolute
;
height
:
2px
;
left
:
0
;
background-color
:
#caad91
;
bottom
:
-12px
;
position
:
absolute
;
}
left
:
0
;
}
bottom
:
-12px
;
.intro-content
{
font-size
:
16px
;
font-family
:
Microsoft
YaHei
;
font-weight
:
400
;
color
:
#444444
;
text-indent
:
32px
;
line-height
:
28px
;
margin-left
:
8px
;
}
}
}
}
.intro-content
{
font-size
:
16px
;
.videos
{
font-family
:
Microsoft
YaHei
;
flex
:
1
;
font-weight
:
400
;
position
:
relative
;
color
:
#444444
;
height
:
256px
;
text-indent
:
32px
;
margin-left
:
70px
;
line-height
:
28px
;
margin-left
:
8px
;
}
}
}
}
.videos
{
flex
:
1
;
position
:
relative
;
height
:
256px
;
margin-left
:
70px
;
}
}
.audio
{
.audio
{
position
:
absolute
;
position
:
absolute
;
right
:
-120px
;
right
:
-120px
;
top
:
34px
;
top
:
34px
;
cursor
:
pointer
;
cursor
:
pointer
;
animation
:
audioRotate
8s
linear
infinite
;
animation
:
audioRotate
8s
linear
infinite
;
transform-origin
:
center
center
;
transform-origin
:
center
center
;
border
:
2px
solid
#892325
;
border
:
2px
solid
#892325
;
padding
:
10px
;
padding
:
10px
;
border-radius
:
50%
;
border-radius
:
50%
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
align-items
:
center
;
align-items
:
center
;
background-color
:
#fff
;
background-color
:
#fff
;
transition
:
all
0
.5s
ease
;
transition
:
all
0
.5s
ease
;
&
:hover
{
box-shadow
:
0
0
14px
rgb
(
0
0
0
/
40%
);
&
:hover
{
}
box-shadow
:
0
0
14px
rgb
(
0
0
0
/
40%
);
img
{
}
width
:
60px
;
height
:
60px
;
img
{
width
:
60px
;
height
:
60px
;
}
}
}
}
}
}
}
}
@keyframes
audioRotate
{
@keyframes
audioRotate
{
0
%
{
0
%
{
transform
:
rotateZ
(
0deg
);
transform
:
rotateZ
(
0deg
);
}
}
100
%
{
transform
:
rotateZ
(
360deg
);
100
%
{
transform
:
rotateZ
(
360deg
);
}
}
}
}
@-webkit-keyframes
audioRotate
{
@-webkit-keyframes
audioRotate
{
0
%
{
0
%
{
transform
:
rotateZ
(
0deg
);
transform
:
rotateZ
(
0deg
);
}
100
%
{
transform
:
rotateZ
(
360deg
);
}
}
}
100
%
{
transform
:
rotateZ
(
360deg
);
.animation-play-paused
{
animation-play-state
:
paused
;
-webkit-animation-play-state
:
paused
;
/* Safari 和 Chrome */
}
}
}
.animation-play-paused
{
/**展览单元 */
animation-play-state
:
paused
;
.units
{
-webkit-animation-play-state
:
paused
;
/* Safari 和 Chrome */
margin-top
:
94px
;
}
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
/**展览单元 */
.units-content
{
.units
{
ul
{
margin-top
:
94px
;
li
{
display
:
flex
;
margin-bottom
:
20px
;
flex-direction
:
column
;
align-items
:
center
;
.unit-title
{
.units-content
{
font-size
:
36px
;
ul
{
font-family
:
KaiTi
;
li
{
font-weight
:
400
;
margin-bottom
:
20px
;
color
:
#4e392c
;
.unit-title
{
line-height
:
83px
;
font-size
:
36px
;
display
:
flex
;
font-family
:
KaiTi
;
justify-content
:
center
;
font-weight
:
400
;
}
color
:
#4e392c
;
line-height
:
83px
;
.unit-intro
{
display
:
flex
;
font-size
:
16px
;
justify-content
:
center
;
font-family
:
Microsoft
YaHei
;
}
font-weight
:
400
;
.unit-intro
{
color
:
#444444
;
font-size
:
16px
;
text-indent
:
36px
;
font-family
:
Microsoft
YaHei
;
margin-bottom
:
10px
;
font-weight
:
400
;
}
color
:
#444444
;
text-indent
:
36px
;
.unit-imgs
{
margin-bottom
:
10px
;
}
.unit-imgs
{
width
:
100%
;
.img-item
{
width
:
100%
;
width
:
100%
;
img
{
.img-item
{
width
:
100%
;
width
:
100%
;
img
{
width
:
100%
;
}
}
}
}
}
}
}
}
}
}
}
}
}
}
/**关联文献 */
/**关联文献 */
.lts
{
.lts
{
// background-color: aquamarine;
// background-color: aquamarine;
display
:
flex
;
flex-direction
:
column
;
align-items
:
center
;
margin-top
:
100px
;
.lts-content
{
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
flex-direction
:
column
;
width
:
100%
;
align-items
:
center
;
height
:
569px
;
margin-top
:
100px
;
background-image
:
url("@/assets/imgs/display/ch/lts-bg.png")
;
overflow-x
:
hidden
;
.lts-content
{
display
:
flex
;
justify-content
:
center
;
width
:
100%
;
height
:
569px
;
background-image
:
url("@/assets/imgs/display/ch/lts-bg.png")
;
overflow-x
:
hidden
;
}
}
}
}
}
}
}
}
.right
{
.right
{
float
:
right
;
float
:
right
;
position
:
absolute
;
right
:
0
;
top
:
50%
;
transform
:
translateY
(
-50%
);
a
{
font-size
:
22px
;
}
.clearfix
{
clear
:
both
;
}
a
:hover
{
cursor
:
pointer
;
color
:
#2069c4
;
}
}
.unit-detail-full
{
position
:
fixed
;
top
:
0
;
left
:
0
;
width
:
100%
;
height
:
100%
;
background-color
:
rgba
(
0
,
0
,
0
,
0
.6
);
z-index
:
99
;
>
i
{
color
:
#fff
;
font-size
:
24px
;
position
:
absolute
;
position
:
absolute
;
top
:
20px
;
right
:
0
;
right
:
20px
;
top
:
50%
;
z-index
:
10
;
transform
:
translateY
(
-50%
);
&
:hover
{
a
{
font-size
:
22px
;
}
.clearfix
{
clear
:
both
;
}
a
:hover
{
cursor
:
pointer
;
cursor
:
pointer
;
color
:
#2069c4
;
}
}
}
}
}
::v-deep
.el-carousel
{
.unit-detail-full
{
height
:
100%
;
position
:
fixed
;
}
top
:
0
;
::v-deep
.el-carousel__container
{
left
:
0
;
height
:
100%
;
width
:
100%
;
}
height
:
100%
;
::v-deep
.el-carousel__item--card
{
background-color
:
rgba
(
0
,
0
,
0
,
0
.6
);
width
:
100%
;
z-index
:
99
;
height
:
100%
;
transform
:
translateX
(
0
)
scale
(
1
)
!
important
;
>
i
{
}
color
:
#fff
;
font-size
:
24px
;
position
:
absolute
;
top
:
20px
;
right
:
20px
;
z-index
:
10
;
&
:hover
{
cursor
:
pointer
;
}
}
}
::v-deep
.el-carousel
{
height
:
100%
;
}
::v-deep
.el-carousel__container
{
height
:
100%
;
}
::v-deep
.el-carousel__item--card
{
width
:
100%
;
height
:
100%
;
transform
:
translateX
(
0
)
scale
(
1
)
!
important
;
}
</
style
>
</
style
>
\ No newline at end of file
src/views/display/components/ChStyleUnit.vue
deleted
100644 → 0
浏览文件 @
e4bf2144
<!-- -->
<
template
>
<div
class=
"units-content"
>
<div
class=
"units-content-item"
v-for=
"(unit, index) in units"
:key=
"index"
>
<div
class=
"unit-title"
>
{{
unit
.
title
}}
</div>
<div
class=
"unit-intro"
>
{{
unit
.
intro
}}
</div>
<div
class=
"unit-imgs"
v-if=
"unit.imagesVo && unit.imagesVo.length > 0"
>
<div
class=
"img-item"
v-for=
"(i, idx) in unit.imagesVo"
:key=
"idx"
>
<img
:src=
"$getFullUrl(i.pressUrl||i.url)"
/>
</div>
</div>
<ChStyleUnit
:units=
"unit.children"
v-if=
"unit.children && unit.children.length > 0"
/>
</div>
</div>
</
template
>
<
script
>
export
default
{
name
:
"ChStyleUnit"
,
props
:
{
units
:
{
type
:
Array
,
default
:
()
=>
[],
},
},
};
</
script
>
<
style
lang=
"scss"
scoped
>
.units-content-item
{
margin-bottom
:
20px
;
.unit-title
{
font-size
:
36px
;
font-family
:
KaiTi
;
font-weight
:
400
;
color
:
#4e392c
;
line-height
:
83px
;
display
:
flex
;
justify-content
:
center
;
}
.unit-intro
{
font-size
:
16px
;
font-family
:
Microsoft
YaHei
;
font-weight
:
400
;
color
:
#444444
;
text-indent
:
36px
;
margin-bottom
:
10px
;
line-height
:
32px
;
}
.unit-imgs
{
width
:
100%
;
.img-item
{
width
:
100%
;
img
{
width
:
100%
;
}
}
}
}
</
style
>
src/views/display/components/RedStyle.vue
浏览文件 @
011391ed
...
@@ -140,7 +140,7 @@
...
@@ -140,7 +140,7 @@
<div
class=
"wrapper"
>
<div
class=
"wrapper"
>
<div
class=
"custom-title"
>
展览简介
</div>
<div
class=
"custom-title"
>
展览简介
</div>
<div
class=
"intro-content"
>
<div
class=
"intro-content"
>
<div
class=
"intro-content-container"
>
{{
displayDetail
.
intro
}}
</div>
<div
class=
"intro-content-container"
v-html=
"displayDetail.intro"
>
</div>
</div>
</div>
<div
<div
class=
"intro-video"
class=
"intro-video"
...
@@ -201,7 +201,7 @@
...
@@ -201,7 +201,7 @@
</div>
</div>
<div
class=
"unit-name-intro"
v-if=
"i == 0"
>
<div
class=
"unit-name-intro"
v-if=
"i == 0"
>
<div
class=
"unit-name"
>
{{
currentUnit
.
title
}}
</div>
<div
class=
"unit-name"
>
{{
currentUnit
.
title
}}
</div>
<div
class=
"unit-intro"
>
{{
currentUnit
.
intro
}}
</div>
<div
class=
"unit-intro"
v-html=
"currentUnit.intro "
>
</div>
</div>
</div>
</el-col>
</el-col>
</el-row>
</el-row>
...
...
src/views/display/components/detail-dialog.vue
浏览文件 @
011391ed
<
template
>
<
template
>
<div
class=
"detail-book"
>
<div
class=
"detail-book"
>
<div
v-if=
"list.length > 0"
>
<div
v-if=
"list.length > 0"
>
<div
<div
class=
"book-page"
v-for=
"(node, i) in list"
:key=
"i"
class=
"book-page"
:class=
"
{ active: i === activePage, flipped: i
<
activePage
}"
>
v-for=
"(node, i) in list"
<div
class=
"article-title"
@
click=
"handlePageChange(i, true)"
v-if=
"node.imagesVo[0]"
>
:key=
"i"
<div
class=
"img"
:style=
"`background-image: url('$
{node.imagesVo[0]
&&
node.imagesVo[0].url}')`">
</div>
:class=
"
{ active: i === activePage, flipped: i
<
activePage
}"
>
<div
class=
"article-title"
@
click=
"handlePageChange(i, true)"
v-if=
"node.imagesVo[0]"
>
<div
class=
"img"
:style=
"`background-image: url('$
{node.imagesVo[0]
&&
node.imagesVo[0].url}')`"
>
</div>
<p>
<p>
<span
class=
"title"
>
{{
node
.
title
}}
</span>
<span
class=
"title"
>
{{
node
.
title
}}
</span>
<span
class=
"seq"
>
{{
node
.
unit
}}
</span>
<span
class=
"seq"
>
{{
node
.
unit
}}
</span>
</p>
</p>
</div>
</div>
<div
class=
"article-big-title"
v-else
@
click=
"handlePageChange(i, true)"
>
<div
class=
"article-big-title"
v-else
@
click=
"handlePageChange(i, true)"
>
<p>
<p>
...
@@ -35,191 +24,208 @@
...
@@ -35,191 +24,208 @@
</p>
</p>
</div>
</div>
<div
class=
"article-content"
v-else
@
click=
"handlePageChange(i)"
>
<div
class=
"article-content"
v-else
@
click=
"handlePageChange(i)"
>
<div
class=
"content-detail"
>
{{
list
[
i
-
1
].
intro
}}
</div>
<div
class=
"content-detail"
v-html=
"list[i - 1].intro "
>
</div>
</div>
</div>
</div>
</div>
<div
class=
"book-page"
>
<div
class=
"book-page"
>
<div
class=
"article-content"
>
<div
class=
"article-content"
>
<div
class=
"content-detail"
>
{{
list
[
list
.
length
-
1
].
intro
}}
</div>
<div
class=
"content-detail"
v-html=
"list[list.length - 1].intro"
>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
props
:
{
props
:
{
data
:
{
data
:
{
type
:
Array
,
type
:
Array
,
default
:
()
=>
[],
default
:
()
=>
[],
},
},
title
:
{
title
:
{
type
:
String
,
type
:
String
,
default
:
""
,
default
:
""
,
},
},
img
:
{
img
:
{
type
:
String
,
type
:
String
,
default
:
""
,
default
:
""
,
},
},
},
},
data
()
{
data
()
{
return
{
return
{
activePage
:
0
,
activePage
:
0
,
};
};
},
computed
:
{
list
()
{
let
arr
=
this
.
data
;
return
this
.
transformTree2List
(
arr
);
},
},
},
computed
:
{
methods
:
{
list
()
{
handlePageChange
(
index
,
flag
)
{
let
arr
=
this
.
data
;
if
(
flag
)
{
this
.
activePage
=
index
;
return
this
.
transformTree2List
(
arr
);
}
else
{
},
this
.
activePage
=
index
+
1
;
}
},
},
transformTree2List
(
arr
)
{
methods
:
{
let
list
=
[];
handlePageChange
(
index
,
flag
)
{
let
loopTree
=
(
data
)
=>
{
if
(
flag
)
{
data
.
forEach
((
n
)
=>
{
this
.
activePage
=
index
;
list
.
push
(
n
);
}
else
{
if
(
n
.
children
&&
n
.
children
.
length
>
0
)
{
this
.
activePage
=
index
+
1
;
loopTree
(
n
.
children
);
}
}
},
});
transformTree2List
(
arr
)
{
};
let
list
=
[];
let
loopTree
=
(
data
)
=>
{
data
.
forEach
((
n
)
=>
{
list
.
push
(
n
);
if
(
n
.
children
&&
n
.
children
.
length
>
0
)
{
loopTree
(
n
.
children
);
}
});
};
loopTree
(
arr
);
loopTree
(
arr
);
console
.
log
(
"list"
,
list
);
console
.
log
(
"list"
,
list
);
return
list
;
return
list
;
},
},
},
},
};
};
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
>
.detail-book
{
.detail-book
{
position
:
relative
;
position
:
relative
;
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
min-height
:
800px
;
min-height
:
800px
;
perspective
:
1000px
;
perspective
:
1000px
;
>
div
{
// position: absolute;
>
div
{
position
:
absolute
;
// position: absolute;
// width: 800px;
position
:
absolute
;
width
:
48%
;
// width: 800px;
height
:
600px
;
width
:
48%
;
top
:
50%
;
height
:
600px
;
left
:
50%
;
top
:
50%
;
transform
:
translate
(
0%
,
-50%
);
left
:
50%
;
transform-style
:
preserve-3d
;
transform
:
translate
(
0%
,
-50%
);
/* &:first-child,
transform-style
:
preserve-3d
;
/* &:first-child,
&:last-child {
&:last-child {
box-shadow: 0px -5px 0 2px #8f712fdb;
box-shadow: 0px -5px 0 2px #8f712fdb;
} */
} */
}
.book-page
{
position
:
absolute
;
// width: 800px;
width
:
100%
;
height
:
100%
;
transition
:
all
1
.5s
;
transform-style
:
preserve-3d
;
transform-origin
:
0
0
;
border-left
:
2px
solid
#8f712f
db
;
box-shadow
:
6px
6px
0
2px
#8f712f
db
;
&
.active
{
z-index
:
1
;
}
}
&
.flipped
{
// z-index: 1;
.book-page
{
transform
:
rotateY
(
-180deg
);
}
>
div
{
position
:
absolute
;
position
:
absolute
;
// width: 800px;
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
box-sizing
:
border-box
;
transition
:
all
1
.5s
;
backface-visibility
:
hidden
;
transform-style
:
preserve-3d
;
background-color
:
#bfa277
;
transform-origin
:
0
0
;
}
border-left
:
2px
solid
#8f712f
db
;
.book-cover
{
box-shadow
:
6px
6px
0
2px
#8f712f
db
;
display
:
flex
;
justify-content
:
space-between
;
&
.active
{
align-items
:
center
;
z-index
:
1
;
padding
:
30px
;
}
width
:
100%
;
height
:
100%
;
&
.flipped
{
// z-index: 1;
transform
:
rotateY
(
-180deg
);
}
>
.img
{
>
div
{
width
:
600px
;
position
:
absolute
;
height
:
400px
;
width
:
100%
;
background-size
:
cover
;
height
:
100%
;
b
ackground-repeat
:
no-repeat
;
b
ox-sizing
:
border-box
;
back
ground-position
:
50%
50%
;
back
face-visibility
:
hidden
;
margin
:
50px
auto
;
background-color
:
#bfa277
;
}
}
>
p
{
.book-cover
{
display
:
flex
;
display
:
flex
;
>
span
{
justify-content
:
space-between
;
display
:
block
;
align-items
:
center
;
text-align
:
center
;
padding
:
30px
;
font-size
:
22px
;
width
:
100%
;
font-weight
:
600
;
height
:
100%
;
font-family
:
"楷体"
;
writing-mode
:
tb-rl
;
>
.img
{
&
.title
{
width
:
600px
;
color
:
#850e0e
;
height
:
400px
;
font-size
:
30px
;
background-size
:
cover
;
}
background-repeat
:
no-repeat
;
&
.seq
{
background-position
:
50%
50%
;
padding-bottom
:
100px
;
margin
:
50px
auto
;
margin-left
:
20px
;
}
>
p
{
display
:
flex
;
>
span
{
display
:
block
;
text-align
:
center
;
font-size
:
22px
;
font-weight
:
600
;
font-family
:
"楷体"
;
writing-mode
:
tb-rl
;
&
.title
{
color
:
#850e0e
;
font-size
:
30px
;
}
&
.seq
{
padding-bottom
:
100px
;
margin-left
:
20px
;
}
}
}
}
}
}
}
}
.article-title
{
.article-title
{
@extend
.book-cover
;
@extend
.book-cover
;
transform
:
rotateY
(
180deg
);
transform
:
rotateY
(
180deg
);
>
.img
{
border-radius
:
10px
;
>
.img
{
border-radius
:
10px
;
}
}
}
}
.article-big-title
{
.article-big-title
{
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
align-items
:
center
;
align-items
:
center
;
transform
:
rotateY
(
180deg
);
transform
:
rotateY
(
180deg
);
>
p
{
font-size
:
36px
;
>
p
{
text-align
:
center
;
font-size
:
36px
;
font-family
:
"华文行楷"
;
text-align
:
center
;
>
span
{
font-family
:
"华文行楷"
;
display
:
block
;
margin
:
20px
;
>
span
{
&
.title
{
display
:
block
;
color
:
#fff2b3
;
margin
:
20px
;
&
.title
{
color
:
#fff2b3
;
}
}
}
}
}
}
}
}
.article-content
{
.article-content
{
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
padding
:
50px
100px
;
padding
:
50px
100px
;
line-height
:
1
.8
;
line-height
:
1
.8
;
color
:
#333
;
color
:
#333
;
font-weight
:
600
;
font-weight
:
600
;
font-family
:
"仿宋"
;
font-family
:
"仿宋"
;
text-indent
:
32px
;
text-indent
:
32px
;
}
}
}
}
}
}
</
style
>
</
style
>
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论