Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
E
exhibition_page
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
龙菲
exhibition_page
Commits
0ccdac09
提交
0ccdac09
authored
11月 22, 2022
作者:
龙菲
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改文物和展览的筛选字典为有数据的才显示
上级
56c5b03a
全部展开
显示空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
77 行增加
和
45 行删除
+77
-45
culturalRelic.js
src/api/culturalRelic.js
+10
-0
display.js
src/api/display.js
+8
-0
index.vue
src/components/ListBanner/index.vue
+20
-10
index.vue
src/views/culturalRelic/index.vue
+38
-33
index.vue
src/views/display/index.vue
+0
-0
Detail.vue
src/views/museum/Detail.vue
+1
-2
没有找到文件。
src/api/culturalRelic.js
浏览文件 @
0ccdac09
...
@@ -41,3 +41,13 @@ export function getRecommendCr(params) {
...
@@ -41,3 +41,13 @@ export function getRecommendCr(params) {
params
params
})
})
}
}
// 获取存在文物的字典
export
function
getCrExistDict
(
params
)
{
return
request
({
url
:
'/bizCulturalRelic/existDict'
,
method
:
'get'
,
params
})
}
src/api/display.js
浏览文件 @
0ccdac09
...
@@ -23,3 +23,11 @@ export function getRecommendDisplay(params){
...
@@ -23,3 +23,11 @@ export function getRecommendDisplay(params){
params
params
})
})
}
}
export
function
getDisplayExistDict
(
params
){
return
request
({
url
:
'/bizExhibition/existDict'
,
method
:
'get'
,
params
})
}
src/components/ListBanner/index.vue
浏览文件 @
0ccdac09
...
@@ -6,11 +6,11 @@
...
@@ -6,11 +6,11 @@
</div>
</div>
<div
class=
"text"
>
{{
title
}}
</div>
<div
class=
"text"
>
{{
title
}}
</div>
</div>
-->
</div>
-->
<div
class=
"total"
>
<div
class=
"total"
>
<div
class=
"total-title"
>
{{
title
}}
</div>
<div
class=
"total-title"
>
{{
title
}}
</div>
<div
class=
"amount"
>
<div
class=
"amount"
>
<span
class=
"num"
>
{{
num
}}
</span>
<span
class=
"num"
>
{{
num
}}
</span>
<span
class=
"unit"
>
{{
unit
}}
</span>
<span
class=
"unit"
>
{{
unit
}}
</span>
</div>
</div>
</div>
</div>
<!--
<div
class=
"banner-1"
>
<!--
<div
class=
"banner-1"
>
...
@@ -30,11 +30,11 @@ export default {
...
@@ -30,11 +30,11 @@ export default {
type
:
String
,
type
:
String
,
default
:
"标题"
,
default
:
"标题"
,
},
},
num
:{
num
:
{
type
:
String
,
type
:
[
String
,
Number
]
,
default
:
'0'
,
default
:
'0'
,
},
},
unit
:{
unit
:
{
type
:
String
,
type
:
String
,
default
:
'个'
,
default
:
'个'
,
},
},
...
@@ -47,11 +47,12 @@ export default {
...
@@ -47,11 +47,12 @@ export default {
width
:
100%
;
width
:
100%
;
height
:
360px
;
height
:
360px
;
position
:
relative
;
position
:
relative
;
background-image
:
linear-gradient
(
to
right
,
$themeColor
,
rgba
(
$themeColor
,
0
.9
)
,
$themeColor
);
background-image
:
linear-gradient
(
to
right
,
$themeColor
,
rgba
(
$themeColor
,
0
.9
)
,
$themeColor
);
padding
:
0
13%
;
padding
:
0
13%
;
display
:
flex
;
display
:
flex
;
align-items
:
center
;
align-items
:
center
;
justify-content
:
space-between
;
justify-content
:
space-between
;
// height: 222px;
// height: 222px;
// background-image: url("@/assets/imgs/list/banner2.png");
// background-image: url("@/assets/imgs/list/banner2.png");
// background-size:100% 100%;
// background-size:100% 100%;
...
@@ -71,18 +72,22 @@ export default {
...
@@ -71,18 +72,22 @@ export default {
.total-title
{
.total-title
{
font-size
:
28px
;
font-size
:
28px
;
}
}
.amount
{
.amount
{
font-weight
:
bold
;
font-weight
:
bold
;
.num
{
.num
{
font-size
:
56px
;
font-size
:
56px
;
font-family
:
$puHuiTi
;
font-family
:
$puHuiTi
;
}
}
.unit
{
.unit
{
font-size
:
$font-size-base
;
font-size
:
$font-size-base
;
}
}
}
}
}
}
// .banner-1 {
// .banner-1 {
// position: absolute;
// position: absolute;
// left: 620px;
// left: 620px;
...
@@ -100,25 +105,30 @@ export default {
...
@@ -100,25 +105,30 @@ export default {
// top: 54%;
// top: 54%;
margin-top
:
30px
;
margin-top
:
30px
;
width
:
520px
;
width
:
520px
;
img
{
img
{
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
}
}
}
}
.title
{
.title
{
padding
:
0
13%
;
padding
:
0
13%
;
display
:
flex
;
display
:
flex
;
align-items
:
flex-end
;
align-items
:
flex-end
;
.img-container
{
.img-container
{
width
:
58px
;
width
:
58px
;
height
:
58px
;
height
:
58px
;
margin-right
:
26px
;
margin-right
:
26px
;
img
{
img
{
width
:
100%
;
width
:
100%
;
height
:
100%
;
height
:
100%
;
object-fit
:
contain
;
object-fit
:
contain
;
}
}
}
}
.text
{
.text
{
font-size
:
28px
;
font-size
:
28px
;
font-weight
:
400
;
font-weight
:
400
;
...
...
src/views/culturalRelic/index.vue
浏览文件 @
0ccdac09
<
template
>
<
template
>
<div
class=
"cultural-relic"
>
<div
class=
"cultural-relic"
>
<ListBanner
title=
"
文物展
"
unit=
"件/套"
:num=
"list.total"
/>
<ListBanner
title=
"
共计文物
"
unit=
"件/套"
:num=
"list.total"
/>
<div
class=
"search-bar wow animate__animated animate__fadeIn"
>
<div
class=
"search-bar wow animate__animated animate__fadeIn"
>
<div
class=
"search-wrapper"
>
<div
class=
"search-wrapper"
>
<div
class=
"search-item"
@
click=
"handleClickSearchBar('type')"
>
<div
class=
"search-item"
@
click=
"handleClickSearchBar('type')"
>
...
@@ -160,7 +160,7 @@
...
@@ -160,7 +160,7 @@
<
script
>
<
script
>
import
ListBanner
from
"@/components/ListBanner"
;
import
ListBanner
from
"@/components/ListBanner"
;
import
{
getCulturalRelicList
}
from
"@/api/culturalRelic"
;
import
{
getCulturalRelicList
,
getCrExistDict
}
from
"@/api/culturalRelic"
;
import
{
mapGetters
}
from
"vuex"
;
import
{
mapGetters
}
from
"vuex"
;
export
default
{
export
default
{
name
:
"CulturalRelic"
,
name
:
"CulturalRelic"
,
...
@@ -209,43 +209,48 @@ export default {
...
@@ -209,43 +209,48 @@ export default {
value
:
""
,
value
:
""
,
}
}
];
];
await
this
.
$store
.
dispatch
(
"dict/getDictList"
,
[
"culturalRelicType"
]);
let
res
=
await
getCrExistDict
()
for
(
const
key
in
this
.
dicts
.
culturalRelicType
)
{
let
resTypeList
=
res
.
data
.
typeList
let
resYearList
=
res
.
data
.
yearDictList
resTypeList
.
map
(
item
=>
{
typeList
.
push
({
typeList
.
push
({
label
:
this
.
dicts
.
culturalRelicType
[
key
],
label
:
item
.
label
,
value
:
key
,
value
:
item
.
value
});
})
}
})
resYearList
.
map
(
item
=>
{
yearList
.
push
({
label
:
item
.
label
,
value
:
item
.
value
})
})
this
.
typeList
=
typeList
;
this
.
typeList
=
typeList
;
let
res
=
await
this
.
$store
.
dispatch
(
"dict/getDictTree"
,
[
"culturalRelicYears"
,
]);
this
.
culturalRelicYears
=
res
.
culturalRelicYears
;
traveseYears
(
this
.
culturalRelicYears
);
this
.
yearList
=
yearList
;
this
.
yearList
=
yearList
;
// 获取叶子节点
// await this.$store.dispatch("dict/getDictList", ["culturalRelicType"]);
function
traveseYears
(
arr
)
{
// for (const key in this.dicts.culturalRelicType) {
if
(
arr
&&
arr
.
length
>
0
)
{
// typeList.push({
arr
.
map
((
item
)
=>
{
// label: this.dicts.culturalRelicType[key],
if
(
item
.
children
&&
item
.
children
.
length
>
0
)
{
// value: key,
traveseYears
(
item
.
children
);
// });
}
else
{
// }
yearList
.
push
({
value
:
item
.
value
,
// let res = await this.$store.dispatch("dict/getDictTree", [
label
:
item
.
label
,
// "culturalRelicYears",
});
// ]);
}
// this.culturalRelicYears = res.culturalRelicYears;
});
// traveseYears(this.culturalRelicYears);
}
}
// // 获取叶子节点
// 删除无children的节点
// function traveseYears(arr) {
// function traveseYears(arr) {
// if (arr && arr.length > 0) {
// if (arr && arr.length > 0) {
// arr.map((item) => {
// arr.map((item) => {
// if (item.children && item.children.length == 0) {
// if (item.children && item.children.length > 0) {
// delete item.children;
// } else {
// traveseYears(item.children);
// traveseYears(item.children);
// } else {
// yearList.push({
// value: item.value,
// label: item.label,
// });
// }
// }
// });
// });
// }
// }
...
@@ -524,7 +529,7 @@ $text-indent: 16px;
...
@@ -524,7 +529,7 @@ $text-indent: 16px;
.search-panel
{
.search-panel
{
min-height
:
100px
;
min-height
:
100px
;
max-height
:
138px
;
max-height
:
138px
;
background
:
rgb
(
#8ac7ff
,
1
)
url("@/assets/imgs/home/panel-bg.png")
;
background
:
rgb
(
$themeColor
,
0
.15
)
url("@/assets/imgs/home/panel-bg.png")
;
width
:
100%
;
width
:
100%
;
display
:
flex
;
display
:
flex
;
justify-content
:
center
;
justify-content
:
center
;
...
...
src/views/display/index.vue
浏览文件 @
0ccdac09
差异被折叠。
点击展开。
src/views/museum/Detail.vue
浏览文件 @
0ccdac09
...
@@ -43,7 +43,6 @@
...
@@ -43,7 +43,6 @@
<i
class=
"el-icon-phone"
></i>
<i
class=
"el-icon-phone"
></i>
<span>
{{
museumDetail
.
phone
}}
</span>
<span>
{{
museumDetail
.
phone
}}
</span>
</div>
</div>
<div
v-if=
"!museumDetail.phone"
>
暂无联系方式
</div>
<div
v-if=
"!museumDetail.phone"
>
暂无联系方式
</div>
</div>
</div>
</div>
</div>
...
@@ -81,7 +80,7 @@ export default {
...
@@ -81,7 +80,7 @@ export default {
tabbars
:
[
tabbars
:
[
'简介'
,
'入园方式'
,
'联系方式'
,
'简介'
,
'入园方式'
,
'联系方式'
,
],
],
currentTab
:
''
currentTab
:
'
简介
'
};
};
},
},
mounted
()
{
mounted
()
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论