Browse Source

首页背景去除,其他界面当前位置标题更新

master
aBin 3 years ago
parent
commit
b602c12003
  1. 15
      src/components/ListPage/ListPage.vue
  2. 26
      src/views/CompanyProfile/CompanyProfile.vue
  3. 375
      src/views/FirstPages/FirstPage.vue
  4. 28
      src/views/NewPages/NewPages.vue
  5. 26
      src/views/OtherPages/Department.vue
  6. 26
      src/views/OtherPages/Information.vue
  7. 28
      src/views/OtherPages/NoticeNotice.vue
  8. 28
      src/views/OtherPages/PartyBuilding.vue
  9. 33
      src/views/OtherPages/SafeProduction.vue
  10. 26
      src/views/OtherPages/System.vue

15
src/components/ListPage/ListPage.vue

@ -1,5 +1,5 @@
<template>
<div style="position:relative;height: 100%;">
<div style="position:relative;min-height: 300px;">
<div class="year-box">
<span :class="year - 0 === item.year - 0 ? 'active' : ''" v-for="item in yearList" :key="item.year" @click="changeYear(item.year)">{{
item.year
@ -56,6 +56,9 @@ export default {
this.getYear();
},
},
created() {
this.getYear();
},
methods: {
onChange(pageNumber) {
this.$emit('getData', pageNumber);
@ -72,7 +75,15 @@ export default {
const params = { showPage: this.code };
const res = await getCondition(params);
console.log('res: ', res);
} catch (error) {}
const { code, msg, data } = res.data;
if (code === 200) {
this.yearList = data;
} else {
console.error(msg);
}
} catch (error) {
console.error(error);
}
},
},
};

26
src/views/CompanyProfile/CompanyProfile.vue

@ -1,19 +1,19 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -26,6 +26,7 @@ export default {
data() {
return {
code: '0101',
defaultTitle: '公司简介',
list: {
title: '公司概况',
url: '/profile',
@ -59,6 +60,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getData(this.code);
}
},

375
src/views/FirstPages/FirstPage.vue

@ -1,19 +1,99 @@
<template>
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="news-box pt-4 d-flex justify-space-between">
<!-- 集团新闻 -->
<div class="flex-1 mr-4 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">集团新闻</div>
<!-- <div class="bg-bottom">
<div class="bg-top"> -->
<div style="background-color:#f5f5f5;padding-bottom:100px">
<div class="content-1180">
<div class="news-box pt-4 d-flex justify-space-between">
<!-- 集团新闻 -->
<div class="flex-1 mr-4 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">集团新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0201', '')">更多></div>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in groupNews" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0201', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
</div>
<!-- 省公司新闻 -->
<div class="flex-1 mr-4 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">省公司新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0202', '')">更多></div>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in provincialNews" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0201', '')">更多></div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0202', newContent.introId)">{{ newContent.title }}</div>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in groupNews" :key="newContent.introId">
</div>
</div>
<!-- 公司新闻 -->
<div class="flex-1 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">公司新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0203', '')">更多></div>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in companyNews" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0203', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
</div>
</div>
<div class="mt-4 policy">
<img src="@/assets/16fangzhen.png" alt="" />
<p>
<span class="mr-4">战略引领</span>
<span class="mr-4">人才驱动</span>
<span class="mr-4">求真务实</span>
<span>开拓创新</span>
</p>
</div>
<!-- 图片新闻 -->
<div class="news-img p-4 mt-4 d-flex flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">图片新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0204', '')">更多></div>
</div>
<div class="flex-1 flex-column justify-space-between mt-4">
<div class="flex-1">
<div class="flex-1 mr-4">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews1" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews1" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
@ -22,17 +102,9 @@
</div>
</div>
</div>
<!-- 省公司新闻 -->
<div class="flex-1 mr-4 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">省公司新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0202', '')">更多></div>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in provincialNews" :key="newContent.introId">
<div class="flex-1 mt-4">
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews2" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
@ -40,18 +112,30 @@
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0202', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
<div class="flex-1 ml-4">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews2" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
</div>
<!-- 公司新闻 -->
<div class="flex-1 p-4 flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">公司新闻</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0203', '')">更多></div>
<div class="flex-1 mt-4">
<div class="flex-1 mr-4">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews3" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
<div class="new-box-content d-flex flex-column justify-space-between pt-4">
<div class="d-flex" v-for="newContent in companyNews" :key="newContent.introId">
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews3" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
@ -61,179 +145,102 @@
</div>
</div>
</div>
<div class="mt-4 policy">
<img src="@/assets/16fangzhen.png" alt="" />
<p>
<span class="mr-4">阿弥陀佛</span>
<span class="mr-4">阿弥陀佛</span>
<span class="mr-4">阿弥陀佛</span>
<span>阿弥陀佛</span>
</p>
</div>
<!-- 图片新闻 -->
<div class="news-img p-4 mt-4 d-flex flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">图片新闻</div>
</div>
<!-- 专题报道 光荣榜 今天我出镜 -->
<div class="honor-box mt-4 p-4 d-flex justify-space-between">
<div class="flex-1 flex-column content-honor mr-4 p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
专题报道
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0204', '')">更多></div>
</div>
<div class="flex-1 flex-column justify-space-between mt-4">
<div class="flex-1">
<div class="flex-1 mr-4">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews1" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews1" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0201', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
<div class="flex-1 mt-4">
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews2" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0202', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
<div class="flex-1">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews2" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
</div>
<div class="flex-1 mt-4">
<div class="flex-1 mr-4">
<a-carousel style="width: 650px" autoplay>
<div class="rotation-box" v-for="newContent in ImgNews3" :key="newContent.introId">
<img :src="newContent.titleUrl" style="height: 369.5px;width: 100%" alt="" />
<div class="rotation-div one-text">
{{ newContent.title }}
</div>
</div>
</a-carousel>
</div>
<div class="news-img-content d-flex flex-column justify-space-between p-4">
<div class="d-flex" v-for="newContent in ImgNews3" :key="newContent.introId">
<div class="content-date">
<div class="content-date-day">{{ $moment(+newContent.publishTime).format('DD') }}</div>
<div class="content-date-year">{{ $moment(+newContent.publishTime).format('YYYY-MM') }}</div>
</div>
<div class="flex-1 new-box-content-jj" @click="openPage('news', '0203', newContent.introId)">{{ newContent.title }}</div>
</div>
</div>
</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in specialList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
</div>
</div>
<!-- 专题报道 光荣榜 今天我出镜 -->
<div class="honor-box mt-4 p-4 d-flex justify-space-between">
<div class="flex-1 flex-column content-honor mr-4 p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
专题报道
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
<div class="flex-1 flex-column content-honor mr-4 p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
光荣榜
</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in specialList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
</div>
<div class="flex-1 flex-column content-honor mr-4 p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
光荣榜
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in gloryList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in gloryList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
</div>
<div class="flex-1 flex-column content-honor p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
今天我出镜
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
</div>
<div class="flex-1 flex-column content-honor p-4">
<div class="honor-title d-flex justify-space-between">
<div style="font-size:22px">
<img style="height:26px" src="@/assets/honor-title.png" alt="" />
今天我出镜
</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in exitList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
<div class="d-flex align-center" style="cursor: pointer;">
更多>
</div>
</div>
</div>
<!-- 职工风采 -->
<div class="news-demeanor mt-4 p-4 d-flex flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">职工风采</div>
<div class="flex-1 flex-column justify-space-between pt-4">
<div v-for="item in exitList" :key="item.introId" class="d-flex justify-space-between">
<div class="one-text" style="cursor: pointer;">{{ item.title }}</div>
<div class="ml-4">{{ $moment(item.publishTime).format('MM/DD') }}</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0210', '')">更多></div>
</div>
<div class="mt-4" style="overflow: hidden;">
<div class="demeanor-content-box">
<div class="demeanor-content mr-4" v-for="item in sceneStyle" :key="item.introId" @click="openPage('news', '0210', item.introId)">
<img :src="item.titleUrl" style="height:260px;width:100%;cursor: pointer;" :title="item.title" />
<div class="one-text-1">
{{ item.title }}
</div>
</div>
</div>
<!-- 职工风采 -->
<div class="news-demeanor mt-4 p-4 d-flex flex-column">
<div class="new-box-title d-flex justify-space-between">
<div class="d-flex align-start">
<div class="icon-red mr-1" style="margin-top: 10px;"></div>
<div style="font-size:22px;color: #333;font-weight:600;margin-top:3px;">职工风采</div>
</div>
<div class="d-flex align-center" style="height: 100%;cursor: pointer;" @click="openPage('news', '0210', '')">更多></div>
</div>
<div class="mt-4" style="overflow: hidden;">
<div class="demeanor-content-box">
<div
class="demeanor-content mr-4"
v-for="item in sceneStyle"
:key="item.introId"
@click="openPage('news', '0210', item.introId)"
>
<img :src="item.titleUrl" style="height:260px;width:100%;cursor: pointer;" :title="item.title" />
<div class="one-text-1">
{{ item.title }}
</div>
<div
class="demeanor-content mr-4"
v-for="item in sceneStyle"
:key="item.introId + '1'"
@click="openPage('news', '0210', item.introId)"
>
<img :src="item.titleUrl" style="height:260px;width:100%;cursor: pointer;" :title="item.title" />
<div class="one-text-1">
{{ item.title }}
</div>
</div>
<div
class="demeanor-content mr-4"
v-for="item in sceneStyle"
:key="item.introId + '1'"
@click="openPage('news', '0210', item.introId)"
>
<img :src="item.titleUrl" style="height:260px;width:100%;cursor: pointer;" :title="item.title" />
<div class="one-text-1">
{{ item.title }}
</div>
</div>
</div>
</div>
<BayWindow v-if="content && content.title" :content="content" @closeBay="closeBay" />
</div>
<BayWindow v-if="content && content.title" :content="content" @closeBay="closeBay" />
</div>
</div>
<!-- </div>
</div> -->
</template>
<script>
import { mapActions } from 'vuex';

28
src/views/NewPages/NewPages.vue

@ -1,20 +1,20 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -28,6 +28,7 @@ export default {
data() {
return {
code: '0201',
defaultTitle: '集团新闻',
list: {
title: '新闻中心',
url: '/news',
@ -85,6 +86,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getContentData();
}
},

26
src/views/OtherPages/Department.vue

@ -1,19 +1,19 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -26,6 +26,7 @@ export default {
data() {
return {
code: '0901',
defaultTitle: '总经理工作部',
list: {
title: '部门首页',
url: '/department',
@ -103,6 +104,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getData(this.code);
}
},

26
src/views/OtherPages/Information.vue

@ -1,19 +1,19 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -26,6 +26,7 @@ export default {
data() {
return {
code: '0601',
defaultTitle: '基本信息',
list: {
title: '信息公开',
url: '/information',
@ -59,6 +60,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getData(this.code);
}
},

28
src/views/OtherPages/NoticeNotice.vue

@ -1,20 +1,20 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -28,6 +28,7 @@ export default {
data() {
return {
code: '0501',
defaultTitle: '通知',
list: {
title: '通知公告',
url: '/notice',
@ -65,6 +66,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getContentData();
}
},

28
src/views/OtherPages/PartyBuilding.vue

@ -1,20 +1,20 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -28,6 +28,7 @@ export default {
data() {
return {
code: '0301',
defaultTitle: '中心组学习',
list: {
title: '党的建设',
url: '/building',
@ -69,6 +70,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getContentData();
}
},

33
src/views/OtherPages/SafeProduction.vue

@ -1,20 +1,20 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<ListPage v-if="!introId" :code="code" @changeYear="changeYear" :content="content" @getData="getData" />
<RichText v-else :rich-obj="introContent" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -28,9 +28,10 @@ export default {
data() {
return {
code: '0401',
defaultTitle: '安全会议',
list: {
title: '安全生产',
url: 'production',
url: '/production',
children: [
{
title: '安全会议',
@ -63,8 +64,16 @@ export default {
},
watch: {
'$route.query.code'(val) {
console.log('val: ', val);
console.log('this.$route.path: ', this.$route.path);
console.log('this.list.url: ', this.list.url);
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getContentData();
}
},

26
src/views/OtherPages/System.vue

@ -1,19 +1,19 @@
<template>
<div class="bg-bottom">
<div class="bg-bottom">
<div class="bg-top">
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="list.title" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
<div class="content-1180">
<div class="d-flex pt-4">
<LeftNav :code="code" :list="list" class="mr-4" @chanegCode="chanegCode" />
<div class="flex-1 flex-column">
<Location :title="defaultTitle" />
<div class="content-detail p-4" :style="{ 'min-height': list.children.length * 56 + 'px' }">
<RichText :rich-obj="content" />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapActions } from 'vuex';
@ -26,6 +26,7 @@ export default {
data() {
return {
code: '0801',
defaultTitle: '集团公司制度',
list: {
title: '制度资料',
url: '/system',
@ -71,6 +72,11 @@ export default {
'$route.query.code'(val) {
if (this.$route.path === this.list.url) {
this.code = val;
for (let i = 0; i < this.list.children.length; i++) {
if (val === this.list.children[i].code) {
this.defaultTitle = this.list.children[i].title;
}
}
this.getData(this.code);
}
},

Loading…
Cancel
Save