123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136 |
- <template>
- <view>
- <!--#ifdef APP-PLUS-->
- <view class="lz-status_bar">
- <view class="lz-top_view"></view>
- </view>
- <!--#endif-->
- <!-- #ifndef MP-WEIXIN -->
- <view class="kaoshi-head">
- <view class="kaoshi-head-top">
- <view class="kaoshi-head-left" @tap="$navigateBack">
- <view class="iconfont icon-zuojiantou"></view>
- </view>
- <view class="kaoshi-head-m">{{title}}</view>
- <view class="kaoshi-head-right"></view>
- </view>
- </view>
- <!--#endif-->
- <view class="index-tiku notice-detail" v-if="info.title != undefined">
- <view class="notice-detail-title">{{info.title}}</view>
- <view class="notice-detail-time">
- <view class="pub-gray">发布时间:{{info.noticetime}}</view>
- </view>
- <view class="notice-detail-content">
- <!-- <uParse :content="info.content + ''" /> -->
- <view class="" v-html="info.content">
-
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- mapState
- } from 'vuex';
- import uParse from '@/components/uParse/gaoyia-parse/parse.vue';
- export default {
- data() {
- return {
- info: {},
- id: 0,
- title: '',
- }
- },
- components: {
- uParse
- },
- computed: {
- ...mapState(['subject', 'userinfo']),
- },
- onShow() {
- this.getJiaocheng()
- },
- onLoad(opts) {
- if (opts && opts.id) {
- this.id = opts.id
- console.log(opts.type);
- if (opts.type == 1) {
- this.title = '资讯详情'
- uni.setNavigationBarTitle({
- title: "资讯详情"
- });
- } else if (opts.type == 2) {
- this.title = '通知详情'
- uni.setNavigationBarTitle({
- title: "通知详情"
- });
- }
- }
- // #ifdef MP-WEIXIN
- wx.showShareMenu({
- withShareTicket: true,
- menus: ["shareAppMessage", "shareTimeline"]
- })
- // #endif
- },
- methods: {
- async getJiaocheng() {
- let res = await this.$myHttp.post({
- url: this.$myHttp.urlMap.articleInfo,
- data: {
- id: this.id,
- subject_id: this.subject.id,
- },
- needLogin: false,
- })
- if (res.code == 1) {
- this.info = res.data
- // console.log(typeof(this.info.content))
- }
- },
- }
- }
- </script>
- <style>
- page {
- background: #fff;
- }
- /*消息详情*/
- .notice-detail {
- width: 92%;
- margin: 12px auto;
- font-size: 16px;
- }
- .notice-detail-content image {
- width: 100% !important;
- }
- .notice-detail-title {
- font-size: 18px;
- font-weight: bold;
- }
- .notice-detail-time {
- display: flex;
- font-size: 14px;
- align-items: center;
- margin: 10px 0 9px;
- }
- .notice-detail-blue {
- color: #000;
- font-weight: bold;
- margin-right: 10px;
- font-size: 15px;
- }
- .notice-detail-content {
- line-height: 23px;
- }
- </style>
|