diff --git a/.gitignore b/.gitignore index b28673a4e5f95674f997c10d116408eeec07ec91..a482c7f6a8c8992cd9e6e17939273254595cac8b 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,5 @@ out/ target/ build/ logs/ +# jrebel +rebel.xml diff --git a/README.md b/README.md index 73b9dad4d73673803edb53a68cc296bac3e127d0..a2ef91a3ff0216826b55b3ef7379f65f519330fd 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# Bootx-Platform (v1.3.0-园博园) +# Bootx-Platform (v1.3.1-园博园)

star - Build Status + Build Status Build Status Downloads @@ -43,10 +43,10 @@ ## 📚文档 -- 系统演示地址:[管理平台(vue2)](http://web.platform.bootx.cn/)、[管理平台(vue3)](http://v3.platform.bootx.cn/)、[可视化大屏](http://visualization.platform.bootx.cn/) -- 前端项目地址:[前端项目(vue2)](https://gitee.com/bootx/bootx-platform-ui)、[前端项目(vue3)](https://gitee.com/bootx/bootx-platform-vue3)、[可视化大屏](https://gitee.com/bootx/bootx-platform-visualization) +- 系统演示地址:[管理平台(vue3)](http://v3.platform.bootx.cn/)、[可视化大屏](http://visualization.platform.bootx.cn/) +- 前端项目地址:[前端项目(vue3)](https://gitee.com/bootx/bootx-platform-vue3)、[可视化大屏](https://gitee.com/bootx/bootx-platform-visualization)、[前端项目(vue2只维护不再更新)](https://gitee.com/bootx/bootx-platform-ui) - 移动端项目地址:[移动端项目(taro+vue3+ts)](https://gitee.com/xucun/bootx-platform-mobile) -- 日志收集:[ELK](http://elk.dev.bootx.cn:5601/app/discove)、[PlumeLog](http://platform.dev.bootx.cn:8080/plumelog/#/) +- 日志收集:[[PlumeLog](http://platform.dev.bootx.cn:8080/plumelog/#/) - 项目文档:[项目文档(GITEE)](https://bootx.gitee.io/)、[项目文档(备用)](https://doc.bootx.cn/) - 更新日志:[更新日志](./_doc/ChangeLog.md) @@ -60,8 +60,6 @@ 支持支付宝、微信、聚合支付、现金支付、储值卡支付、钱包,对各种支付方式抽象成策略类,通过模板模式进行串通,方便扩展新的支付方式或业务 -结算台演示地址:[http://web.platform.bootx.cn/cashier](http://web.platform.bootx.cn/cashier) - ![](https://oscimg.oschina.net/oscnet/up-9f0044b76071d5a7f598ceab591c5fedb02.png) ## 🍎特色功能 diff --git a/_config/sql/bootx-platform.sql b/_config/sql/bootx-platform.sql index c126cf17c0d313f211e71c9b8ab7fbd32056d31b..0fb97592923089be8c0c3a9133671c642b4f4360 100644 --- a/_config/sql/bootx-platform.sql +++ b/_config/sql/bootx-platform.sql @@ -1,7 +1,6 @@ /* Navicat Premium Data Transfer - Source Server : bootx Source Server Type : MySQL Source Server Version : 50735 @@ -9,7 +8,7 @@ Target Server Version : 50735 File Encoding : 65001 - Date: 10/05/2023 09:31:59 + Date: 07/06/2023 15:15:39 */ SET NAMES utf8mb4; @@ -3598,6 +3597,7 @@ CREATE TABLE `base_dynamic_data_source` ( `code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '数据源编码', `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '数据源名称', `database_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '数据库类型', + `auto_load` bit(1) NULL DEFAULT NULL COMMENT '是否启动自动加载', `db_driver` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '驱动类', `db_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '数据库地址', `db_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '数据库名称', @@ -3740,6 +3740,31 @@ INSERT INTO `base_province` VALUES ('63', '青海省'); INSERT INTO `base_province` VALUES ('64', '宁夏回族自治区'); INSERT INTO `base_province` VALUES ('65', '新疆维吾尔自治区'); +-- ---------------------------- +-- Table structure for base_query_sql +-- ---------------------------- +DROP TABLE IF EXISTS `base_query_sql`; +CREATE TABLE `base_query_sql` ( + `id` bigint(20) NOT NULL COMMENT '主键', + `database_id` bigint(20) NULL DEFAULT NULL COMMENT '数据源ID', + `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '名称', + `is_list` bit(1) NULL DEFAULT NULL COMMENT '是否集合', + `sql` text CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT 'sql语句', + `params` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'SQL查询参数', + `fields` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'SQL查询结果字段', + `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建者ID', + `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', + `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修者ID', + `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', + `version` int(11) NOT NULL COMMENT '乐观锁', + `deleted` bit(1) NOT NULL COMMENT '删除标志', + PRIMARY KEY (`id`) USING BTREE +) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = 'SQL查询语句' ROW_FORMAT = DYNAMIC; + +-- ---------------------------- +-- Records of base_query_sql +-- ---------------------------- + -- ---------------------------- -- Table structure for base_street -- ---------------------------- @@ -3772,141 +3797,6 @@ CREATE TABLE `base_village` ( -- Records of base_village -- ---------------------------- --- ---------------------------- --- Table structure for bpm_instance --- ---------------------------- -DROP TABLE IF EXISTS `bpm_instance`; -CREATE TABLE `bpm_instance` ( - `id` bigint(20) NOT NULL, - `instance_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL COMMENT '流程实例的id', - `instance_name` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程标题', - `model_id` bigint(20) NULL DEFAULT NULL COMMENT '模型id', - `def_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程定义ID', - `def_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程定义名称', - `start_user_id` bigint(20) NULL DEFAULT NULL COMMENT '发起人', - `start_user_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '发起人名称', - `state` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程实例的状态', - `start_time` datetime(0) NULL DEFAULT NULL COMMENT '开始时间', - `end_time` datetime(0) NULL DEFAULT NULL COMMENT '结束时间', - `form_variables` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT '提交的表单值', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '更新人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', - `deleted` tinyint(1) NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - `version` int(8) NULL DEFAULT NULL COMMENT '版本', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '流程实例扩展' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of bpm_instance --- ---------------------------- - --- ---------------------------- --- Table structure for bpm_model --- ---------------------------- -DROP TABLE IF EXISTS `bpm_model`; -CREATE TABLE `bpm_model` ( - `id` bigint(20) NOT NULL, - `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL COMMENT '名称', - `model_type` varchar(120) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程类型', - `form_id` bigint(20) NULL DEFAULT NULL COMMENT '关联表单', - `publish` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '发布状态', - `enable` bit(1) NULL DEFAULT NULL COMMENT '启用状态', - `deploy_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '部署id', - `def_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程定义id', - `def_key` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程key', - `def_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程名称', - `def_remark` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程备注', - `main_process` bit(1) NULL DEFAULT NULL COMMENT '是否主流程', - `process_version` int(8) NULL DEFAULT NULL COMMENT '流程版本号', - `model_editor_xml` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT '流程xml', - `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NULL DEFAULT NULL COMMENT '备注', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '更新人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', - `deleted` tinyint(1) NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - `version` int(8) NULL DEFAULT NULL COMMENT '版本', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '流程模型' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of bpm_model --- ---------------------------- - --- ---------------------------- --- Table structure for bpm_model_node --- ---------------------------- -DROP TABLE IF EXISTS `bpm_model_node`; -CREATE TABLE `bpm_model_node` ( - `id` bigint(20) NOT NULL, - `model_id` bigint(20) NOT NULL COMMENT '关联模型id', - `def_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程定义id', - `def_key` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程key', - `node_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '任务节点id', - `node_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '任务节点名称', - `multi` bit(1) NOT NULL COMMENT '是否多任务', - `sequential` bit(1) NULL DEFAULT NULL COMMENT '是否串签', - `or_sign` bit(1) NULL DEFAULT NULL COMMENT '是否是或签', - `ratio_pass` bit(1) NULL DEFAULT NULL COMMENT '是否比例通过', - `pass_ratio` int(3) NULL DEFAULT NULL COMMENT '通过比例', - `reject` bit(1) NOT NULL COMMENT '是否允许驳回', - `back` bit(1) NOT NULL COMMENT '是否允许回退', - `retrieve` bit(1) NOT NULL COMMENT '是否允许取回', - `skip` bit(1) NOT NULL COMMENT '是否跳过当前节点', - `form_id` bigint(20) NULL DEFAULT NULL COMMENT '关联表单', - `assign_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '分配类型', - `assign_raw` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT '分配的原始数据', - `assign_show` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT '分配的数据的展示', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '更新人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', - `version` int(8) NULL DEFAULT NULL COMMENT '版本', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '模型任务节点配置' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of bpm_model_node --- ---------------------------- - --- ---------------------------- --- Table structure for bpm_task --- ---------------------------- -DROP TABLE IF EXISTS `bpm_task`; -CREATE TABLE `bpm_task` ( - `id` bigint(20) NOT NULL, - `task_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL COMMENT '任务ID', - `execution_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '任务执行 ID', - `multi_id` bigint(20) NULL DEFAULT NULL COMMENT '多实例关联id', - `instance_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL COMMENT '流程实例的id', - `instance_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程名称(业务标题)', - `def_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '流程定义名称', - `node_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '任务节点id', - `node_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '任务节点名称', - `state` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '处理状态', - `result` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '处理结果', - `reason` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '处理意见', - `start_time` datetime(0) NULL DEFAULT NULL COMMENT '开始时间', - `end_time` datetime(0) NULL DEFAULT NULL COMMENT '结束时间', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '当前处理人', - `user_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '当前处理人', - `start_user_id` bigint(20) NULL DEFAULT NULL COMMENT '发起人', - `start_user_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '发起人名称', - `form_variables` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL COMMENT '提交的表单值', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '更新人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '更新时间', - `version` int(8) NOT NULL COMMENT '版本', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '流程任务扩展' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of bpm_task --- ---------------------------- - -- ---------------------------- -- Table structure for common_sequence_range -- ---------------------------- @@ -4297,7 +4187,7 @@ INSERT INTO `iam_perm_menu` VALUES (1511266086400524288, 'admin', 14508225110872 INSERT INTO `iam_perm_menu` VALUES (1530120084482084864, 'admin', 1495968302034210816, '消息中间件演示', 'MQDemo', NULL, b'0', '', b'0', b'0', 'demo/mq/MqDemo', NULL, '/demo/mq', '', 0, 1, NULL, b'1', b'0', b'0', b'0', NULL, 1399985191002447872, '2022-05-27 17:33:51', 1399985191002447872, '2022-05-31 15:12:15', 1, 0); INSERT INTO `iam_perm_menu` VALUES (1530120684645044224, 'admin', 1530120084482084864, 'MQTT消息', 'MqttDemo', NULL, b'0', '', b'0', b'0', '', NULL, '/demo/mq/mqtt', '', 0, 1, NULL, b'1', b'0', b'0', b'0', NULL, 1399985191002447872, '2022-05-27 17:36:14', 1399985191002447872, '2022-05-27 17:36:14', 0, 1); INSERT INTO `iam_perm_menu` VALUES (1530120821144473600, 'admin', 1530120084482084864, 'RabbitMQ', 'RabbitDemo', NULL, b'0', '', b'0', b'0', '', NULL, '/demo/mq/rabbit', '', 0, 1, NULL, b'1', b'0', b'0', b'0', NULL, 1399985191002447872, '2022-05-27 17:36:47', 1399985191002447872, '2022-05-27 17:36:47', 0, 1); -INSERT INTO `iam_perm_menu` VALUES (1534000136370204672, 'admin', 1431152689832525824, 'ELK日志', 'ELK', '', b'0', '', b'0', b'0', '', NULL, 'http://elk.dev.bootx.cn:5601/app/discover', '', 0, 1, NULL, b'1', b'1', b'0', b'0', NULL, 1399985191002447872, '2022-06-07 10:31:48', 1399985191002447872, '2022-06-07 10:31:48', 0, 0); +INSERT INTO `iam_perm_menu` VALUES (1534000136370204672, 'admin', 1431152689832525824, 'ELK日志', 'ELK', '', b'0', '', b'1', b'0', '', NULL, 'http://elk.dev.bootx.cn:5601/app/discover', '', 0, 1, NULL, b'1', b'1', b'0', b'0', NULL, 1399985191002447872, '2022-06-07 10:31:48', 1399985191002447872, '2022-06-07 10:31:48', 0, 0); INSERT INTO `iam_perm_menu` VALUES (1534008203006652416, 'admin', 1431152689832525824, 'PlumeLog日志', 'PlumeLog', '', b'0', '', b'0', b'0', '', NULL, 'http://127.0.0.1:9999/plumelog/#/', '', 0, 1, NULL, b'1', b'1', b'0', b'0', NULL, 1399985191002447872, '2022-06-07 11:03:51', 1399985191002447872, '2022-06-07 11:06:13', 1, 0); INSERT INTO `iam_perm_menu` VALUES (1535451167008436224, 'admin', 1431152689832525824, '系统信息', 'SysInfo', NULL, b'0', '', b'0', b'0', 'starter/monitor/SystemInfoMonitor', NULL, '/monitor/sysinfo', '', 0, 1, NULL, b'0', b'0', b'0', b'0', NULL, 1399985191002447872, '2022-06-11 10:37:40', 1399985191002447872, '2022-06-13 13:07:46', 1, 0); INSERT INTO `iam_perm_menu` VALUES (1535965936371085312, 'admin', 1431152689832525824, 'Redis监控', 'RedisInfoMonitor', NULL, b'0', '', b'0', b'0', 'starter/monitor/RedisInfoMonitor', NULL, '/monitor/redis', '', 0, 1, NULL, b'0', b'0', b'0', b'0', NULL, 1399985191002447872, '2022-06-12 20:43:11', 1399985191002447872, '2022-06-13 13:07:38', 1, 0); @@ -4675,8 +4565,6 @@ CREATE TABLE `notice_mail_config` ( -- ---------------------------- -- Records of notice_mail_config -- ---------------------------- -INSERT INTO `notice_mail_config` VALUES (1554739296333955072, 'fox', 'foxmail邮箱', 'smtp.qq.com', 465, 'sJfAJDDviYlqZ3BtdjMZF8V5jVSYCaMa9DNdVGDbe/s=', '7AtgVwObaO7wrsRpLvKkoo5O+udeEcFP1ONq4gYwOj0=', 'bootx-platform平台', 'xxm1995@foxmail.com', 1, 3, 1399985191002447872, '2022-08-03 16:01:49', 1399985191002447872, '2022-08-03 16:14:55', 0, 8); -INSERT INTO `notice_mail_config` VALUES (1584814372311744512, '11', '22', '33', 465, 'pwfAgEMJjGLjbVYEcgdXzA==', 'f3zJMwbPGmNRlNXpN5AMyA==', '666', '33333333@foxmail.com', 0, 1, 1414143554414059520, '2022-10-25 15:49:25', 1414143554414059520, '2022-10-25 16:27:12', 0, 10); -- ---------------------------- -- Table structure for notice_message_template @@ -4738,11 +4626,6 @@ CREATE TABLE `notice_site_message` ( -- ---------------------------- -- Records of notice_site_message -- ---------------------------- -INSERT INTO `notice_site_message` VALUES (1424212599079161857, '测试消息', '

55
5
5
5
5
5
5
5
5
5
5
5
6等非撒扥森速度扥三扥所
6
8
8
5撒扥森森的
5
5撒扥岁送
8
8
8
', 1399985191002447872, '小小明', '2021-08-08 11:34:11', 'all', 'cancel', NULL, '2022-08-21 23:01:16', 1399985191002447872, '2021-08-08 11:35:19', 1399985191002447872, '2022-08-21 23:01:16', 1, 0); -INSERT INTO `notice_site_message` VALUES (1558781525200130048, '测试站内信', '
sdfsdfsdf
  1. 333
', 0, '未知', '2022-08-14 19:44:11', NULL, 'sent', NULL, NULL, 0, '2022-08-14 19:44:11', 0, '2022-08-14 19:44:11', 0, 0); -INSERT INTO `notice_site_message` VALUES (1561363288741085184, '测试消息', '

三扥广丰和扥撒扥撒扥东方

', 1399985191002447872, '小小明', '2022-08-21 22:59:45', 'all', 'draft', '2022-09-20 00:00:00', NULL, 1399985191002447872, '2022-08-21 22:43:11', 1399985191002447872, '2022-08-21 23:23:03', 4, 1); -INSERT INTO `notice_site_message` VALUES (1561365894804766720, '测试数据', '

234554通扥广森

', 1399985191002447872, '小小明', '2022-08-21 23:48:55', 'all', 'sent', '2022-09-20 00:00:00', NULL, 1399985191002447872, '2022-08-21 22:53:33', 1399985191002447872, '2022-08-21 23:48:55', 1, 0); -INSERT INTO `notice_site_message` VALUES (1561368170558623744, '测试数据', '

234554通扥广森

DFF

撒扥萨芬的

11
33
44
风很高
', 1399985191002447872, '小小明', '2022-08-21 23:33:01', 'all', 'sent', '2022-09-20 00:00:00', NULL, 1399985191002447872, '2022-08-21 23:02:35', 1399985191002447872, '2022-08-21 23:33:01', 7, 0); -- ---------------------------- -- Table structure for notice_site_message_user @@ -4848,440 +4731,6 @@ CREATE TABLE `notice_wechat_config` ( -- ---------------------------- -- Records of notice_wechat_config -- ---------------------------- -INSERT INTO `notice_wechat_config` VALUES (181361815405135421, 0, 'test01', 'test01', 'ww9d6247559117d202', '8n6A3SzN-DJNkw8wyCcJnr8-SOjFFWSOlBqZN8vypKM', 1, 1415, '2018-11-20 11:07:07', 1415, '2018-11-20 11:07:07', 0, 0); - --- ---------------------------- --- Table structure for pay_ali_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_ali_payment`; -CREATE TABLE `pay_ali_payment` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NULL DEFAULT NULL COMMENT '交易记录ID', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '用户ID', - `amount` decimal(19, 2) NULL DEFAULT NULL COMMENT '交易金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款余额', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '业务id', - `pay_status` int(11) NULL DEFAULT NULL COMMENT '支付状态', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `trade_no` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '支付宝关联流水号', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(6) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NULL DEFAULT NULL COMMENT '版本', - `deleted` bit(1) NOT NULL COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '支付宝支付记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_ali_payment --- ---------------------------- - --- ---------------------------- --- Table structure for pay_alipay_config --- ---------------------------- -DROP TABLE IF EXISTS `pay_alipay_config`; -CREATE TABLE `pay_alipay_config` ( - `id` bigint(20) NOT NULL, - `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '名称', - `app_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '支付宝商户appId', - `notify_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '服务器异步通知页面路径', - `return_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '页面跳转同步通知页面路径', - `server_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '请求网关地址', - `auth_type` int(4) NOT NULL COMMENT '认证方式', - `sign_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '签名类型', - `alipay_public_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝公钥', - `private_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '私钥', - `app_cert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '应用公钥', - `alipay_cert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝公钥证书', - `alipay_root_cert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝CA根证书', - `sandbox` bit(1) NOT NULL COMMENT '是否沙箱环境', - `expire_time` int(10) NOT NULL COMMENT '超时配置', - `pay_ways` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '支持的支付类型', - `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注', - `activity` bit(1) NOT NULL COMMENT '是否启用', - `state` int(11) NOT NULL COMMENT '状态', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '支付宝配置' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_alipay_config --- ---------------------------- - --- ---------------------------- --- Table structure for pay_cash_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_cash_payment`; -CREATE TABLE `pay_cash_payment` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '支付id', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务id', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '用户ID', - `amount` decimal(19, 2) NULL DEFAULT NULL COMMENT '金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款金额', - `pay_status` int(11) NULL DEFAULT NULL COMMENT '支付状态', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '现金交易记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_cash_payment --- ---------------------------- - --- ---------------------------- --- Table structure for pay_pay_notify_record --- ---------------------------- -DROP TABLE IF EXISTS `pay_pay_notify_record`; -CREATE TABLE `pay_pay_notify_record` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '支付号', - `notify_info` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '通知消息', - `pay_channel` int(11) NOT NULL COMMENT '支付通道', - `status` int(2) NOT NULL COMMENT '处理状态', - `msg` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '提示信息', - `notify_time` datetime(6) NULL DEFAULT NULL COMMENT '回调时间', - `creator` bigint(20) NULL DEFAULT NULL, - `create_time` datetime(6) NULL DEFAULT NULL, - `last_modifier` bigint(20) NULL DEFAULT NULL, - `last_modified_time` datetime(6) NULL DEFAULT NULL, - `version` int(11) NOT NULL, - `deleted` bit(1) NOT NULL, - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '支付回调记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_pay_notify_record --- ---------------------------- - --- ---------------------------- --- Table structure for pay_pay_order_log --- ---------------------------- -DROP TABLE IF EXISTS `pay_pay_order_log`; -CREATE TABLE `pay_pay_order_log` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '支付id', - `business_pay_param` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '订单扩展业务参数', - `pay_order_param` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '订单参数', - `creator` bigint(20) NULL DEFAULT NULL, - `create_time` datetime(6) NULL DEFAULT NULL, - `last_modifier` bigint(20) NULL DEFAULT NULL, - `last_modified_time` datetime(6) NULL DEFAULT NULL, - `version` int(11) NOT NULL, - `deleted` bit(1) NOT NULL, - `tid` bigint(20) NOT NULL, - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '支付关联订单信息' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_pay_order_log --- ---------------------------- - --- ---------------------------- --- Table structure for pay_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_payment`; -CREATE TABLE `pay_payment` ( - `id` bigint(20) NOT NULL, - `user_id` bigint(20) NOT NULL COMMENT '用户id', - `business_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '业务id', - `title` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '标题', - `description` varchar(240) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '描述', - `amount` decimal(19, 2) NOT NULL COMMENT '金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款余额', - `pay_status` int(11) NOT NULL COMMENT '支付状态', - `error_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '错误码', - `error_msg` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '错误信息', - `pay_type_info` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '支付信息', - `async_pay_mode` bit(1) NOT NULL COMMENT '是否是异步支付', - `async_pay_channel` int(11) NULL DEFAULT NULL COMMENT '异步支付方式', - `pay_channel_info` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付通道信息列表', - `refundable_info` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '可退款信息', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `expired_time` datetime(6) NULL DEFAULT NULL COMMENT '过期时间', - `client_ip` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '客户ip', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE, - UNIQUE INDEX `uniq_business_id`(`business_id`) USING BTREE COMMENT '业务编号id, 唯一ID' -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '支付记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_payment --- ---------------------------- - --- ---------------------------- --- Table structure for pay_refund_record --- ---------------------------- -DROP TABLE IF EXISTS `pay_refund_record`; -CREATE TABLE `pay_refund_record` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '支付记录id', - `business_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '关联业务id', - `refund_request_no` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '异步方式关联退款请求号', - `user_id` bigint(20) NOT NULL COMMENT '用户id', - `title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '标题', - `amount` decimal(19, 2) NOT NULL COMMENT '金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '剩余可退款金额', - `refundable_info` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '可退款信息', - `refund_status` int(2) NULL DEFAULT NULL COMMENT '退款状态', - `refund_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `client_ip` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '客户ip', - `error_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '错误码', - `error_msg` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '错误信息', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '退款记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_refund_record --- ---------------------------- - --- ---------------------------- --- Table structure for pay_voucher --- ---------------------------- -DROP TABLE IF EXISTS `pay_voucher`; -CREATE TABLE `pay_voucher` ( - `id` bigint(20) NOT NULL, - `card_no` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '卡号', - `batch_no` bigint(20) NULL DEFAULT NULL COMMENT '批次号', - `face_value` decimal(15, 2) NULL DEFAULT NULL COMMENT '面值', - `balance` decimal(15, 2) NULL DEFAULT NULL COMMENT '余额', - `enduring` bit(1) NOT NULL COMMENT '是否长期有效', - `start_time` datetime(0) NULL DEFAULT NULL COMMENT '开始时间', - `end_time` datetime(0) NULL DEFAULT NULL COMMENT '结束时间', - `status` int(2) NOT NULL COMMENT '状态', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '储值卡' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_voucher --- ---------------------------- - --- ---------------------------- --- Table structure for pay_voucher_log --- ---------------------------- -DROP TABLE IF EXISTS `pay_voucher_log`; -CREATE TABLE `pay_voucher_log` ( - `id` bigint(20) NOT NULL, - `voucher_id` bigint(20) NOT NULL, - `voucher_no` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, - `amount` decimal(19, 2) NULL DEFAULT NULL, - `type` int(5) NOT NULL COMMENT '类型', - `payment_id` bigint(20) NULL DEFAULT NULL COMMENT '交易记录ID', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务ID', - `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '储值卡日志' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_voucher_log --- ---------------------------- - --- ---------------------------- --- Table structure for pay_voucher_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_voucher_payment`; -CREATE TABLE `pay_voucher_payment` ( - `id` bigint(20) NOT NULL, - `voucher_ids` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '储值卡id列表', - `payment_id` bigint(20) NOT NULL COMMENT '支付id', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务id', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '用户ID', - `amount` decimal(19, 2) NULL DEFAULT NULL COMMENT '金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款金额', - `pay_status` int(11) NULL DEFAULT NULL COMMENT '支付状态', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '储值卡支付记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_voucher_payment --- ---------------------------- - --- ---------------------------- --- Table structure for pay_wallet --- ---------------------------- -DROP TABLE IF EXISTS `pay_wallet`; -CREATE TABLE `pay_wallet` ( - `id` bigint(20) NOT NULL, - `user_id` bigint(20) NOT NULL COMMENT '关联用户id', - `balance` decimal(19, 2) NOT NULL COMMENT '余额', - `status` int(11) NOT NULL COMMENT '状态', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE, - INDEX `pk_user_id`(`user_id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '钱包' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_wallet --- ---------------------------- -INSERT INTO `pay_wallet` VALUES (1336489524259352576, 1399985191002447872, 999982.96, 1, NULL, '2022-03-11 21:37:33', 1399985191002447872, '2022-05-03 21:24:04', 29, 0); -INSERT INTO `pay_wallet` VALUES (1502554238582968320, 1414143554414059520, 1019.00, 1, 1399985191002447872, '2022-03-12 15:57:01', 1399985191002447872, '2022-03-13 11:21:10', 2, 0); -INSERT INTO `pay_wallet` VALUES (1502848353136791552, 1435894470432456704, 100.00, 1, 1399985191002447872, '2022-03-13 11:25:44', 1399985191002447872, '2022-03-24 13:22:37', 1, 0); - --- ---------------------------- --- Table structure for pay_wallet_log --- ---------------------------- -DROP TABLE IF EXISTS `pay_wallet_log`; -CREATE TABLE `pay_wallet_log` ( - `id` bigint(20) NOT NULL, - `wallet_id` bigint(20) NOT NULL COMMENT '钱包id', - `user_id` bigint(20) NOT NULL COMMENT '用户id', - `type` int(11) NOT NULL COMMENT '类型', - `payment_id` bigint(20) NULL DEFAULT NULL COMMENT '交易记录ID', - `client_ip` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '操作终端ip', - `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务ID', - `operation_source` int(11) NOT NULL COMMENT '操作源', - `amount` decimal(19, 2) NULL DEFAULT NULL COMMENT '金额', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '钱包日志' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_wallet_log --- ---------------------------- - --- ---------------------------- --- Table structure for pay_wallet_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_wallet_payment`; -CREATE TABLE `pay_wallet_payment` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '交易记录ID', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务id', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '用户ID', - `wallet_id` bigint(20) NULL DEFAULT NULL COMMENT '钱包ID', - `amount` decimal(19, 2) NULL DEFAULT NULL COMMENT '交易金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款金额', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `pay_status` int(11) NOT NULL COMMENT '支付状态', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '钱包交易记录表' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_wallet_payment --- ---------------------------- - --- ---------------------------- --- Table structure for pay_wechat_pay_config --- ---------------------------- -DROP TABLE IF EXISTS `pay_wechat_pay_config`; -CREATE TABLE `pay_wechat_pay_config` ( - `id` bigint(20) NOT NULL COMMENT '主键', - `name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '名称', - `app_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '微信应用AppId', - `mch_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商户号', - `api_version` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '服务商应用编号', - `api_key_v2` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商户平台「API安全」中的 APIv2 密钥', - `api_key_v3` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商户平台「API安全」中的 APIv3 密钥', - `app_secret` varchar(150) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT 'APPID对应的接口密码,用于获取接口调用凭证access_token时使用', - `p12` bigint(20) NULL DEFAULT NULL COMMENT 'p12的文件id', - `cert_pem` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'API 证书中的 cert.pem', - `key_pem` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT 'API 证书中的 key.pem', - `domain` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '应用域名,回调中会使用此参数', - `notify_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '服务器异步通知页面路径', - `return_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '页面跳转同步通知页面路径', - `pay_ways` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支持的支付类型', - `sandbox` bit(1) NOT NULL COMMENT '是否沙箱环境', - `expire_time` int(10) NOT NULL COMMENT '超时配置', - `activity` bit(1) NOT NULL COMMENT '是否启用', - `state` int(11) NULL DEFAULT NULL COMMENT '状态', - `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '微信支付配置' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_wechat_pay_config --- ---------------------------- - --- ---------------------------- --- Table structure for pay_wechat_payment --- ---------------------------- -DROP TABLE IF EXISTS `pay_wechat_payment`; -CREATE TABLE `pay_wechat_payment` ( - `id` bigint(20) NOT NULL, - `payment_id` bigint(20) NOT NULL COMMENT '交易记录ID', - `pay_status` int(11) NOT NULL COMMENT '支付状态', - `user_id` bigint(20) NULL DEFAULT NULL COMMENT '用户ID', - `trade_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '微信交易号', - `amount` decimal(19, 2) NOT NULL COMMENT '交易金额', - `refundable_balance` decimal(19, 2) NULL DEFAULT NULL COMMENT '可退款金额', - `business_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '业务id', - `pay_time` datetime(6) NULL DEFAULT NULL COMMENT '支付时间', - `creator` bigint(20) NULL DEFAULT NULL COMMENT '创建人', - `create_time` datetime(0) NULL DEFAULT NULL COMMENT '创建时间', - `last_modifier` bigint(20) NULL DEFAULT NULL COMMENT '最后修改人', - `last_modified_time` datetime(0) NULL DEFAULT NULL COMMENT '最后修改时间', - `version` int(11) NOT NULL COMMENT '版本', - `deleted` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0:未删除。1:已删除', - PRIMARY KEY (`id`) USING BTREE -) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '微信支付记录' ROW_FORMAT = DYNAMIC; - --- ---------------------------- --- Records of pay_wechat_payment --- ---------------------------- -- ---------------------------- -- Table structure for qrtz_blob_triggers @@ -5698,6 +5147,10 @@ CREATE TABLE `starter_file_upload_info` ( PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '上传文件信息' ROW_FORMAT = DYNAMIC; +-- ---------------------------- +-- Records of starter_file_upload_info +-- ---------------------------- + -- ---------------------------- -- Table structure for starter_quartz_job -- ---------------------------- diff --git a/_doc/ChangeLog.md b/_doc/ChangeLog.md index c0b53e64029997476b2896bcb360457550b491c2..36aa8b954578b8bced6e58ccad7545415cbd56db 100644 --- a/_doc/ChangeLog.md +++ b/_doc/ChangeLog.md @@ -1,5 +1,18 @@ # CHANGELOG - +## [v1.3.1] 一号线-园博园 +- 新增: 代码生成器支持多数据源 +- 新增: 多数据源增加启动时自动加载配置 +- 优化: 可视化大屏同步GoVIew最新版本 +- 优化: 数据版本记录插件解析失败SQL时的报错提示 +- 优化: 调整减少部分传递依赖 +- 优化: 代码生成器模板更新 +- fix: 工具类构建树时子孙元素排序未生效 +- fix: 超级查询字段获取失败问题 +- fix: maven-javadoc-plugin升级到3.5.0版本, 避免macos下出现报错 +- fix: mongo相关service条件注入处理,避免在无Mongo依赖的情况下无法启动 +- fix: 记录ip对应地址时偶发的空指针处理 +- fix: 用户分配数据权限有误 +- fix: 系统参数配置值字段缺少 ## [v1.3.0] 一号线-园博园 **项目主要更新** - 重构: 拆分支付模块为`dax-pay`子项目 diff --git a/_doc/Task.md b/_doc/Task.md deleted file mode 100644 index 71bb1fac8dc9b652a9c65869d72feeb3277df937..0000000000000000000000000000000000000000 --- a/_doc/Task.md +++ /dev/null @@ -1 +0,0 @@ -[ ] diff --git a/bootx-common-core/pom.xml b/bootx-common-core/pom.xml index 36d12932c83730a17cdfe899ac76f39e96b0a8f2..95059d544203967e811ded55b139a1506ad36fc6 100644 --- a/bootx-common-core/pom.xml +++ b/bootx-common-core/pom.xml @@ -5,7 +5,7 @@ cn.bootx.platform bootx-platform-parent - 1.3.0 + 1.3.1 4.0.0 diff --git a/bootx-common-core/src/main/java/cn/bootx/platform/common/core/util/TreeBuildUtil.java b/bootx-common-core/src/main/java/cn/bootx/platform/common/core/util/TreeBuildUtil.java index 3f85cd3bb0d06e4a16788d6938f35114356e6db6..d93c06a87baa89b4662bebd49061f1343d345af2 100644 --- a/bootx-common-core/src/main/java/cn/bootx/platform/common/core/util/TreeBuildUtil.java +++ b/bootx-common-core/src/main/java/cn/bootx/platform/common/core/util/TreeBuildUtil.java @@ -48,7 +48,7 @@ public class TreeBuildUtil { return null; } for (T region : children) { - List childrenList = build(list, getId.apply(region), getId, getPid, setChildren); + List childrenList = build(list, getId.apply(region), getId, getPid, setChildren,comparator); setChildren.accept(region, childrenList); } // 排序 diff --git a/bootx-common-starters/common-starter-audit-log/pom.xml b/bootx-common-starters/common-starter-audit-log/pom.xml index 9420b6f1bcf7af4f8e1ba43b612a5e931c4aa81f..5397f6ea2da630059f66ab007ca2032817720db8 100644 --- a/bootx-common-starters/common-starter-audit-log/pom.xml +++ b/bootx-common-starters/common-starter-audit-log/pom.xml @@ -5,7 +5,7 @@ bootx-common-starters cn.bootx.platform - 1.3.0 + 1.3.1 4.0.0 diff --git a/bootx-common-starters/common-starter-audit-log/src/main/java/cn/bootx/platform/starter/audit/log/ip2region/IpToRegionService.java b/bootx-common-starters/common-starter-audit-log/src/main/java/cn/bootx/platform/starter/audit/log/ip2region/IpToRegionService.java index 9cc5416d38f411161da939019d3da95ae799fcc6..66e0d1a07f69cf4001509e3d3520e570fb0c1da3 100644 --- a/bootx-common-starters/common-starter-audit-log/src/main/java/cn/bootx/platform/starter/audit/log/ip2region/IpToRegionService.java +++ b/bootx-common-starters/common-starter-audit-log/src/main/java/cn/bootx/platform/starter/audit/log/ip2region/IpToRegionService.java @@ -80,7 +80,8 @@ public class IpToRegionService { // 判断IP是否合法 Matcher matcher = PatternPool.IPV4.matcher(ip); if (!matcher.matches()) { - throw new BizException("IP非法"); + log.warn("非法IPv4地址: {}",ip); + return null; } // 根据类型获取 Searcher 对象 @@ -101,6 +102,7 @@ public class IpToRegionService { } // 无法进行查询 if (Objects.isNull(searcher)){ + log.warn(""); return null; } @@ -130,7 +132,7 @@ public class IpToRegionService { IpRegion region = this.getRegionByIp(ip); // 未查询到 if (Objects.isNull(region)){ - location = "未知"; + return "未知"; } // 中国 港澳台 if (region.isBigChina()){ diff --git a/bootx-common-starters/common-starter-auth/pom.xml b/bootx-common-starters/common-starter-auth/pom.xml index ee0987b19e424c99a6316fcc0de46810530d4c2f..09b1ebad61b95024659a3100680e7168efd81c69 100644 --- a/bootx-common-starters/common-starter-auth/pom.xml +++ b/bootx-common-starters/common-starter-auth/pom.xml @@ -5,7 +5,7 @@ cn.bootx.platform bootx-common-starters - 1.3.0 + 1.3.1 4.0.0 common-starter-auth diff --git a/bootx-common-starters/common-starter-code-gen/pom.xml b/bootx-common-starters/common-starter-code-gen/pom.xml index 45307869281defb0603e6dfc8ac10641970ec2a2..e1769a16d0ab12dbc16f8ea83dcbef2243af60ac 100644 --- a/bootx-common-starters/common-starter-code-gen/pom.xml +++ b/bootx-common-starters/common-starter-code-gen/pom.xml @@ -5,7 +5,7 @@ cn.bootx.platform bootx-common-starters - 1.3.0 + 1.3.1 4.0.0 diff --git a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/CodeGeneratorController.java b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/CodeGeneratorController.java index 5128e98bbe677e97a51839512c364b849e6be851..007db3f73c08572c6677c2c88428f0506b808601 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/CodeGeneratorController.java +++ b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/CodeGeneratorController.java @@ -1,6 +1,5 @@ package cn.bootx.platform.starter.code.gen.controller; -import cn.bootx.platform.common.core.function.SystemKeyValueService; import cn.bootx.platform.common.core.rest.Res; import cn.bootx.platform.common.core.rest.ResResult; import cn.bootx.platform.starter.code.gen.dto.CodeGenPreview; @@ -31,8 +30,6 @@ public class CodeGeneratorController { private final CodeGeneratorService generatorService; - private final SystemKeyValueService systemKeyValueService; - @Operation(summary = "预览生成代码") @PostMapping("/codeGenPreview") public ResResult> codeGenPreview(@RequestBody CodeGenParam param) { diff --git a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/DatabaseTableController.java b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/DatabaseTableController.java index c1b31fce64362072f12eae017e7f6a43adb49d0d..6efe27c9641aec5f7aa4aae8d8349087a3d903a2 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/DatabaseTableController.java +++ b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/controller/DatabaseTableController.java @@ -1,5 +1,6 @@ package cn.bootx.platform.starter.code.gen.controller; +import cn.bootx.platform.common.core.rest.PageResult; import cn.bootx.platform.common.core.rest.Res; import cn.bootx.platform.common.core.rest.ResResult; import cn.bootx.platform.common.core.rest.param.PageParam; @@ -38,9 +39,11 @@ public class DatabaseTableController { @Operation(summary = "表列表分页") @GetMapping("/page") - public ResResult> page(@ParameterObject PageParam pageParam, - @ParameterObject DatabaseTable param) { - return Res.ok(databaseTableService.page(pageParam, param)); + public ResResult> page(@ParameterObject PageParam pageParam, + @ParameterObject DatabaseTable param, + @ParameterObject String dataSourceCode) + { + return Res.ok(databaseTableService.page(pageParam, param,dataSourceCode)); } @Operation(summary = "获取表信息") @@ -57,8 +60,8 @@ public class DatabaseTableController { @Operation(summary = "获取表相关的代码生成参数信息") @GetMapping("/getTableGenParam") - public ResResult getTableGenParam(String tableName) { - return Res.ok(databaseTableService.getTableGenParam(tableName)); + public ResResult getTableGenParam(String dataSourceCode, String tableName) { + return Res.ok(databaseTableService.getTableGenParam(dataSourceCode,tableName)); } } diff --git a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/param/CodeGenParam.java b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/param/CodeGenParam.java index 04d30480b82317144024051048993eb8bb094a27..0111ce0cbca3a79ad4f4f20952de00a74949d03b 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/param/CodeGenParam.java +++ b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/param/CodeGenParam.java @@ -15,6 +15,9 @@ import lombok.experimental.Accessors; @Schema(title = "代码生成参数") public class CodeGenParam { + @Schema(description = "数据库源") + private String dataSourceCode; + @Schema(description = "表名") private String tableName; diff --git a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/CodeGeneratorService.java b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/CodeGeneratorService.java index f8a3110572033e62c3149484bc5d447fcd2e4380..dfb9e3c8ac236b57f36920671768296a84913198 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/CodeGeneratorService.java +++ b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/CodeGeneratorService.java @@ -15,6 +15,8 @@ import cn.hutool.core.io.IoUtil; import cn.hutool.core.text.NamingCase; import cn.hutool.core.util.CharsetUtil; import cn.hutool.core.util.StrUtil; +import com.baomidou.dynamic.datasource.annotation.DS; +import com.baomidou.dynamic.datasource.toolkit.DynamicDataSourceContextHolder; import lombok.RequiredArgsConstructor; import lombok.SneakyThrows; import lombok.extern.slf4j.Slf4j; @@ -135,6 +137,7 @@ public class CodeGeneratorService { * 生成代码文件压缩包 */ @SneakyThrows + @DS("#codeGenParam.getDataSourceCode()") public ResponseEntity genCodeZip(CodeGenParam codeGenParam) { ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); ZipOutputStream zip = new ZipOutputStream(outputStream); diff --git a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/DatabaseTableService.java b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/DatabaseTableService.java index 67e405739f0aa03b204825837b01039cba1d93fe..562ae2b126b0561f9a375ce653b032b3543cdf63 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/DatabaseTableService.java +++ b/bootx-common-starters/common-starter-code-gen/src/main/java/cn/bootx/platform/starter/code/gen/service/DatabaseTableService.java @@ -1,6 +1,7 @@ package cn.bootx.platform.starter.code.gen.service; import cn.bootx.platform.common.core.exception.DataNotExistException; +import cn.bootx.platform.common.core.rest.PageResult; import cn.bootx.platform.common.core.rest.param.PageParam; import cn.bootx.platform.common.mybatisplus.util.MpUtil; import cn.bootx.platform.starter.code.gen.dao.DatabaseTableMapper; @@ -9,6 +10,8 @@ import cn.bootx.platform.starter.code.gen.entity.DatabaseColumn; import cn.bootx.platform.starter.code.gen.entity.DatabaseTable; import cn.bootx.platform.starter.code.gen.util.CodeGenUtil; import cn.hutool.core.util.StrUtil; +import com.baomidou.dynamic.datasource.annotation.DS; +import com.baomidou.dynamic.datasource.toolkit.DynamicDataSourceContextHolder; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import lombok.RequiredArgsConstructor; @@ -16,6 +19,7 @@ import lombok.extern.slf4j.Slf4j; import lombok.val; import org.springframework.stereotype.Service; +import javax.sql.DataSource; import java.util.List; /** @@ -30,6 +34,7 @@ import java.util.List; public class DatabaseTableService { private final DatabaseTableMapper databaseTableMapper; + private final DataSource bigScreen; /** * 查询全部 @@ -42,7 +47,8 @@ public class DatabaseTableService { /** * 分页 */ - public Page page(PageParam pageParam, DatabaseTable param) { + @DS("#dataSourceName") + public PageResult page(PageParam pageParam, DatabaseTable param, String dataSourceName) { val mpPage = MpUtil.getMpPage(pageParam, DatabaseTable.class); QueryWrapper wrapper = new QueryWrapper<>(); @@ -50,7 +56,8 @@ public class DatabaseTableService { .like(StrUtil.isNotBlank(param.getTableComment()), DatabaseTable.Fields.tableComment, param.getTableComment()) .orderByDesc(DatabaseTable.Fields.createTime, DatabaseTable.Fields.tableName); - return databaseTableMapper.page(mpPage, wrapper); + + return MpUtil.convert2PageResult(databaseTableMapper.page(mpPage, wrapper)) ; } /** @@ -70,7 +77,8 @@ public class DatabaseTableService { /** * 获取表相关的代码生成参数信息 */ - public TableGenParamDto getTableGenParam(String tableName) { + @DS("#dataSourceCode") + public TableGenParamDto getTableGenParam(String dataSourceCode, String tableName) { DatabaseTable databaseTable = this.findByTableName(tableName); String entityName = CodeGenUtil.tableToJava(databaseTable.getTableName()); return new TableGenParamDto().setEntityName(entityName).setModule(entityName.toLowerCase()); diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/dto.java.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/dto.java.vm index 6440e3bc7dbaf837a795ad76d43c1633b1a3a20f..95c4a8f548a11f2b64b8cb46678539a85640a210 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/dto.java.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/dto.java.vm @@ -1,5 +1,9 @@ package ${dtoPack}; +import java.math.BigDecimal; +import java.time.LocalDateTime; +import java.time.LocalDate; + import cn.bootx.platform.common.core.rest.dto.BaseDto; import io.swagger.v3.oas.annotations.media.Schema; import lombok.Data; diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/entity.java.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/entity.java.vm index d05ef1ff3775b369f68d9c75e7c4ab13ad293f6c..dccc5fb7b9006f20cf93cf0a492436ac69045ea7 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/entity.java.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/entity.java.vm @@ -1,6 +1,13 @@ package ${corePack}.entity; - ${baseClass}; +import java.math.BigDecimal; +import java.time.LocalDateTime; +import java.time.LocalDate; +import java.time.LocalTime; + +import cn.bootx.platform.common.core.function.EntityBaseFunction; +import cn.bootx.platform.common.mybatisplus.base.${baseClass}; + import com.baomidou.mybatisplus.annotation.TableName; import ${dtoPack}.${entityUpName}Dto; import ${paramPack}.${entityUpName}Param; diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/manager.java.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/manager.java.vm index 59bb001d145243d22c7ffc4be4647e483097f21c..bc113790cb9dafd5f8a49f245e4fdbc2b84e1c84 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/manager.java.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/manager.java.vm @@ -1,11 +1,13 @@ package ${corePack}.dao; -import cn.bootx.platform.common.mybatisplus.impl.BaseManager; import ${paramPack}.${entityUpName}Param; import ${corePack}.entity.${entityUpName}; +import cn.bootx.platform.common.mybatisplus.impl.BaseManager; import cn.bootx.platform.common.core.rest.param.PageParam; import cn.bootx.platform.common.mybatisplus.base.MpIdEntity; import cn.bootx.platform.common.mybatisplus.util.MpUtil; +import cn.bootx.platform.common.query.generator.QueryGenerator; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import lombok.RequiredArgsConstructor; @@ -25,9 +27,9 @@ public class ${entityUpName}Manager extends BaseManager<${entityUpName}Mapper, $ */ public Page<${entityUpName}> page(PageParam pageParam, ${entityUpName}Param param) { Page<${entityUpName}> mpPage = MpUtil.getMpPage(pageParam, ${entityUpName}.class); - return this.lambdaQuery() - .select(this.getEntityClass(),MpUtil::excludeBigField) - .orderByDesc(MpIdEntity::getId) - .page(mpPage); + QueryWrapper<${entityUpName}> wrapper = QueryGenerator.generator(param, this.getEntityClass()); + wrapper.select(this.getEntityClass(),MpUtil::excludeBigField) + .orderByDesc(MpUtil.getColumnName(${entityUpName}::getId)); + return this.page(mpPage,wrapper); } } diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/param.java.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/param.java.vm index 370556415c687c0003fcfb398451b5aa39128a53..3317c54a62301abc87b518f97f5a2c977f0b5877 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/param.java.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/param.java.vm @@ -26,4 +26,4 @@ public class ${entityUpName}Param { private $column.javaType $column.name; #end -} \ No newline at end of file +} diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/service.java.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/service.java.vm index 2788ee082d9f5211b605cc2713f4678e06547d71..dca787572be2409423b1324ae08744baf9396960 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/service.java.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/java/service.java.vm @@ -12,6 +12,8 @@ import ${corePack}.entity.${entityUpName}; import ${corePack}.dao.${entityUpName}Manager; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; +import cn.hutool.core.bean.BeanUtil; +import cn.hutool.core.bean.copier.CopyOptions; import java.util.List; diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/edit.vue.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/edit.vue.vm index 833f003ac985bbb10d9410a56d5eb373fc8ad6b2..a97b146b0d4e7a3f211bb56b720ad739944ddc23 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/edit.vue.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/edit.vue.vm @@ -33,7 +33,7 @@ :label-col="labelCol" :wrapper-col="wrapperCol" > - + #foreach ($column in $columns) @@ -98,13 +98,19 @@ const rules = reactive({} as Record) // 事件 const emits = defineEmits(['ok']) - // 入口 + + /** + * 入口 + */ function init(id, editType: FormEditType) { initFormEditType(editType) resetForm() getInfo(id, editType) } - // 获取信息 + + /** + * 获取信息 + */ function getInfo(id, editType: FormEditType) { if ([FormEditType.Edit, FormEditType.Show].includes(editType)) { confirmLoading.value = true @@ -116,7 +122,10 @@ confirmLoading.value = false } } - // 保存 + + /** + * 保存 + */ function handleOk() { formRef?.validate().then(async () => { confirmLoading.value = true @@ -131,7 +140,9 @@ }) } - // 重置表单 + /** + * 重置表单 + */ function resetForm() { nextTick(() => { formRef?.resetFields() diff --git a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/list.vue.vm b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/list.vue.vm index adfcfdb9cf78343264ac37920ff2647365551da6..9edcc2a4806a5b67c58281e84dd2b0c7cf6fdf02 100644 --- a/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/list.vue.vm +++ b/bootx-common-starters/common-starter-code-gen/src/main/resources/codegen/template/vue3/list.vue.vm @@ -4,7 +4,7 @@
- +