123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- <template>
- <view class="container">
- <!-- <uni-title type="h1" align="center" :title="info.title || info.noticeTitle"></uni-title>
- <text class="time">创建时间:{{ info.createTime }}</text> -->
- <rich-text image-menu-prevent="true" :nodes="info.content || info.noticeContent" class="content"></rich-text>
- <!-- <view class="content" v-html="info.content || info.noticeContent"> -->
- </view>
- </view>
- </template>
- <script>
- import request from '../../api/cms.js';
- import requestNotice from '../../api/system.js';
- export default {
- onLoad: function (option) {
- this.id = option.id;
- },
- data() {
- return {
- id: '',
- info: null,
- }
- },
- async mounted() {
- const res = await request.getArticleDetail({ id: this.id });
- this.info = res.data;
- await request.addBlogViews({ id: this.id });
- },
- methods: {}
- }
- </script>
- <style>
- .time {
- width: 100%;
- text-align: center;
- display: block;
- font-size: 12px;
- }
- .content {
- display: block;
- width: 90%;
- margin: 10px auto;
- }
- </style>
|