|
|
@@ -3,15 +3,15 @@
|
|
|
<div class="titleBox">
|
|
|
<!-- <div class="titleStyle">【{{contentData.title}}】{{contentData.addtime}}</div> -->
|
|
|
<div class="titleStyle">{{contentData.title}}</div>
|
|
|
- <span @click="backToPre()">返回上一级</span>
|
|
|
+ <div class="backStyle" @click="backToPre()">返回上一级</div>
|
|
|
</div>
|
|
|
<div style=" border: 1px solid #ccc"></div>
|
|
|
<div class="content">
|
|
|
<!--{{contentData.content || '-'}}-->
|
|
|
<p v-html="contentData.content"></p>
|
|
|
</div>
|
|
|
- <div class="files">
|
|
|
- <p style="width: 65px">附件:</p>
|
|
|
+ <div class="files" v-if="showFileLength">
|
|
|
+ <p style="width: 65px" >附件:</p>
|
|
|
<div class="filesName">
|
|
|
<p v-for="(item, index) in contentData.files"
|
|
|
:key="index"
|
|
|
@@ -32,6 +32,7 @@ export default {
|
|
|
return {
|
|
|
contentData:{},
|
|
|
unifiedUrl:'/lexus_php/api/',
|
|
|
+ showFileLength:''
|
|
|
};
|
|
|
},
|
|
|
computed: {},
|
|
|
@@ -55,15 +56,17 @@ export default {
|
|
|
},
|
|
|
})
|
|
|
.then((res) => {
|
|
|
- console.log(res)
|
|
|
if (res.data.code === 200) {
|
|
|
- console.log(res)
|
|
|
this.contentData = {
|
|
|
addtime:res.data.addtime,
|
|
|
content:res.data.content,
|
|
|
title:res.data.title,
|
|
|
files:res.data.files
|
|
|
- }
|
|
|
+ };
|
|
|
+ this.showFileLength = this.contentData.files.length
|
|
|
+ console.log(this.showFileLength)
|
|
|
+ }else {
|
|
|
+ alert('发生错误,请稍后再试')
|
|
|
}
|
|
|
})
|
|
|
.catch((err) => {
|
|
|
@@ -87,9 +90,9 @@ export default {
|
|
|
align-items: center;
|
|
|
justify-content: space-between;
|
|
|
}
|
|
|
-.titleBox span{
|
|
|
+.backStyle {
|
|
|
+ margin-right: 10px;
|
|
|
color: #0000ff;
|
|
|
- text-align: right;
|
|
|
cursor: pointer;
|
|
|
}
|
|
|
.notice_jingXiaoshang_detail {
|