审核帖子列表获取完整正文内容

change
ZHD 5 years ago
parent 6a54f2ec58
commit ccb72e9512
  1. 8
      src/app/forum/forum/forum.component.html
  2. 6
      src/app/forum/forum/forum.component.ts
  3. 6
      src/app/interface/ForumType.ts

@ -136,7 +136,7 @@
<h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1> <h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1>
<!-- 帖子正文--> <!-- 帖子正文-->
<div class="forum-content border-info overflow-auto col-9 offset-2 mb-3"> <div class="forum-content border-info overflow-auto col-9 offset-2 mb-3">
{{getForum().content}} {{getContent().content}}
</div> </div>
<!-- 帖子底部--> <!-- 帖子底部-->
<div class="forum-footer border-info p-3 mb-3"> <div class="forum-footer border-info p-3 mb-3">
@ -189,7 +189,7 @@
<h1 class="text-center">{{getForum().title}}</h1> <h1 class="text-center">{{getForum().title}}</h1>
<!-- 投诉内容--> <!-- 投诉内容-->
<div class="forum-content border-info overflow-auto mb-3"> <div class="forum-content border-info overflow-auto mb-3">
{{getForum().content}} {{getContent().content}}
</div> </div>
<!-- 投诉时间--> <!-- 投诉时间-->
<h1 <h1
@ -219,7 +219,7 @@
<h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1> <h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1>
<!-- 帖子正文--> <!-- 帖子正文-->
<div class="forum-content border-info overflow-auto col-9 offset-2 mb-3"> <div class="forum-content border-info overflow-auto col-9 offset-2 mb-3">
{{getForum().content}} {{getContent().content}}
</div> </div>
</div> </div>
</ng-container> </ng-container>
@ -246,7 +246,7 @@
<h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1> <h1 class="text-info col-12 text-center mb-3 forum-title">{{getForum().title}}</h1>
<!-- 帖子正文--> <!-- 帖子正文-->
<div class="forum-content border-info overflow-auto col-9 offset-2 mb-3"> <div class="forum-content border-info overflow-auto col-9 offset-2 mb-3">
{{getForum().content}} {{getContent().content}}
</div> </div>
</div> </div>

@ -2,7 +2,7 @@ import {Component, OnInit} from '@angular/core';
import {Router} from '@angular/router'; import {Router} from '@angular/router';
import {ForumService} from '../forum.service'; import {ForumService} from '../forum.service';
import {Result} from '../../interface/Result'; import {Result} from '../../interface/Result';
import {Active, Complaint, Forum, Score} from '../../interface/ForumType'; import {Active, Complaint, Forum, ForumContent, Score} from '../../interface/ForumType';
import {Notice} from '../../interface/Notice'; import {Notice} from '../../interface/Notice';
import {MessageInterface, MessageUtil} from '../../message/message.service'; import {MessageInterface, MessageUtil} from '../../message/message.service';
import {NoticeService} from '../notice/notice.service'; import {NoticeService} from '../notice/notice.service';
@ -68,6 +68,10 @@ export class ForumComponent implements OnInit, MessageInterface {
return this.posts.forumList.list[this.currentIndex]; return this.posts.forumList.list[this.currentIndex];
} }
getContent(): ForumContent {
return this.getForum().detailContent;
}
getActive(): Active { getActive(): Active {
return this.getForum().activeDto; return this.getForum().activeDto;
} }

@ -12,6 +12,10 @@ export enum ForumStatus {
ok = 'ok', ok = 'ok',
fail = 'fail' fail = 'fail'
} }
export interface ForumContent {
// 正文
content: string;
}
export interface Forum { export interface Forum {
// 帖子 // 帖子
@ -36,6 +40,8 @@ export interface Forum {
score: Score; score: Score;
// 发帖人详情信息 // 发帖人详情信息
info: Info; info: Info;
// 1楼信息
detailContent: ForumContent;
} }

Loading…
Cancel
Save