后台小说发布功能上线

This commit is contained in:
xiongxiaoyang
2019-11-20 12:04:57 +08:00
parent e08f91f130
commit dfc7d7184f
184 changed files with 98 additions and 16353 deletions

View File

@ -2,6 +2,7 @@ package xyz.zinglizingli.books.web;
import com.github.pagehelper.PageInfo;
import org.apache.commons.text.StringEscapeUtils;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
@ -246,6 +247,9 @@ public class BookController {
modelMap.put("bookContent", bookContent);
modelMap.put("indexName", indexName);
Book basicBook = bookService.queryBaseInfo(bookId);
if(basicBook.getCatid() < 8) {
bookContent.setContent(StringEscapeUtils.unescapeHtml4(bookContent.getContent()));
}
String bookName = basicBook.getBookName();
Integer catId = basicBook.getCatid();
modelMap.put("bookName", bookName);