后台小说发布功能上线

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);

View File

@ -6,9 +6,9 @@ spring:
# url: jdbc:mysql://148.70.59.92:3306/books?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
# username: xiongxiaoyang
# password: Lzslov123!
url: jdbc:mysql://127.0.0.1:3306/books?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
url: jdbc:mysql://127.0.0.1:3306/books?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Shanghai
username: books
password: books!8888
password: books
cache:
ehcache:
config: classpath:ehcache.xml