Compare commits

...

50 Commits

Author SHA1 Message Date
3a7972a47c Merge remote-tracking branch 'Gitee/master' 2024-06-01 08:22:04 +08:00
976db9420e build: 修改版本号 2024-05-31 20:59:34 +08:00
e33db86081 Update README.md 2024-05-28 12:34:00 +08:00
48a70c2aca build: 修改版本号 2024-05-28 09:45:23 +08:00
ea5c0e8bd1 模版更新 2024-05-28 09:42:27 +08:00
b0c249cdca fix: 默认logo图片失效 2024-05-26 22:50:57 +08:00
730fcb4c76 fix: 默认logo图片失效 2024-05-26 22:46:46 +08:00
b976a00389 perf: UI优化 2024-05-26 22:31:26 +08:00
6d9b563583 fix: 文件上传大小限制 2024-05-25 22:05:03 +08:00
bfb7d6cc5c fix: i笔趣阁域名更换 2024-05-12 17:26:59 +08:00
9d4dc409c6 fix: URI编码 2024-03-03 11:10:46 +08:00
34d211afbf fix: 只推荐有内容的小说 2024-02-21 19:27:48 +08:00
2d218076c4 chore: 修改打包默认模版 2024-02-18 10:28:29 +08:00
674e4df84c chore: 模版更新 2024-02-07 14:59:31 +08:00
331f56d112 fix: 移动端首页在数据量小于10时报错 2024-02-07 14:58:36 +08:00
f494aae2c7 chore: 模版更新 2024-02-07 14:23:32 +08:00
2fc533f8ae fix(novel-crawl): 登录页样式问题 2024-02-05 21:12:41 +08:00
82758271e3 feat: 增加语音播放小说内容 2024-02-05 12:05:26 +08:00
4c82c2d720 perf: 优化支付宝支付流程 2024-02-04 12:25:26 +08:00
4665b5c4b9 fix: bug 2024-02-03 16:14:36 +08:00
7bbabb3492 fix: 修复充值页面的未登录跳转路径 2024-02-03 14:03:23 +08:00
d6093d8182 fix(novel-admin): 友情链接URL格式校验 2023-12-29 18:54:53 +08:00
f77792aa3c perf: 限制昵称长度并优化显示 2023-12-29 00:34:04 +08:00
c62da9bb3a fix: nickName、userPhoto 更新校验 2023-12-29 00:11:01 +08:00
8a63cff0b5 Update README.md 2023-10-31 08:24:54 +08:00
07bed12fa5 fix(mobile): 充值页标题 2023-10-30 14:17:03 +08:00
0d6e0ffb06 perf(mobile): 内容页优化
去掉小说内容前面的多余空格
2023-10-30 14:07:31 +08:00
e7005004bb perf(mobile): 登录/注册页优化 2023-10-30 14:01:39 +08:00
ff68cdd829 perf(mobile): 首页优化 2023-10-30 14:01:24 +08:00
b61dc4d0d5 build(Docker): 管理 Dockerfile 文件 2023-10-22 19:20:52 +08:00
98f1f804c3 chore(sql): 自动创建 novel_plus 数据库 2023-10-22 19:07:32 +08:00
5978d6cbcc build: 修改版本号 2023-10-21 21:21:54 +08:00
ef290bed9c fix: 书架列表时间格式化 2023-10-21 21:02:00 +08:00
xxy
156f0378b2 Merge pull request #129 from 201206030/develop_xxy
分支合并
2023-10-15 20:40:18 +08:00
5543e5aa57 perf: 设置网站 ico 图标 2023-10-15 20:30:11 +08:00
0332802fe5 feat(crawl): 账号退出 2023-10-15 19:13:07 +08:00
a55f456b3d perf: 更新爬虫管理系统主题颜色 2023-10-15 17:54:44 +08:00
xxy
c66d56615f Merge pull request #128 from 201206030/develop_xxy
合并开发分支代码
2023-10-15 08:34:41 +08:00
f6d66e69fb Update README.md 2023-10-14 18:19:00 +08:00
96960789e1 fix(alipay): 修改默认支付宝支付成功跳转地址 2023-10-14 17:50:14 +08:00
1998dcd460 fix(alipay): 修复支付宝支付页面报错
沙箱环境自动升级到新版后,没有在代码中更换新版本的应用/网关/账号信息,也没有从左边栏沙箱工具中下载最新版本的沙箱支付宝APP安装使用。
2023-10-14 17:42:42 +08:00
a33d8f68a2 删除垃圾文件 2023-10-14 13:42:37 +08:00
30959da038 删除垃圾文件 2023-10-14 13:39:11 +08:00
5406783344 删除垃圾文件 2023-10-14 12:54:33 +08:00
d84345918b Update README.md 2023-10-14 10:32:46 +08:00
a5394cb426 Update README.md 2023-10-14 10:20:16 +08:00
2275b85752 chore: 模版更新 2023-10-14 10:16:41 +08:00
2062123edd perf(mobile): 去除手机网站底部空白间隙 2023-10-14 10:06:16 +08:00
255b3f8c4b feat(templates): 新增绿色主题模版,并设置为默认模版
和文档站点 docs.xxyopen.com 风格保持一致
2023-10-13 21:21:21 +08:00
00179359bd chore: 更新 Dockerfile 文件 2023-10-12 16:33:57 +08:00
709 changed files with 59298 additions and 19909 deletions

View File

@ -57,9 +57,17 @@ novel-plus -- 父工程
| Thymeleaf | 模板引擎 | Thymeleaf | 模板引擎
| Layui | 前端 UI 框架 | Layui | 前端 UI 框架
## 项目演示 ## 项目截图
https://www.bilibili.com/video/BV1Zo4y187Mi ### 绿色主题模版
[![点击查看大图](https://www.xxyopen.com/images/green_novel.png)](https://www.xxyopen.com/images/green_novel.png)
[![点击查看大图](https://www.xxyopen.com/images/resource/os/novel-plus/green3.png)](https://www.xxyopen.com/images/resource/os/novel-plus/green3.png)
[![点击查看大图](https://www.xxyopen.com/images/resource/os/novel-plus/green2.png)](https://www.xxyopen.com/images/resource/os/novel-plus/green2.png)
## 演示视频
https://www.bilibili.com/video/BV18e41197xs
## 增值服务 ## 增值服务

Binary file not shown.

Before

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 411 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 263 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 75 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 105 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 461 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 130 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 310 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 223 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 155 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 360 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 357 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 307 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 929 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 194 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 85 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 77 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 764 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 MiB

View File

@ -1,116 +0,0 @@
<h1 class="curproject-name"> 小说精品屋-plus </h1>
小说精品屋-plus接口
# 作家模块
## 小说章节分页列表查询接口
<a id=小说章节分页列表查询接口> </a>
### 基本信息
**Path** /book/queryIndexList
**Method** GET
**接口描述:**
<p>作家后台章节管理页面需要请求该接口获取小说章节分页列表信息</p>
### 请求参数
**Query**
| 参数名称 | 是否必须 | 示例 | 备注 |
| ------------ | ------------ | ------------ | ------------ |
| bookId | 是 | 1334337530296893441 | 小说ID |
| curr | 否 | 1 | 查询页码默认1 |
| limit | 否 | 5 | 分页大小默认5 |
### 返回数据
<table>
<thead class="ant-table-thead">
<tr>
<th key=name>名称</th><th key=type>类型</th><th key=required>是否必须</th><th key=default>默认值</th><th key=desc>备注</th><th key=sub>其他信息</th>
</tr>
</thead><tbody className="ant-table-tbody"><tr key=0-0><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> code</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应状态吗200表示成功</span></td><td key=5></td></tr><tr key=0-1><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> msg</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应信息</span></td><td key=5></td></tr><tr key=0-2><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> data</span></td><td key=1><span>object</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应数据</span></td><td key=5></td></tr><tr key=0-2-0><td key=0><span style="padding-left: 20px"><span style="color: #8c8a8a">├─</span> total</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">总数量</span></td><td key=5></td></tr><tr key=0-2-1><td key=0><span style="padding-left: 20px"><span style="color: #8c8a8a">├─</span> list</span></td><td key=1><span>object []</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">章节数据集合</span></td><td key=5><p key=3><span style="font-weight: '700'">item 类型: </span><span>object</span></p></td></tr><tr key=0-2-1-0><td key=0><span style="padding-left: 40px"><span style="color: #8c8a8a">├─</span> id</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">章节ID</span></td><td key=5></td></tr><tr key=0-2-1-1><td key=0><span style="padding-left: 40px"><span style="color: #8c8a8a">├─</span> bookId</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">小说ID</span></td><td key=5></td></tr><tr key=0-2-1-2><td key=0><span style="padding-left: 40px"><span style="color: #8c8a8a">├─</span> indexName</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">章节名</span></td><td key=5></td></tr><tr key=0-2-1-3><td key=0><span style="padding-left: 40px"><span style="color: #8c8a8a">├─</span> isVip</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">是否收费1:收费0:免费</span></td><td key=5></td></tr><tr key=0-2-1-4><td key=0><span style="padding-left: 40px"><span style="color: #8c8a8a">├─</span> updateTime</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">更新时间</span></td><td key=5></td></tr><tr key=0-2-2><td key=0><span style="padding-left: 20px"><span style="color: #8c8a8a">├─</span> pageNum</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">页码</span></td><td key=5></td></tr><tr key=0-2-3><td key=0><span style="padding-left: 20px"><span style="color: #8c8a8a">├─</span> pageSize</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">分页大小</span></td><td key=5></td></tr><tr key=0-2-4><td key=0><span style="padding-left: 20px"><span style="color: #8c8a8a">├─</span> size</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">当前页数量</span></td><td key=5></td></tr>
</tbody>
</table>
## 小说章节删除接口
<a id=小说章节删除接口> </a>
### 基本信息
**Path** /author/deleteIndex/{indexId}
**Method** DELETE
**接口描述:**
<p>作家后台章节管理页面点击删除按钮请求该接口删除小说章节内容</p>
### 请求参数
**Headers**
| 参数名称 | 参数值 | 是否必须 | 示例 | 备注 |
| ------------ | ------------ | ------------ | ------------ | ------------ |
| Content-Type | application/x-www-form-urlencoded | 是 | | |
| Authorization | | 是 | eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2MDgzNDg0NzksInN1YiI6IntcImlkXCI6MTI1NTA2MDMyODMyMjAyNzUyMCxcInVzZXJuYW1lXCI6XCIxMzU2MDQyMTMyNFwiLFwibmlja05hbWVcIjpcIjEzNTYwNDIxMzI0XCJ9IiwiY3JlYXRlZCI6MTYwNzc0MzY3OTkxM30.0qhwis_zPb6t8wGNejMhDZ2iHCL9Tgh2UHd1gcQBCp8t6RW3ggSwtfo4l_RgMT_v8jOkLW91GzTVWlNnTE6LCA | 认证JWT请求登录接口成功后返回 |
**路径参数**
| 参数名称 | 示例 | 备注 |
| ------------ | ------------ | ------------ |
| indexId | 1337603246936645632 | 章节ID |
### 返回数据
<table>
<thead class="ant-table-thead">
<tr>
<th key=name>名称</th><th key=type>类型</th><th key=required>是否必须</th><th key=default>默认值</th><th key=desc>备注</th><th key=sub>其他信息</th>
</tr>
</thead><tbody className="ant-table-tbody"><tr key=0-0><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> code</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应状态吗200表示成功</span></td><td key=5></td></tr><tr key=0-1><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> msg</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应信息</span></td><td key=5></td></tr>
</tbody>
</table>
## 小说章节发布接口
<a id=小说章节发布接口> </a>
### 基本信息
**Path** /author/addBookContent
**Method** POST
**接口描述:**
<p>作家后台章节发布页面点击提交按钮请求该接口新增小说章节内容</p>
### 请求参数
**Headers**
| 参数名称 | 参数值 | 是否必须 | 示例 | 备注 |
| ------------ | ------------ | ------------ | ------------ | ------------ |
| Content-Type | application/x-www-form-urlencoded | 是 | | |
| Authorization | | 是 | eyJhbGciOiJIUzUxMiJ9.eyJleHAiOjE2MDgzNDg0NzksInN1YiI6IntcImlkXCI6MTI1NTA2MDMyODMyMjAyNzUyMCxcInVzZXJuYW1lXCI6XCIxMzU2MDQyMTMyNFwiLFwibmlja05hbWVcIjpcIjEzNTYwNDIxMzI0XCJ9IiwiY3JlYXRlZCI6MTYwNzc0MzY3OTkxM30.0qhwis_zPb6t8wGNejMhDZ2iHCL9Tgh2UHd1gcQBCp8t6RW3ggSwtfo4l_RgMT_v8jOkLW91GzTVWlNnTE6LCA | 认证JWT请求登录接口成功后返回 |
**Body**
| 参数名称 | 参数类型 | 是否必须 | 示例 | 备注 |
| ------------ | ------------ | ------------ | ------------ | ------------ |
| bookId | text | 是 | 1334337530296893441 | 小说ID |
| indexName | text | 是 | 第六章未婚妻(下) | 章节名 |
| content | text | 是 | 开始之时,李七夜还是生疏无比,那怕他对于刀术的所有奥义了然于胸,但是,他出刀之时依然会颤抖,无法达到妙及巅毫的要求。 | 章节内容 |
| isVip | text | 是 | 1 | 是否收费1:收费0:免费 |
### 返回数据
<table>
<thead class="ant-table-thead">
<tr>
<th key=name>名称</th><th key=type>类型</th><th key=required>是否必须</th><th key=default>默认值</th><th key=desc>备注</th><th key=sub>其他信息</th>
</tr>
</thead><tbody className="ant-table-tbody"><tr key=0-0><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> code</span></td><td key=1><span>number</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应状态吗200表示成功</span></td><td key=5></td></tr><tr key=0-1><td key=0><span style="padding-left: 0px"><span style="color: #8c8a8a"></span> msg</span></td><td key=1><span>string</span></td><td key=2>必须</td><td key=3></td><td key=4><span style="white-space: pre-wrap">响应信息</span></td><td key=5></td></tr>
</tbody>
</table>

3
doc/sql/20240512.sql Normal file
View File

@ -0,0 +1,3 @@
update crawl_source
set crawl_rule = replace(crawl_rule, 'ibiquge.net', 'ibiquzw.org')
where id = 16;

2
doc/sql/Dockerfile Normal file
View File

@ -0,0 +1,2 @@
FROM mysql:8.0
COPY novel_plus.sql /docker-entrypoint-initdb.d/init.sql

View File

@ -1,20 +1,9 @@
/* CREATE
Navicat MySQL Data Transfer database if NOT EXISTS `novel_plus` default character set utf8mb4 collate utf8mb4_unicode_ci;
use
`novel_plus`;
Source Server : localhost SET NAMES utf8mb4;
Source Server Version : 50725
Source Host : localhost:3306
Source Database : novel_plus
Target Server Type : MYSQL
Target Server Version : 50725
File Encoding : 65001
Date: 2020-05-18 13:59:04
*/
SET
FOREIGN_KEY_CHECKS=0;
-- ---------------------------- -- ----------------------------
-- Table structure for author -- Table structure for author
@ -33,7 +22,9 @@ CREATE TABLE `author`
`status` tinyint(4) DEFAULT '0' COMMENT '0正常1封禁', `status` tinyint(4) DEFAULT '0' COMMENT '0正常1封禁',
`create_time` datetime DEFAULT NULL COMMENT '创建时间', `create_time` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COMMENT='作者表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 3
DEFAULT CHARSET = utf8mb4 COMMENT ='作者表';
-- ---------------------------- -- ----------------------------
-- Records of author -- Records of author
@ -58,7 +49,9 @@ CREATE TABLE `author_code`
`create_user_id` bigint(20) DEFAULT NULL COMMENT '创建人ID', `create_user_id` bigint(20) DEFAULT NULL COMMENT '创建人ID',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_code` (`invite_code`) USING BTREE UNIQUE KEY `key_code` (`invite_code`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COMMENT='作家邀请码表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 6
DEFAULT CHARSET = utf8mb4 COMMENT ='作家邀请码表';
-- ---------------------------- -- ----------------------------
-- Records of author_code -- Records of author_code
@ -105,7 +98,9 @@ CREATE TABLE `book`
UNIQUE KEY `key_uq_bookName_authorName` (`book_name`, `author_name`) USING BTREE, UNIQUE KEY `key_uq_bookName_authorName` (`book_name`, `author_name`) USING BTREE,
KEY `key_lastIndexUpdateTime` (`last_index_update_time`) USING BTREE, KEY `key_lastIndexUpdateTime` (`last_index_update_time`) USING BTREE,
KEY `key_createTime` (`create_time`) USING BTREE KEY `key_createTime` (`create_time`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1262260513468559361 DEFAULT CHARSET=utf8mb4 COMMENT='小说表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1262260513468559361
DEFAULT CHARSET = utf8mb4 COMMENT ='小说表';
-- ---------------------------- -- ----------------------------
-- Records of book -- Records of book
@ -130,7 +125,9 @@ CREATE TABLE `book_author`
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
`update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID', `update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1254957873655066625 DEFAULT CHARSET=utf8mb4 COMMENT='作者表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1254957873655066625
DEFAULT CHARSET = utf8mb4 COMMENT ='作者表';
-- ---------------------------- -- ----------------------------
-- Records of book_author -- Records of book_author
@ -151,7 +148,9 @@ CREATE TABLE `book_category`
`update_user_id` bigint(20) DEFAULT NULL, `update_user_id` bigint(20) DEFAULT NULL,
`update_time` datetime DEFAULT NULL, `update_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4 COMMENT='小说类别表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 8
DEFAULT CHARSET = utf8mb4 COMMENT ='小说类别表';
-- ---------------------------- -- ----------------------------
-- Records of book_category -- Records of book_category
@ -186,7 +185,9 @@ CREATE TABLE `book_comment`
`create_user_id` bigint(20) DEFAULT NULL COMMENT '评价人', `create_user_id` bigint(20) DEFAULT NULL COMMENT '评价人',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_bookid_userid` (`book_id`, `create_user_id`) USING BTREE UNIQUE KEY `key_uq_bookid_userid` (`book_id`, `create_user_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb4 COMMENT='小说评论表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 13
DEFAULT CHARSET = utf8mb4 COMMENT ='小说评论表';
-- ---------------------------- -- ----------------------------
-- Records of book_comment -- Records of book_comment
@ -209,7 +210,8 @@ CREATE TABLE `book_comment_reply`
`create_time` datetime DEFAULT NULL COMMENT '回复用户ID', `create_time` datetime DEFAULT NULL COMMENT '回复用户ID',
`create_user_id` bigint(20) DEFAULT NULL COMMENT '回复时间', `create_user_id` bigint(20) DEFAULT NULL COMMENT '回复时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='小说评论回复表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4 COMMENT ='小说评论回复表';
-- ---------------------------- -- ----------------------------
-- Records of book_comment_reply -- Records of book_comment_reply
@ -226,7 +228,9 @@ CREATE TABLE `book_content`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=3347665 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 3347665
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Records of book_content -- Records of book_content
@ -250,7 +254,9 @@ CREATE TABLE `book_index`
UNIQUE KEY `key_uq_bookId_indexNum` (`book_id`, `index_num`) USING BTREE, UNIQUE KEY `key_uq_bookId_indexNum` (`book_id`, `index_num`) USING BTREE,
KEY `key_bookId` (`book_id`) USING BTREE, KEY `key_bookId` (`book_id`) USING BTREE,
KEY `key_indexNum` (`index_num`) USING BTREE KEY `key_indexNum` (`index_num`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1262260612777095169 DEFAULT CHARSET=utf8mb4 COMMENT='小说目录表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1262260612777095169
DEFAULT CHARSET = utf8mb4 COMMENT ='小说目录表';
-- ---------------------------- -- ----------------------------
-- Records of book_index -- Records of book_index
@ -268,7 +274,9 @@ CREATE TABLE `book_screen_bullet`
`create_time` datetime NOT NULL COMMENT '创建时间', `create_time` datetime NOT NULL COMMENT '创建时间',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
KEY `key_contentId` (`content_id`) USING BTREE KEY `key_contentId` (`content_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=79 DEFAULT CHARSET=utf8mb4 COMMENT='小说弹幕表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 79
DEFAULT CHARSET = utf8mb4 COMMENT ='小说弹幕表';
-- ---------------------------- -- ----------------------------
-- Records of book_screen_bullet -- Records of book_screen_bullet
@ -289,7 +297,9 @@ CREATE TABLE `book_setting`
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
`update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID', `update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=64 DEFAULT CHARSET=utf8mb4 COMMENT='首页小说设置表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 64
DEFAULT CHARSET = utf8mb4 COMMENT ='首页小说设置表';
-- ---------------------------- -- ----------------------------
-- Records of book_setting -- Records of book_setting
@ -373,7 +383,8 @@ CREATE TABLE `crawl_batch_task`
`start_time` datetime DEFAULT NULL COMMENT '任务开始时间', `start_time` datetime DEFAULT NULL COMMENT '任务开始时间',
`end_time` datetime DEFAULT NULL COMMENT '任务结束时间', `end_time` datetime DEFAULT NULL COMMENT '任务结束时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='批量抓取任务表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4 COMMENT ='批量抓取任务表';
-- ---------------------------- -- ----------------------------
-- Records of crawl_batch_task -- Records of crawl_batch_task
@ -392,7 +403,8 @@ CREATE TABLE `crawl_single_task`
`exc_count` tinyint(2) DEFAULT '0' COMMENT '已经执行次数最多执行5次', `exc_count` tinyint(2) DEFAULT '0' COMMENT '已经执行次数最多执行5次',
`create_time` datetime DEFAULT NULL COMMENT '创建时间', `create_time` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='抓取单本小说任务表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4 COMMENT ='抓取单本小说任务表';
-- ---------------------------- -- ----------------------------
-- Records of crawl_single_task -- Records of crawl_single_task
@ -411,7 +423,9 @@ CREATE TABLE `crawl_source`
`create_time` datetime DEFAULT NULL COMMENT '创建时间', `create_time` datetime DEFAULT NULL COMMENT '创建时间',
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='爬虫源表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 5
DEFAULT CHARSET = utf8mb4 COMMENT ='爬虫源表';
-- ---------------------------- -- ----------------------------
-- Records of crawl_source -- Records of crawl_source
@ -449,7 +463,9 @@ CREATE TABLE `friend_link`
`update_user_id` bigint(20) DEFAULT NULL COMMENT '更新者用户id', `update_user_id` bigint(20) DEFAULT NULL COMMENT '更新者用户id',
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4; ) ENGINE = InnoDB
AUTO_INCREMENT = 6
DEFAULT CHARSET = utf8mb4;
-- ---------------------------- -- ----------------------------
-- Records of friend_link -- Records of friend_link
@ -474,7 +490,9 @@ CREATE TABLE `news`
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
`update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID', `update_user_id` bigint(20) DEFAULT NULL COMMENT '更新人ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COMMENT='新闻表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 3
DEFAULT CHARSET = utf8mb4 COMMENT ='新闻表';
-- ---------------------------- -- ----------------------------
-- Records of news -- Records of news
@ -502,7 +520,9 @@ CREATE TABLE `news_category`
`update_user_id` bigint(20) DEFAULT NULL, `update_user_id` bigint(20) DEFAULT NULL,
`update_time` datetime DEFAULT NULL, `update_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COMMENT='新闻类别表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 4
DEFAULT CHARSET = utf8mb4 COMMENT ='新闻类别表';
-- ---------------------------- -- ----------------------------
-- Records of news_category -- Records of news_category
@ -528,7 +548,9 @@ CREATE TABLE `order_pay`
`create_time` datetime DEFAULT NULL COMMENT '创建时间', `create_time` datetime DEFAULT NULL COMMENT '创建时间',
`update_time` datetime DEFAULT NULL COMMENT '更新时间', `update_time` datetime DEFAULT NULL COMMENT '更新时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=15 DEFAULT CHARSET=utf8mb4 COMMENT='充值订单'; ) ENGINE = InnoDB
AUTO_INCREMENT = 15
DEFAULT CHARSET = utf8mb4 COMMENT ='充值订单';
-- ---------------------------- -- ----------------------------
-- Records of order_pay -- Records of order_pay
@ -551,7 +573,9 @@ CREATE TABLE `sys_data_perm`
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间', `gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
`gmt_modified` datetime DEFAULT NULL COMMENT '修改时间', `gmt_modified` datetime DEFAULT NULL COMMENT '修改时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=216 DEFAULT CHARSET=utf8 COMMENT='数据权限管理'; ) ENGINE = InnoDB
AUTO_INCREMENT = 216
DEFAULT CHARSET = utf8 COMMENT ='数据权限管理';
-- ---------------------------- -- ----------------------------
-- Records of sys_data_perm -- Records of sys_data_perm
@ -581,7 +605,9 @@ CREATE TABLE `sys_dept`
`order_num` int(11) DEFAULT NULL COMMENT '排序', `order_num` int(11) DEFAULT NULL COMMENT '排序',
`del_flag` tinyint(4) DEFAULT '0' COMMENT '是否删除 -1已删除 0正常', `del_flag` tinyint(4) DEFAULT '0' COMMENT '是否删除 -1已删除 0正常',
PRIMARY KEY (`dept_id`) PRIMARY KEY (`dept_id`)
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8 COMMENT='部门管理'; ) ENGINE = InnoDB
AUTO_INCREMENT = 17
DEFAULT CHARSET = utf8 COMMENT ='部门管理';
-- ---------------------------- -- ----------------------------
-- Records of sys_dept -- Records of sys_dept
@ -618,7 +644,10 @@ CREATE TABLE `sys_dict`
KEY `sys_dict_value` (`value`), KEY `sys_dict_value` (`value`),
KEY `sys_dict_label` (`name`), KEY `sys_dict_label` (`name`),
KEY `sys_dict_del_flag` (`del_flag`) KEY `sys_dict_del_flag` (`del_flag`)
) ENGINE=InnoDB AUTO_INCREMENT=142 DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='字典表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 142
DEFAULT CHARSET = utf8
COLLATE = utf8_bin COMMENT ='字典表';
-- ---------------------------- -- ----------------------------
-- Records of sys_dict -- Records of sys_dict
@ -895,7 +924,9 @@ CREATE TABLE `sys_file`
`url` varchar(200) DEFAULT NULL COMMENT 'URL地址', `url` varchar(200) DEFAULT NULL COMMENT 'URL地址',
`create_date` datetime DEFAULT NULL COMMENT '创建时间', `create_date` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=183 DEFAULT CHARSET=utf8 COMMENT='文件上传'; ) ENGINE = InnoDB
AUTO_INCREMENT = 183
DEFAULT CHARSET = utf8 COMMENT ='文件上传';
-- ---------------------------- -- ----------------------------
-- Records of sys_file -- Records of sys_file
@ -1001,7 +1032,9 @@ CREATE TABLE `sys_gen_columns`
`is_required` tinyint(1) DEFAULT NULL COMMENT '是否必填', `is_required` tinyint(1) DEFAULT NULL COMMENT '是否必填',
`dict_type` varchar(100) CHARACTER SET utf8 DEFAULT '' COMMENT '页面显示为下拉时使用,字典类型从字典表中取出', `dict_type` varchar(100) CHARACTER SET utf8 DEFAULT '' COMMENT '页面显示为下拉时使用,字典类型从字典表中取出',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=815 DEFAULT CHARSET=utf8mb4; ) ENGINE = InnoDB
AUTO_INCREMENT = 815
DEFAULT CHARSET = utf8mb4;
-- ---------------------------- -- ----------------------------
-- Records of sys_gen_columns -- Records of sys_gen_columns
@ -1189,7 +1222,8 @@ CREATE TABLE `sys_gen_table`
`update_date` datetime NOT NULL COMMENT '更新时间', `update_date` datetime NOT NULL COMMENT '更新时间',
`remarks` varchar(500) DEFAULT NULL COMMENT '备注信息', `remarks` varchar(500) DEFAULT NULL COMMENT '备注信息',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='代码生成表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8 COMMENT ='代码生成表';
-- ---------------------------- -- ----------------------------
-- Records of sys_gen_table -- Records of sys_gen_table
@ -1225,7 +1259,8 @@ CREATE TABLE `sys_gen_table_column`
`options` varchar(1000) DEFAULT NULL COMMENT '其它生成选项', `options` varchar(1000) DEFAULT NULL COMMENT '其它生成选项',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
KEY `idx_gen_table_column_tn` (`table_id`) USING BTREE KEY `idx_gen_table_column_tn` (`table_id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='代码生成表列'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8 COMMENT ='代码生成表列';
-- ---------------------------- -- ----------------------------
-- Records of sys_gen_table_column -- Records of sys_gen_table_column
@ -1247,7 +1282,9 @@ CREATE TABLE `sys_log`
`ip` varchar(64) DEFAULT NULL COMMENT 'IP地址', `ip` varchar(64) DEFAULT NULL COMMENT 'IP地址',
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间', `gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1412 DEFAULT CHARSET=utf8 COMMENT='系统日志'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1412
DEFAULT CHARSET = utf8 COMMENT ='系统日志';
-- ---------------------------- -- ----------------------------
@ -1267,7 +1304,9 @@ CREATE TABLE `sys_menu`
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间', `gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
`gmt_modified` datetime DEFAULT NULL COMMENT '修改时间', `gmt_modified` datetime DEFAULT NULL COMMENT '修改时间',
PRIMARY KEY (`menu_id`) PRIMARY KEY (`menu_id`)
) ENGINE=InnoDB AUTO_INCREMENT=234 DEFAULT CHARSET=utf8 COMMENT='菜单管理'; ) ENGINE = InnoDB
AUTO_INCREMENT = 234
DEFAULT CHARSET = utf8 COMMENT ='菜单管理';
-- ---------------------------- -- ----------------------------
-- Records of sys_menu -- Records of sys_menu
@ -1417,7 +1456,9 @@ CREATE TABLE `sys_role`
`gmt_create` datetime DEFAULT NULL COMMENT '创建时间', `gmt_create` datetime DEFAULT NULL COMMENT '创建时间',
`gmt_modified` datetime DEFAULT NULL COMMENT '创建时间', `gmt_modified` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`role_id`) PRIMARY KEY (`role_id`)
) ENGINE=InnoDB AUTO_INCREMENT=62 DEFAULT CHARSET=utf8 COMMENT='角色'; ) ENGINE = InnoDB
AUTO_INCREMENT = 62
DEFAULT CHARSET = utf8 COMMENT ='角色';
-- ---------------------------- -- ----------------------------
-- Records of sys_role -- Records of sys_role
@ -1435,7 +1476,9 @@ CREATE TABLE `sys_role_data_perm`
`role_id` bigint(20) DEFAULT NULL COMMENT '角色ID', `role_id` bigint(20) DEFAULT NULL COMMENT '角色ID',
`perm_id` bigint(20) DEFAULT NULL COMMENT '权限ID', `perm_id` bigint(20) DEFAULT NULL COMMENT '权限ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=79 DEFAULT CHARSET=utf8 COMMENT='角色与数据权限对应关系'; ) ENGINE = InnoDB
AUTO_INCREMENT = 79
DEFAULT CHARSET = utf8 COMMENT ='角色与数据权限对应关系';
-- ---------------------------- -- ----------------------------
-- Records of sys_role_data_perm -- Records of sys_role_data_perm
@ -1473,7 +1516,9 @@ CREATE TABLE `sys_role_menu`
`role_id` bigint(20) DEFAULT NULL COMMENT '角色ID', `role_id` bigint(20) DEFAULT NULL COMMENT '角色ID',
`menu_id` bigint(20) DEFAULT NULL COMMENT '菜单ID', `menu_id` bigint(20) DEFAULT NULL COMMENT '菜单ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4830 DEFAULT CHARSET=utf8 COMMENT='角色与菜单对应关系'; ) ENGINE = InnoDB
AUTO_INCREMENT = 4830
DEFAULT CHARSET = utf8 COMMENT ='角色与菜单对应关系';
-- ---------------------------- -- ----------------------------
-- Records of sys_role_menu -- Records of sys_role_menu
@ -2255,7 +2300,9 @@ CREATE TABLE `sys_user`
`city` varchar(255) DEFAULT NULL COMMENT '所在城市', `city` varchar(255) DEFAULT NULL COMMENT '所在城市',
`district` varchar(255) DEFAULT NULL COMMENT '所在地区', `district` varchar(255) DEFAULT NULL COMMENT '所在地区',
PRIMARY KEY (`user_id`) PRIMARY KEY (`user_id`)
) ENGINE=InnoDB AUTO_INCREMENT=139 DEFAULT CHARSET=utf8; ) ENGINE = InnoDB
AUTO_INCREMENT = 139
DEFAULT CHARSET = utf8;
-- ---------------------------- -- ----------------------------
-- Records of sys_user -- Records of sys_user
@ -2275,7 +2322,9 @@ CREATE TABLE `sys_user_role`
`user_id` bigint(20) DEFAULT NULL COMMENT '用户ID', `user_id` bigint(20) DEFAULT NULL COMMENT '用户ID',
`role_id` bigint(20) DEFAULT NULL COMMENT '角色ID', `role_id` bigint(20) DEFAULT NULL COMMENT '角色ID',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=137 DEFAULT CHARSET=utf8 COMMENT='用户与角色对应关系'; ) ENGINE = InnoDB
AUTO_INCREMENT = 137
DEFAULT CHARSET = utf8 COMMENT ='用户与角色对应关系';
-- ---------------------------- -- ----------------------------
-- Records of sys_user_role -- Records of sys_user_role
@ -2367,7 +2416,9 @@ CREATE TABLE `user`
`update_time` datetime NOT NULL COMMENT '更新时间', `update_time` datetime NOT NULL COMMENT '更新时间',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_username` (`username`) USING BTREE UNIQUE KEY `key_uq_username` (`username`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1255664783722586113 DEFAULT CHARSET=utf8mb4; ) ENGINE = InnoDB
AUTO_INCREMENT = 1255664783722586113
DEFAULT CHARSET = utf8mb4;
-- ---------------------------- -- ----------------------------
-- Records of user -- Records of user
@ -2408,7 +2459,9 @@ CREATE TABLE `user_bookshelf`
`update_time` datetime DEFAULT NULL, `update_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_userid_bookid` (`user_id`, `book_id`) USING BTREE UNIQUE KEY `key_uq_userid_bookid` (`user_id`, `book_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=42 DEFAULT CHARSET=utf8mb4 COMMENT='用户书架表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 42
DEFAULT CHARSET = utf8mb4 COMMENT ='用户书架表';
-- ---------------------------- -- ----------------------------
-- Records of user_bookshelf -- Records of user_bookshelf
@ -2441,7 +2494,9 @@ CREATE TABLE `user_buy_record`
`create_time` datetime DEFAULT NULL COMMENT '购买时间', `create_time` datetime DEFAULT NULL COMMENT '购买时间',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_userId_indexId` (`user_id`, `book_index_id`) UNIQUE KEY `key_userId_indexId` (`user_id`, `book_index_id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COMMENT='用户消费记录表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 3
DEFAULT CHARSET = utf8mb4 COMMENT ='用户消费记录表';
-- ---------------------------- -- ----------------------------
-- Records of user_buy_record -- Records of user_buy_record
@ -2464,7 +2519,9 @@ CREATE TABLE `user_feedback`
`content` varchar(512) DEFAULT NULL COMMENT '反馈内容', `content` varchar(512) DEFAULT NULL COMMENT '反馈内容',
`create_time` datetime DEFAULT NULL COMMENT '反馈时间', `create_time` datetime DEFAULT NULL COMMENT '反馈时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=9 DEFAULT CHARSET=utf8mb4; ) ENGINE = InnoDB
AUTO_INCREMENT = 9
DEFAULT CHARSET = utf8mb4;
-- ---------------------------- -- ----------------------------
-- Records of user_feedback -- Records of user_feedback
@ -2486,7 +2543,9 @@ CREATE TABLE `user_read_history`
`update_time` datetime DEFAULT NULL, `update_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_userid_bookid` (`user_id`, `book_id`) USING BTREE UNIQUE KEY `key_uq_userid_bookid` (`user_id`, `book_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=119 DEFAULT CHARSET=utf8mb4 COMMENT='用户阅读记录表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 119
DEFAULT CHARSET = utf8mb4 COMMENT ='用户阅读记录表';
-- ---------------------------- -- ----------------------------
-- Records of user_read_history -- Records of user_read_history
@ -2552,7 +2611,9 @@ CREATE TABLE `book_content0`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1155 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1155
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content1 -- Table structure for book_content1
@ -2565,7 +2626,9 @@ CREATE TABLE `book_content1`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=406 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 406
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content2 -- Table structure for book_content2
@ -2578,7 +2641,9 @@ CREATE TABLE `book_content2`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1222 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1222
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content3 -- Table structure for book_content3
@ -2591,7 +2656,9 @@ CREATE TABLE `book_content3`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=410 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 410
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content4 -- Table structure for book_content4
@ -2604,7 +2671,9 @@ CREATE TABLE `book_content4`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1188 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1188
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content5 -- Table structure for book_content5
@ -2617,7 +2686,9 @@ CREATE TABLE `book_content5`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=416 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 416
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content6 -- Table structure for book_content6
@ -2630,7 +2701,9 @@ CREATE TABLE `book_content6`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1180 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1180
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content7 -- Table structure for book_content7
@ -2643,7 +2716,9 @@ CREATE TABLE `book_content7`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=404 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 404
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content8 -- Table structure for book_content8
@ -2656,7 +2731,9 @@ CREATE TABLE `book_content8`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1134 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 1134
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
-- ---------------------------- -- ----------------------------
-- Table structure for book_content9 -- Table structure for book_content9
@ -2669,7 +2746,9 @@ CREATE TABLE `book_content9`
`content` mediumtext COMMENT '小说章节内容', `content` mediumtext COMMENT '小说章节内容',
PRIMARY KEY (`id`), PRIMARY KEY (`id`),
UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE UNIQUE KEY `key_uq_indexId` (`index_id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=415 DEFAULT CHARSET=utf8mb4 COMMENT='小说内容表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 415
DEFAULT CHARSET = utf8mb4 COMMENT ='小说内容表';
DROP TABLE IF EXISTS `crawl_single_task`; DROP TABLE IF EXISTS `crawl_single_task`;
@ -2686,7 +2765,9 @@ CREATE TABLE `crawl_single_task`
`exc_count` tinyint(2) DEFAULT '0' COMMENT '已经执行次数最多执行5次', `exc_count` tinyint(2) DEFAULT '0' COMMENT '已经执行次数最多执行5次',
`create_time` datetime DEFAULT NULL COMMENT '创建时间', `create_time` datetime DEFAULT NULL COMMENT '创建时间',
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4 COMMENT='抓取单本小说任务表'; ) ENGINE = InnoDB
AUTO_INCREMENT = 8
DEFAULT CHARSET = utf8mb4 COMMENT ='抓取单本小说任务表';
-- ---------------------------- -- ----------------------------
-- Records of crawl_single_task -- Records of crawl_single_task
@ -2716,7 +2797,8 @@ CREATE TABLE `author_income_detail`
`income_number` int(11) NOT NULL DEFAULT '0' COMMENT '订阅人数', `income_number` int(11) NOT NULL DEFAULT '0' COMMENT '订阅人数',
`create_time` datetime DEFAULT NULL, `create_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='稿费收入明细统计表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4 COMMENT ='稿费收入明细统计表';
CREATE TABLE `author_income` CREATE TABLE `author_income`
( (
@ -2732,7 +2814,8 @@ CREATE TABLE `author_income`
`detail` varchar(255) DEFAULT NULL COMMENT '详情', `detail` varchar(255) DEFAULT NULL COMMENT '详情',
`create_time` datetime DEFAULT NULL, `create_time` datetime DEFAULT NULL,
PRIMARY KEY (`id`) PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='稿费收入统计表'; ) ENGINE = InnoDB
DEFAULT CHARSET = utf8mb4 COMMENT ='稿费收入统计表';
alter table book alter table book
@ -3006,3 +3089,20 @@ INSERT INTO `sys_menu` (`menu_id`, `parent_id`, `name`, `url`, `perms`, `type`,
VALUES (305, '301', '修改', null, 'novel:websiteInfo:edit', '2', null, '6'); VALUES (305, '301', '修改', null, 'novel:websiteInfo:edit', '2', null, '6');
INSERT INTO sys_role_menu (role_id, menu_id) INSERT INTO sys_role_menu (role_id, menu_id)
VALUES (1, 305); VALUES (1, 305);
update website_info
set logo = 'https://youdoc.gitee.io/resource/images/logo%20(1).png',
logo_dark='https://youdoc.gitee.io/resource/images/logo%20(1).png'
where id = 1;
update crawl_source
set crawl_rule = replace(crawl_rule, 'ibiquge.net', 'ibiquzw.org')
where id = 16;
update website_info
set logo = '/images/logo.png',
logo_dark='/images/logo.png'
where id = 1;

View File

@ -1,6 +0,0 @@
FROM java:8
ADD novel-admin-1.0.0.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -jar /root/novel-admin-1.0.0.jar"]

View File

@ -5,7 +5,7 @@
<groupId>com.java2nb</groupId> <groupId>com.java2nb</groupId>
<artifactId>novel-admin</artifactId> <artifactId>novel-admin</artifactId>
<version>4.2.0</version> <version>4.3.0</version>
<packaging>jar</packaging> <packaging>jar</packaging>
<name>novel-admin</name> <name>novel-admin</name>
@ -296,6 +296,9 @@
<zip destfile='${project.build.directory}/build/${project.artifactId}.zip'> <zip destfile='${project.build.directory}/build/${project.artifactId}.zip'>
<zipfileset filemode="755" dir='${project.build.directory}/build/'/> <zipfileset filemode="755" dir='${project.build.directory}/build/'/>
</zip> </zip>
<copy file="${basedir}/src/main/build/docker/Dockerfile"
tofile="${project.build.directory}/build/Dockerfile"/>
</tasks> </tasks>
</configuration> </configuration>
</execution> </execution>

View File

@ -0,0 +1,9 @@
FROM openjdk:8
ADD novel-admin.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENV redishost = ""
ENV redisport = ""
ENV redispwd = ""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -Dspring.redis.host=${redishost} -Dspring.redis.port=${redisport} -Dspring.redis.password=${redispwd} -jar /root/novel-admin.jar"]

View File

@ -68,6 +68,7 @@ public class ShiroConfig {
filterChainDefinitionMap.put("/js/**", "anon"); filterChainDefinitionMap.put("/js/**", "anon");
filterChainDefinitionMap.put("/fonts/**", "anon"); filterChainDefinitionMap.put("/fonts/**", "anon");
filterChainDefinitionMap.put("/img/**", "anon"); filterChainDefinitionMap.put("/img/**", "anon");
filterChainDefinitionMap.put("/favicon.ico", "anon");
filterChainDefinitionMap.put("/docs/**", "anon"); filterChainDefinitionMap.put("/docs/**", "anon");
filterChainDefinitionMap.put("/layuimini/**", "anon"); filterChainDefinitionMap.put("/layuimini/**", "anon");
filterChainDefinitionMap.put("/upload/**", "anon"); filterChainDefinitionMap.put("/upload/**", "anon");

View File

@ -12,6 +12,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate; import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.Model; import org.springframework.ui.Model;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@ -83,7 +84,7 @@ public class FriendLinkController {
@ResponseBody @ResponseBody
@PostMapping("/save") @PostMapping("/save")
@RequiresPermissions("novel:friendLink:add") @RequiresPermissions("novel:friendLink:add")
public R save(FriendLinkDO friendLink) { public R save(@Validated FriendLinkDO friendLink) {
if (friendLinkService.save(friendLink) > 0) { if (friendLinkService.save(friendLink) > 0) {
redisTemplate.delete(CacheKey.INDEX_LINK_KEY); redisTemplate.delete(CacheKey.INDEX_LINK_KEY);
return R.ok(); return R.ok();
@ -98,7 +99,7 @@ public class FriendLinkController {
@ResponseBody @ResponseBody
@RequestMapping("/update") @RequestMapping("/update")
@RequiresPermissions("novel:friendLink:edit") @RequiresPermissions("novel:friendLink:edit")
public R update(FriendLinkDO friendLink) { public R update(@Validated FriendLinkDO friendLink) {
friendLinkService.update(friendLink); friendLinkService.update(friendLink);
redisTemplate.delete(CacheKey.INDEX_LINK_KEY); redisTemplate.delete(CacheKey.INDEX_LINK_KEY);
return R.ok(); return R.ok();

View File

@ -1,27 +1,21 @@
package com.java2nb.novel.domain; package com.java2nb.novel.domain;
import java.io.Serializable;
import java.math.BigDecimal;
import com.fasterxml.jackson.databind.annotation.JsonSerialize; import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.java2nb.common.jsonserializer.LongToStringSerializer; import com.java2nb.common.jsonserializer.LongToStringSerializer;
import org.hibernate.validator.constraints.URL;
import org.springframework.format.annotation.DateTimeFormat; import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date; import java.util.Date;
/** /**
*
*
* @author xiongxy * @author xiongxy
* @email 1179705413@qq.com * @email 1179705413@qq.com
* @date 2023-04-14 15:12:25 * @date 2023-04-14 15:12:25
*/ */
public class FriendLinkDO implements Serializable { public class FriendLinkDO implements Serializable {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
@ -30,6 +24,7 @@ public class FriendLinkDO implements Serializable {
//链接名 //链接名
private String linkName; private String linkName;
//链接url //链接url
@URL
private String linkUrl; private String linkUrl;
//排序号 //排序号
private Integer sort; private Integer sort;
@ -58,102 +53,119 @@ public class FriendLinkDO implements Serializable {
public void setId(Integer id) { public void setId(Integer id) {
this.id = id; this.id = id;
} }
/** /**
* 获取:主键 * 获取:主键
*/ */
public Integer getId() { public Integer getId() {
return id; return id;
} }
/** /**
* 设置:链接名 * 设置:链接名
*/ */
public void setLinkName(String linkName) { public void setLinkName(String linkName) {
this.linkName = linkName; this.linkName = linkName;
} }
/** /**
* 获取:链接名 * 获取:链接名
*/ */
public String getLinkName() { public String getLinkName() {
return linkName; return linkName;
} }
/** /**
* 设置链接url * 设置链接url
*/ */
public void setLinkUrl(String linkUrl) { public void setLinkUrl(String linkUrl) {
this.linkUrl = linkUrl; this.linkUrl = linkUrl;
} }
/** /**
* 获取链接url * 获取链接url
*/ */
public String getLinkUrl() { public String getLinkUrl() {
return linkUrl; return linkUrl;
} }
/** /**
* 设置:排序号 * 设置:排序号
*/ */
public void setSort(Integer sort) { public void setSort(Integer sort) {
this.sort = sort; this.sort = sort;
} }
/** /**
* 获取:排序号 * 获取:排序号
*/ */
public Integer getSort() { public Integer getSort() {
return sort; return sort;
} }
/** /**
* 设置是否开启0不开启1开启 * 设置是否开启0不开启1开启
*/ */
public void setIsOpen(Integer isOpen) { public void setIsOpen(Integer isOpen) {
this.isOpen = isOpen; this.isOpen = isOpen;
} }
/** /**
* 获取是否开启0不开启1开启 * 获取是否开启0不开启1开启
*/ */
public Integer getIsOpen() { public Integer getIsOpen() {
return isOpen; return isOpen;
} }
/** /**
* 设置创建人id * 设置创建人id
*/ */
public void setCreateUserId(Long createUserId) { public void setCreateUserId(Long createUserId) {
this.createUserId = createUserId; this.createUserId = createUserId;
} }
/** /**
* 获取创建人id * 获取创建人id
*/ */
public Long getCreateUserId() { public Long getCreateUserId() {
return createUserId; return createUserId;
} }
/** /**
* 设置:创建时间 * 设置:创建时间
*/ */
public void setCreateTime(Date createTime) { public void setCreateTime(Date createTime) {
this.createTime = createTime; this.createTime = createTime;
} }
/** /**
* 获取:创建时间 * 获取:创建时间
*/ */
public Date getCreateTime() { public Date getCreateTime() {
return createTime; return createTime;
} }
/** /**
* 设置更新者用户id * 设置更新者用户id
*/ */
public void setUpdateUserId(Long updateUserId) { public void setUpdateUserId(Long updateUserId) {
this.updateUserId = updateUserId; this.updateUserId = updateUserId;
} }
/** /**
* 获取更新者用户id * 获取更新者用户id
*/ */
public Long getUpdateUserId() { public Long getUpdateUserId() {
return updateUserId; return updateUserId;
} }
/** /**
* 设置:更新时间 * 设置:更新时间
*/ */
public void setUpdateTime(Date updateTime) { public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime; this.updateTime = updateTime;
} }
/** /**
* 获取:更新时间 * 获取:更新时间
*/ */

View File

@ -18,10 +18,11 @@ spring:
profiles: profiles:
active: dev active: dev
#上传文件的最大值10M #上传文件的最大值100M
servlet: servlet:
multipart: multipart:
max-file-size: 10485760 max-file-size: 100MB
max-request-size: 100MB
devtools: devtools:
restart: restart:

Binary file not shown.

After

Width:  |  Height:  |  Size: 162 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.9 KiB

View File

@ -23,7 +23,7 @@
<div class="col-sm-8"> <div class="col-sm-8">
<input id="linkUrl" name="linkUrl" <input id="linkUrl" name="linkUrl"
class="form-control" class="form-control"
type="text" required> type="url" required>
</div> </div>
</div> </div>

View File

@ -26,7 +26,7 @@
<input id="linkUrl" name="linkUrl" <input id="linkUrl" name="linkUrl"
th:value="${friendLink.linkUrl}" th:value="${friendLink.linkUrl}"
class="form-control" class="form-control"
type="text" required> type="url" required>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">

View File

@ -5,7 +5,7 @@
<parent> <parent>
<artifactId>novel</artifactId> <artifactId>novel</artifactId>
<groupId>com.java2nb</groupId> <groupId>com.java2nb</groupId>
<version>4.2.0</version> <version>4.3.0</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -16,6 +16,7 @@ public class User {
@NotBlank(groups = {AddGroup.class}, message = "手机号不能为空!") @NotBlank(groups = {AddGroup.class}, message = "手机号不能为空!")
@Pattern(groups = {AddGroup.class}, regexp = "^1[3|4|5|6|7|8|9][0-9]{9}$", message = "手机号格式不正确!") @Pattern(groups = {AddGroup.class}, regexp = "^1[3|4|5|6|7|8|9][0-9]{9}$", message = "手机号格式不正确!")
@Null(groups = {UpdateGroup.class})
@Generated("org.mybatis.generator.api.MyBatisGenerator") @Generated("org.mybatis.generator.api.MyBatisGenerator")
private String username; private String username;
@ -25,10 +26,14 @@ public class User {
private String password; private String password;
@Null(groups = {AddGroup.class}) @Null(groups = {AddGroup.class})
@Pattern(groups = {
UpdateGroup.class}, regexp = "[\u4E00-\u9FA5A-Za-z0-9_]{1,11}", message = "昵称格式不正确!")
@Generated("org.mybatis.generator.api.MyBatisGenerator") @Generated("org.mybatis.generator.api.MyBatisGenerator")
private String nickName; private String nickName;
@Null(groups = {AddGroup.class}) @Null(groups = {AddGroup.class})
@Pattern(groups = {
UpdateGroup.class}, regexp = "^/localPic/\\d{4}/\\d{2}/\\d{2}/[A-Za-z0-9]+\\.(jpg|jpeg|swf|gif|png|JPG|JPEG|SWF|GIF|PNG)$", message = "只能上传图片格式的文件!")
@Generated("org.mybatis.generator.api.MyBatisGenerator") @Generated("org.mybatis.generator.api.MyBatisGenerator")
private String userPhoto; private String userPhoto;

View File

@ -11,10 +11,11 @@ spring:
generator: generator:
write-numbers-as-strings: true write-numbers-as-strings: true
#上传文件的最大值1M #上传文件的最大值100M
servlet: servlet:
multipart: multipart:
max-file-size: 1048576 max-file-size: 100MB
max-request-size: 100MB
mybatis: mybatis:
configuration: configuration:

View File

@ -1,6 +0,0 @@
FROM java:8
ADD novel-crawl-1.1.0.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -jar /root/novel-crawl-1.1.0.jar"]

View File

@ -5,7 +5,7 @@
<parent> <parent>
<artifactId>novel</artifactId> <artifactId>novel</artifactId>
<groupId>com.java2nb</groupId> <groupId>com.java2nb</groupId>
<version>4.2.0</version> <version>4.3.0</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
@ -72,6 +72,9 @@
<zip destfile='${project.build.directory}/build/${project.artifactId}.zip'> <zip destfile='${project.build.directory}/build/${project.artifactId}.zip'>
<zipfileset filemode="755" dir='${project.build.directory}/build/'/> <zipfileset filemode="755" dir='${project.build.directory}/build/'/>
</zip> </zip>
<copy file="${basedir}/src/main/build/docker/Dockerfile"
tofile="${project.build.directory}/build/Dockerfile"/>
</tasks> </tasks>
</configuration> </configuration>
</execution> </execution>

View File

@ -0,0 +1,9 @@
FROM openjdk:8
ADD novel-crawl.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENV redishost = ""
ENV redisport = ""
ENV redispwd = ""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -Dspring.redis.host=${redishost} -Dspring.redis.port=${redisport} -Dspring.redis.password=${redispwd} -jar /root/novel-crawl.jar"]

View File

@ -53,8 +53,12 @@ public class SecurityConfiguration extends WebSecurityConfigurerAdapter {
http.csrf().disable() http.csrf().disable()
.authorizeRequests() .authorizeRequests()
.antMatchers("/css/**").permitAll() .antMatchers("/css/**").permitAll()
.antMatchers("/favicon.ico").permitAll()
.antMatchers("/**").hasRole("ADMIN") .antMatchers("/**").hasRole("ADMIN")
.and().formLogin().loginPage("/login.html").loginProcessingUrl("/login").permitAll() .and().formLogin().loginPage("/login.html").loginProcessingUrl("/login").permitAll()
.and().logout()
.logoutUrl("/logout")
.logoutSuccessUrl("/")
.and().httpBasic(); .and().httpBasic();
} }

Binary file not shown.

After

Width:  |  Height:  |  Size: 162 KiB

File diff suppressed because it is too large Load Diff

View File

@ -1,100 +1,511 @@
@charset "utf-8"; @charset "utf-8";
.updateTable .style a { color:#999 } .updateTable .style a {
.updateTable .author a { color:#999; cursor:text } color: #999
.bind, .updateTable .style a:hover { color:#f65167 } }
.userBox { /*width: 998px; border: 1px solid #eaeaea;*/ margin:0 auto 50px; background: #fff; border-radius: 6px }
.channelViewhistory .userBox { margin: 0 auto } .updateTable .author a {
.user_l { width:350px; float:left; padding:50px 50px } color: #999;
.user_l h3 { font-size:23px; font-weight:normal; line-height:1; text-align: center } cursor: text
.user_l #LabErr { color:#ff4040; display:block; height:40px; line-height:40px; text-align: center; font-size: 14px } }
.user_l .log_list { width:350px }
.user_l .s_input { margin-bottom:25px; font-size:14px } .bind, .updateTable .style a:hover {
.s_input { width:348px; height:30px; line-height:38px\9; vertical-align:middle; border:1px solid #ddd; border-radius:2px } color: #f65167
.icon_name, .icon_key, .icon_code { width:312px; padding-left:36px} }
.icon_key { background-position: 13px -51px }
.icon_code { background-position: 13px -117px; width:200px; float:left } .userBox { /*width: 998px; border: 1px solid #eaeaea;*/
.code_pic { height:38px; float:right } margin: 0 auto 50px;
.btn_phone { height:40px; width:100px; float:right; cursor:pointer; padding:0; text-align:center; border-radius:2px; background:#dfdfdf } background: #fff;
.log_code { *padding-bottom:25px } border-radius: 6px
.user_l .btn_red { width:100%; font-size:19px; padding:12px } }
.autologin { color:#999; line-height:1; margin-bottom:18px }
.autologin em { vertical-align:2px; margin-left:4px } .channelViewhistory .userBox {
.user_r { width:259px; margin:80px 0; padding:20px 70px; border-left:1px dotted #e3e3e3; float:right; text-align:center } margin: 0 auto
.user_r .tit { font-size:16px; line-height:1; padding: 6px 0 25px } }
.user_r .btn_ora { padding:10px 34px }
.fast_login { padding:60px 0 0 } .user_l {
.fast_list { text-align:center; padding:0.5rem } width: 350px;
.fast_list li { display:inline-block; *display:inline; zoom:1 } float: left;
.fast_list li .img { width:48px; height:48px; margin:20px 0 5px } padding: 50px 50px
.fast_list li a:hover { opacity:0.8; filter: alpha(opacity=80); -moz-opacity: 0.8 } }
.fast_list li span { display:block }
.fast_list .login_qq { margin:0 42px } .user_l h3 {
.fast_list .login_wb a { color:#f55c5b } font-size: 23px;
.fast_list .login_qq a { color:#51b7ff } font-weight: normal;
.fast_list .login_wx a { color:#66d65e } line-height: 1;
.fast_tit { position:relative; overflow:hidden } text-align: center
.fast_tit .lines { position:absolute; top:50%; left:0; width:100%; height:1px; line-height:1; background:#eaeaea } }
.fast_tit .title { background:#fff; font-size:16px; padding:3px 14px; position:relative; display:inline-block; z-index:999 }
/*userinfo*/ .user_l #LabErr {
.my_l { width:198px; float:left; font-size: 13px; padding-top: 20px; } color: #ff4040;
.my_l li a { display:block; height:42px; line-height:42px; padding-left:62px; border-left:4px solid #fff; margin-bottom:5px; color: #666 } display: block;
.my_l li .on { background-color:#fafafa; border-left:2px solid #f80; color:#000; border-radius: 0 2px 2px 0 } height: 40px;
.my_l .link_1 { background-position:32px -188px } line-height: 40px;
.my_l .link_2 { background-position:32px -230px } text-align: center;
.my_l .link_3 { background-position:32px -272px } font-size: 14px
.my_l .link_4 { background-position:32px -314px } }
.my_l .link_5 { background-position:32px -356px }
.my_l .link_6 { background-position:32px -397px } .user_l .log_list {
.my_l .link_7 { background-position:32px -440px } width: 350px
.my_l .link_8 { background-position:32px -481px } }
.my_r { width:739px; padding:0 30px 30px; float:right; border-left:1px solid #efefef; min-height:470px }
.my_info { padding:30px 0 5px } .user_l .s_input {
.user_big_head { /*width:110px; height:110px; padding:4px; border:1px solid #eaeaea;*/ margin-right:30px; float:left; width: 80px; margin-bottom: 25px;
height: 80px; font-size: 14px
border-radius: 50%; } }
.my_r .my_name { font-size:18px; line-height:1; padding:5px 0 12px 0 }
.my_r .s_input { width:318px; padding:0 10px } .s_input {
.my_list li { line-height:28px } width: 348px;
.my_list li i, .my_list li em.red { margin-right:6px } height: 30px;
.my_list .binded { color:#999; margin-left:6px } line-height: 38px \9;
.my_list .btn_link { margin-left:12px } vertical-align: middle;
.mytab_list li { line-height:30px; padding:10px 0; font-size:14px } border: 1px solid #ddd;
.mytab_list li .tit { width:70px; color: #aaa; text-align:right; display:inline-block; margin-right:18px } border-radius: 2px
.mytab_list .user_img { width:48px; height:48px; vertical-align:middle; border-radius:50% } }
.my_bookshelf .title { padding:20px 0 15px; line-height:30px }
.my_bookshelf h4 { font-size:14px; color:#666 } .icon_name, .icon_key, .icon_code {
.my_bookshelf h2 { font-size:18px; font-weight:normal } width: 312px;
.updateTable { width: 739px; color: #999 } padding-left: 36px
.updateTable table { width: 100%; margin-bottom:14px } }
.updateTable th, .updateTable td { height: 40px; line-height: 40px; vertical-align: middle; padding-left: 6px; font-weight:normal; text-align:left }
.updateTable th { background:#f9f9f9; color:#333; border-top:1px solid #eee } .icon_key {
.updateTable td { height:40px; line-height:40px } background-position: 13px -51px
.updateTable .style { width:80px; padding-left:10px } }
.updateTable .name { width: 178px; padding-right: 10px }
.updateTable .name a, .updateTable .chapter a { max-width: 168px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap } .icon_code {
.updateTable .chapter { padding-right: 5px } background-position: 13px -117px;
.updateTable .chapter a { max-width:220px; float: left } width: 200px;
.updateTable .author { width: 72px; text-align: left } float: left
.updateTable .goread { width: 80px; text-align:center } }
.updateTable .time { width: 86px }
.updateTable .word { width: 64px; padding-right:10px; text-align: right } .code_pic {
.updateTable .rank { width: 30px; padding-right:10px; text-align: center } height: 38px;
.updateTable .name a, .updateTable .chapter a, .updateTable .author a { height: 40px; line-height: 40px; display: inline-block; overflow: hidden } float: right
.updateTable tr:nth-child(2n) td { background:#fafafa } }
.dataTable { width: 739px }
.dataTable table { width: 100%; margin-bottom:14px; border-collapse:collapse } .btn_phone {
.dataTable th, .dataTable td { height: 40px; line-height: 40px; vertical-align: middle; padding:0 10px; font-weight:normal; text-align:center; border:1px solid #eaeaea } height: 40px;
.dataTable th { background:#f8f8f8 } width: 100px;
.nodate { border-top: 1px solid #eaeaea; padding:60px 0 } float: right;
.viewhistoryBox { /*padding: 0 30px 30px; */ padding: 0 20px 10px } cursor: pointer;
.viewhistoryBox .updateTable { width:100% } padding: 0;
/*.btn_gray, .btn_red, .btn_ora { font-size:14px; padding:8px 28px }*/ text-align: center;
.book_tit { height: 48px; line-height:48px; margin: 0 14px; border-bottom: 1px solid #eaeaea; overflow:hidden } border-radius: 2px;
.book_tit .fl { font-size:14px; color:#999 } background: #dfdfdf
.book_tit .fl h3 { font-size:18px; color:#333; font-weight:normal; margin-right:5px; display:inline } }
.book_tit .fr { font-size:14px }
.log_code {
*padding-bottom: 25px
}
.user_l .btn_red {
width: 100%;
font-size: 19px;
padding: 12px
}
.autologin {
color: #999;
line-height: 1;
margin-bottom: 18px
}
.autologin em {
vertical-align: 2px;
margin-left: 4px
}
.user_r {
width: 259px;
margin: 80px 0;
padding: 20px 70px;
border-left: 1px dotted #e3e3e3;
float: right;
text-align: center
}
.user_r .tit {
font-size: 16px;
line-height: 1;
padding: 6px 0 25px
}
.user_r .btn_ora {
padding: 10px 34px
}
.fast_login {
padding: 60px 0 0
}
.fast_list {
text-align: center;
padding: 0.5rem
}
.fast_list li {
display: inline-block;
*display: inline;
zoom: 1
}
.fast_list li .img {
width: 48px;
height: 48px;
margin: 20px 0 5px
}
.fast_list li a:hover {
opacity: 0.8;
filter: alpha(opacity=80);
-moz-opacity: 0.8
}
.fast_list li span {
display: block
}
.fast_list .login_qq {
margin: 0 42px
}
.fast_list .login_wb a {
color: #f55c5b
}
.fast_list .login_qq a {
color: #51b7ff
}
.fast_list .login_wx a {
color: #66d65e
}
.fast_tit {
position: relative;
overflow: hidden
}
.fast_tit .lines {
position: absolute;
top: 50%;
left: 0;
width: 100%;
height: 1px;
line-height: 1;
background: #eaeaea
}
.fast_tit .title {
background: #fff;
font-size: 16px;
padding: 3px 14px;
position: relative;
display: inline-block;
z-index: 999
}
/*userinfo*/
.my_l {
width: 198px;
float: left;
font-size: 13px;
padding-top: 20px;
}
.my_l li a {
display: block;
height: 42px;
line-height: 42px;
padding-left: 62px;
border-left: 4px solid #fff;
margin-bottom: 5px;
color: #666
}
.my_l li .on {
background-color: #fafafa;
border-left: 2px solid #3eaf7c;
color: #000;
border-radius: 0 2px 2px 0
}
.my_l .link_1 {
background-position: 32px -188px
}
.my_l .link_2 {
background-position: 32px -230px
}
.my_l .link_3 {
background-position: 32px -272px
}
.my_l .link_4 {
background-position: 32px -314px
}
.my_l .link_5 {
background-position: 32px -356px
}
.my_l .link_6 {
background-position: 32px -397px
}
.my_l .link_7 {
background-position: 32px -440px
}
.my_l .link_8 {
background-position: 32px -481px
}
.my_r {
width: 739px;
padding: 0 30px 30px;
float: right;
border-left: 1px solid #efefef;
min-height: 470px
}
.my_info {
padding: 30px 0 5px
}
.user_big_head { /*width:110px; height:110px; padding:4px; border:1px solid #eaeaea;*/
margin-right: 30px;
float: left;
width: 80px;
height: 80px;
border-radius: 50%;
}
.my_r .my_name {
font-size: 18px;
line-height: 1;
padding: 5px 0 12px 0
}
.my_r .s_input {
width: 318px;
padding: 0 10px
}
.my_list li {
line-height: 28px
}
.my_list li i, .my_list li em.red {
margin-right: 6px
}
.my_list .binded {
color: #999;
margin-left: 6px
}
.my_list .btn_link {
margin-left: 12px
}
.mytab_list li {
line-height: 30px;
padding: 10px 0;
font-size: 14px
}
.mytab_list li .tit {
width: 70px;
color: #aaa;
text-align: right;
display: inline-block;
margin-right: 18px
}
.mytab_list .user_img {
width: 48px;
height: 48px;
vertical-align: middle;
border-radius: 50%
}
.my_bookshelf .title {
padding: 20px 0 15px;
line-height: 30px
}
.my_bookshelf h4 {
font-size: 14px;
color: #666
}
.my_bookshelf h2 {
font-size: 18px;
font-weight: normal
}
.updateTable {
width: 739px;
color: #999
}
.updateTable table {
width: 100%;
margin-bottom: 14px
}
.updateTable th, .updateTable td {
height: 40px;
line-height: 40px;
vertical-align: middle;
padding-left: 6px;
font-weight: normal;
text-align: left
}
.updateTable th {
background: #f9f9f9;
color: #333;
border-top: 1px solid #eee
}
.updateTable td {
height: 40px;
line-height: 40px
}
.updateTable .style {
width: 80px;
padding-left: 10px
}
.updateTable .name {
width: 178px;
padding-right: 10px
}
.updateTable .name a, .updateTable .chapter a {
max-width: 168px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap
}
.updateTable .chapter {
padding-right: 5px
}
.updateTable .chapter a {
max-width: 220px;
float: left
}
.updateTable .author {
width: 72px;
text-align: left
}
.updateTable .goread {
width: 80px;
text-align: center
}
.updateTable .time {
width: 86px
}
.updateTable .word {
width: 64px;
padding-right: 10px;
text-align: right
}
.updateTable .rank {
width: 30px;
padding-right: 10px;
text-align: center
}
.updateTable .name a, .updateTable .chapter a, .updateTable .author a {
height: 40px;
line-height: 40px;
display: inline-block;
overflow: hidden
}
.updateTable tr:nth-child(2n) td {
background: #fafafa
}
.dataTable {
width: 739px
}
.dataTable table {
width: 100%;
margin-bottom: 14px;
border-collapse: collapse
}
.dataTable th, .dataTable td {
height: 40px;
line-height: 40px;
vertical-align: middle;
padding: 0 10px;
font-weight: normal;
text-align: center;
border: 1px solid #eaeaea
}
.dataTable th {
background: #f8f8f8
}
.nodate {
border-top: 1px solid #eaeaea;
padding: 60px 0
}
.viewhistoryBox { /*padding: 0 30px 30px; */
padding: 0 20px 10px
}
.viewhistoryBox .updateTable {
width: 100%
}
/*.btn_gray, .btn_red, .btn_ora { font-size:14px; padding:8px 28px }*/
.book_tit {
height: 48px;
line-height: 48px;
margin: 0 14px;
border-bottom: 1px solid #eaeaea;
overflow: hidden
}
.book_tit .fl {
font-size: 14px;
color: #999
}
.book_tit .fl h3 {
font-size: 18px;
color: #333;
font-weight: normal;
margin-right: 5px;
display: inline
}
.book_tit .fr {
font-size: 14px
}
.commentBar, .feedback_list {
border-top: 1px solid #eee;
margin-bottom: 15px
}
.commentBar, .feedback_list { border-top:1px solid #eee; margin-bottom:15px }
/*.comment_list { padding: 16px 0; border-bottom: 1px solid #eee } /*.comment_list { padding: 16px 0; border-bottom: 1px solid #eee }
.comment_list .user_head { width:54px; height:54px; border-radius:50%; float: left; margin-right: 14px } .comment_list .user_head { width:54px; height:54px; border-radius:50%; float: left; margin-right: 14px }
.comment_list .li_1 { overflow: hidden } .comment_list .li_1 { overflow: hidden }
@ -105,33 +516,128 @@
.comment_list .num { color: #ed4259; margin: 0 3px } .comment_list .num { color: #ed4259; margin: 0 3px }
.comment_list .li_4 { line-height:34px; padding-top:8px; margin-top:15px; border-top:1px solid #eaeaea } .comment_list .li_4 { line-height:34px; padding-top:8px; margin-top:15px; border-top:1px solid #eaeaea }
.comment_list .li_4 .more { background:#f7f7f7; border-radius:2px; color:#ed4259; text-align:center }*/ .comment_list .li_4 .more { background:#f7f7f7; border-radius:2px; color:#ed4259; text-align:center }*/
.no_contet { padding:190px 0 40px; text-align:center; color:#999; border-top:1px solid #eee } .no_contet {
.no_comment { background:url(../images/no_comment.png) no-repeat center 80px } padding: 190px 0 40px;
text-align: center;
color: #999;
border-top: 1px solid #eee
}
.no_comment {
background: url(../images/no_comment.png) no-repeat center 80px
}
.comment_list {
padding: 20px 0;
border-bottom: 1px solid #eee
}
.comment_list:last-child {
border: none
}
.comment_list .user_heads { /*width: 54px; height: 54px; float: left;*/
position: relative;
margin-right: 20px
}
.comment_list .user_head {
width: 50px;
height: 50px;
border-radius: 50%;
background: #f6f6f6
}
.comment_list .user_heads span {
display: block;
margin: 0;
position: absolute;
left: 12px;
bottom: 0
}
.comment_list ul { /*width: 640px;*/
width: 660px;
}
.comment_list .li_0 {
font-family: "宋体"
}
.comment_list .li_0 strong {
font-size: 14px;
color: #f00
}
.comment_list .li_1 {
overflow: hidden
}
.comment_list .user_name {
color: #ed4259
}
.comment_list .li_2 {
padding: 6px 0
}
.comment_list .li_3 {
color: #999
}
.comment_list .reply {
padding-left: 12px
}
.comment_list .num {
color: #ed4259;
margin: 0 3px
}
.comment_list .li_4 {
line-height: 34px;
padding-top: 8px;
margin-top: 15px;
border-top: 1px solid #eaeaea
}
.pl_bar li {
display: block
}
.pl_bar .name {
color: #666;
padding-top: 2px;
font-size: 14px
}
.pl_bar .dec {
font-size: 14px;
line-height: 1.8;
padding: 12px 0
}
.pl_bar .other {
line-height: 24px;
color: #999;
font-size: 13px
}
.pl_bar .other a {
display: inline-block;
color: #999
}
.pl_bar .reply {
padding-left: 22px;
background: url(../images/icon_reply.png) no-repeat 0 2px
}
.comment_list { padding: 20px 0; border-bottom: 1px solid #eee }
.comment_list:last-child { border: none }
.comment_list .user_heads { /*width: 54px; height: 54px; float: left;*/ position:relative; margin-right: 20px }
.comment_list .user_head { width: 50px; height: 50px; border-radius: 50%; background: #f6f6f6 }
.comment_list .user_heads span { display: block; margin: 0; position: absolute; left: 12px; bottom: 0 }
.comment_list ul { /*width: 640px;*/ width: 660px; }
.comment_list .li_0 { font-family: "宋体" }
.comment_list .li_0 strong { font-size: 14px; color: #f00 }
.comment_list .li_1 { overflow: hidden }
.comment_list .user_name { color: #ed4259 }
.comment_list .li_2 { padding: 6px 0 }
.comment_list .li_3 { color: #999 }
.comment_list .reply { padding-left: 12px }
.comment_list .num { color: #ed4259; margin: 0 3px }
.comment_list .li_4 { line-height: 34px; padding-top: 8px; margin-top: 15px; border-top: 1px solid #eaeaea }
.pl_bar li { display: block }
.pl_bar .name { color: #666; padding-top: 2px; font-size: 14px }
.pl_bar .dec { font-size: 14px; line-height: 1.8; padding: 12px 0 }
.pl_bar .other { line-height: 24px; color: #999; font-size: 13px }
.pl_bar .other a { display: inline-block; color: #999 }
.pl_bar .reply { padding-left: 22px; background: url(../images/icon_reply.png) no-repeat 0 2px }
/*.no_comment { padding: 70px 14px 115px; color: #CCCCCC; text-align: center; font-size: 14px; }*/ /*.no_comment { padding: 70px 14px 115px; color: #CCCCCC; text-align: center; font-size: 14px; }*/
.reply_bar { .reply_bar {
background: #f9f9f9; background: #f9f9f9;
border: 1px solid #eee; border-radius: 6px; border: 1px solid #eee;
border-radius: 6px;
padding: 10px; padding: 10px;
line-height: 1.8;} line-height: 1.8;
}

View File

@ -457,8 +457,8 @@ html #layuicss-layer {
} }
.layui-layer-btn .layui-layer-btn0 { .layui-layer-btn .layui-layer-btn0 {
border-color: #f70; border-color: #3eaf7c;
background-color: #f70; background-color: #3eaf7c;
color: #fff color: #fff
} }

View File

@ -12,15 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">
@ -165,7 +157,14 @@
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "/crawl/addCrawlSingleTask", url: "/crawl/addCrawlSingleTask",
data: {'sourceId': sourceId, 'sourceName': sourceName,'catId':catId,'sourceBookId' : sourceBookId,'bookName':bookName,'authorName':authorName}, data: {
'sourceId': sourceId,
'sourceName': sourceName,
'catId': catId,
'sourceBookId': sourceBookId,
'bookName': bookName,
'authorName': authorName
},
dataType: "json", dataType: "json",
success: function (data) { success: function (data) {
if (data.code == 200) { if (data.code == 200) {

View File

@ -12,15 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">

View File

@ -12,15 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">

View File

@ -1,5 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"> <html xmlns="http://www.w3.org/1999/xhtml">
<head> <head>
<head> <head>
@ -12,14 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf" style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">
@ -41,6 +34,7 @@
<h2 class="fl">爬虫源列表</h2> <h2 class="fl">爬虫源列表</h2>
<div class="fr"><a href="/crawl/crawlSource_add.html" class="btn_red">增加爬虫源</a> <div class="fr"><a href="/crawl/crawlSource_add.html" class="btn_red">增加爬虫源</a>
</div> </div>
</div>
<div id="divData" class="updateTable"> <div id="divData" class="updateTable">
<table cellpadding="0" cellspacing="0"> <table cellpadding="0" cellspacing="0">
@ -69,7 +63,6 @@
<tbody id="crawlSourceList"> <tbody id="crawlSourceList">
</tbody> </tbody>
</table> </table>
<div class="pageBox cf" id="shellPage"> <div class="pageBox cf" id="shellPage">
@ -121,6 +114,7 @@
search(1, 10); search(1, 10);
var pageCrawlSourceList = null; var pageCrawlSourceList = null;
function search(curr, limit) { function search(curr, limit) {
$.ajax({ $.ajax({
@ -201,6 +195,7 @@
}) })
} }
function updateCrawlSource(crawlSourceId) { function updateCrawlSource(crawlSourceId) {
localStorage.setItem("crawlSourceId", crawlSourceId); localStorage.setItem("crawlSourceId", crawlSourceId);
@ -244,9 +239,6 @@
}) })
} }
</script> </script>
</html> </html>

View File

@ -12,15 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">
@ -28,9 +20,9 @@
<div class="my_l"> <div class="my_l">
<ul class="log_list"> <ul class="log_list">
<li><a class="link_1 on" href="/">爬虫源管理</a></li> <li><a class="link_1" href="/">爬虫源管理</a></li>
<li><a class="link_1" href="/crawl/crawlSingleTask_list.html">单本采集管理</a></li> <li><a class="link_1" href="/crawl/crawlSingleTask_list.html">单本采集管理</a></li>
<li><a class="link_1" href="/crawl/crawlSource_test.html" target="_blank" >规则测试</a></li> <li><a class="link_1 on" href="/crawl/crawlSource_test.html" target="_blank">规则测试</a></li>
<!--<li><a class="link_1 " href="/user/userinfo.html">批量小说爬取</a></li> <!--<li><a class="link_1 " href="/user/userinfo.html">批量小说爬取</a></li>
<li><a class="link_4 " href="/user/favorites.html">单本小说爬取</a></li>--> <li><a class="link_4 " href="/user/favorites.html">单本小说爬取</a></li>-->
</ul> </ul>
@ -64,12 +56,12 @@
示例:<b>value=\"(\\d+)/\\d+\"</b> 示例:<b>value=\"(\\d+)/\\d+\"</b>
<li><input type="text" id="rule" class="s_input icon_name" placeholder="规则"></li> <li><input type="text" id="rule" class="s_input icon_name" placeholder="规则"></li>
示例:<b>1强制刷新 空或0使用缓存</b> 示例:<b>1强制刷新 空或0使用缓存</b>
<li><input type="text" id="isRefresh" class="s_input icon_name" placeholder="是否强制刷新"></li> <li><input type="text" id="isRefresh" class="s_input icon_name" placeholder="是否强制刷新">
</li>
<li><textarea rows="20" cols="100" id="resultMap"></textarea></li> <li><textarea rows="20" cols="100" id="resultMap"></textarea></li>
<li><input type="button" onclick="testCrawlSource()" name="btnRegister" value="测试" <li><input type="button" onclick="testCrawlSource()" name="btnRegister" value="测试"
id="btnRegister" class="btn_red"></li> id="btnRegister" class="btn_red"></li>
</ul> </ul>
@ -125,6 +117,7 @@
var testParseRule = localStorage.getItem("testParseRule"); var testParseRule = localStorage.getItem("testParseRule");
$("#rule").val(testParseRule); $("#rule").val(testParseRule);
} }
function testCrawlSource() { function testCrawlSource() {
var data = {}; var data = {};

View File

@ -12,15 +12,7 @@
</head> </head>
<body class=""> <body class="">
<div class="header"> <div th:replace="crawl/header :: header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;">
小说精品屋爬虫管理
</div>
</div>
</div> </div>
<div class="main box_center cf"> <div class="main box_center cf">
@ -229,6 +221,7 @@
}) })
} }
} }
function loadPage(data) { function loadPage(data) {
$("#sourceId").val(data.id); $("#sourceId").val(data.id);
$("#sourceName").val(data.sourceName); $("#sourceName").val(data.sourceName);
@ -279,6 +272,7 @@
} }
} }
load(); load();
function updateCrawlSource() { function updateCrawlSource() {

View File

@ -0,0 +1,28 @@
<div th:fragment="header" class="header">
<div class="mainNav" id="mainNav">
<div class="box_center cf"
style="text-align: center;height: 44px;line-height: 48px;color: #fff;font-size: 16px;width: 100%">
小说精品屋爬虫管理
<div style="text-align: center;height: 44px;line-height: 48px;font-size: 14px;float: right;padding-right: 20px">
<a style="color: #fff;"
href="/logout">
退出
</a>
</div>
<div style="float: right;margin-right:5px;margin-top: 15px">
<svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" role="img"
class="mr-3 iconify iconify--gitee icon-user-arrow-right" width="16" height="16"
preserveAspectRatio="xMidYMid meet" viewBox="0 0 16 16">
<g fill="none" fill-rule="evenodd">
<path d="M0 0h16v16H0z"></path>
<path fill="currentColor" fill-rule="nonzero"
d="M8 1.5a3.5 3.5 0 01.192 6.995L8 8.5a5.75 5.75 0 00-5.75 5.75.5.5 0 11-1 0 6.753 6.753 0 014.681-6.427A3.5 3.5 0 018 1.5zm6.996 10.767.003.041v.002l.001.011a.51.51 0 010 .006v.006l-.002.03a.502.502 0 01-.004.037l-.002.011a.39.39 0 01-.016.063.491.491 0 01-.053.114l-.028.039-.031.035.027-.03-.009.011-.017.02-.011.012-2.122 2.121a.5.5 0 01-.707-.707l1.268-1.268H9.5a.5.5 0 110-1h3.794l-1.269-1.267a.5.5 0 11.707-.708l2.122 2.122a.491.491 0 01.135.248l.005.037v-.006zM8 2.5a2.5 2.5 0 100 5 2.5 2.5 0 000-5z"></path>
</g>
</svg>
</div>
</div>
</div>
</div>

View File

@ -5,25 +5,55 @@
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" content=""> <meta name="description" content="">
<meta name="author" content=""> <meta name="author" content="">
<title>Please sign in</title> <title>爬虫管理系统登录</title>
<link href="/css/bootstrap.min.css" rel="stylesheet" <link href="/css/bootstrap.min.css" rel="stylesheet"/>
integrity="sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6M" crossorigin="anonymous"> <link href="/css/signin.css" rel="stylesheet"/>
<link href="/css/signin.css" rel="stylesheet" crossorigin="anonymous"/> <style>
.btn-primary {
color: #fff;
background-color: #3eaf7c;
border-color: #3eaf7c
}
.btn-primary:hover {
color: #fff;
background-color: #65bf96;
border-color: #65bf96
}
.btn-primary.focus, .btn-primary:focus {
box-shadow: 0 0 0 3px rgba(101, 191, 96, .5)
}
.btn-primary.disabled, .btn-primary:disabled {
background-color: #3eaf7c;
border-color: #3eaf7c
}
.form-control:focus {
color: #495057;
background-color: #fff;
border-color: #78c7a3;
outline: 0
}
</style>
</head> </head>
<body> <body>
<div class="container"> <div class="container">
<form class="form-signin" method="post" action="/login"> <form class="form-signin" method="post" action="/login">
<h2 class="form-signin-heading">Please sign in</h2> <h4 style="text-align: center" class="form-signin-heading">爬虫管理系统登录</h4>
<p> <p>
<label for="username" class="sr-only">Username</label> <label for="username" class="sr-only">用户名</label>
<input type="text" id="username" name="username" class="form-control" placeholder="Username" required <input type="text" id="username" name="username" class="form-control" placeholder="用户名" required
autofocus> autofocus>
</p> </p>
<p> <p>
<label for="password" class="sr-only">Password</label> <label for="password" class="sr-only">密码</label>
<input type="password" id="password" name="password" class="form-control" placeholder="Password" required> <input type="password" id="password" name="password" class="form-control" placeholder="密码" required>
</p> </p>
<button class="btn btn-lg btn-primary btn-block" type="submit">Sign in</button> <button class="btn btn-lg btn-primary btn-block" type="submit">登录</button>
</form> </form>
</div> </div>
</body> </body>

View File

@ -1,6 +0,0 @@
FROM java:8
ADD novel-front-1.1.0.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -jar /root/novel-front-1.1.0.jar"]

View File

@ -5,7 +5,7 @@
<parent> <parent>
<artifactId>novel</artifactId> <artifactId>novel</artifactId>
<groupId>com.java2nb</groupId> <groupId>com.java2nb</groupId>
<version>4.2.0</version> <version>4.3.0</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
@ -98,6 +98,9 @@
<zip destfile='${project.build.directory}/build/${project.artifactId}.zip'> <zip destfile='${project.build.directory}/build/${project.artifactId}.zip'>
<zipfileset filemode="755" dir='${project.build.directory}/build/'/> <zipfileset filemode="755" dir='${project.build.directory}/build/'/>
</zip> </zip>
<copy file="${basedir}/src/main/build/docker/Dockerfile"
tofile="${project.build.directory}/build/Dockerfile"/>
</tasks> </tasks>
</configuration> </configuration>
</execution> </execution>

View File

@ -34,7 +34,7 @@ pic:
#模版配置 #模版配置
templates: templates:
name: orange name: green
#小说内容保存配置 #小说内容保存配置
content: content:

View File

@ -0,0 +1,9 @@
FROM openjdk:8
ADD novel-front.jar /root
ENV dburl=""
ENV username=""
ENV password=""
ENV redishost = ""
ENV redisport = ""
ENV redispwd = ""
ENTRYPOINT ["sh","-c","java -Dspring.datasource.url=${dburl} -Dspring.datasource.username=${username} -Dspring.datasource.password=${password} -Dspring.redis.host=${redishost} -Dspring.redis.port=${redisport} -Dspring.redis.password=${redispwd} -jar /root/novel-front.jar"]

View File

@ -6,6 +6,7 @@ import com.alipay.api.DefaultAlipayClient;
import com.alipay.api.internal.util.AlipaySignature; import com.alipay.api.internal.util.AlipaySignature;
import com.alipay.api.request.AlipayTradePagePayRequest; import com.alipay.api.request.AlipayTradePagePayRequest;
import com.alipay.api.request.AlipayTradeWapPayRequest; import com.alipay.api.request.AlipayTradeWapPayRequest;
import com.alipay.api.response.AlipayTradePagePayResponse;
import com.alipay.api.response.AlipayTradeWapPayResponse; import com.alipay.api.response.AlipayTradeWapPayResponse;
import com.java2nb.novel.core.bean.UserDetails; import com.java2nb.novel.core.bean.UserDetails;
import com.java2nb.novel.core.config.AlipayProperties; import com.java2nb.novel.core.config.AlipayProperties;
@ -50,7 +51,7 @@ public class PayController extends BaseController {
UserDetails userDetails = getUserDetails(request); UserDetails userDetails = getUserDetails(request);
if (userDetails == null) { if (userDetails == null) {
//未登录,跳转到登陆页面 //未登录,跳转到登陆页面
httpResponse.sendRedirect("/user/login.html?originUrl=/pay/aliPay?payAmount=" + payAmount); httpResponse.sendRedirect("/user/login.html?originUrl=/pay/index.html");
} else { } else {
//创建充值订单 //创建充值订单
Long outTradeNo = orderService.createPayOrder((byte) 1, payAmount, userDetails.getId()); Long outTradeNo = orderService.createPayOrder((byte) 1, payAmount, userDetails.getId());
@ -79,8 +80,8 @@ public class PayController extends BaseController {
bizContent.put("product_code", "QUICK_WAP_WAY"); bizContent.put("product_code", "QUICK_WAP_WAY");
alipayRequest.setBizContent(bizContent.toString()); alipayRequest.setBizContent(bizContent.toString());
AlipayTradeWapPayResponse response = alipayClient.pageExecute(alipayRequest); AlipayTradeWapPayResponse payResponse = alipayClient.pageExecute(alipayRequest);
form = alipayClient.pageExecute(alipayRequest).getBody(); form = payResponse.getBody();
} else { } else {
// 电脑站 // 电脑站
//创建API对应的request //创建API对应的request
@ -96,7 +97,8 @@ public class PayController extends BaseController {
" \"subject\":\"小说精品屋-plus\"" + " \"subject\":\"小说精品屋-plus\"" +
" }"); " }");
//调用SDK生成表单 //调用SDK生成表单
form = alipayClient.pageExecute(alipayRequest).getBody(); AlipayTradePagePayResponse payResponse = alipayClient.pageExecute(alipayRequest);
form = payResponse.getBody();
} }
@ -119,7 +121,7 @@ public class PayController extends BaseController {
PrintWriter out = httpResponse.getWriter(); PrintWriter out = httpResponse.getWriter();
//获取支付宝POST过来反馈信息 //获取支付宝POST过来信息
Map<String, String> params = new HashMap<>(); Map<String, String> params = new HashMap<>();
Map<String, String[]> requestParams = request.getParameterMap(); Map<String, String[]> requestParams = request.getParameterMap();
for (String name : requestParams.keySet()) { for (String name : requestParams.keySet()) {
@ -132,18 +134,10 @@ public class PayController extends BaseController {
params.put(name, valueStr); params.put(name, valueStr);
} }
//调用SDK验证签名 //验证签名
boolean signVerified = AlipaySignature.rsaCheckV1(params, alipayConfig.getPublicKey(), boolean signVerified = AlipaySignature.rsaCheckV1(params, alipayConfig.getPublicKey(),
alipayConfig.getCharset(), alipayConfig.getSignType()); alipayConfig.getCharset(), alipayConfig.getSignType());
//——请在这里编写您的程序(以下代码仅作参考)——
/* 实际验证过程建议商户务必添加以下校验:
1、需要验证该通知数据中的out_trade_no是否为商户系统中创建的订单号
2、判断total_amount是否确实为该订单的实际金额即商户订单创建时的金额
3、校验通知中的seller_id或者seller_email) 是否为out_trade_no这笔单据的对应的操作方有的时候一个商户可能有多个seller_id/seller_email
4、验证app_id是否为该商户本身。
*/
if (signVerified) { if (signVerified) {
//验证成功 //验证成功
//商户订单号 //商户订单号
@ -158,21 +152,18 @@ public class PayController extends BaseController {
String tradeStatus = new String(request.getParameter("trade_status").getBytes(StandardCharsets.ISO_8859_1), String tradeStatus = new String(request.getParameter("trade_status").getBytes(StandardCharsets.ISO_8859_1),
StandardCharsets.UTF_8); StandardCharsets.UTF_8);
//更新订单状态 if ("TRADE_SUCCESS".equals(tradeStatus)) {
orderService.updatePayOrder(Long.parseLong(outTradeNo), tradeNo, tradeStatus); //支付成功
orderService.updatePayOrder(Long.parseLong(outTradeNo), tradeNo, 1);
}
out.println("success"); out.println("success");
} else {//验证失败 } else {//验证失败
out.println("fail"); out.println("fail");
//调试用,写文本函数记录程序运行情况是否正常
//String sWord = AlipaySignature.getSignCheckContentV1(params);
//AlipayConfig.logResult(sWord);
} }
} }
} }

View File

@ -0,0 +1,15 @@
package com.java2nb.novel.mapper;
import org.apache.ibatis.annotations.Param;
/**
* @author Administrator
*/
public interface FrontUserMapper extends UserMapper {
void addUserBalance(@Param("userId") Long userId, @Param("amount") Integer amount);
}

View File

@ -1,7 +1,6 @@
package com.java2nb.novel.service; package com.java2nb.novel.service;
/** /**
* @author 11797 * @author 11797
*/ */
@ -15,15 +14,16 @@ public interface OrderService {
* @param payAmount 支付金额 * @param payAmount 支付金额
* @param userId 用户ID * @param userId 用户ID
* @return 商户订单号 * @return 商户订单号
* */ */
Long createPayOrder(Byte payChannel, Integer payAmount, Long userId); Long createPayOrder(Byte payChannel, Integer payAmount, Long userId);
/** /**
* 更新订单状态 * 更新订单状态
*
* @param outTradeNo 商户订单号 * @param outTradeNo 商户订单号
* @param tradeNo 支付宝/微信 订单号 * @param tradeNo 支付宝/微信 订单号
* @param tradeStatus 支付状态 * @param payStatus 支付状态
* */ */
void updatePayOrder(Long outTradeNo, String tradeNo, String tradeStatus); void updatePayOrder(Long outTradeNo, String tradeNo, int payStatus);
} }

View File

@ -9,6 +9,7 @@ import lombok.RequiredArgsConstructor;
import lombok.SneakyThrows; import lombok.SneakyThrows;
import org.mybatis.dynamic.sql.render.RenderingStrategies; import org.mybatis.dynamic.sql.render.RenderingStrategies;
import org.mybatis.dynamic.sql.select.render.SelectStatementProvider; import org.mybatis.dynamic.sql.select.render.SelectStatementProvider;
import org.mybatis.dynamic.sql.update.render.UpdateStatementProvider;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
@ -17,6 +18,7 @@ import java.util.Date;
import java.util.Random; import java.util.Random;
import static org.mybatis.dynamic.sql.SqlBuilder.isEqualTo; import static org.mybatis.dynamic.sql.SqlBuilder.isEqualTo;
import static org.mybatis.dynamic.sql.SqlBuilder.update;
import static org.mybatis.dynamic.sql.select.SelectDSL.select; import static org.mybatis.dynamic.sql.select.SelectDSL.select;
/** /**
@ -35,7 +37,8 @@ public class OrderServiceImpl implements OrderService {
@Override @Override
public Long createPayOrder(Byte payChannel, Integer payAmount, Long userId) { public Long createPayOrder(Byte payChannel, Integer payAmount, Long userId) {
Date currentDate = new Date(); Date currentDate = new Date();
Long outTradeNo = Long.parseLong(new SimpleDateFormat("yyyyMMddHHmmssSSS").format(currentDate)+new Random().nextInt(10)); Long outTradeNo = Long.parseLong(
new SimpleDateFormat("yyyyMMddHHmmssSSS").format(currentDate) + new Random().nextInt(10));
OrderPay orderPay = new OrderPay(); OrderPay orderPay = new OrderPay();
orderPay.setOutTradeNo(outTradeNo); orderPay.setOutTradeNo(outTradeNo);
orderPay.setPayChannel(payChannel); orderPay.setPayChannel(payChannel);
@ -49,37 +52,39 @@ public class OrderServiceImpl implements OrderService {
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Override @Override
public void updatePayOrder(Long outTradeNo, String tradeNo, String tradeStatus) { public void updatePayOrder(Long outTradeNo, String tradeNo, int payStatus) {
SelectStatementProvider selectStatement = select(OrderPayDynamicSqlSupport.id,OrderPayDynamicSqlSupport.payStatus,OrderPayDynamicSqlSupport.totalAmount,OrderPayDynamicSqlSupport.userId) SelectStatementProvider selectStatement = select(OrderPayDynamicSqlSupport.id,
OrderPayDynamicSqlSupport.payStatus, OrderPayDynamicSqlSupport.totalAmount,
OrderPayDynamicSqlSupport.userId)
.from(OrderPayDynamicSqlSupport.orderPay) .from(OrderPayDynamicSqlSupport.orderPay)
.where(OrderPayDynamicSqlSupport.outTradeNo, isEqualTo(outTradeNo)) .where(OrderPayDynamicSqlSupport.outTradeNo, isEqualTo(outTradeNo))
.build() .build()
.render(RenderingStrategies.MYBATIS3); .render(RenderingStrategies.MYBATIS3);
OrderPay orderPay = orderPayMapper.selectMany(selectStatement).get(0); OrderPay orderPay = orderPayMapper.selectOne(selectStatement).orElse(null);
if(orderPay.getPayStatus()!=1) { if (orderPay.getPayStatus().intValue() == 2) {
//此订单还未处理 //待支付订单处理
if (payStatus == 1) {
if (tradeStatus.equals("TRADE_SUCCESS") || tradeStatus.equals("TRADE_FINISHED")) {
//支付成功 //支付成功
//1.更新订单状态为成功 //1.更新订单状态为成功
orderPay.setPayStatus((byte) 1); UpdateStatementProvider updateStatement = update(OrderPayDynamicSqlSupport.orderPay)
orderPay.setUpdateTime(new Date()); .set(OrderPayDynamicSqlSupport.tradeNo).equalTo(tradeNo)
orderPayMapper.updateByPrimaryKeySelective(orderPay); .set(OrderPayDynamicSqlSupport.payStatus).equalTo((byte) 1)
.set(OrderPayDynamicSqlSupport.updateTime).equalTo(new Date())
.where(OrderPayDynamicSqlSupport.id, isEqualTo(orderPay.getId()))
.and(OrderPayDynamicSqlSupport.payStatus, isEqualTo((byte) 2))
.build()
.render(RenderingStrategies.MYBATIS3);
int updateRow = orderPayMapper.update(updateStatement);
if (updateRow > 0) {
//更新成功
//2.增加用户余额 //2.增加用户余额
userService.addAmount(orderPay.getUserId(), orderPay.getTotalAmount() * 100); userService.addAmount(orderPay.getUserId(), orderPay.getTotalAmount() * 100);
}
} }
} }
} }
} }

Some files were not shown because too many files have changed in this diff Show More