13 Commits

Author SHA1 Message Date
166be502a5 Merge remote-tracking branch 'origin/main' 2026-02-05 11:53:37 +08:00
463f58b69e feat:
1. prod
2026-02-05 11:53:26 +08:00
lzqadmin
b4a3443c4c 用户族谱 , 福利包 , 商城 2026-02-05 10:41:44 +08:00
80826ea6dc feat:
1. prod
2026-02-05 10:18:05 +08:00
6299928120 feat:
1. prod
2026-02-05 04:05:40 +08:00
cb6b757c38 feat:
1. prod
2026-02-04 23:41:53 +08:00
dd20dd53eb feat:
1. add APPUserController
2026-02-04 23:34:15 +08:00
149857442d feat:
1. add APPUserController
2026-02-04 22:06:25 +08:00
89d95daa2e feat:
1. add AppRegisterTokenGranter
2026-02-04 21:03:29 +08:00
f77da89aaa remove 2026-02-04 18:26:36 +08:00
80f670065e remove 2026-02-04 17:02:57 +08:00
c95046c600 remove 2026-02-04 16:57:36 +08:00
7d48faca11 remove 2026-02-04 00:53:07 +08:00
668 changed files with 1308 additions and 109907 deletions

View File

@@ -1,6 +0,0 @@
BLADE_PROFILES_ACTIVE=test
BLADE_OAUTH2_PUBLIC_KEY=国密公钥需自行填写
BLADE_OAUTH2_PRIVATE_KEY=国密私钥需自行填写
BLADE_TOKEN_SIGN_KEY=令牌密钥需自行填写
HOST_IP=宿主机IP需自行填写
MYSQL_ROOT_PASSWORD=MYSQL的ROOT密码需自行填写

View File

@@ -1,6 +0,0 @@
## 一键部署流程
1. 将开发完毕的数据库脚本放入`database`目录下,重命名为`init.sql`, 提前修改好`admin`的密码。
2. 将`.env`文件内所需的内容填充完整,注意`publicKey`需要与前端配置保持一致。
3. 将前端工程配置好`publicKey`后打包,将打包后的文件放入`nginx/html`目录下。
4. 生产环境需采用`prod`模式启动,将会强制校验弱密码,未修改`admin`密码将会无法登陆。
5. 执行`docker compose up -d`命令启动容器即可。

File diff suppressed because one or more lines are too long

View File

@@ -1,114 +0,0 @@
# 定义网络配置
networks:
blade_net:
driver: bridge # 使用 bridge 驱动,创建一个桥接网络
ipam: # IP 地址管理配置
config:
- subnet: 172.30.0.0/16 # 定义子网,IP 范围从 172.30.0.0 到 172.30.255.255
# 定义服务配置
services:
# BladeX 后端 服务,提供BladeX平台业务功能
blade-api:
image: blade/blade-api:4.8.0.RELEASE
container_name: blade-api
restart: unless-stopped
environment:
# OAuth2 公钥,用于身份验证
- BLADE_OAUTH2_PUBLIC_KEY=${BLADE_OAUTH2_PUBLIC_KEY}
# OAuth2 私钥,用于验签解码
- BLADE_OAUTH2_PRIVATE_KEY=${BLADE_OAUTH2_PRIVATE_KEY}
# BladeX 密钥,用于Token签名
- BLADE_TOKEN_SIGN_KEY=${BLADE_TOKEN_SIGN_KEY}
# 时区设置
- TZ=Asia/Shanghai
ports:
- 8000:80 # 映射 80 端口到主机的 8000 端口
command:
- --spring.profiles.active=${BLADE_PROFILES_ACTIVE} # 设置系统启动模式
- --social.domain=http://${HOST_IP}:2888 # 设置第三方登录跳转域名
depends_on:
- blade-db # 依赖数据库
- blade-oss # 依赖对象存储
networks:
blade_net:
ipv4_address: 172.30.0.80
# MySQL 数据库服务
blade-db:
image: mysql:8.3.0
container_name: blade-db
restart: unless-stopped
security_opt:
- seccomp:unconfined # 禁用 seccomp 安全配置,允许更多操作
environment:
- TZ=Asia/Shanghai # 时区设置
- MYSQL_CHARSET=utf8mb4 # 设置字符集为 utf8mb4
- MYSQL_COLLATION=utf8mb4_unicode_ci # 设置排序规则为 utf8mb4_unicode_ci
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD} # 数据库 root 密码
- MYSQL_USER=bladexadmin
- MYSQL_PASSWORD=bladexadmin
- MYSQL_DATABASE=bladex_boot
ports:
- 13306:3306 # 映射 MySQL 服务端口
volumes:
- ./data/mysql:/var/lib/mysql # 持久化 MySQL 数据
- ./database/init.sql:/docker-entrypoint-initdb.d/init.sql # 挂载 SQL 初始化脚本
command: --lower_case_table_names=1 # 添加忽略大小写配置
networks:
blade_net:
ipv4_address: 172.30.0.33
# Redis 服务,用于缓存
blade-redis:
image: redis:7.2.5
container_name: blade-redis
environment:
- TZ=Asia/Shanghai # 时区设置
ports:
- 16379:6379 # 映射 Redis 默认端口
command: redis-server --appendonly yes --requirepass bladexadmin # 配置密码和持久化
privileged: true
restart: always
volumes:
- ./data/redis/data:/data # 持久化 Redis 数据
networks:
blade_net:
ipv4_address: 172.30.0.63
# MinIO 对象存储服务
blade-oss:
image: minio/minio:RELEASE.2021-04-22T15-44-28Z.hotfix.56647434e
container_name: blade-oss
restart: unless-stopped
security_opt:
- seccomp:unconfined
environment:
- TZ=Asia/Shanghai # 时区设置
- MINIO_ACCESS_KEY=bladexadmin # 存储访问密钥
- MINIO_SECRET_KEY=bladexadmin # 存储密钥
ports:
- 9000:9000 # 映射 MinIO 服务端口
command: server /data --address '0.0.0.0:9000' # 启动 MinIO
volumes:
- ./data/minio/data:/data # 持久化数据
networks:
blade_net:
ipv4_address: 172.30.0.90
# Nginx 服务,用于反向代理和负载均衡
blade-nginx:
image: nginx:stable-alpine-perl
container_name: blade-nginx
environment:
- TZ=Asia/Shanghai # 时区设置
ports:
- 2888:2888 # 映射端口
volumes:
- ./nginx/html:/usr/share/nginx/html # 持久化 Nginx 网页数据
- ./nginx/nginx.conf:/etc/nginx/nginx.conf # 持久化 Nginx 配置
privileged: true
restart: always
networks:
blade_net:
ipv4_address: 172.30.0.18

View File

@@ -1,46 +0,0 @@
<!DOCTYPE html>
<html lang='en'>
<head>
<meta charset='UTF-8' />
<meta http-equiv='Content-Type' content='text/html; charset=utf-8'>
<meta http-equiv='X-UA-Compatible' content='IE=edge'>
<meta http-equiv='X-UA-Compatible' content='chrome=1' />
<meta name='renderer' content='webkit'>
<meta name='viewport' content='width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0'>
<meta name='apple-mobile-web-app-capable' content='yes'>
<meta name='apple-mobile-web-app-status-bar-style' content='black'>
<meta name='format-detection' content='telephone=no'>
<link rel='icon' href='/favicon.png' />
<link rel='stylesheet' href='/iconfont/index.css'>
<link rel='stylesheet' href='/iconfont/avue/iconfont.css'>
<link rel='stylesheet' href='/iconfont/saber/iconfont.css'>
<link rel='stylesheet' href='/iconfont/common/iconfont.css'>
<link rel='stylesheet' href='/css/loading.css'>
<link rel='stylesheet' href='/css/saber.css'>
<title>BladeX微服务开发平台</title>
<script type="module" crossorigin src="/assets/index-DpW_RhWM.js"></script>
<link rel="modulepreload" crossorigin href="/assets/element-plus-BIeOjcXi.js">
<link rel="modulepreload" crossorigin href="/assets/@smallwei/avue-vR-k9VHw.js">
<link rel="stylesheet" crossorigin href="/assets/index-BsjWj5lr.css">
</head>
<body>
<div id='app'>
<div id='loader-wrapper'>
<div class='loader-box'>
<span>BladeX</span>
<span>微</span>
<span>服</span>
<span>务</span>
<span>开</span>
<span>发</span>
<span>平</span>
<span>台</span>
</div>
<div class='loader-title'>系统加载中</div>
</div>
</div>
</body>
</html>

View File

@@ -1,77 +0,0 @@
user root;
worker_processes 1;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
#tcp_nopush on;
keepalive_timeout 65;
#gzip on;
#include /etc/nginx/conf.d/*.conf;
upstream gateway {
server blade-api;
}
server {
listen 2888;
server_name web;
root /usr/share/nginx/html;
gzip on;
gzip_min_length 1k;
gzip_buffers 4 16k;
gzip_http_version 1.1;
gzip_comp_level 2;
gzip_types text/plain application/javascript application/x-javascript text/javascript text/css application/xml;
gzip_vary on;
gzip_proxied expired no-cache no-store private auth;
gzip_disable "MSIE [1-6]\.";
location /{
index index.html;
error_page 404 /index.html;
}
location ~ ^/(api/)?actuator {
return 403;
}
location ^~ /oauth/redirect {
try_files $uri /index.html;
}
location ^~ /api/ {
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_buffering off;
rewrite ^/api/(.*)$ /$1 break;
proxy_pass http://gateway/;
}
}
}

View File

@@ -1,27 +0,0 @@
## 一、调整内存:max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144](elasticsearch用户拥有的内存权限太小,至少需要262144)
#### 1.修改配置sysctl.conf
[root@localhost ~]# vi /etc/sysctl.conf
#### 2.添加下面配置:
vm.max_map_count=262144
#### 3.重新加载:
[root@localhost ~]# sysctl -p
#### 4.最后重新启动elasticsearch,即可启动成功。
## 二、Docker 命令自动补全
#### 1.安装依赖工具bash-complete
[root@localhost ~]# yum install -y bash-completion
[root@localhost ~]# source /usr/share/bash-completion/completions/docker
[root@localhost ~]# source /usr/share/bash-completion/bash_completion
## 三、将本文件夹内的文件拷贝至服务器
#### 1.对sh脚本赋予执行权限
#### 2.执行 ./deploy.sh
#### 3.等待服务启动完毕即可
#### 4.卸载执行 ./undeploy.sh

View File

@@ -1,88 +0,0 @@
#./bin/bash
# 定义颜色
BLUE_COLOR="\033[36m"
RED_COLOR="\033[31m"
GREEN_COLOR="\033[32m"
VIOLET_COLOR="\033[35m"
RES="\033[0m"
echo -e "${BLUE_COLOR}# ######################################################################${RES}"
echo -e "${BLUE_COLOR}# Docker ELK Deploy Script #${RES}"
echo -e "${BLUE_COLOR}# ######################################################################${RES}"
# 创建目录
echo -e "${BLUE_COLOR}---> create [elasticsearch]directory start.${RES}"
if [ ! -d "./elasticsearch/" ]; then
mkdir -p ./elasticsearch/master/conf ./elasticsearch/master/data ./elasticsearch/master/logs \
./elasticsearch/slave1/conf ./elasticsearch/slave1/data ./elasticsearch/slave1/logs \
./elasticsearch/slave2/conf ./elasticsearch/slave2/data ./elasticsearch/slave2/logs
fi
echo -e "${RED_COLOR}---> create [kibana]directory start.${RES}"
if [ ! -d "./kibana/" ]; then
mkdir -p ./kibana/conf ./kibana/logs
fi
echo -e "${GREEN_COLOR}---> create [logstash]directory start.${RES}"
if [ ! -d "./logstash/" ]; then
mkdir -p ./logstash/conf ./logstash/logs
fi
echo -e "${GREEN_COLOR}---> create [filebeat]directory start.${RES}"
if [ ! -d "./filebeat/" ]; then
mkdir -p ./filebeat/conf ./filebeat/logs ./filebeat/data
fi
echo -e "${VIOLET_COLOR}---> create [nginx]directory start.${RES}"
if [ ! -d "./nginx/" ]; then
mkdir -p ./nginx/conf ./nginx/logs ./nginx/www
fi
echo -e "${BLUE_COLOR}===> create directory success.${RES}"
# 目录授权(data/logs 都要授读/写权限)
echo -e "${BLUE_COLOR}---> directory authorize start.${RES}"
if [ -d "./elasticsearch/" ]; then
chmod 777 ./elasticsearch/master/data/ ./elasticsearch/master/logs/ \
./elasticsearch/slave1/data/ ./elasticsearch/slave1/logs/ \
./elasticsearch/slave2/data/ ./elasticsearch/slave2/logs
fi
if [ -d "./filebeat/" ]; then
chmod 777 ./filebeat/data/ ./filebeat/logs/
fi
echo -e "${BLUE_COLOR}===> directory authorize success.${RES}"
# 移动配置文件
echo -e "${BLUE_COLOR}---> move [elasticsearch]config file start.${RES}"
if [ -f "./es-master.yml" ] && [ -f "./es-slave1.yml" ] && [ -f "./es-slave2.yml" ]; then
mv ./es-master.yml ./elasticsearch/master/conf
mv ./es-slave1.yml ./elasticsearch/slave1/conf
mv ./es-slave2.yml ./elasticsearch/slave2/conf
fi
echo -e "${RED_COLOR}---> move [kibana]config file start.${RES}"
if [ -f "./kibana.yml" ]; then
mv ./kibana.yml ./kibana/conf
fi
echo -e "${GREEN_COLOR}---> move [logstash]config file start.${RES}"
if [ -f "./logstash.yml" ] && [ -f "./logstash-filebeat.conf" ]; then
mv ./logstash-filebeat.conf ./logstash/conf
mv ./logstash.yml ./logstash/conf
fi
echo -e "${GREEN_COLOR}---> move [filebeat]config file start.${RES}"
if [ -f "./filebeat.yml" ]; then
mv ./filebeat.yml ./filebeat/conf
fi
echo -e "${VIOLET_COLOR}---> move [nginx]config file start.${RES}"
if [ -f "./nginx.conf" ]; then
mv ./nginx.conf ./nginx/conf
fi
echo -e "${BLUE_COLOR}===> move config files success.${RES}"
echo -e "${GREEN_COLOR}>>>>>>>>>>>>>>>>>> The End <<<<<<<<<<<<<<<<<<${RES}"
# 部署项目
echo -e "${BLUE_COLOR}==================> Docker deploy Start <==================${RES}"
docker-compose up --build -d

View File

@@ -1,115 +0,0 @@
version: "3"
services:
es-master:
container_name: es-master
hostname: es-master
image: elasticsearch:7.1.1
restart: always
ports:
- 9200:9200
- 9300:9300
volumes:
- ./elasticsearch/master/conf/es-master.yml:/usr/share/elasticsearch/config/elasticsearch.yml
- ./elasticsearch/master/data:/usr/share/elasticsearch/data
- ./elasticsearch/master/logs:/usr/share/elasticsearch/logs
environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
es-slave1:
container_name: es-slave1
image: elasticsearch:7.1.1
restart: always
ports:
- 9201:9200
- 9301:9300
volumes:
- ./elasticsearch/slave1/conf/es-slave1.yml:/usr/share/elasticsearch/config/elasticsearch.yml
- ./elasticsearch/slave1/data:/usr/share/elasticsearch/data
- ./elasticsearch/slave1/logs:/usr/share/elasticsearch/logs
environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
es-slave2:
container_name: es-slave2
image: elasticsearch:7.1.1
restart: always
ports:
- 9202:9200
- 9302:9300
volumes:
- ./elasticsearch/slave2/conf/es-slave2.yml:/usr/share/elasticsearch/config/elasticsearch.yml
- ./elasticsearch/slave2/data:/usr/share/elasticsearch/data
- ./elasticsearch/slave2/logs:/usr/share/elasticsearch/logs
environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
es-head:
container_name: es-head
image: mobz/elasticsearch-head:5
restart: always
ports:
- 9100:9100
depends_on:
- es-master
- es-slave1
- es-slave2
kibana:
container_name: kibana
hostname: kibana
image: kibana:7.1.1
restart: always
ports:
- 5601:5601
volumes:
- ./kibana/conf/kibana.yml:/usr/share/kibana/config/kibana.yml
environment:
- elasticsearch.hosts=http://es-master:9200
depends_on:
- es-master
- es-slave1
- es-slave2
filebeat:
# 容器名称
container_name: filebeat
# 主机名称
hostname: filebeat
# 镜像
image: docker.elastic.co/beats/filebeat:7.1.1
# 重启机制
restart: always
# 持久化挂载
volumes:
- ./filebeat/conf/filebeat.yml:/usr/share/filebeat/filebeat.yml
# 映射到容器中[作为数据源]
- ./logs:/home/project/elk/logs
- ./filebeat/logs:/usr/share/filebeat/logs
- ./filebeat/data:/usr/share/filebeat/data
# 将指定容器连接到当前连接,可以设置别名,避免ip方式导致的容器重启动态改变的无法连接情况
links:
- logstash
ports:
- 9000:9000
# 依赖服务[可无]
depends_on:
- es-master
- es-slave1
- es-slave2
logstash:
container_name: logstash
hostname: logstash
image: logstash:7.1.1
command: logstash -f ./conf/logstash-filebeat.conf
restart: always
volumes:
# 映射到容器中
- ./logstash/conf/logstash-filebeat.conf:/usr/share/logstash/conf/logstash-filebeat.conf
- ./logstash/conf/logstash.yml:/usr/share/logstash/config/logstash.yml
ports:
- 5044:5044
depends_on:
- es-master
- es-slave1
- es-slave2

View File

@@ -1,28 +0,0 @@
# 集群名称
cluster.name: es-cluster
# 节点名称
node.name: es-master
# 是否可以成为master节点
node.master: true
# 是否允许该节点存储数据,默认开启
node.data: false
# 网络绑定
network.host: 0.0.0.0
# 设置对外服务的http端口
http.port: 9200
# 设置节点间交互的tcp端口
transport.port: 9300
# 集群发现
discovery.seed_hosts:
- es-master
- es-slave1
- es-slave2
# 手动指定可以成为 mater 的所有节点的 name 或者 ip,这些配置将会在第一次选举中进行计算
cluster.initial_master_nodes:
- es-master
# 支持跨域访问
http.cors.enabled: true
http.cors.allow-origin: "*"
# 安全认证
xpack.security.enabled: false
#http.cors.allow-headers: "Authorization"

View File

@@ -1,28 +0,0 @@
# 集群名称
cluster.name: es-cluster
# 节点名称
node.name: es-slave1
# 是否可以成为master节点
node.master: true
# 是否允许该节点存储数据,默认开启
node.data: true
# 网络绑定
network.host: 0.0.0.0
# 设置对外服务的http端口
http.port: 9201
# 设置节点间交互的tcp端口
#transport.port: 9301
# 集群发现
discovery.seed_hosts:
- es-master
- es-slave1
- es-slave2
# 手动指定可以成为 mater 的所有节点的 name 或者 ip,这些配置将会在第一次选举中进行计算
cluster.initial_master_nodes:
- es-master
# 支持跨域访问
http.cors.enabled: true
http.cors.allow-origin: "*"
# 安全认证
xpack.security.enabled: false
#http.cors.allow-headers: "Authorization"

View File

@@ -1,28 +0,0 @@
# 集群名称
cluster.name: es-cluster
# 节点名称
node.name: es-slave2
# 是否可以成为master节点
node.master: true
# 是否允许该节点存储数据,默认开启
node.data: true
# 网络绑定
network.host: 0.0.0.0
# 设置对外服务的http端口
http.port: 9202
# 设置节点间交互的tcp端口
#transport.port: 9302
# 集群发现
discovery.seed_hosts:
- es-master
- es-slave1
- es-slave2
# 手动指定可以成为 mater 的所有节点的 name 或者 ip,这些配置将会在第一次选举中进行计算
cluster.initial_master_nodes:
- es-master
# 支持跨域访问
http.cors.enabled: true
http.cors.allow-origin: "*"
# 安全认证
xpack.security.enabled: false
#http.cors.allow-headers: "Authorization"

View File

@@ -1,37 +0,0 @@
filebeat.inputs:
- type: log
enabled: true
paths:
# 当前目录下的所有.log文件
- /home/project/elk/logs/*.log
multiline.pattern: ^\[
multiline.negate: true
multiline.match: after
- type: tcp
enabled: true
max_message_size: 10MiB
host: "0.0.0.0:9000"
filebeat.config.modules:
path: ${path.config}/modules.d/*.yml
reload.enabled: false
setup.template.settings:
index.number_of_shards: 1
setup.dashboards.enabled: false
setup.kibana:
host: "http://kibana:5601"
# 不直接传输至ES
#output.elasticsearch:
# hosts: ["http://es-master:9200"]
# index: "filebeat-%{[beat.version]}-%{+yyyy.MM.dd}"
output.logstash:
hosts: ["logstash:5044"]
processors:
- add_host_metadata: ~
- add_cloud_metadata: ~

View File

@@ -1,8 +0,0 @@
# 服务端口
server.port: 5601
# 服务IP
server.host: "0.0.0.0"
# ES
elasticsearch.hosts: ["http://es-master:9200"]
# 汉化
i18n.locale: "zh-CN"

View File

@@ -1,23 +0,0 @@
input {
# 来源beats
beats {
# 端口
port => "5044"
}
}
# 分析、过滤插件,可以多个
filter {
grok {
match => { "message" => "%{COMBINEDAPACHELOG}"}
}
geoip {
source => "clientip"
}
}
output {
# 选择elasticsearch
elasticsearch {
hosts => ["http://es-master:9200"]
index => "%{[@metadata][beat]}-%{[@metadata][version]}-%{+YYYY.MM.dd}"
}
}

View File

@@ -1,8 +0,0 @@
# 服务IP
http.host: "0.0.0.0"
# ES
xpack.monitoring.elasticsearch.hosts: [ "http://es-master:9200" ]
xpack.monitoring.enabled: true
xpack.management.enabled: false

View File

@@ -1,16 +0,0 @@
#./bin/bash
# 定义颜色
BLUE_COLOR="\033[36m"
RED_COLOR="\033[31m"
GREEN_COLOR="\033[32m"
VIOLET_COLOR="\033[35m"
RES="\033[0m"
echo -e "${BLUE_COLOR}# ######################################################################${RES}"
echo -e "${BLUE_COLOR}# Docker ELK UnDeploy Script #${RES}"
echo -e "${BLUE_COLOR}# ######################################################################${RES}"
# 部署项目
echo -e "${BLUE_COLOR}==================> Docker UnDeploy Start <==================${RES}"
docker-compose stop
docker-compose rm

View File

@@ -0,0 +1,182 @@
create table user_genealogy
(
id int8 not null primary key,
name varchar(128),
phone int8,
level integer default 1, --当前层数
pid int8,
p_name varchar(128),
p_phone int8,
root_id int8, --遍历当前树
group_id int8, --树内最近团队长的id
genealogy_list int8[], -- 往上所有父级
user_child_number int, --用户下线总人数
user_direct_number int, --用户直推总人数
user_direct_list int8[], --直推列表
is_revoked int4 default 0, --是否注销 0-否 1-是
register_date timestamp(6), -- 注册时间
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
CREATE INDEX user_genealogy_list_gin_idx
ON user_genealogy USING gin (genealogy_list);
CREATE INDEX user_direct_list_gin_idx
ON user_genealogy USING gin (user_direct_list);
create index user_genealogy_phone_index
on user_genealogy (is_deleted, phone , is_revoked);
create index user_genealogy_register_date_index
on user_genealogy (is_deleted, register_date);
comment on table user_genealogy is '用户族谱表';
comment on column user_genealogy.id is '主键';
comment on column user_genealogy.pid is '上级id';
comment on column user_genealogy.name is '用户名';
comment on column user_genealogy.phone is '手机号';
comment on column user_genealogy.p_name is '上级用户名';
comment on column user_genealogy.p_phone is '上级用户手机号';
comment on column user_genealogy.level is '层级';
comment on column user_genealogy.root_id is '根节点id';
comment on column user_genealogy.group_id is '团队长id';
comment on column user_genealogy.genealogy_list is '族谱列表';
comment on column user_genealogy.user_child_number is '用户下线总人数';
comment on column user_genealogy.user_direct_number is '用户直推总人数';
comment on column user_genealogy.user_direct_list is '直推列表';
comment on column user_genealogy.is_revoked is '是否注销 0-否 1-是';
comment on column user_genealogy.register_date is '注册时间';
comment on column user_genealogy.create_user is '创建人';
comment on column user_genealogy.create_dept is '创建部门';
comment on column user_genealogy.create_time is '创建时间';
comment on column user_genealogy.update_user is '修改人';
comment on column user_genealogy.update_time is '修改时间';
comment on column user_genealogy.status is '状态';
comment on column user_genealogy.is_deleted is '是否已删除';
alter table user_genealogy
owner to postgres;
create table user_tree
(
id int8 not null primary key,
name varchar(128),
phone int8,
level int4 default 1,
pid int8,
p_name varchar(128),
p_phone int8,
p_level int4 default 1,
is_revoked int4 default 0, --是否注销 0-否 1-是
is_sync_genealogy int4 default 0, --是否同步族谱 0-否 1-是
register_date timestamp(6), -- 注册时间
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index user_tree_phone_index
on user_tree (is_deleted, phone);
create index user_tree_sync_genealogy_index
on user_tree (is_deleted, is_sync_genealogy);
create index user_tree_register_date_index
on user_tree (is_deleted, register_date);
comment on table user_tree is '用户树结构表';
comment on column user_tree.id is '主键';
comment on column user_tree.pid is '上级id';
comment on column user_tree.name is '用户名';
comment on column user_tree.phone is '手机号';
comment on column user_tree.level is '层级';
comment on column user_tree.p_name is '上级用户名';
comment on column user_tree.p_phone is '上级用户手机号';
comment on column user_tree.p_level is '上级用户层级';
comment on column user_tree.is_revoked is '是否注销 0-否 1-是';
comment on column user_tree.is_sync_genealogy is '是否同步族谱 0-否 1-是';
comment on column user_tree.register_date is '注册时间';
comment on column user_tree.create_user is '创建人';
comment on column user_tree.create_dept is '创建部门';
comment on column user_tree.create_time is '创建时间';
comment on column user_tree.update_user is '修改人';
comment on column user_tree.update_time is '修改时间';
comment on column user_tree.status is '状态';
comment on column user_tree.is_deleted is '是否已删除';
alter table user_tree
owner to postgres;
create table user_increase_day
(
id int8 not null primary key,
name varchar(128),
phone int8,
current_level_id int4, --用户当前等级
current_level_name varchar(12), --用户当前等级
pid int8,
p_name varchar(128),
p_phone int8,
p_level int4 default 1,
is_real int4 default 0, -- 是否实名用户 0-否 1-是
real_date timestamp(6), -- 实名时间
real_name varchar(128), -- 实名姓名
real_id_card varchar(128), -- 实名身份证
is_revoked int4 default 0, --是否注销 0-否 1-是
register_date timestamp(6), -- 注册时间
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index user_increase_day_phone_index
on user_increase_day (is_deleted, phone);
create index uid_register_date_index
on user_increase_day (is_deleted, register_date);
comment on table user_increase_day is '用户增加天数表';
comment on column user_increase_day.id is '主键';
comment on column user_increase_day.current_level_id is '用户当前等级';
comment on column user_increase_day.current_level_name is '用户当前等级';
comment on column user_increase_day.name is '用户名';
comment on column user_increase_day.p_name is '上级用户名';
comment on column user_increase_day.p_phone is '上级用户手机号';
comment on column user_increase_day.p_level is '上级用户层级';
comment on column user_increase_day.is_real is '是否实名用户 0-否 1-是';
comment on column user_increase_day.real_date is '实名时间';
comment on column user_increase_day.real_name is '实名姓名';
comment on column user_increase_day.real_id_card is '实名身份证';
comment on column user_increase_day.register_date is '注册时间';
comment on column user_increase_day.is_revoked is '是否注销 0-否 1-是';
comment on column user_increase_day.register_date is '注册时间';
comment on column user_increase_day.create_user is '创建人';
comment on column user_increase_day.create_dept is '创建部门';
comment on column user_increase_day.create_time is '创建时间';
comment on column user_increase_day.update_user is '修改人';
comment on column user_increase_day.update_time is '修改时间';
comment on column user_increase_day.status is '状态';
comment on column user_increase_day.is_deleted is '是否已删除';
alter table user_increase_day
owner to postgres;

View File

@@ -0,0 +1,342 @@
CREATE TABLE package_info
(
id int8 NOT NULL PRIMARY KEY,
name VARCHAR(128) NULL,
buy_qty int4 default 0, -- 最大购买数量
day_total int4 default 0, -- 产出总天数
amount_total decimal(14, 2) default 0, -- 总产出福利积分
give_amount decimal(14, 2) default 0, -- 购买赠与福利值
bonus decimal(16, 4) default 0, -- 激活比率
user_benefit decimal(14, 2) default 0, --兑换包需要的福利积分
user_cash decimal(14, 2) default 0, --兑换包需要的现金券
is_need_benefit int4 DEFAULT 0, --是否需要福利积分
is_need_cash int4 DEFAULT 0, --是否需要现金券
max_exchange_qty int4 default 0, -- 全网最大兑换数量
exchanged_qty int4 default 0, -- 已兑换数量
version int4 default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
COMMENT ON TABLE package_info IS '积分包信息表';
COMMENT ON COLUMN package_info.id IS '主键';
COMMENT ON COLUMN package_info.name IS '积分包名称';
COMMENT ON COLUMN package_info.buy_qty IS '最大购买数量';
COMMENT ON COLUMN package_info.day_total IS '产出总天数';
COMMENT ON COLUMN package_info.amount_total IS '总产出福利积分';
COMMENT ON COLUMN package_info.give_amount IS '购买赠与福利值';
COMMENT ON COLUMN package_info.bonus IS '激活比率';
COMMENT ON COLUMN package_info.user_benefit IS '兑换包需要的福利积分';
COMMENT ON COLUMN package_info.user_cash IS '兑换包需要的现金券';
COMMENT ON COLUMN package_info.is_need_benefit IS '是否需要福利积分 0-否 1-是';
COMMENT ON COLUMN package_info.is_need_cash IS '是否需要现金券 0-否 1-是';
COMMENT ON COLUMN package_info.max_exchange_qty IS '全网最大兑换数量';
COMMENT ON COLUMN package_info.exchanged_qty IS '已兑换数量';
comment on column package_info.create_user is '创建人';
comment on column package_info.create_dept is '创建部门';
comment on column package_info.create_time is '创建时间';
comment on column package_info.update_user is '修改人';
comment on column package_info.update_time is '修改时间';
comment on column package_info.status is '状态';
comment on column package_info.is_deleted is '是否已删除';
alter table package_info
owner to postgres;
create table give_pack_log
(
id int8 not null primary key,
statistical_date timestamp(6),
user_id int8,
phone int8,
user_name varchar(128),
package_id int8,
package_name varchar(128),
package_detail text,
give_number int4 default 1,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index gpl_date_index
on give_pack_log (is_deleted, statistical_date ,user_id);
COMMENT ON TABLE give_pack_log IS '划拨积分记录';
COMMENT ON COLUMN give_pack_log.id IS '主键';
COMMENT ON COLUMN give_pack_log.statistical_date IS '统计日期';
COMMENT ON COLUMN give_pack_log.user_id IS '用户id';
COMMENT ON COLUMN give_pack_log.phone IS '用户手机号';
COMMENT ON COLUMN give_pack_log.user_name IS '用户名';
COMMENT ON COLUMN give_pack_log.package_id IS '积分包id';
COMMENT ON COLUMN give_pack_log.package_name IS '积分包名称';
COMMENT ON COLUMN give_pack_log.package_detail IS '积分包信息快照';
COMMENT ON COLUMN give_pack_log.give_number IS '赠送数量';
COMMENT ON COLUMN give_pack_log.remark IS '备注';
comment on column give_pack_log.create_user is '创建人';
comment on column give_pack_log.create_dept is '创建部门';
comment on column give_pack_log.create_time is '创建时间';
comment on column give_pack_log.update_user is '修改人';
comment on column give_pack_log.update_time is '修改时间';
comment on column give_pack_log.status is '状态';
comment on column give_pack_log.is_deleted is '是否已删除';
alter table give_pack_log
owner to postgres;
create table user_package_info
(
id int8 not null primary key,
statistical_date timestamp(6),
user_id int8,
phone int8,
user_name varchar(128),
package_id int8,
package_name varchar(128),
type int4 default 1, -- 1-积分兑换 2-后台划拨
user_benefit decimal(14, 2) default 0, --兑换包需要的福利积分
user_cash decimal(14, 2) default 0, --兑换包需要的现金券
give_amount decimal(14, 2) default 0, -- 购买赠与福利值
day_total int4 default 0, -- 产出总天数
amount_total decimal(14, 2) default 0, -- 总产出福利积分
amount_day decimal(14, 2) default 0, -- 每日产出福利积分 = 总产出 / 总产出
amount_out decimal(16, 4) default 0, -- 已产出福利积分
out_day int4 default 0, -- 已产出天数
is_complete integer default 0, -- 是否完成 0未完成 1完成
expired_date timestamp(6),
is_expired int4 default 0,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index upi_complete_index
on user_package_info (is_deleted, user_id , is_complete , is_expired);
create index upi_date_index
on user_package_info (is_deleted, statistical_date ,user_id);
create index upi_expired_index
on user_package_info (is_deleted, expired_date ,is_expired);
COMMENT ON TABLE user_package_info IS '用户积分包信息表';
COMMENT ON COLUMN user_package_info.id IS '主键';
COMMENT ON COLUMN user_package_info.user_id IS '用户id';
COMMENT ON COLUMN user_package_info.phone IS '用户手机号';
COMMENT ON COLUMN user_package_info.user_name IS '用户名';
COMMENT ON COLUMN user_package_info.package_id IS '积分包id';
COMMENT ON COLUMN user_package_info.package_name IS '积分包名称';
COMMENT ON COLUMN user_package_info.type IS '1-积分兑换 2-后台划拨';
COMMENT ON COLUMN user_package_info.user_benefit IS '兑换包需要的福利积分';
COMMENT ON COLUMN user_package_info.user_cash IS '兑换包需要的现金券';
COMMENT ON COLUMN user_package_info.give_amount IS '购买赠与福利值';
COMMENT ON COLUMN user_package_info.day_total IS '产出总天数';
COMMENT ON COLUMN user_package_info.amount_total IS '总产出福利积分';
COMMENT ON COLUMN user_package_info.amount_day IS '每日产出福利积分';
COMMENT ON COLUMN user_package_info.amount_out IS '已产出福利积分';
COMMENT ON COLUMN user_package_info.out_day IS '已产出天数';
COMMENT ON COLUMN user_package_info.is_complete IS '是否完成 0-未完成 1-完成';
COMMENT ON COLUMN user_package_info.expired_date IS '过期时间';
COMMENT ON COLUMN user_package_info.is_expired IS '是否过期 0-未过期 1-已过期';
COMMENT ON COLUMN user_package_info.remark IS '备注';
comment on column user_package_info.create_user is '创建人';
comment on column user_package_info.create_dept is '创建部门';
comment on column user_package_info.create_time is '创建时间';
comment on column user_package_info.update_user is '修改人';
comment on column user_package_info.update_time is '修改时间';
comment on column user_package_info.status is '状态';
comment on column user_package_info.is_deleted is '是否已删除';
alter table user_package_info
owner to postgres;
create table user_package_info_copy
(
id int8 not null primary key,
statistical_date timestamp(6),
user_id int8,
phone int8,
user_name varchar(128),
user_package_info_Id int8, --user_package_info id
package_id int8,
package_name varchar(128),
type int4 default 1, -- 1-积分兑换 2-后台划拨
user_benefit decimal(14, 2) default 0, --兑换包需要的福利积分
user_cash decimal(14, 2) default 0, --兑换包需要的现金券
give_amount decimal(14, 2) default 0, -- 购买赠与福利值
day_total int4 default 0, -- 产出总天数
amount_total decimal(14, 2) default 0, -- 总产出福利积分
amount_day decimal(14, 2) default 0, -- 每日产出福利积分 = 总产出 / 总产出
amount_out decimal(16, 4) default 0, -- 已产出多少福利积分
remaining_amount decimal(16, 4) default 0, -- 剩余可产出福利积分 (总计 - 已经经历多少天 * 每天产出 - 加速积分)
accelerated_amount decimal(16, 4) default 0, -- 已加速多少福利积分
parent_id int8, -- 给到谁10%积分,到用户id
parent_amount decimal(16, 4) default 0, -- 给到谁10%积分,到积分账户(福利积分)
out_day integer default 0, -- 产出天数 当前包已经产出天数
experience_day integer default 0, -- 当前包已经经历的天数
not_sign_list int8[], -- 未签到日期详情 (数组)
is_complete int4 default 0, -- 是否完成 0未完成 1完成
active_time timestamp(6), -- 当前包激活时间
start_time timestamp(6), -- 当前包生效时间
sign_bitmap int8 default 0, -- 位图将包的签到时间360天二进制转成十进制
expired_date timestamp(6),
is_expired int4 default 0,
version int4 default 1,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index upi_copy_complete_index
on user_package_info_copy (is_deleted, is_complete , is_expired ,user_id );
create index upi_copy_date_index
on user_package_info_copy (is_deleted, statistical_date ,user_id);
create index upi_copy_expired_index
on user_package_info_copy (is_deleted, expired_date ,is_expired);
COMMENT ON TABLE user_package_info_copy IS '用户积分包信息-副本表';
COMMENT ON COLUMN user_package_info_copy.id IS '主键';
COMMENT ON COLUMN user_package_info_copy.user_id IS '用户id';
COMMENT ON COLUMN user_package_info_copy.phone IS '用户手机号';
COMMENT ON COLUMN user_package_info_copy.user_name IS '用户名';
COMMENT ON COLUMN user_package_info_copy.user_package_info_Id IS '用户积分包id';
COMMENT ON COLUMN user_package_info_copy.package_id IS '积分包id';
COMMENT ON COLUMN user_package_info_copy.package_name IS '积分包名称';
COMMENT ON COLUMN user_package_info_copy.type IS '1-积分兑换 2-后台划拨';
COMMENT ON COLUMN user_package_info_copy.user_benefit IS '兑换包需要的福利积分';
COMMENT ON COLUMN user_package_info_copy.user_cash IS '兑换包需要的现金券';
COMMENT ON COLUMN user_package_info_copy.give_amount IS '购买赠与福利值';
COMMENT ON COLUMN user_package_info_copy.day_total IS '产出总天数';
COMMENT ON COLUMN user_package_info_copy.amount_total IS '总产出福利积分';
COMMENT ON COLUMN user_package_info_copy.amount_day IS '每日产出福利积分';
COMMENT ON COLUMN user_package_info_copy.amount_out IS '已产出福利积分';
COMMENT ON COLUMN user_package_info_copy.remaining_amount IS '剩余可产出福利积分';
COMMENT ON COLUMN user_package_info_copy.accelerated_amount IS '已加速多少福利积分';
COMMENT ON COLUMN user_package_info_copy.parent_id IS '给到谁10%积分,到用户id';
COMMENT ON COLUMN user_package_info_copy.parent_amount IS '给到谁10%积分,到积分账户(福利积分)';
COMMENT ON COLUMN user_package_info_copy.out_day IS '产出天数 当前包已经产出天数';
COMMENT ON COLUMN user_package_info_copy.experience_day IS '当前包已经经历的天数';
COMMENT ON COLUMN user_package_info_copy.not_sign_list IS '未签到日期详情 (数组)';
COMMENT ON COLUMN user_package_info_copy.is_complete IS '是否完成 0-未完成 1-完成';
COMMENT ON COLUMN user_package_info_copy.start_time IS '当前包生效时间';
COMMENT ON COLUMN user_package_info_copy.active_time IS '当前包激活时间';
COMMENT ON COLUMN user_package_info_copy.sign_bitmap IS '位图将包的签到时间360天二进制转成十进制';
COMMENT ON COLUMN user_package_info_copy.expired_date IS '过期时间';
COMMENT ON COLUMN user_package_info_copy.is_expired IS '是否过期 0-未过期 1-已过期';
COMMENT ON COLUMN user_package_info_copy.version IS '版本号';
COMMENT ON COLUMN user_package_info_copy.remark IS '备注';
COMMENT ON COLUMN user_package_info_copy.create_user IS '创建人';
COMMENT ON COLUMN user_package_info_copy.create_dept IS '创建部门';
COMMENT ON COLUMN user_package_info_copy.create_time IS '创建时间';
COMMENT ON COLUMN user_package_info_copy.update_user IS '修改人';
COMMENT ON COLUMN user_package_info_copy.update_time IS '修改时间';
COMMENT ON COLUMN user_package_info_copy.status IS '状态';
COMMENT ON COLUMN user_package_info_copy.is_deleted IS '是否已删除';
create table user_benefit
(
id int8 not null primary key,
amount decimal(14, 2) default 0,
version int4 default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
comment on table user_benefit is '用户福利值表';
comment on column user_benefit.id is '主键';
comment on column user_benefit.amount is '金额';
comment on column user_benefit.version is '版本号';
comment on column user_benefit.create_user is '创建人';
comment on column user_benefit.create_dept is '创建部门';
comment on column user_benefit.create_time is '创建时间';
comment on column user_benefit.update_user is '修改人';
comment on column user_benefit.update_time is '修改时间';
comment on column user_benefit.status is '状态';
comment on column user_benefit.is_deleted is '是否已删除';
alter table user_benefit
owner to postgres;
create table user_benefit_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
user_pack_id int8,
source_detail text,
order_id int8,
type int4 default 1,
statistical_date timestamp(6),
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status int4 default 1,
is_deleted int4 default 0
);
create index ub_log_date_index
on user_benefit_log (is_deleted, user_id , statistical_date , type);
comment on table user_benefit_log is '用户福利值流水表';
comment on column user_benefit_log.id is '主键';
comment on column user_benefit_log.user_id is '用户id';
comment on column user_benefit_log.user_phone is '用户手机号';
comment on column user_benefit_log.user_name is '用户名称';
comment on column user_benefit_log.amount is '金额';
comment on column user_benefit_log.source_id is '来源id';
comment on column user_benefit_log.user_pack_id is '用户积分包id';
comment on column user_benefit_log.source_detail is '来源详情';
comment on column user_benefit_log.order_id is '订单id';
comment on column user_benefit_log.type is '消费类型 1-收入 2-支出';
comment on column user_benefit_log.statistical_date is '统计时间';
comment on column user_benefit_log.remark is '备注';
comment on column user_benefit_log.create_user is '创建人';
comment on column user_benefit_log.create_dept is '创建部门';
comment on column user_benefit_log.create_time is '创建时间';
comment on column user_benefit_log.update_user is '修改人';
comment on column user_benefit_log.update_time is '修改时间';
comment on column user_benefit_log.status is '状态';
comment on column user_benefit_log.is_deleted is '是否已删除';
alter table user_benefit_log
owner to postgres;

View File

@@ -12,16 +12,16 @@ CREATE TABLE mall_spu
original_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, original_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
retail_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, retail_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
profit DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, profit DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
sales INTEGER DEFAULT 0 NOT NULL, sales int4 DEFAULT 0 NOT NULL,
spu_qty INTEGER DEFAULT 0 NOT NULL, spu_qty int4 DEFAULT 0 NOT NULL,
tags text DEFAULT '' NOT NULL, tags text DEFAULT '' NOT NULL,
status INTEGER DEFAULT 0 NULL, status int4 DEFAULT 0 NULL,
create_user int8 NULL, create_user int8 NULL,
create_dept int8 NULL, create_dept int8 NULL,
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );
@@ -53,16 +53,16 @@ COMMENT ON COLUMN mall_spu.is_deleted IS '是否已删除';
CREATE TABLE ys_category CREATE TABLE ys_category
( (
id INTEGER NOT NULL PRIMARY KEY, id int8 NOT NULL PRIMARY KEY,
cname VARCHAR(100) DEFAULT '' NOT NULL, cname VARCHAR(100) DEFAULT '' NOT NULL,
pid int8 DEFAULT 0 NOT NULL, pid int8 DEFAULT 0 NOT NULL,
level INTEGER DEFAULT 0 NOT NULL, level int4 DEFAULT 0 NOT NULL,
is_deleted INTEGER DEFAULT 0 NULL, is_deleted int4 DEFAULT 0 NULL,
create_time TIMESTAMP(6) NULL, create_time TIMESTAMP(6) NULL,
create_user int8 NULL, create_user int8 NULL,
update_time TIMESTAMP(6) NULL, update_time TIMESTAMP(6) NULL,
update_user int8 NULL, update_user int8 NULL,
status INTEGER NULL, status int4 NULL,
create_dept int8 NULL create_dept int8 NULL
); );
@@ -90,7 +90,7 @@ CREATE TABLE mall_cart
user_id int8 DEFAULT 0 NOT NULL, user_id int8 DEFAULT 0 NOT NULL,
title VARCHAR(200) DEFAULT '' NOT NULL, title VARCHAR(200) DEFAULT '' NOT NULL,
spu_id int8 DEFAULT 0 NOT NULL, spu_id int8 DEFAULT 0 NOT NULL,
quantity INTEGER DEFAULT 0 NOT NULL, quantity int4 DEFAULT 0 NOT NULL,
original_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, original_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
main_img VARCHAR(255) DEFAULT '' NOT NULL, main_img VARCHAR(255) DEFAULT '' NOT NULL,
retail_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, retail_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
@@ -99,8 +99,8 @@ CREATE TABLE mall_cart
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
status INTEGER NULL, status int4 NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );
@@ -136,14 +136,14 @@ CREATE TABLE user_address
detail VARCHAR(200) NULL, detail VARCHAR(200) NULL,
consignee VARCHAR(200) NULL, consignee VARCHAR(200) NULL,
phone VARCHAR(200) NULL, phone VARCHAR(200) NULL,
is_default INTEGER NULL, is_default int4 NULL,
create_user int8 NULL, create_user int8 NULL,
create_dept int8 NULL, create_dept int8 NULL,
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
status INTEGER NULL, status int4 NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );

View File

@@ -4,26 +4,26 @@ CREATE TABLE user_order
user_id int8 DEFAULT 0 NOT NULL, user_id int8 DEFAULT 0 NOT NULL,
user_phone int8, user_phone int8,
user_name varchar(128), user_name varchar(128),
order_type INTEGER DEFAULT 0 NOT NULL, order_type int4 DEFAULT 0 NOT NULL,
order_id int8 DEFAULT 0 NOT NULL, order_id int8 DEFAULT 0 NOT NULL,
title VARCHAR(256) DEFAULT '' NOT NULL, title VARCHAR(256) DEFAULT '' NOT NULL,
images VARCHAR(512) NULL, images VARCHAR(512) NULL,
quantity INTEGER NULL, quantity int4 NULL,
description VARCHAR(200) DEFAULT '' NOT NULL, description VARCHAR(200) DEFAULT '' NOT NULL,
order_status INTEGER DEFAULT 0 NOT NULL, order_status int4 DEFAULT 0 NOT NULL,
total_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, total_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
payment_type INTEGER DEFAULT 0 NOT NULL, payment_type int4 DEFAULT 0 NOT NULL,
payment_time TIMESTAMP NULL, payment_time TIMESTAMP NULL,
payment_track VARCHAR(255) DEFAULT '' NOT NULL, payment_track VARCHAR(255) DEFAULT '' NOT NULL,
payment_status INTEGER DEFAULT 1 NOT NULL, payment_status int4 DEFAULT 1 NOT NULL,
create_user int8 NULL, create_user int8 NULL,
create_dept int8 NULL, create_dept int8 NULL,
create_time TIMESTAMP(6) NULL, create_time TIMESTAMP(6) NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP(6) NULL, update_time TIMESTAMP(6) NULL,
status INTEGER NULL, status int4 NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );
COMMENT ON TABLE user_order IS '用户订单'; COMMENT ON TABLE user_order IS '用户订单';
@@ -50,25 +50,6 @@ COMMENT ON COLUMN user_order.create_time IS '创建时间';
COMMENT ON COLUMN user_order.update_user IS '修改人'; COMMENT ON COLUMN user_order.update_user IS '修改人';
COMMENT ON COLUMN user_order.update_time IS '修改时间'; COMMENT ON COLUMN user_order.update_time IS '修改时间';
COMMENT ON COLUMN user_order.status IS '状态'; COMMENT ON COLUMN user_order.status IS '状态';
COMMENT ON COLUMN user_order.update_user IS '修改人';
COMMENT ON COLUMN user_order.update_time IS '修改时间';
COMMENT ON COLUMN user_order.status IS '状态';
COMMENT ON COLUMN user_order.payment_time IS '支付时间';
COMMENT ON COLUMN user_order.payment_track IS '支付凭证编号';
COMMENT ON COLUMN user_order.payment_status IS '支付状态';
COMMENT ON COLUMN user_order.create_user IS '创建人';
COMMENT ON COLUMN user_order.create_dept IS '创建部门';
COMMENT ON COLUMN user_order.create_time IS '创建时间';
COMMENT ON COLUMN user_order.update_user IS '修改人';
COMMENT ON COLUMN user_order.update_time IS '修改时间';
COMMENT ON COLUMN user_order.status IS '状态';
COMMENT ON COLUMN user_order.update_user IS '修改人';
COMMENT ON COLUMN user_order.update_time IS '修改时间';
COMMENT ON COLUMN user_order.status IS '状态';
COMMENT ON COLUMN user_order.update_user IS '修改人';
COMMENT ON COLUMN user_order.update_time IS '修改时间';
COMMENT ON COLUMN user_order.status IS '状态';
COMMENT ON COLUMN user_order.is_deleted IS '是否已删除';
CREATE INDEX user_order_index ON user_order (user_id, order_type); CREATE INDEX user_order_index ON user_order (user_id, order_type);
@@ -92,18 +73,15 @@ CREATE TABLE mall_summary_order
total_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, total_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
refund_amount DECIMAL(10, 2) DEFAULT 0.00 NULL, refund_amount DECIMAL(10, 2) DEFAULT 0.00 NULL,
payment_type INTEGER DEFAULT 0 NOT NULL, payment_type int4 DEFAULT 0 NOT NULL,
extra_type INTEGER DEFAULT 0 NOT NULL, extra_type int4 DEFAULT 0 NOT NULL,
payment_status INTEGER DEFAULT 0 NOT NULL, payment_status int4 DEFAULT 0 NOT NULL,
order_status INTEGER DEFAULT 0 NOT NULL, order_status int4 DEFAULT 0 NOT NULL,
payment_completed_time TIMESTAMP NULL, payment_completed_time TIMESTAMP NULL,
payment_track VARCHAR(200) DEFAULT '' NOT NULL, payment_track VARCHAR(200) DEFAULT '' NOT NULL,
expire_time TIMESTAMP NULL, expire_time TIMESTAMP NULL,
give_token DECIMAL(10, 2) NULL, is_recorded int4 DEFAULT 0 NULL,
actual_give_token DECIMAL(10, 2) NULL, is_statistics int4 DEFAULT 0 NULL,
is_royalty INTEGER DEFAULT 0 NULL,
is_recorded INTEGER DEFAULT 0 NULL,
is_statistics INTEGER DEFAULT 0 NULL,
remarks VARCHAR(200) DEFAULT '' NOT NULL, remarks VARCHAR(200) DEFAULT '' NOT NULL,
version int8 DEFAULT 0 NULL, version int8 DEFAULT 0 NULL,
create_user int8 NULL, create_user int8 NULL,
@@ -111,8 +89,8 @@ CREATE TABLE mall_summary_order
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
status INTEGER DEFAULT 0 NULL, status int4 DEFAULT 0 NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );
@@ -137,16 +115,13 @@ COMMENT ON COLUMN mall_summary_order.payment_type IS '支付类型';
COMMENT ON COLUMN mall_summary_order.extra_type IS '附加支付类型'; COMMENT ON COLUMN mall_summary_order.extra_type IS '附加支付类型';
COMMENT ON COLUMN mall_summary_order.payment_status IS '支付状态'; COMMENT ON COLUMN mall_summary_order.payment_status IS '支付状态';
COMMENT ON COLUMN mall_summary_order.extra_type IS '附加支付类型'; COMMENT ON COLUMN mall_summary_order.extra_type IS '附加支付类型';
COMMENT ON COLUMN mall_summary_order.order_status IS '订单状态 0=失败,1=待确认,2=待发货,3=待收货,4=已完成,5=已取消,6=售后中,7=已完结'; COMMENT ON COLUMN mall_summary_order.order_status IS '订单状态 1=待确认,2=待发货,3=待收货,4=已完成,5=已取消, 6=已关闭 ,7=售后中,8=已完结';
COMMENT ON COLUMN mall_summary_order.payment_completed_time IS '支付完成时间'; COMMENT ON COLUMN mall_summary_order.payment_completed_time IS '支付完成时间';
COMMENT ON COLUMN mall_summary_order.payment_track IS '支付凭证'; COMMENT ON COLUMN mall_summary_order.payment_track IS '支付凭证';
COMMENT ON COLUMN mall_summary_order.order_status IS '订单状态 0=失败,1=待确认,2=待发货,3=待收货,4=已完成,5=已取消,6=售后中,7=已完结'; COMMENT ON COLUMN mall_summary_order.order_status IS '订单状态 1=待确认,2=待发货,3=待收货,4=已完成,5=已取消, 6=已关闭 ,7=售后中,8=已完结';
COMMENT ON COLUMN mall_summary_order.payment_completed_time IS '支付完成时间'; COMMENT ON COLUMN mall_summary_order.payment_completed_time IS '支付完成时间';
COMMENT ON COLUMN mall_summary_order.payment_track IS '支付凭证'; COMMENT ON COLUMN mall_summary_order.payment_track IS '支付凭证';
COMMENT ON COLUMN mall_summary_order.expire_time IS '超时时间'; COMMENT ON COLUMN mall_summary_order.expire_time IS '超时时间';
COMMENT ON COLUMN mall_summary_order.give_token IS '赠送积分';
COMMENT ON COLUMN mall_summary_order.actual_give_token IS '实际赠送扣分';
COMMENT ON COLUMN mall_summary_order.is_royalty IS '是否已经给上级分红 0=否,1=是';
COMMENT ON COLUMN mall_summary_order.is_recorded IS '是否记录资金账户里 0=否,1=是'; COMMENT ON COLUMN mall_summary_order.is_recorded IS '是否记录资金账户里 0=否,1=是';
COMMENT ON COLUMN mall_summary_order.is_statistics IS '是否统计到用户现金业绩里 0=否,1=是'; COMMENT ON COLUMN mall_summary_order.is_statistics IS '是否统计到用户现金业绩里 0=否,1=是';
COMMENT ON COLUMN mall_summary_order.remarks IS '备注'; COMMENT ON COLUMN mall_summary_order.remarks IS '备注';
@@ -169,27 +144,26 @@ CREATE TABLE mall_detail_order
user_name varchar(128), user_name varchar(128),
summary_order_id int8 DEFAULT 0 NOT NULL, summary_order_id int8 DEFAULT 0 NOT NULL,
spu_id int8 DEFAULT 0 NOT NULL, spu_id int8 DEFAULT 0 NOT NULL,
quantity INTEGER DEFAULT 0 NOT NULL, quantity int4 DEFAULT 0 NOT NULL,
sku_snapshot text NULL, sku_snapshot text NULL,
actual_cost_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, actual_cost_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
order_amount DECIMAL(10, 2) NULL, order_amount DECIMAL(10, 2) NULL,
cost_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, cost_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
given_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
remarks VARCHAR(200) DEFAULT '' NOT NULL, remarks VARCHAR(200) DEFAULT '' NOT NULL,
order_status INTEGER DEFAULT 0 NOT NULL, order_status int4 DEFAULT 0 NOT NULL,
freight VARCHAR(200) DEFAULT 0.00 NOT NULL, freight VARCHAR(200) DEFAULT 0.00 NOT NULL,
logistics VARCHAR(200) DEFAULT 0.00 NOT NULL, logistics VARCHAR(200) DEFAULT 0.00 NOT NULL,
delivery_time timestamp(6), delivery_time timestamp(6),
products_info text NULL, products_info text NULL,
version integer DEFAULT 0 NULL, version int4 DEFAULT 0 NULL,
create_user int8 NULL, create_user int8 NULL,
create_dept int8 NULL, create_dept int8 NULL,
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
status INTEGER DEFAULT -1 NULL, status int4 DEFAULT -1 NULL,
is_deleted INTEGER DEFAULT 0 NULL is_deleted int4 DEFAULT 0 NULL
); );
COMMENT ON TABLE mall_detail_order IS '商城详情订单'; COMMENT ON TABLE mall_detail_order IS '商城详情订单';
@@ -206,19 +180,16 @@ COMMENT ON COLUMN mall_detail_order.sku_snapshot IS '商品快照';
COMMENT ON COLUMN mall_detail_order.actual_cost_amount IS '实际成本'; COMMENT ON COLUMN mall_detail_order.actual_cost_amount IS '实际成本';
COMMENT ON COLUMN mall_detail_order.order_amount IS '订单金额'; COMMENT ON COLUMN mall_detail_order.order_amount IS '订单金额';
COMMENT ON COLUMN mall_detail_order.cost_amount IS '订单成本'; COMMENT ON COLUMN mall_detail_order.cost_amount IS '订单成本';
COMMENT ON COLUMN mall_detail_order.cost_amount IS '订单成本';
COMMENT ON COLUMN mall_detail_order.actual_amount IS '实际支付'; COMMENT ON COLUMN mall_detail_order.actual_amount IS '实际支付';
COMMENT ON COLUMN mall_detail_order.given_amount IS '赠送积分';
COMMENT ON COLUMN mall_detail_order.remarks IS '备注'; COMMENT ON COLUMN mall_detail_order.remarks IS '备注';
COMMENT ON COLUMN mall_detail_order.logistics IS '物流'; COMMENT ON COLUMN mall_detail_order.logistics IS '物流';
COMMENT ON COLUMN mall_detail_order.products_info IS '商品信息'; COMMENT ON COLUMN mall_detail_order.products_info IS '商品信息';
COMMENT ON COLUMN mall_detail_order.freight IS '运费'; COMMENT ON COLUMN mall_detail_order.freight IS '运费';
COMMENT ON COLUMN mall_detail_order.order_status IS '订单状态 0=失败,1=待确认,2=待发货,3=待收货,4=已完成,5=已取消,6=售后中,7=已完结'; COMMENT ON COLUMN mall_detail_order.order_status IS '订单状态 1=待确认,2=待发货,3=待收货,4=已完成,5=已取消, 6=已关闭 ,7=售后中,8=已完结';
COMMENT ON COLUMN mall_detail_order.status IS '状态';
COMMENT ON COLUMN mall_detail_order.is_deleted IS '是否已删除';
COMMENT ON COLUMN mall_detail_order.status IS '状态'; COMMENT ON COLUMN mall_detail_order.status IS '状态';
COMMENT ON COLUMN mall_detail_order.is_deleted IS '是否已删除'; COMMENT ON COLUMN mall_detail_order.is_deleted IS '是否已删除';
CREATE INDEX mdo_index ON mall_detail_order (summary_order_id); CREATE INDEX mdo_index ON mall_detail_order (summary_order_id);
CREATE INDEX mdo_uid_index ON mall_detail_order (user_id); CREATE INDEX mdo_uid_index ON mall_detail_order (user_id);
@@ -233,28 +204,26 @@ CREATE TABLE mall_summary_order_after
goods_id int8 DEFAULT -1 NOT NULL, goods_id int8 DEFAULT -1 NOT NULL,
sku_id int8 NOT NULL, sku_id int8 NOT NULL,
goods_name VARCHAR(256) NOT NULL, goods_name VARCHAR(256) NOT NULL,
third_plat_order_no VARCHAR(32) NOT NULL, quantity int4 DEFAULT -1 NULL,
third_plat_after_no VARCHAR(32) NOT NULL, apply_type int4 NULL,
quantity INTEGER DEFAULT -1 NULL,
apply_type INTEGER NULL,
apply_reason VARCHAR(100) DEFAULT '-1' NULL, apply_reason VARCHAR(100) DEFAULT '-1' NULL,
apply_pic_urls TEXT NULL, apply_pic_urls TEXT NULL,
refund_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL, refund_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
refund_status INTEGER DEFAULT 0 NULL, refund_status int4 DEFAULT 0 NULL,
refund_reason VARCHAR(255) NULL, refund_reason VARCHAR(255) NULL,
receiver VARCHAR(125) NULL, receiver VARCHAR(125) NULL,
receiver_phone VARCHAR(255) NULL, receiver_phone VARCHAR(255) NULL,
receiver_addr VARCHAR(255) NULL, receiver_addr VARCHAR(255) NULL,
receiver_delivery_no VARCHAR(255) NULL, receiver_delivery_no VARCHAR(255) NULL,
remarks VARCHAR(200) DEFAULT '' NULL, remarks VARCHAR(200) DEFAULT '' NULL,
version integer DEFAULT 0 NULL, version int4 DEFAULT 0 NULL,
create_user int8 NULL, create_user int8 NULL,
create_dept int8 NULL, create_dept int8 NULL,
create_time TIMESTAMP NULL, create_time TIMESTAMP NULL,
update_user int8 NULL, update_user int8 NULL,
update_time TIMESTAMP NULL, update_time TIMESTAMP NULL,
status INTEGER DEFAULT 0 NULL, status int4 DEFAULT 0 NULL,
is_deleted INTEGER DEFAULT 0 NULL, is_deleted int4 DEFAULT 0 NULL,
after_info JSON NULL after_info JSON NULL
); );
@@ -266,9 +235,7 @@ COMMENT ON COLUMN mall_summary_order_after.user_name IS '用户名称';
COMMENT ON COLUMN mall_summary_order_after.summary_order_id IS '总订单id'; COMMENT ON COLUMN mall_summary_order_after.summary_order_id IS '总订单id';
COMMENT ON COLUMN mall_summary_order_after.goods_id IS '商品ID'; COMMENT ON COLUMN mall_summary_order_after.goods_id IS '商品ID';
COMMENT ON COLUMN mall_summary_order_after.sku_id IS '商品订单号'; COMMENT ON COLUMN mall_summary_order_after.sku_id IS '商品订单号';
COMMENT ON COLUMN mall_summary_order_after.goods_name IS '商品名称'; COMMENT ON COLUMN mall_summary_order_after.goods_name IS '商品名称';;
COMMENT ON COLUMN mall_summary_order_after.third_plat_order_no IS '第三方订单单号';
COMMENT ON COLUMN mall_summary_order_after.third_plat_after_no IS '第三方售后单号';
COMMENT ON COLUMN mall_summary_order_after.quantity IS '商品数量'; COMMENT ON COLUMN mall_summary_order_after.quantity IS '商品数量';
COMMENT ON COLUMN mall_summary_order_after.apply_type IS '申请售后类型,1=未收货退款,2=退货退款,3=换货补发,4=不退货仅退款'; COMMENT ON COLUMN mall_summary_order_after.apply_type IS '申请售后类型,1=未收货退款,2=退货退款,3=换货补发,4=不退货仅退款';
COMMENT ON COLUMN mall_summary_order_after.apply_reason IS '申请售后原因'; COMMENT ON COLUMN mall_summary_order_after.apply_reason IS '申请售后原因';
@@ -285,15 +252,5 @@ COMMENT ON COLUMN mall_summary_order_after.status IS '状态';
COMMENT ON COLUMN mall_summary_order_after.status IS '状态'; COMMENT ON COLUMN mall_summary_order_after.status IS '状态';
COMMENT ON COLUMN mall_summary_order_after.is_deleted IS '是否已删除'; COMMENT ON COLUMN mall_summary_order_after.is_deleted IS '是否已删除';
COMMENT ON COLUMN mall_summary_order_after.after_info IS '售后详情'; COMMENT ON COLUMN mall_summary_order_after.after_info IS '售后详情';
COMMENT ON COLUMN mall_summary_order_after.refund_amount IS '退款金额';
COMMENT ON COLUMN mall_summary_order_after.refund_status IS '处理售后状态';
COMMENT ON COLUMN mall_summary_order_after.refund_reason IS '处理回复';
COMMENT ON COLUMN mall_summary_order_after.receiver IS '退件收货人姓名';
COMMENT ON COLUMN mall_summary_order_after.receiver_phone IS '退件收货人电话';
COMMENT ON COLUMN mall_summary_order_after.receiver_addr IS '退件地址';
COMMENT ON COLUMN mall_summary_order_after.receiver_delivery_no IS '退货物流单号';
COMMENT ON COLUMN mall_summary_order_after.remarks IS '备注';
COMMENT ON COLUMN mall_summary_order_after.status IS '状态';
COMMENT ON COLUMN mall_summary_order_after.is_deleted IS '是否已删除';
COMMENT ON COLUMN mall_summary_order_after.after_info IS '售后详情';
;

View File

@@ -1,46 +0,0 @@
create table aliyun_certify
(
id int8 not null primary key,
user_id int8 not null,
user_phone int8,
name varchar(128) null,
id_card varchar(128) null,
certify_id varchar(64) null,
image text null,
message varchar(255) null,
is_success integer default 0 not null,
is_deleted integer default 0 not null,
create_time timestamp not null,
create_user int8 null,
update_time timestamp null,
update_user int8 null,
create_dept int8 null,
status integer null
);
comment on table aliyun_certify is '阿里云实名记录表';
comment on column aliyun_certify.id is 'ID';
comment on column aliyun_certify.user_id is '用户ID';
comment on column aliyun_certify.user_phone is '用户手机号';
comment on column aliyun_certify.name is '实名用户名';
comment on column aliyun_certify.id_card is '实名身份证';
comment on column aliyun_certify.certify_id is '阿里云实名身份标识';
comment on column aliyun_certify.image is '实名照片';
comment on column aliyun_certify.message is '阿里云认证消息';
comment on column aliyun_certify.is_success is '是否成功';
comment on column aliyun_certify.is_deleted is '是否删除';
comment on column aliyun_certify.create_time is '创建时间';
comment on column aliyun_certify.create_user is '创建人ID';
comment on column aliyun_certify.update_time is '修改时间';
comment on column aliyun_certify.update_user is '修改人ID';
comment on column aliyun_certify.create_dept is '创建部门';
comment on column aliyun_certify.status is '状态';
create index certify_id_index
on aliyun_certify (is_deleted, certify_id);
create index user_certify_id_index
on aliyun_certify (is_deleted, user_id, certify_id);
create index user_id_index
on aliyun_certify (is_deleted, user_id, is_success);

View File

@@ -1,42 +0,0 @@
-- 创建表
CREATE TABLE app_banner
(
id int8 NOT NULL PRIMARY KEY,
cover_url VARCHAR(300) NULL,
route VARCHAR(255) NULL,
outside_url VARCHAR(300) NULL,
sort INTEGER DEFAULT 1 NOT NULL,
banner_type INTEGER NULL,
remark VARCHAR(100) NULL,
is_show INTEGER DEFAULT 0 NOT NULL,
tag_name VARCHAR(255) NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP NULL,
update_user int8 NULL,
update_time TIMESTAMP NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
-- 添加表注释
COMMENT ON TABLE app_banner IS '首页轮播图';
-- 添加列注释
COMMENT ON COLUMN app_banner.id IS 'ID';
COMMENT ON COLUMN app_banner.cover_url IS '轮播图地址';
COMMENT ON COLUMN app_banner.route IS '路由';
COMMENT ON COLUMN app_banner.outside_url IS '外链地址';
COMMENT ON COLUMN app_banner.sort IS '排序';
COMMENT ON COLUMN app_banner.banner_type IS '轮播图类型 1-主banner 2-商城banner';
COMMENT ON COLUMN app_banner.remark IS '备注';
COMMENT ON COLUMN app_banner.is_show IS '是否显示';
COMMENT ON COLUMN app_banner.tag_name IS '标签名';
COMMENT ON COLUMN app_banner.create_user IS '创建人';
COMMENT ON COLUMN app_banner.create_dept IS '创建部门';
COMMENT ON COLUMN app_banner.create_time IS '创建时间';
COMMENT ON COLUMN app_banner.update_user IS '修改人';
COMMENT ON COLUMN app_banner.update_time IS '修改时间';
COMMENT ON COLUMN app_banner.status IS '状态';
COMMENT ON COLUMN app_banner.is_deleted IS '是否已删除';

View File

@@ -1,250 +0,0 @@
CREATE TABLE registration_order
(
id int8 NOT NULL PRIMARY KEY,
spu_id int8 NULL,
sku_id int8 NULL,
title VARCHAR(100) NOT NULL,
transaction_type INTEGER NOT NULL,
thumbnail VARCHAR(500) NOT NULL,
thumbnail_height INTEGER NULL,
detail TEXT NULL,
price DECIMAL(10, 2) NOT NULL,
points DECIMAL(10, 2) NOT NULL,
quantity INTEGER NOT NULL,
remaining INTEGER NOT NULL,
user_id int8 NOT NULL,
user_nickname VARCHAR(100) NULL,
in_transaction INTEGER DEFAULT 0 NOT NULL,
is_full_package INTEGER DEFAULT 0 NOT NULL,
delivery_type INTEGER DEFAULT 1 NULL,
region_code VARCHAR(10) NULL,
region_name VARCHAR(100) NULL,
receiver_address VARCHAR(100) NULL,
contact VARCHAR(100) NULL,
contact_number VARCHAR(100) NULL,
is_virtual INTEGER DEFAULT 0 NOT NULL,
is_closed INTEGER DEFAULT 0 NOT NULL,
version integer DEFAULT 0 NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL,
is_vendor INTEGER DEFAULT 0 NULL,
is_priority INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE registration_order IS '挂单表';
COMMENT ON COLUMN registration_order.id IS '挂单ID';
COMMENT ON COLUMN registration_order.spu_id IS 'spuId';
COMMENT ON COLUMN registration_order.sku_id IS 'skuId';
COMMENT ON COLUMN registration_order.title IS '规格名称';
COMMENT ON COLUMN registration_order.transaction_type IS '交易类型 1-买 2-卖';
COMMENT ON COLUMN registration_order.thumbnail IS '商品缩略图';
COMMENT ON COLUMN registration_order.thumbnail_height IS '缩略图高度';
COMMENT ON COLUMN registration_order.detail IS '详情图';
COMMENT ON COLUMN registration_order.price IS '单价';
COMMENT ON COLUMN registration_order.points IS '单个赠送积分';
COMMENT ON COLUMN registration_order.quantity IS '数量';
COMMENT ON COLUMN registration_order.remaining IS '剩余数量';
COMMENT ON COLUMN registration_order.user_id IS '用户id';
COMMENT ON COLUMN registration_order.user_nickname IS '用户昵称';
COMMENT ON COLUMN registration_order.in_transaction IS '是否交易中 1-交易中 0-空闲中';
COMMENT ON COLUMN registration_order.is_full_package IS '是否全量交易 1-是 0-否';
COMMENT ON COLUMN registration_order.delivery_type IS '配送方式 1-物流快递 2-同城配送 3-上门自提';
COMMENT ON COLUMN registration_order.region_code IS '收货地址区域编码';
COMMENT ON COLUMN registration_order.region_name IS '行政区域名称';
COMMENT ON COLUMN registration_order.receiver_address IS '收货地址';
COMMENT ON COLUMN registration_order.contact IS '收货人';
COMMENT ON COLUMN registration_order.contact_number IS '收货人联系方式';
COMMENT ON COLUMN registration_order.is_virtual IS '是否虚拟商品 1-是 0-否';
COMMENT ON COLUMN registration_order.is_closed IS '是否交易完成 1-是 0-否';
COMMENT ON COLUMN registration_order.version IS '乐观锁版本号';
COMMENT ON COLUMN registration_order.create_user IS '创建人';
COMMENT ON COLUMN registration_order.create_dept IS '创建部门';
COMMENT ON COLUMN registration_order.create_time IS '创建时间';
COMMENT ON COLUMN registration_order.update_user IS '修改人';
COMMENT ON COLUMN registration_order.update_time IS '修改时间';
COMMENT ON COLUMN registration_order.status IS '状态';
COMMENT ON COLUMN registration_order.is_deleted IS '是否已删除';
COMMENT ON COLUMN registration_order.is_vendor IS '是否服务商订单';
COMMENT ON COLUMN registration_order.is_priority IS '是否优先';
CREATE TABLE transaction_order
(
id int8 NOT NULL PRIMARY KEY,
registration_id int8 NOT NULL,
sku_id int8 NULL,
title VARCHAR(100) NOT NULL,
transaction_type INTEGER NOT NULL,
thumbnail VARCHAR(500) NOT NULL,
price DECIMAL(10, 2) NOT NULL,
points DECIMAL(10, 2) NOT NULL,
quantity INTEGER NOT NULL,
total_amount DECIMAL(10, 2) NOT NULL,
total_points DECIMAL(10, 2) NOT NULL,
user_id int8 NOT NULL,
user_nickname VARCHAR(500) NULL,
payment_voucher VARCHAR(500) NULL,
delivery_voucher VARCHAR(500) NULL,
delivery_type INTEGER DEFAULT 1 NOT NULL,
region_code VARCHAR(10) NULL,
region_name VARCHAR(100) NULL,
receiver_address VARCHAR(100) NULL,
contact VARCHAR(100) NULL,
contact_number VARCHAR(100) NULL,
counterparty_order_id int8 DEFAULT 0 NOT NULL,
is_virtual INTEGER DEFAULT 0 NOT NULL,
supplier_order_sn VARCHAR(100) NULL,
expire_time TIMESTAMP NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE transaction_order IS '交易单表';
COMMENT ON COLUMN transaction_order.id IS '交易单ID';
COMMENT ON COLUMN transaction_order.registration_id IS '挂单Id';
COMMENT ON COLUMN transaction_order.sku_id IS 'skuId';
COMMENT ON COLUMN transaction_order.title IS '规格名称';
COMMENT ON COLUMN transaction_order.transaction_type IS '交易类型 1-买 2-卖';
COMMENT ON COLUMN transaction_order.thumbnail IS '商品缩略图';
COMMENT ON COLUMN transaction_order.price IS '单价';
COMMENT ON COLUMN transaction_order.points IS '单个赠送积分';
COMMENT ON COLUMN transaction_order.quantity IS '数量';
COMMENT ON COLUMN transaction_order.total_amount IS '总金额';
COMMENT ON COLUMN transaction_order.total_points IS '总赠送积分';
COMMENT ON COLUMN transaction_order.user_id IS '用户id';
COMMENT ON COLUMN transaction_order.user_nickname IS '用户昵称';
COMMENT ON COLUMN transaction_order.payment_voucher IS '付款凭证';
COMMENT ON COLUMN transaction_order.delivery_voucher IS '物流凭证';
COMMENT ON COLUMN transaction_order.delivery_type IS '收货方式 1-物流快递 2-同城配送 3-上门自提';
COMMENT ON COLUMN transaction_order.region_code IS '收货地址区域编码';
COMMENT ON COLUMN transaction_order.region_name IS '行政区域名称';
COMMENT ON COLUMN transaction_order.receiver_address IS '收货地址';
COMMENT ON COLUMN transaction_order.contact IS '收货联系人';
COMMENT ON COLUMN transaction_order.contact_number IS '收货人联系方式';
COMMENT ON COLUMN transaction_order.counterparty_order_id IS '对手单单号';
COMMENT ON COLUMN transaction_order.is_virtual IS '是否虚拟商品 1-是 0-否';
COMMENT ON COLUMN transaction_order.supplier_order_sn IS '三方供应商订单号';
COMMENT ON COLUMN transaction_order.expire_time IS '待支付超时时间';
COMMENT ON COLUMN transaction_order.create_user IS '创建人';
COMMENT ON COLUMN transaction_order.create_dept IS '创建部门';
COMMENT ON COLUMN transaction_order.create_time IS '创建时间';
COMMENT ON COLUMN transaction_order.update_user IS '修改人';
COMMENT ON COLUMN transaction_order.update_time IS '修改时间';
COMMENT ON COLUMN transaction_order.status IS '状态 1-待支付 2-已支付 3-待发货 4-已发货 5-已完成';
COMMENT ON COLUMN transaction_order.is_deleted IS '是否已删除';
CREATE TABLE user_inventory
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 NOT NULL,
sku_id int8 NOT NULL,
title VARCHAR(100) NOT NULL,
thumbnail VARCHAR(500) NOT NULL,
price DECIMAL(10, 2) NOT NULL,
quantity INTEGER NOT NULL,
is_virtual INTEGER DEFAULT 0 NOT NULL,
attribute JSON NULL,
version int8 DEFAULT 0 NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE user_inventory IS '用户库存';
COMMENT ON COLUMN user_inventory.id IS '库存ID';
COMMENT ON COLUMN user_inventory.user_id IS '用户Id';
COMMENT ON COLUMN user_inventory.sku_id IS 'skuId';
COMMENT ON COLUMN user_inventory.title IS '规格名称';
COMMENT ON COLUMN user_inventory.thumbnail IS '商品缩略图';
COMMENT ON COLUMN user_inventory.price IS '单价';
COMMENT ON COLUMN user_inventory.quantity IS '数量';
COMMENT ON COLUMN user_inventory.is_virtual IS '是否虚拟商品 1-是 0-否';
COMMENT ON COLUMN user_inventory.attribute IS '规格';
COMMENT ON COLUMN user_inventory.version IS '乐观锁版本号';
COMMENT ON COLUMN user_inventory.create_user IS '创建人';
COMMENT ON COLUMN user_inventory.create_dept IS '创建部门';
COMMENT ON COLUMN user_inventory.create_time IS '创建时间';
COMMENT ON COLUMN user_inventory.update_user IS '修改人';
COMMENT ON COLUMN user_inventory.update_time IS '修改时间';
COMMENT ON COLUMN user_inventory.status IS '状态';
COMMENT ON COLUMN user_inventory.is_deleted IS '是否已删除';
CREATE TABLE calendar_non_working
(
id int8 NOT NULL PRIMARY KEY,
off_date DATE NOT NULL,
remark VARCHAR(200) NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE calendar_non_working IS '节假日';
COMMENT ON COLUMN calendar_non_working.id IS '主键';
COMMENT ON COLUMN calendar_non_working.off_date IS '休息日期';
COMMENT ON COLUMN calendar_non_working.remark IS '备忘';
COMMENT ON COLUMN calendar_non_working.create_user IS '创建人';
COMMENT ON COLUMN calendar_non_working.create_dept IS '创建部门';
COMMENT ON COLUMN calendar_non_working.create_time IS '创建时间';
COMMENT ON COLUMN calendar_non_working.update_user IS '修改人';
COMMENT ON COLUMN calendar_non_working.update_time IS '修改时间';
COMMENT ON COLUMN calendar_non_working.status IS '状态';
COMMENT ON COLUMN calendar_non_working.is_deleted IS '是否已删除';
CREATE TABLE user_otc_info
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 NOT NULL,
alipay_account VARCHAR(200) NULL,
wechat_account VARCHAR(200) NULL,
alipay_qr_code VARCHAR(200) NULL,
wechat_qr_code VARCHAR(200) NULL,
bank_account VARCHAR(200) NULL,
branch_info VARCHAR(200) NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE user_otc_info IS 'OTC收款信息';
COMMENT ON COLUMN user_otc_info.id IS 'ID';
COMMENT ON COLUMN user_otc_info.user_id IS '用户ID';
COMMENT ON COLUMN user_otc_info.alipay_account IS '支付宝账号';
COMMENT ON COLUMN user_otc_info.wechat_account IS '微信账号';
COMMENT ON COLUMN user_otc_info.alipay_qr_code IS '支付宝收款码';
COMMENT ON COLUMN user_otc_info.wechat_qr_code IS '微信收款码';
COMMENT ON COLUMN user_otc_info.bank_account IS '银行账号';
COMMENT ON COLUMN user_otc_info.branch_info IS '银行信息';
COMMENT ON COLUMN user_otc_info.create_user IS '创建人';
COMMENT ON COLUMN user_otc_info.create_dept IS '创建部门';
COMMENT ON COLUMN user_otc_info.create_time IS '创建时间';
COMMENT ON COLUMN user_otc_info.update_user IS '修改人';
COMMENT ON COLUMN user_otc_info.update_time IS '修改时间';
COMMENT ON COLUMN user_otc_info.status IS '状态';
COMMENT ON COLUMN user_otc_info.is_deleted IS '是否已删除';

View File

@@ -1,48 +0,0 @@
CREATE TABLE regions_info
(
id SERIAL PRIMARY KEY,
name VARCHAR(50) NULL,
level INTEGER NULL,
pid INTEGER DEFAULT 0 NULL,
lon DECIMAL(10, 6) NULL,
lat DECIMAL(10, 6) NULL,
region_code VARCHAR(128) NULL,
full_name VARCHAR(200) NULL,
vendor_region_id int8 NULL,
store_city_id int8 NULL,
hotel_city_code VARCHAR(128) NULL,
hotel_city_pinyin VARCHAR(128) NULL,
hotel_city_initials VARCHAR(4) NULL,
sight_city_name VARCHAR(32) NULL,
is_deleted INTEGER DEFAULT 0 NULL,
create_time TIMESTAMP(6) NULL,
create_user int8 NULL,
update_time TIMESTAMP(6) NULL,
update_user int8 NULL,
status INTEGER NULL,
create_dept int8 NULL
);
COMMENT ON TABLE regions_info IS '地区详情表';
COMMENT ON COLUMN regions_info.id IS '主键';
COMMENT ON COLUMN regions_info.name IS '名称';
COMMENT ON COLUMN regions_info.level IS '层级';
COMMENT ON COLUMN regions_info.pid IS '父主键';
COMMENT ON COLUMN regions_info.lon IS '经度';
COMMENT ON COLUMN regions_info.lat IS '纬度';
COMMENT ON COLUMN regions_info.region_code IS '地区编码';
COMMENT ON COLUMN regions_info.full_name IS '全称';
COMMENT ON COLUMN regions_info.vendor_region_id IS '服务商地区表id';
COMMENT ON COLUMN regions_info.store_city_id IS '城市店铺id';
COMMENT ON COLUMN regions_info.hotel_city_code IS '酒店地区编码';
COMMENT ON COLUMN regions_info.hotel_city_pinyin IS '酒店地区拼音';
COMMENT ON COLUMN regions_info.hotel_city_initials IS '酒店地区拼音首字母';
COMMENT ON COLUMN regions_info.sight_city_name IS '景点城市名';
COMMENT ON COLUMN regions_info.is_deleted IS '是否删除';
COMMENT ON COLUMN regions_info.create_user IS '创建人';
COMMENT ON COLUMN regions_info.create_dept IS '创建部门';
COMMENT ON COLUMN regions_info.create_time IS '创建时间';
COMMENT ON COLUMN regions_info.update_user IS '修改人';
COMMENT ON COLUMN regions_info.update_time IS '修改时间';
COMMENT ON COLUMN regions_info.status IS '状态';

View File

@@ -1,73 +0,0 @@
CREATE TABLE user_daily_sign
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 NULL,
user_phone int8,
user_name varchar(128),
statistics_date DATE NULL,
sign_count INTEGER NULL,
type INTEGER DEFAULT 1 NULL,
remarks TEXT NULL,
is_complete INTEGER DEFAULT 0 NULL,
is_deleted INTEGER DEFAULT 0 NULL,
create_time TIMESTAMP(6) NULL,
create_user int8 NULL,
update_time TIMESTAMP(6) NULL,
update_user int8 NULL,
status INTEGER NULL,
create_dept int8 NULL
);
COMMENT ON TABLE user_daily_sign IS '用户看广告记录表';
COMMENT ON COLUMN user_daily_sign.user_id IS '用户id';
COMMENT ON COLUMN user_daily_sign.user_phone IS '用户手机号';
COMMENT ON COLUMN user_daily_sign.user_name IS '用户名称';
COMMENT ON COLUMN user_daily_sign.statistics_date IS '统计日期';
COMMENT ON COLUMN user_daily_sign.sign_count IS '看广告统计';
COMMENT ON COLUMN user_daily_sign.type IS '广告类型 1-积分分产出';
COMMENT on column user_daily_sign.is_complete is '是否完成 0-未完成 1-完成';
COMMENT ON COLUMN user_daily_sign.remarks IS '备注';
comment on column user_daily_sign.create_user is '创建人';
comment on column user_daily_sign.create_dept is '创建部门';
comment on column user_daily_sign.create_time is '创建时间';
comment on column user_daily_sign.update_user is '修改人';
comment on column user_daily_sign.update_time is '修改时间';
comment on column user_daily_sign.status is '状态';
comment on column user_daily_sign.is_deleted is '是否已删除';
CREATE INDEX uds_date_index
ON user_daily_sign (is_deleted, type, statistics_date);
CREATE INDEX uds_complete_index
ON user_daily_sign (is_deleted, statistics_date ,type, is_complete);
CREATE INDEX uds_uid_index
ON user_daily_sign (is_deleted, type, user_id, statistics_date);
CREATE TABLE ads
(
id int8 NOT NULL PRIMARY KEY,
name VARCHAR(255) NULL,
url VARCHAR(255) NULL,
sort INTEGER DEFAULT 1,
type INTEGER DEFAULT 1,
ads_time INTEGER NULL,
is_deleted INTEGER DEFAULT 0,
create_time TIMESTAMP(6) NULL,
create_user int8 NULL,
update_time TIMESTAMP(6) NULL,
update_user int8 NULL,
create_dept int8 NULL,
status INTEGER NULL
);
COMMENT ON TABLE ads IS '广告表';
COMMENT ON COLUMN ads.name IS '视频名称';
COMMENT ON COLUMN ads.url IS '视频链接';
COMMENT ON COLUMN ads.sort IS '广告序号';
COMMENT ON COLUMN ads.type IS '广告类型 1-积分分产出';
COMMENT ON COLUMN ads.ads_time IS '视频观看时长';
COMMENT ON COLUMN ads.create_dept IS '创建部门';
COMMENT ON COLUMN ads.status IS '状态';

File diff suppressed because it is too large Load Diff

View File

@@ -1,44 +0,0 @@
-- 创建表
CREATE TABLE user_notice
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 DEFAULT 0 NOT NULL,
notice_type INTEGER DEFAULT 0 NOT NULL,
has_read INTEGER DEFAULT 0 NOT NULL,
release_time TIMESTAMP NULL,
title VARCHAR(100) NULL,
content TEXT NULL,
remarks VARCHAR(200) NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP NULL,
update_user int8 NULL,
update_time TIMESTAMP NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
create index user_notice_user_index
on user_notice (is_deleted, user_id);
-- 添加表注释
COMMENT ON TABLE user_notice IS '用户通知';
-- 添加列注释
COMMENT ON COLUMN user_notice.id IS '主键';
COMMENT ON COLUMN user_notice.user_id IS '用户id';
COMMENT ON COLUMN user_notice.notice_type IS '通知类型0-系统通知';
COMMENT ON COLUMN user_notice.has_read IS '是否已读 0-否 1-是';
COMMENT ON COLUMN user_notice.release_time IS '阅读时间';
COMMENT ON COLUMN user_notice.title IS '标题';
COMMENT ON COLUMN user_notice.content IS '内容';
COMMENT ON COLUMN user_notice.remarks IS '备注';
COMMENT ON COLUMN user_notice.create_user IS '创建人';
COMMENT ON COLUMN user_notice.create_dept IS '创建部门';
COMMENT ON COLUMN user_notice.create_time IS '创建时间';
COMMENT ON COLUMN user_notice.update_user IS '修改人';
COMMENT ON COLUMN user_notice.update_time IS '修改时间';
COMMENT ON COLUMN user_notice.status IS '状态';
COMMENT ON COLUMN user_notice.is_deleted IS '是否已删除';

View File

@@ -1,180 +0,0 @@
create table user_performance
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
performance decimal(16, 4) default 0,
own_performance decimal(16, 4) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index up_index
on user_performance (is_deleted, user_id);
COMMENT ON TABLE user_performance IS '用户现金业绩表';
COMMENT ON COLUMN user_performance.id IS '主键';
COMMENT ON COLUMN user_performance.user_id IS '用户ID';
COMMENT ON COLUMN user_performance.user_phone IS '用户手机号';
COMMENT ON COLUMN user_performance.user_name IS '用户名称';
COMMENT ON COLUMN user_performance.performance IS '总业绩';
COMMENT ON COLUMN user_performance.own_performance IS '自身业绩';
COMMENT ON COLUMN user_performance.version IS '版本号';
comment on column user_performance.create_user is '创建人';
comment on column user_performance.create_dept is '创建部门';
comment on column user_performance.create_time is '创建时间';
comment on column user_performance.update_user is '修改人';
comment on column user_performance.update_time is '修改时间';
comment on column user_performance.status is '状态';
comment on column user_performance.is_deleted is '是否已删除';
alter table user_performance
owner to postgres;
create table user_performance_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 4) default 0,
source_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index user_performance_log_index
on user_performance_log (is_deleted, user_id, statistical_date , type);
comment on table user_performance_log is '用户现金业绩日志表';
comment on column user_performance_log.id is '主键';
comment on column user_performance_log.user_id is '用户ID';
comment on column user_performance_log.user_phone is '用户手机号';
comment on column user_performance_log.user_name is '用户名称';
comment on column user_performance_log.amount is '业绩变动金额';
comment on column user_performance_log.source_id is '来源ID';
comment on column user_performance_log.source_detail is '来源详情';
comment on column user_performance_log.order_id is '订单ID';
comment on column user_performance_log.type is '类型 1增加 2减少';
comment on column user_performance_log.statistical_date is '统计日期';
comment on column user_performance_log.channel is '渠道';
comment on column user_performance_log.channel_detail is '渠道详情';
comment on column user_performance_log.remark is '备注';
comment on column user_performance_log.create_user is '创建人';
comment on column user_performance_log.create_dept is '创建部门';
comment on column user_performance_log.create_time is '创建时间';
comment on column user_performance_log.update_user is '修改人';
comment on column user_performance_log.update_time is '修改时间';
comment on column user_performance_log.status is '状态';
comment on column user_performance_log.is_deleted is '是否已删除';
alter table user_performance_log
owner to postgres;
create table user_performance_benefit
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
performance decimal(16, 4) default 0,
own_performance decimal(16, 4) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index upb_index
on user_performance_benefit (is_deleted, user_id);
COMMENT ON TABLE user_performance_benefit IS '用户福利值业绩表';
COMMENT ON COLUMN user_performance_benefit.id IS '主键';
COMMENT ON COLUMN user_performance_benefit.user_id IS '用户ID';
COMMENT ON COLUMN user_performance_benefit.user_phone IS '用户手机号';
COMMENT ON COLUMN user_performance_benefit.user_name IS '用户名称';
COMMENT ON COLUMN user_performance_benefit.performance IS '总业绩';
COMMENT ON COLUMN user_performance_benefit.own_performance IS '自身业绩';
COMMENT ON COLUMN user_performance_benefit.version IS '版本号';
comment on column user_performance_benefit.create_user is '创建人';
comment on column user_performance_benefit.create_dept is '创建部门';
comment on column user_performance_benefit.create_time is '创建时间';
comment on column user_performance_benefit.update_user is '修改人';
comment on column user_performance_benefit.update_time is '修改时间';
comment on column user_performance_benefit.status is '状态';
comment on column user_performance_benefit.is_deleted is '是否已删除';
alter table user_performance_benefit
owner to postgres;
create table user_performance_benefit_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 4) default 0,
source_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index upbl_index
on user_performance_benefit_log (is_deleted, user_id, statistical_date , type);
comment on table user_performance_benefit_log is '用户福利值业绩日志表';
comment on column user_performance_benefit_log.id is '主键';
comment on column user_performance_benefit_log.user_id is '用户ID';
comment on column user_performance_benefit_log.user_phone is '用户手机号';
comment on column user_performance_benefit_log.user_name is '用户名称';
comment on column user_performance_benefit_log.amount is '业绩变动金额';
comment on column user_performance_benefit_log.source_id is '来源ID';
comment on column user_performance_benefit_log.source_detail is '来源详情';
comment on column user_performance_benefit_log.order_id is '订单ID';
comment on column user_performance_benefit_log.type is '类型 1增加 2减少';
comment on column user_performance_benefit_log.statistical_date is '统计日期';
comment on column user_performance_benefit_log.channel is '渠道';
comment on column user_performance_benefit_log.channel_detail is '渠道详情';
comment on column user_performance_benefit_log.remark is '备注';
comment on column user_performance_benefit_log.create_user is '创建人';
comment on column user_performance_benefit_log.create_dept is '创建部门';
comment on column user_performance_benefit_log.create_time is '创建时间';
comment on column user_performance_benefit_log.update_user is '修改人';
comment on column user_performance_benefit_log.update_time is '修改时间';
comment on column user_performance_benefit_log.status is '状态';
comment on column user_performance_benefit_log.is_deleted is '是否已删除';
alter table user_performance_benefit_log
owner to postgres;

View File

@@ -1,424 +0,0 @@
create table user_benefit
(
id int8 not null primary key,
amount decimal(14, 2) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
comment on table user_benefit is '用户福利值表';
comment on column user_benefit.id is '主键';
comment on column user_benefit.amount is '金额';
comment on column user_benefit.version is '版本号';
comment on column user_benefit.create_user is '创建人';
comment on column user_benefit.create_dept is '创建部门';
comment on column user_benefit.create_time is '创建时间';
comment on column user_benefit.update_user is '修改人';
comment on column user_benefit.update_time is '修改时间';
comment on column user_benefit.status is '状态';
comment on column user_benefit.is_deleted is '是否已删除';
alter table user_benefit
owner to postgres;
create table user_benefit_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
user_pack_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index ub_log_date_index
on user_benefit_log (is_deleted, user_id , statistical_date , type);
comment on table user_benefit_log is '用户福利值流水表';
comment on column user_benefit_log.id is '主键';
comment on column user_benefit_log.user_id is '用户id';
comment on column user_benefit_log.user_phone is '用户手机号';
comment on column user_benefit_log.user_name is '用户名称';
comment on column user_benefit_log.amount is '金额';
comment on column user_benefit_log.source_id is '来源id';
comment on column user_benefit_log.user_pack_id is '用户积分包id';
comment on column user_benefit_log.source_detail is '来源详情';
comment on column user_benefit_log.order_id is '订单id';
comment on column user_benefit_log.type is '消费类型 1-收入 2-支出';
comment on column user_benefit_log.statistical_date is '统计时间';
comment on column user_benefit_log.channel is '消费渠道';
comment on column user_benefit_log.channel_detail is '消费渠道详情';
comment on column user_benefit_log.remark is '备注';
comment on column user_benefit_log.create_user is '创建人';
comment on column user_benefit_log.create_dept is '创建部门';
comment on column user_benefit_log.create_time is '创建时间';
comment on column user_benefit_log.update_user is '修改人';
comment on column user_benefit_log.update_time is '修改时间';
comment on column user_benefit_log.status is '状态';
comment on column user_benefit_log.is_deleted is '是否已删除';
alter table user_benefit_log
owner to postgres;
create table user_commission
(
id int8 not null primary key,
amount decimal(14, 2) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
comment on table user_commission is '用户佣金表';
comment on column user_commission.id is '主键';
comment on column user_commission.amount is '佣金金额';
comment on column user_commission.version is '版本号';
comment on column user_commission.create_user is '创建人';
comment on column user_commission.create_dept is '创建部门';
comment on column user_commission.create_time is '创建时间';
comment on column user_commission.update_user is '修改人';
comment on column user_commission.update_time is '修改时间';
comment on column user_commission.status is '状态';
comment on column user_commission.is_deleted is '是否已删除';
alter table user_commission
owner to postgres;
create table user_commission_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index user_commission_log_index
on user_commission_log (is_deleted, user_id, statistical_date, type);
comment on table user_commission_log is '用户佣金流水表';
comment on column user_commission_log.id is '主键';
comment on column user_commission_log.user_id is '用户id';
comment on column user_commission_log.user_phone is '用户手机号';
comment on column user_commission_log.user_name is '用户名称';
comment on column user_commission_log.amount is '金额';
comment on column user_commission_log.source_id is '来源id';
comment on column user_commission_log.source_detail is '来源详情';
comment on column user_commission_log.order_id is '订单id';
comment on column user_commission_log.type is '消费类型 1-收入 2-支出';
comment on column user_commission_log.statistical_date is '统计时间';
comment on column user_commission_log.channel is '消费渠道';
comment on column user_commission_log.channel_detail is '消费渠道详情';
comment on column user_commission_log.remark is '备注';
comment on column user_commission_log.create_user is '创建人';
comment on column user_commission_log.create_dept is '创建部门';
comment on column user_commission_log.create_time is '创建时间';
comment on column user_commission_log.update_user is '修改人';
comment on column user_commission_log.update_time is '修改时间';
comment on column user_commission_log.status is '状态';
comment on column user_commission_log.is_deleted is '是否已删除';
alter table user_commission_log
owner to postgres;
create table user_cash
(
id int8 not null primary key,
amount decimal(14, 2) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
comment on table user_cash is '用户现金券表';
comment on column user_cash.id is '主键';
comment on column user_cash.amount is '面额';
comment on column user_cash.version is '版本号';
comment on column user_cash.create_user is '创建人';
comment on column user_cash.create_dept is '创建部门';
comment on column user_cash.create_time is '创建时间';
comment on column user_cash.update_user is '修改人';
comment on column user_cash.update_time is '修改时间';
comment on column user_cash.status is '状态';
comment on column user_cash.is_deleted is '是否已删除';
alter table user_cash
owner to postgres;
create table user_cash_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index user_cash_log_index
on user_cash_log (is_deleted, user_id, statistical_date , type);
comment on table user_cash_log is '用户现金券流水表';
comment on column user_cash_log.id is '主键';
comment on column user_cash_log.user_id is '用户id';
comment on column user_cash_log.user_phone is '用户手机号';
comment on column user_cash_log.user_name is '用户名称';
comment on column user_cash_log.amount is '金额';
comment on column user_cash_log.source_id is '来源id';
comment on column user_cash_log.source_detail is '来源详情';
comment on column user_cash_log.order_id is '订单id';
comment on column user_cash_log.type is '消费类型 1-收入 2-支出';
comment on column user_cash_log.statistical_date is '统计时间';
comment on column user_cash_log.channel is '消费渠道';
comment on column user_cash_log.channel_detail is '消费渠道详情';
comment on column user_cash_log.remark is '备注';
comment on column user_cash_log.create_user is '创建人';
comment on column user_cash_log.create_dept is '创建部门';
comment on column user_cash_log.create_time is '创建时间';
comment on column user_cash_log.update_user is '修改人';
comment on column user_cash_log.update_time is '修改时间';
comment on column user_cash_log.status is '状态';
comment on column user_cash_log.is_deleted is '是否已删除';
alter table user_cash_log
owner to postgres;
create table user_mall_integral
(
id int8 not null primary key,
amount decimal(14, 2) default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
comment on table user_mall_integral is '用户商城积分表';
comment on column user_mall_integral.amount is '面额';
comment on column user_mall_integral.version is '版本号';
comment on column user_mall_integral.create_user is '创建人';
comment on column user_mall_integral.create_dept is '创建部门';
comment on column user_mall_integral.create_time is '创建时间';
comment on column user_mall_integral.update_user is '修改人';
comment on column user_mall_integral.update_time is '修改时间';
comment on column user_mall_integral.is_deleted is '是否已删除';
alter table user_mall_integral
owner to postgres;
create table user_mall_integral_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
source_detail text,
order_id int8,
type int default 1,
statistical_date timestamp(6),
channel varchar(64),
channel_detail text,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index user_mall_integral_log_index
on user_mall_integral_log (is_deleted, user_id, statistical_date , type);
comment on table user_mall_integral_log is '用户商城积分流水表';
comment on column user_mall_integral_log.id is '主键';
comment on column user_mall_integral_log.user_id is '用户id';
comment on column user_mall_integral_log.user_phone is '用户手机号';
comment on column user_mall_integral_log.user_name is '用户名称';
comment on column user_mall_integral_log.amount is '金额';
comment on column user_mall_integral_log.source_id is '来源id';
comment on column user_mall_integral_log.source_detail is '来源详情';
comment on column user_mall_integral_log.order_id is '订单id';
comment on column user_mall_integral_log.type is '消费类型 1-收入 2-支出';
comment on column user_mall_integral_log.statistical_date is '统计时间';
comment on column user_mall_integral_log.channel is '消费渠道';
comment on column user_mall_integral_log.channel_detail is '消费渠道详情';
comment on column user_mall_integral_log.remark is '备注';
comment on column user_mall_integral_log.create_user is '创建人';
comment on column user_mall_integral_log.create_dept is '创建部门';
comment on column user_mall_integral_log.create_time is '创建时间';
comment on column user_mall_integral_log.update_user is '修改人';
comment on column user_mall_integral_log.update_time is '修改时间';
comment on column user_mall_integral_log.status is '状态';
comment on column user_mall_integral_log.is_deleted is '是否已删除';
alter table user_mall_integral_log
owner to postgres;
create table user_gains_day
(
id int8 not null primary key,
statistical_date timestamp(6),
user_id int8,
amount decimal(14, 2) default 0,
gains_details text,
is_credited integer default 0,
version int default 1,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index ugd_date_index
on user_gains_day (is_deleted, statistical_date , is_credited);
comment on table user_gains_day is '用户每日加速福利值汇总表';
comment on column user_gains_day.id is '主键';
comment on column user_gains_day.statistical_date is '统计时间';
comment on column user_gains_day.user_id is '用户id';
comment on column user_gains_day.amount is '金额';
comment on column user_gains_day.gains_details is '福利值汇总详情';
comment on column user_gains_day.is_credited is '是否已入账 0-未入账 1-已入账';
comment on column user_gains_day.version is '版本号';
comment on column user_gains_day.create_user is '创建人';
comment on column user_gains_day.create_dept is '创建部门';
comment on column user_gains_day.create_time is '创建时间';
comment on column user_gains_day.update_user is '修改人';
comment on column user_gains_day.update_time is '修改时间';
comment on column user_gains_day.status is '状态';
comment on column user_gains_day.is_deleted is '是否已删除';
alter table user_gains_day
owner to postgres;
create table user_gains_day_log
(
id int8 not null primary key,
user_id int8,
user_phone int8,
user_name varchar(128),
amount decimal(14, 2) default 0,
source_id int8,
source_detail text,
gains_details text,
order_id int8,
statistical_date timestamp(6),
is_summary integer default 0,
remark text,
create_user int8,
create_dept int8,
create_time timestamp(6),
update_user int8,
update_time timestamp(6),
status integer default 1,
is_deleted integer default 0
);
create index ugd_log_date_index
on user_gains_day_log (is_deleted, statistical_date , is_summary );
comment on table user_gains_day_log is '用户每日加速福利值流水表';
comment on column user_gains_day_log.id is '主键';
comment on column user_gains_day_log.user_id is '用户id';
comment on column user_gains_day_log.user_phone is '用户手机号';
comment on column user_gains_day_log.user_name is '用户名称';
comment on column user_gains_day_log.amount is '金额';
comment on column user_gains_day_log.source_id is '来源id';
comment on column user_gains_day_log.source_detail is '来源详情';
comment on column user_gains_day_log.gains_details is '加速福利详情';
comment on column user_gains_day_log.order_id is '订单id';
comment on column user_gains_day_log.statistical_date is '统计时间';
comment on column user_gains_day_log.is_summary is '是否汇总 0-否 1-是';
comment on column user_gains_day_log.remark is '备注';
comment on column user_gains_day_log.create_user is '创建人';
comment on column user_gains_day_log.create_dept is '创建部门';
comment on column user_gains_day_log.create_time is '创建时间';
comment on column user_gains_day_log.update_user is '修改人';
comment on column user_gains_day_log.update_time is '修改时间';
comment on column user_gains_day_log.status is '状态';
comment on column user_gains_day_log.is_deleted is '是否已删除';
alter table user_gains_day_log
owner to postgres;

View File

@@ -1,322 +0,0 @@
CREATE TABLE vendor_daily_activity
(
id int8 NOT NULL PRIMARY KEY,
settle_date DATE NOT NULL,
region_id int8 NOT NULL,
region_level INTEGER DEFAULT 0 NOT NULL,
total_amount INTEGER DEFAULT 0 NOT NULL,
activity_amount INTEGER DEFAULT 0 NOT NULL,
activity_value_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
increase_activity_value_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE vendor_daily_activity IS '服务商用户收益';
COMMENT ON COLUMN vendor_daily_activity.id IS '主键';
COMMENT ON COLUMN vendor_daily_activity.settle_date IS '结算日期';
COMMENT ON COLUMN vendor_daily_activity.region_id IS '地域id';
COMMENT ON COLUMN vendor_daily_activity.region_level IS '地域等级 1-省 2-市 3-区';
COMMENT ON COLUMN vendor_daily_activity.total_amount IS '用户总量';
COMMENT ON COLUMN vendor_daily_activity.activity_amount IS '活跃数量';
COMMENT ON COLUMN vendor_daily_activity.activity_value_amount IS '活跃值总数';
COMMENT ON COLUMN vendor_daily_activity.increase_activity_value_amount IS '活跃值增量';
COMMENT ON COLUMN vendor_daily_activity.create_user IS '创建人';
COMMENT ON COLUMN vendor_daily_activity.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_daily_activity.create_time IS '创建时间';
COMMENT ON COLUMN vendor_daily_activity.update_user IS '修改人';
COMMENT ON COLUMN vendor_daily_activity.update_time IS '修改时间';
COMMENT ON COLUMN vendor_daily_activity.status IS '状态';
COMMENT ON COLUMN vendor_daily_activity.is_deleted IS '是否已删除';
CREATE TABLE vendor_daily_profit
(
id int8 NOT NULL PRIMARY KEY,
settle_date DATE NOT NULL,
region_id int8 NOT NULL,
region_level INTEGER DEFAULT 0 NOT NULL,
profit_type INTEGER DEFAULT 0 NOT NULL,
order_type INTEGER NOT NULL,
total_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
profit_amount DECIMAL(10, 1) DEFAULT 0.0 NOT NULL,
quantity INTEGER DEFAULT 0 NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE vendor_daily_profit IS '服务商营收收益';
COMMENT ON COLUMN vendor_daily_profit.id IS '主键';
COMMENT ON COLUMN vendor_daily_profit.settle_date IS '结算日期';
COMMENT ON COLUMN vendor_daily_profit.region_id IS '地域id';
COMMENT ON COLUMN vendor_daily_profit.region_level IS '地域等级 1-省 2-市 3-区';
COMMENT ON COLUMN vendor_daily_profit.profit_type IS '收益类型: 1.线上商城 2.线下点餐';
COMMENT ON COLUMN vendor_daily_profit.order_type IS '订单类型 1-商城订单 8-活动订单 9-店铺订单 10-旅行订单 11-门票订单 12-酒店订单';
COMMENT ON COLUMN vendor_daily_profit.total_amount IS '总金额';
COMMENT ON COLUMN vendor_daily_profit.profit_amount IS '总利润';
COMMENT ON COLUMN vendor_daily_profit.quantity IS '总单数';
COMMENT ON COLUMN vendor_daily_profit.create_user IS '创建人';
COMMENT ON COLUMN vendor_daily_profit.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_daily_profit.create_time IS '创建时间';
COMMENT ON COLUMN vendor_daily_profit.update_user IS '修改人';
COMMENT ON COLUMN vendor_daily_profit.update_time IS '修改时间';
COMMENT ON COLUMN vendor_daily_profit.status IS '状态';
COMMENT ON COLUMN vendor_daily_profit.is_deleted IS '是否已删除';
CREATE TABLE vendor_info
(
id int8 NOT NULL PRIMARY KEY,
region_id int8 NOT NULL,
user_id int8 NOT NULL,
company_name VARCHAR(200) DEFAULT '' NOT NULL,
legal_person_name VARCHAR(200) DEFAULT '' NOT NULL,
id_card VARCHAR(50) DEFAULT '' NOT NULL,
contact_no VARCHAR(50) DEFAULT '' NOT NULL,
id_card_front VARCHAR(200) DEFAULT '' NOT NULL,
id_card_back VARCHAR(200) DEFAULT '' NOT NULL,
id_card_handheld VARCHAR(200) DEFAULT '' NOT NULL,
business_license VARCHAR(200) DEFAULT '' NOT NULL,
audit_status INTEGER DEFAULT 1 NOT NULL,
auditor int8 NULL,
reject_reason VARCHAR(200) DEFAULT '' NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL,
apply_time TIMESTAMP(6) NULL
);
COMMENT ON TABLE vendor_info IS '服务商';
COMMENT ON COLUMN vendor_info.id IS '主键';
COMMENT ON COLUMN vendor_info.region_id IS '区域id';
COMMENT ON COLUMN vendor_info.user_id IS '用户id';
COMMENT ON COLUMN vendor_info.company_name IS '企业名称';
COMMENT ON COLUMN vendor_info.legal_person_name IS '法人';
COMMENT ON COLUMN vendor_info.id_card IS '身份证';
COMMENT ON COLUMN vendor_info.contact_no IS '联系电话';
COMMENT ON COLUMN vendor_info.id_card_front IS '身份证正面';
COMMENT ON COLUMN vendor_info.id_card_back IS '身份证反面';
COMMENT ON COLUMN vendor_info.id_card_handheld IS '手持身份证照片';
COMMENT ON COLUMN vendor_info.business_license IS '营业执照';
COMMENT ON COLUMN vendor_info.audit_status IS '审核状态 1-待审核 2-审核通过 3-审核失败';
COMMENT ON COLUMN vendor_info.auditor IS '审核人';
COMMENT ON COLUMN vendor_info.reject_reason IS '拒绝原因';
COMMENT ON COLUMN vendor_info.create_user IS '创建人';
COMMENT ON COLUMN vendor_info.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_info.create_time IS '创建时间';
COMMENT ON COLUMN vendor_info.update_user IS '修改人';
COMMENT ON COLUMN vendor_info.update_time IS '修改时间';
COMMENT ON COLUMN vendor_info.status IS '状态';
COMMENT ON COLUMN vendor_info.is_deleted IS '是否已删除';
COMMENT ON COLUMN vendor_info.apply_time IS '申请时间';
CREATE TABLE vendor_payout_apply
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 DEFAULT 0 NOT NULL,
apply_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
company_fully_name VARCHAR(255) NULL,
bank_account VARCHAR(255) NULL,
branch_info VARCHAR(255) NULL,
transfer_description VARCHAR(255) NULL,
invoice_url TEXT NULL,
invoice_number VARCHAR(255) NULL,
transfer_voucher TEXT NULL,
apply_status INTEGER DEFAULT 1 NOT NULL,
remark VARCHAR(255) NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER NULL
);
COMMENT ON TABLE vendor_payout_apply IS '服务商提现申请';
COMMENT ON COLUMN vendor_payout_apply.id IS '主键';
COMMENT ON COLUMN vendor_payout_apply.user_id IS '用户主键';
COMMENT ON COLUMN vendor_payout_apply.apply_amount IS '申请提现金额';
COMMENT ON COLUMN vendor_payout_apply.company_fully_name IS '公司全称';
COMMENT ON COLUMN vendor_payout_apply.bank_account IS '银行账号';
COMMENT ON COLUMN vendor_payout_apply.branch_info IS '开户行信息';
COMMENT ON COLUMN vendor_payout_apply.transfer_description IS '转账内容描述';
COMMENT ON COLUMN vendor_payout_apply.invoice_url IS '发票截图地址';
COMMENT ON COLUMN vendor_payout_apply.invoice_number IS '发票号';
COMMENT ON COLUMN vendor_payout_apply.transfer_voucher IS '转账凭证';
COMMENT ON COLUMN vendor_payout_apply.apply_status IS '申请提现状态 1:待审核 2:审核通过 3:审核不通过';
COMMENT ON COLUMN vendor_payout_apply.remark IS '备注';
COMMENT ON COLUMN vendor_payout_apply.create_user IS '创建人';
COMMENT ON COLUMN vendor_payout_apply.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_payout_apply.create_time IS '创建时间';
COMMENT ON COLUMN vendor_payout_apply.update_user IS '修改人';
COMMENT ON COLUMN vendor_payout_apply.update_time IS '修改时间';
COMMENT ON COLUMN vendor_payout_apply.status IS '状态';
COMMENT ON COLUMN vendor_payout_apply.is_deleted IS '是否已删除';
CREATE TABLE vendor_profit_detail
(
id int8 NOT NULL PRIMARY KEY,
order_id int8 DEFAULT 0 NOT NULL,
user_id int8 DEFAULT 0 NOT NULL,
district_id int8 DEFAULT 0 NOT NULL,
city_id int8 DEFAULT 0 NOT NULL,
province_id int8 DEFAULT 0 NOT NULL,
order_type INTEGER DEFAULT 0 NOT NULL,
payment_type INTEGER DEFAULT 0 NOT NULL,
actual_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
cost_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
profit_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
order_settle_date TIMESTAMP NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER NULL
);
COMMENT ON TABLE vendor_profit_detail IS '服务商分润详情';
COMMENT ON COLUMN vendor_profit_detail.id IS '主键';
COMMENT ON COLUMN vendor_profit_detail.order_id IS '订单主键';
COMMENT ON COLUMN vendor_profit_detail.user_id IS '用户主键';
COMMENT ON COLUMN vendor_profit_detail.district_id IS '区主键';
COMMENT ON COLUMN vendor_profit_detail.city_id IS '市主键';
COMMENT ON COLUMN vendor_profit_detail.province_id IS '省主键';
COMMENT ON COLUMN vendor_profit_detail.order_type IS '订单类型';
COMMENT ON COLUMN vendor_profit_detail.payment_type IS '支付类型';
COMMENT ON COLUMN vendor_profit_detail.actual_amount IS '实际支付金额';
COMMENT ON COLUMN vendor_profit_detail.cost_amount IS '成本金额';
COMMENT ON COLUMN vendor_profit_detail.profit_amount IS '利润金额';
COMMENT ON COLUMN vendor_profit_detail.order_settle_date IS '订单结算日期';
COMMENT ON COLUMN vendor_profit_detail.create_user IS '创建人';
COMMENT ON COLUMN vendor_profit_detail.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_profit_detail.create_time IS '创建时间';
COMMENT ON COLUMN vendor_profit_detail.update_user IS '修改人';
COMMENT ON COLUMN vendor_profit_detail.update_time IS '修改时间';
COMMENT ON COLUMN vendor_profit_detail.status IS '状态';
COMMENT ON COLUMN vendor_profit_detail.is_deleted IS '是否已删除';
CREATE TABLE vendor_regions
(
id int8 NOT NULL PRIMARY KEY,
name VARCHAR(50) NULL,
level INTEGER NULL,
pid INTEGER DEFAULT 0 NULL,
lon DECIMAL(10, 6) NULL,
lat DECIMAL(10, 6) NULL,
vendor_id int8 NULL,
token_amount DECIMAL(10, 2) DEFAULT 0.00 NULL,
points_amount DECIMAL(10, 2) DEFAULT 0.00 NULL,
apply_amount DECIMAL(10, 2) DEFAULT 0.00 NULL,
apply_status INTEGER DEFAULT 1 NULL,
region_code VARCHAR(10) NULL
);
COMMENT ON TABLE vendor_regions IS '服务商地区';
COMMENT ON COLUMN vendor_regions.id IS '主键';
COMMENT ON COLUMN vendor_regions.name IS '名称';
COMMENT ON COLUMN vendor_regions.level IS '层级';
COMMENT ON COLUMN vendor_regions.pid IS '父主键';
COMMENT ON COLUMN vendor_regions.lon IS '经度';
COMMENT ON COLUMN vendor_regions.lat IS '纬度';
COMMENT ON COLUMN vendor_regions.vendor_id IS '服务商id';
COMMENT ON COLUMN vendor_regions.token_amount IS '消费金数量';
COMMENT ON COLUMN vendor_regions.points_amount IS '抵扣券数量';
COMMENT ON COLUMN vendor_regions.apply_amount IS '申请金额';
COMMENT ON COLUMN vendor_regions.apply_status IS '1-未申请 2-申请中 3-已申请';
COMMENT ON COLUMN vendor_regions.region_code IS '区划编号';
CREATE TABLE vendor_virtual_data_activity
(
id int8 NOT NULL PRIMARY KEY,
region_id INTEGER NOT NULL,
user_amount INTEGER DEFAULT 0 NOT NULL,
active_user_amount INTEGER DEFAULT 0 NOT NULL,
order_amount DECIMAL(10, 2) DEFAULT 0.00 NULL,
order_quantity INTEGER DEFAULT 0 NOT NULL,
activity_value DECIMAL(10, 2) DEFAULT 0.00 NULL,
increase_activity_value DECIMAL(10, 2) DEFAULT 0.00 NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE vendor_virtual_data_activity IS '服务商活跃度虚拟增益';
COMMENT ON COLUMN vendor_virtual_data_activity.id IS '主键';
COMMENT ON COLUMN vendor_virtual_data_activity.region_id IS '地区id';
COMMENT ON COLUMN vendor_virtual_data_activity.user_amount IS '用户数量';
COMMENT ON COLUMN vendor_virtual_data_activity.active_user_amount IS '活跃用户数量';
COMMENT ON COLUMN vendor_virtual_data_activity.order_amount IS '订单总额';
COMMENT ON COLUMN vendor_virtual_data_activity.order_quantity IS '订单量';
COMMENT ON COLUMN vendor_virtual_data_activity.activity_value IS '活跃值';
COMMENT ON COLUMN vendor_virtual_data_activity.increase_activity_value IS '新增活跃值';
COMMENT ON COLUMN vendor_virtual_data_activity.create_user IS '创建人';
COMMENT ON COLUMN vendor_virtual_data_activity.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_virtual_data_activity.create_time IS '创建时间';
COMMENT ON COLUMN vendor_virtual_data_activity.update_user IS '修改人';
COMMENT ON COLUMN vendor_virtual_data_activity.update_time IS '修改时间';
COMMENT ON COLUMN vendor_virtual_data_activity.status IS '状态';
COMMENT ON COLUMN vendor_virtual_data_activity.is_deleted IS '是否已删除';
CREATE TABLE vendor_virtual_data_profit
(
id int8 NOT NULL PRIMARY KEY,
region_id INTEGER NOT NULL,
settle_date DATE NOT NULL,
online_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
offline_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
activity_amount DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE vendor_virtual_data_profit IS '服务商营收虚拟增益';
COMMENT ON COLUMN vendor_virtual_data_profit.id IS '主键';
COMMENT ON COLUMN vendor_virtual_data_profit.region_id IS '地区id';
COMMENT ON COLUMN vendor_virtual_data_profit.settle_date IS '日期';
COMMENT ON COLUMN vendor_virtual_data_profit.online_amount IS '线上收益';
COMMENT ON COLUMN vendor_virtual_data_profit.offline_amount IS '线下收益';
COMMENT ON COLUMN vendor_virtual_data_profit.activity_amount IS '活跃值收益';
COMMENT ON COLUMN vendor_virtual_data_profit.create_user IS '创建人';
COMMENT ON COLUMN vendor_virtual_data_profit.create_dept IS '创建部门';
COMMENT ON COLUMN vendor_virtual_data_profit.create_time IS '创建时间';
COMMENT ON COLUMN vendor_virtual_data_profit.update_user IS '修改人';
COMMENT ON COLUMN vendor_virtual_data_profit.update_time IS '修改时间';
COMMENT ON COLUMN vendor_virtual_data_profit.status IS '状态';
COMMENT ON COLUMN vendor_virtual_data_profit.is_deleted IS '是否已删除';

View File

@@ -1,79 +0,0 @@
CREATE TABLE prize_spu
(
id int8 NOT NULL PRIMARY KEY,
spu_name VARCHAR(255) DEFAULT '' NOT NULL,
main_img VARCHAR(255) DEFAULT '' NOT NULL,
detail_img text NULL,
cost_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
original_price DECIMAL(10, 2) DEFAULT 0.00 NOT NULL,
spu_qty INTEGER DEFAULT 0 NOT NULL,
status INTEGER DEFAULT 0 NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
COMMENT ON TABLE prize_spu IS '奖池商品';
COMMENT ON COLUMN prize_spu.id IS '主键';
COMMENT ON COLUMN prize_spu.spu_name IS '商品名称';
COMMENT ON COLUMN prize_spu.main_img IS '主图';
COMMENT ON COLUMN prize_spu.detail_img IS '详情图(多图,逗号分割)';
COMMENT ON COLUMN prize_spu.cost_price IS '成本价';
COMMENT ON COLUMN prize_spu.original_price IS '原价';
COMMENT ON COLUMN prize_spu.spu_qty IS '库存';
COMMENT ON COLUMN prize_spu.status IS '状态(0=下架,1=上架,3=删除)';
COMMENT ON COLUMN prize_spu.create_user IS '创建人';
COMMENT ON COLUMN prize_spu.create_dept IS '创建部门';
COMMENT ON COLUMN prize_spu.create_time IS '创建时间';
COMMENT ON COLUMN prize_spu.update_user IS '修改人';
COMMENT ON COLUMN prize_spu.update_time IS '修改时间';
COMMENT ON COLUMN prize_spu.is_deleted IS '是否已删除';
CREATE TABLE prize_spu_order
(
id int8 NOT NULL PRIMARY KEY,
user_id int8 DEFAULT 0 NOT NULL,
user_name VARCHAR(128) NULL,
user_phone int8 NULL,
spu_id int8 NULL,
spu_name VARCHAR(255) NULL,
main_img VARCHAR(255) NULL,
detail_img text NULL,
quantity INTEGER DEFAULT 0 NOT NULL,
order_status INTEGER DEFAULT 0 NOT NULL,
version int8 DEFAULT 0 NULL,
create_user int8 NULL,
create_dept int8 NULL,
create_time TIMESTAMP(6) NULL,
update_user int8 NULL,
update_time TIMESTAMP(6) NULL,
status INTEGER DEFAULT -1 NULL,
is_deleted INTEGER DEFAULT 0 NULL
);
create index prize_spu_order_index on prize_spu_order (user_id);
COMMENT ON TABLE prize_spu_order IS '奖池商品订单';
comment on column prize_spu_order.id is '主键';
comment on column prize_spu_order.user_id is '用户ID';
comment on column prize_spu_order.user_name is '用户名称';
comment on column prize_spu_order.user_phone is '用户手机号';
comment on column prize_spu_order.spu_id is '商品ID';
comment on column prize_spu_order.spu_name is '商品名称';
comment on column prize_spu_order.main_img is '商品主图';
comment on column prize_spu_order.detail_img is '商品详情图(多图,逗号分割)';
comment on column prize_spu_order.quantity is '商品数量';
comment on column prize_spu_order.order_status is '订单状态(0=待发货,1=已发货,2=已完成,3=已取消)';
comment on column prize_spu_order.version is '版本号';
comment on column prize_spu_order.create_user is '创建人';
comment on column prize_spu_order.create_dept is '创建部门';
comment on column prize_spu_order.create_time is '创建时间';
comment on column prize_spu_order.update_user is '修改人';
comment on column prize_spu_order.update_time is '修改时间';
comment on column prize_spu_order.status is '状态(-1=无效,0=有效)';
comment on column prize_spu_order.is_deleted is '是否已删除';

File diff suppressed because one or more lines are too long

View File

@@ -1,4 +0,0 @@
INSERT INTO ads ("id", "name", "url", "sort", "type", "ads_time", "is_deleted", "create_time", "create_user", "update_time", "update_user", "create_dept", "status") VALUES (2017839712136810498, '广告1', '11111', 1, 1, 5, 0, '2026-02-01 13:57:31', 1123598821738675201, '2026-02-01 13:57:44.351', 1123598821738675201, 1123598813738675201, 1);
INSERT INTO ads ("id", "name", "url", "sort", "type", "ads_time", "is_deleted", "create_time", "create_user", "update_time", "update_user", "create_dept", "status") VALUES (2017839810455490561, '广告2', '22222', 2, 1, 5, 0, '2026-02-01 13:57:55.123', 1123598821738675201, '2026-02-01 13:57:55.123', 1123598821738675201, 1123598813738675201, 1);
INSERT INTO ads ("id", "name", "url", "sort", "type", "ads_time", "is_deleted", "create_time", "create_user", "update_time", "update_user", "create_dept", "status") VALUES (2017839854445350914, '广告3', '33333', 3, 1, 5, 0, '2026-02-01 13:58:05.608', 1123598821738675201, '2026-02-01 13:58:05.608', 1123598821738675201, 1123598813738675201, 1);
INSERT INTO ads ("id", "name", "url", "sort", "type", "ads_time", "is_deleted", "create_time", "create_user", "update_time", "update_user", "create_dept", "status") VALUES (2017839920576942081, '广告4', '44444', 4, 1, 5, 0, '2026-02-01 13:58:21.378', 1123598821738675201, '2026-02-01 13:58:21.378', 1123598821738675201, 1123598813738675201, 1);

View File

@@ -1,2 +0,0 @@
INSERT INTO blade_client ("id", "client_id", "client_secret", "resource_ids", "scope", "authorized_grant_types", "web_server_redirect_uri", "authorities", "access_token_validity", "refresh_token_validity", "additional_information", "autoapprove", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2016023363404103681, 'appFormal', 'uP1mG5gT1sC6tG4mT7nU7fL9yP6yW1sY', '', 'all', 'refresh_token,password,sms_code,register', 'http://localhost:8081', '', 86400, 604800, NULL, 'true', 1123598821738675201, 1123598813738675201, '2026-01-27 13:40:00', 1123598821738675201, '2026-01-30 21:11:21.64', 1, 0);
INSERT INTO blade_client ("id", "client_id", "client_secret", "resource_ids", "scope", "authorized_grant_types", "web_server_redirect_uri", "authorities", "access_token_validity", "refresh_token_validity", "additional_information", "autoapprove", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017525783019851778, 'appOffline', 'gL8nS4oV2cS8fC2zD9tB3xB9zY8vA3hE9xS2uR7gC2tO0sO8pE4gC4sF6kB7bN7q', '', 'all', 'refresh_token,password,sms_code', 'http://localhost:8081', '', 259200, 604800, NULL, 'true', 1123598821738675201, 1123598813738675201, '2026-01-31 17:10:05', 1123598821738675201, '2026-01-31 17:10:19.598', 1, 0);

View File

@@ -1,36 +0,0 @@
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256532300197889, 0, 'app_order_status', '-1', 'app订单状态', 17, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256701003493378, 2017256532300197889, 'app_order_status', '3', '待收货', 3, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256735887519745, 2017256532300197889, 'app_order_status', '4', '已完成', 4, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256766271057921, 2017256532300197889, 'app_order_status', '5', '已取消', 5, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256798575587330, 2017256532300197889, 'app_order_status', '6', '售后中', 6, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256831240826882, 2017256532300197889, 'app_order_status', '7', '已完结', 7, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017277351755730945, 0, 'app_yes_no', '-1', 'app是否状态', 18, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017277404973060097, 2017277351755730945, 'app_yes_no', '0', '否', 0, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017277445628448770, 2017277351755730945, 'app_yes_no', '1', '是', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279052097212417, 0, 'app_pay_status', '-1', 'app支付状态', 19, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279219479302146, 2017279052097212417, 'app_pay_status', '1', '待支付', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279260155662338, 2017279052097212417, 'app_pay_status', '2', '已支付', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279292049149953, 2017279052097212417, 'app_pay_status', '3', '已关闭', 3, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256666383708162, 2017256532300197889, 'app_order_status', '2', '已支付', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256633735245825, 2017256532300197889, 'app_order_status', '1', '待支付', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279326488580097, 2017279052097212417, 'app_pay_status', '4', '退款中', 4, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017279356754677762, 2017279052097212417, 'app_pay_status', '5', '已退款', 5, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017280506669256705, 0, 'app_order_model', '-1', 'app订单类型', 20, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017280559299383297, 2017280506669256705, 'app_order_model', '1', '商城订单', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017448732011200513, 0, 'app_pay_type', '-1', 'app支付类型', 21, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017448799661129730, 2017448732011200513, 'app_pay_type', '1', '支付宝', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017448849464295426, 2017448732011200513, 'app_pay_type', '2', '微信', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017448927499321345, 2017448732011200513, 'app_pay_type', '3', '线下支付', 3, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017256598469537794, 2017256532300197889, 'app_order_status', '0', '待支付', 0, '', 0, 1, 1);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017478580159041538, 0, 'app_point_spending_type', '-1', 'app积分消费类型', 22, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017478672572141569, 2017478580159041538, 'app_point_spending_type', '1', '收入', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017478708412469249, 2017478580159041538, 'app_point_spending_type', '2', '支出', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017517140190855170, 0, 'app_package_type', '-1', 'app福利包类型', 23, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017517209350733826, 2017517140190855170, 'app_package_type', '1', '积分兑换', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2017517264824598530, 2017517140190855170, 'app_package_type', '2', '后台划拨', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2018600540205121537, 0, 'app_banner_type', '-1', 'app轮播图类型', 24, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2018600645536677890, 2018600540205121537, 'app_banner_type', '1', '主banner', 1, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2018600683209916417, 2018600540205121537, 'app_banner_type', '2', '商城banner', 2, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2018607816655708161, 0, 'app_user_notice', '-1', 'app用户通知类型', 25, '', 0, 1, 0);
INSERT INTO blade_dict ("id", "parent_id", "code", "dict_key", "dict_value", "sort", "remark", "is_sealed", "status", "is_deleted") VALUES (2018607875027836929, 2018607816655708161, 'app_user_notice', '0', '系统通知', 0, '', 0, 1, 0);

View File

@@ -1,245 +0,0 @@
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511999274860547, 2016511999274860546, 'ads_add', '新增', 'add', '/userPackInfo/ads/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511999274860548, 2016511999274860546, 'ads_edit', '修改', 'edit', '/userPackInfo/ads/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511999274860549, 2016511999274860546, 'ads_delete', '删除', 'delete', '/api/blade-ads/ads/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511999274860550, 2016511999274860546, 'ads_view', '查看', 'view', '/userPackInfo/ads/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986561925122, 2016511986561925121, 'level_info_add', '新增', 'add', '/customer/levelInfo/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016444412729917441, 0, 'customer', '用户信息', 'menu', '/customer', 'iconfont iconicon_subordinate', 9, 1, -1, 1, '', '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016445572647911425, 0, 'cashAccount', '资金账户', 'menu', '/cashAccount', 'iconfont icon-biaodanzujian-biaoge', 10, 1, -1, 1, '', '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016445919294554113, 0, 'mall', '商城', 'menu', '/mall', 'iconfont iconicon_message', 11, 1, NULL, 1, NULL, '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016446167375052801, 0, 'order', '订单管理', 'menu', '/order', 'iconfont iconicon_message', 12, 1, NULL, 1, NULL, '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016446332399943682, 0, 'userPackInfo', '积分包管理', 'menu', '/userPackInfo', 'iconfont iconicon_principal', 13, 1, NULL, 1, NULL, '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016446547672596482, 0, 'userPoint', '用户积分管理', 'menu', '/userPoint', 'iconfont iconicon_message', 14, 1, NULL, 1, NULL, '', 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986561925123, 2016511986561925121, 'level_info_edit', '修改', 'edit', '/customer/levelInfo/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986561925124, 2016511986561925121, 'level_info_delete', '删除', 'delete', '/api/blade-level-info/level_info/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986561925125, 2016511986561925121, 'level_info_view', '查看', 'view', '/customer/levelInfo/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987606306819, 2016511987606306818, 'cart_add', '新增', 'add', '/mall/mallCart/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987606306820, 2016511987606306818, 'cart_edit', '修改', 'edit', '/mall/mallCart/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987606306821, 2016511987606306818, 'cart_delete', '删除', 'delete', '/api/blade-mall-cart/cart/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987606306822, 2016511987606306818, 'cart_view', '查看', 'view', '/mall/mallCart/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989300805634, 2016511989300805633, 'detailOrder_add', '新增', 'add', '/order/mallDetailOrder/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989300805635, 2016511989300805633, 'detailOrder_edit', '修改', 'edit', '/order/mallDetailOrder/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989300805636, 2016511989300805633, 'detailOrder_delete', '删除', 'delete', '/api/blade-mall-detailorder/detailOrder/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989300805637, 2016511989300805633, 'detailOrder_view', '查看', 'view', '/order/mallDetailOrder/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988126400515, 2016511988126400514, 'spu_add', '新增', 'add', '/mall/mallSpu/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988126400516, 2016511988126400514, 'spu_edit', '修改', 'edit', '/mall/mallSpu/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988126400517, 2016511988126400514, 'spu_delete', '删除', 'delete', '/api/blade-mall-spu/spu/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988126400518, 2016511988126400514, 'spu_view', '查看', 'view', '/mall/mallSpu/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989883813891, 2016511989883813890, 'summaryOrder_add', '新增', 'add', '/order/mallSummaryOrder/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989883813892, 2016511989883813890, 'summaryOrder_edit', '修改', 'edit', '/order/mallSummaryOrder/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989883813893, 2016511989883813890, 'summaryOrder_delete', '删除', 'delete', '/api/blade-mall-summaryorder/summaryOrder/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989883813894, 2016511989883813890, 'summaryOrder_view', '查看', 'view', '/order/mallSummaryOrder/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511990412296194, 2016511990412296193, 'summaryOrderAfter_add', '新增', 'add', '/order/mallSummaryOrderAfter/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511990412296195, 2016511990412296193, 'summaryOrderAfter_edit', '修改', 'edit', '/order/mallSummaryOrderAfter/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511990412296196, 2016511990412296193, 'summaryOrderAfter_delete', '删除', 'delete', '/api/blade-mall-summaryorderafter/summaryOrderAfter/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511990412296197, 2016511990412296193, 'summaryOrderAfter_view', '查看', 'view', '/order/mallSummaryOrderAfter/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985072947202, 2016511985072947201, 'info_add', '新增', 'add', '/userPackInfo/appPackageInfo/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985072947203, 2016511985072947201, 'info_edit', '修改', 'edit', '/userPackInfo/appPackageInfo/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985072947204, 2016511985072947201, 'info_delete', '删除', 'delete', '/blade-app-package/info/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985072947205, 2016511985072947201, 'info_view', '查看', 'view', '/userPackInfo/appPackageInfo/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997844602884, 2016511997844602881, 'info_delete', '删除', 'delete', '/api/blade-app-regions/info/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988646494210, 2016511988646494209, 'address_add', '新增', 'add', '/mall/userAddress/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988646494211, 2016511988646494209, 'address_edit', '修改', 'edit', '/mall/userAddress/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988646494212, 2016511988646494209, 'address_delete', '删除', 'delete', '/api/blade-user-address/address/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988646494213, 2016511988646494209, 'address_view', '查看', 'view', '/mall/userAddress/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979087675395, 2016511979087675394, 'benefit_add', '新增', 'add', '/userPoint/userBenefit/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979087675396, 2016511979087675394, 'benefit_edit', '修改', 'edit', '/userPoint/userBenefit/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979087675397, 2016511979087675394, 'benefit_delete', '删除', 'delete', '/api/blade-user-benefit/benefit/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979087675398, 2016511979087675394, 'benefit_view', '查看', 'view', '/userPoint/userBenefit/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998809292802, 2016511998809292801, 'benefitLog_add', '新增', 'add', '/userPoint/userBenefitLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998809292803, 2016511998809292801, 'benefitLog_edit', '修改', 'edit', '/userPoint/userBenefitLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998809292804, 2016511998809292801, 'benefitLog_delete', '删除', 'delete', '/api/blade-user-benefitlog/benefitLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998809292805, 2016511998809292801, 'benefitLog_view', '查看', 'view', '/userPoint/userBenefitLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985072947201, 2016446332399943682, 'info', '积分包信息', 'menu', '/userPackInfo/appPackageInfo', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989883813890, 2016446167375052801, 'summaryOrder', '商城总订单', 'menu', '/order/mallSummaryOrder', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511989300805633, 2016446167375052801, 'detailOrder', '商城详情订单', 'menu', '/order/mallDetailOrder', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988126400514, 2016445919294554113, 'spu', '商城spu', 'menu', '/mall/mallSpu', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987606306818, 2016445919294554113, 'cart', '商城购物车', 'menu', '/mall/mallCart', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511990412296193, 2016446167375052801, 'summaryOrderAfter', '商品售后订单', 'menu', '/order/mallSummaryOrderAfter', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979087675394, 2016446547672596482, 'benefit', '用户福利值', 'menu', '/userPoint/userBenefit', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511988646494209, 2016445919294554113, 'address', '用户地址', 'menu', '/mall/userAddress', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979599380483, 2016511979599380482, 'cash_add', '新增', 'add', '/userPoint/userCash/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979599380484, 2016511979599380482, 'cash_edit', '修改', 'edit', '/userPoint/userCash/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979599380485, 2016511979599380482, 'cash_delete', '删除', 'delete', '/api/blade-user-cash/cash/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979599380486, 2016511979599380482, 'cash_view', '查看', 'view', '/userPoint/userCash/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998356307971, 2016511998356307970, 'cashLog_add', '新增', 'add', '/userPoint/userCashLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998356307972, 2016511998356307970, 'cashLog_edit', '修改', 'edit', '/userPoint/userCashLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998356307973, 2016511998356307970, 'cashLog_delete', '删除', 'delete', '/api/blade-user-cashlog/cashLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998356307974, 2016511998356307970, 'cashLog_view', '查看', 'view', '/userPoint/userCashLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980115279874, 2016511980115279873, 'commission_add', '新增', 'add', '/userPoint/userCommission/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980115279875, 2016511980115279873, 'commission_edit', '修改', 'edit', '/userPoint/userCommission/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980115279876, 2016511980115279873, 'commission_delete', '删除', 'delete', '/api/blade-user-commission/commission/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980115279877, 2016511980115279873, 'commission_view', '查看', 'view', '/userPoint/userCommission/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991586701314, 2016511991586701313, 'commissionAccount_add', '新增', 'add', '/cashAccount/userCommissionAccount/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991586701315, 2016511991586701313, 'commissionAccount_edit', '修改', 'edit', '/cashAccount/userCommissionAccount/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991586701316, 2016511991586701313, 'commissionAccount_delete', '删除', 'delete', '/api/blade-user-commissionaccount/commissionAccount/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991586701317, 2016511991586701313, 'commissionAccount_view', '查看', 'view', '/cashAccount/userCommissionAccount/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992102600706, 2016511992102600705, 'commissionAdvertisingLog_add', '新增', 'add', '/cashAccount/userCommissionAdvertisingLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992102600707, 2016511992102600705, 'commissionAdvertisingLog_edit', '修改', 'edit', '/cashAccount/userCommissionAdvertisingLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992102600708, 2016511992102600705, 'commissionAdvertisingLog_delete', '删除', 'delete', '/api/blade-user-commissionadvertisinglog/commissionAdvertisingLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992102600709, 2016511992102600705, 'commissionAdvertisingLog_view', '查看', 'view', '/cashAccount/userCommissionAdvertisingLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994174586883, 2016511994174586882, 'commissionAgencyLog_add', '新增', 'add', '/cashAccount/userCommissionAgencyLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994174586884, 2016511994174586882, 'commissionAgencyLog_edit', '修改', 'edit', '/cashAccount/userCommissionAgencyLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994174586885, 2016511994174586882, 'commissionAgencyLog_delete', '删除', 'delete', '/api/blade-user-commissionagencylog/commissionAgencyLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994174586886, 2016511994174586882, 'commissionAgencyLog_view', '查看', 'view', '/cashAccount/userCommissionAgencyLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994694680578, 2016511994694680577, 'commissionCoCreatorLog_add', '新增', 'add', '/cashAccount/userCommissionCoCreatorLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994694680579, 2016511994694680577, 'commissionCoCreatorLog_edit', '修改', 'edit', '/cashAccount/userCommissionCoCreatorLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994694680580, 2016511994694680577, 'commissionCoCreatorLog_delete', '删除', 'delete', '/api/blade-user-commissioncocreatorlog/commissionCoCreatorLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994694680581, 2016511994694680577, 'commissionCoCreatorLog_view', '查看', 'view', '/cashAccount/userCommissionCoCreatorLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995218968579, 2016511995218968578, 'commissionDirectPushLog_add', '新增', 'add', '/cashAccount/userCommissionDirectPushLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995218968580, 2016511995218968578, 'commissionDirectPushLog_edit', '修改', 'edit', '/cashAccount/userCommissionDirectPushLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995218968581, 2016511995218968578, 'commissionDirectPushLog_delete', '删除', 'delete', '/api/blade-user-commissiondirectpushlog/commissionDirectPushLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995218968582, 2016511995218968578, 'commissionDirectPushLog_view', '查看', 'view', '/cashAccount/userCommissionDirectPushLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995743256578, 2016511995743256577, 'commissionGoodsCostLog_add', '新增', 'add', '/cashAccount/userCommissionGoodsCostLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995743256579, 2016511995743256577, 'commissionGoodsCostLog_edit', '修改', 'edit', '/cashAccount/userCommissionGoodsCostLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995743256580, 2016511995743256577, 'commissionGoodsCostLog_delete', '删除', 'delete', '/api/blade-user-commissiongoodscostlog/commissionGoodsCostLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995743256581, 2016511995743256577, 'commissionGoodsCostLog_view', '查看', 'view', '/cashAccount/userCommissionGoodsCostLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980631179267, 2016511980631179266, 'commissionLog_add', '新增', 'add', '/userPoint/userCommissionLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980631179268, 2016511980631179266, 'commissionLog_edit', '修改', 'edit', '/userPoint/userCommissionLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980631179269, 2016511980631179266, 'commissionLog_delete', '删除', 'delete', '/api/blade-user-commissionlog/commissionLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980631179270, 2016511980631179266, 'commissionLog_view', '查看', 'view', '/userPoint/userCommissionLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996863135746, 2016511996863135745, 'commissionServiceProviderLog_add', '新增', 'add', '/cashAccount/userCommissionServiceProviderLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996863135747, 2016511996863135745, 'commissionServiceProviderLog_edit', '修改', 'edit', '/cashAccount/userCommissionServiceProviderLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996863135748, 2016511996863135745, 'commissionServiceProviderLog_delete', '删除', 'delete', '/api/blade-user-commissionserviceproviderlog/commissionServiceProviderLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996863135749, 2016511996863135745, 'commissionServiceProviderLog_view', '查看', 'view', '/cashAccount/userCommissionServiceProviderLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997387423747, 2016511997387423746, 'commissionUserPointLog_add', '新增', 'add', '/cashAccount/userCommissionUserPointLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997387423748, 2016511997387423746, 'commissionUserPointLog_edit', '修改', 'edit', '/cashAccount/userCommissionUserPointLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997387423749, 2016511997387423746, 'commissionUserPointLog_delete', '删除', 'delete', '/api/blade-user-commissionuserpointlog/commissionUserPointLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997387423750, 2016511997387423746, 'commissionUserPointLog_view', '查看', 'view', '/cashAccount/userCommissionUserPointLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981159661571, 2016511981159661570, 'gainsDay_add', '新增', 'add', '/userPoint/userGainsDay/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981159661572, 2016511981159661570, 'gainsDay_edit', '修改', 'edit', '/userPoint/userGainsDay/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981159661573, 2016511981159661570, 'gainsDay_delete', '删除', 'delete', '/api/blade-user-gainsday/gainsDay/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981159661574, 2016511981159661570, 'gainsDay_view', '查看', 'view', '/userPoint/userGainsDay/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981612646403, 2016511981612646402, 'gainsDayLog_add', '新增', 'add', '/userPoint/userGainsDayLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981612646404, 2016511981612646402, 'gainsDayLog_edit', '修改', 'edit', '/userPoint/userGainsDayLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981612646405, 2016511981612646402, 'gainsDayLog_delete', '删除', 'delete', '/api/blade-user-gainsdaylog/gainsDayLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981612646406, 2016511981612646402, 'gainsDayLog_view', '查看', 'view', '/userPoint/userGainsDayLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992614305794, 2016511992614305793, 'genealogy_add', '新增', 'add', '/customer/userGenealogy/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992614305795, 2016511992614305793, 'genealogy_edit', '修改', 'edit', '/customer/userGenealogy/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992614305796, 2016511992614305793, 'genealogy_delete', '删除', 'delete', '/api/blade-user-genealogy/genealogy/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992614305797, 2016511992614305793, 'genealogy_view', '查看', 'view', '/customer/userGenealogy/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993197314050, 2016511993197314049, 'increaseDay_add', '新增', 'add', '/customer/userIncreaseDay/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993197314051, 2016511993197314049, 'increaseDay_edit', '修改', 'edit', '/customer/userIncreaseDay/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993197314052, 2016511993197314049, 'increaseDay_delete', '删除', 'delete', '/api/blade-user-increaseday/increaseDay/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993197314053, 2016511993197314049, 'increaseDay_view', '查看', 'view', '/customer/userIncreaseDay/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511978492084226, 2016511978492084225, 'levelLog_add', '新增', 'add', '/customer/userLevelLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511978492084227, 2016511978492084225, 'levelLog_edit', '修改', 'edit', '/customer/userLevelLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511978492084228, 2016511978492084225, 'levelLog_delete', '删除', 'delete', '/api/blade-userLevellog/levelLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511978492084229, 2016511978492084225, 'levelLog_view', '查看', 'view', '/customer/userLevelLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982136934402, 2016511982136934401, 'mallIntegral_add', '新增', 'add', '/userPoint/userMallIntegral/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982136934403, 2016511982136934401, 'mallIntegral_edit', '修改', 'edit', '/userPoint/userMallIntegral/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982136934404, 2016511982136934401, 'mallIntegral_delete', '删除', 'delete', '/api/blade-user-mallintegral/mallIntegral/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982136934405, 2016511982136934401, 'mallIntegral_view', '查看', 'view', '/userPoint/userMallIntegral/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982589919235, 2016511982589919234, 'mallIntegralLog_add', '新增', 'add', '/userPoint/userMallIntegralLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982589919236, 2016511982589919234, 'mallIntegralLog_edit', '修改', 'edit', '/userPoint/userMallIntegralLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982589919237, 2016511982589919234, 'mallIntegralLog_delete', '删除', 'delete', '/api/blade-user-mallintegrallog/mallIntegralLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982589919238, 2016511982589919234, 'mallIntegralLog_view', '查看', 'view', '/userPoint/userMallIntegralLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991016275970, 2016446167375052801, 'order', '用户订单', 'menu', '/order/userOrder', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991016275971, 2016511991016275970, 'order_add', '新增', 'add', '/order/userOrder/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991016275972, 2016511991016275970, 'order_edit', '修改', 'edit', '/order/userOrder/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991016275973, 2016511991016275970, 'order_delete', '删除', 'delete', '/api/blade-user-order/order/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991016275974, 2016511991016275970, 'order_view', '查看', 'view', '/order/userOrder/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985525932035, 2016511985525932034, 'packageInfo_add', '新增', 'add', '/userPackInfo/userPackageInfo/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985525932036, 2016511985525932034, 'packageInfo_edit', '修改', 'edit', '/userPackInfo/userPackageInfo/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985525932037, 2016511985525932034, 'packageInfo_delete', '删除', 'delete', '/api/blade-user-packageinfo/packageInfo/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985525932038, 2016511985525932034, 'packageInfo_view', '查看', 'view', '/userPackInfo/userPackageInfo/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986113134594, 2016511986113134593, 'packageInfoCopy_add', '新增', 'add', '/userPackInfo/userPackageInfoCopy/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986113134595, 2016511986113134593, 'packageInfoCopy_edit', '修改', 'edit', '/userPackInfo/userPackageInfoCopy/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986113134596, 2016511986113134593, 'packageInfoCopy_delete', '删除', 'delete', '/api/blade-user-packageinfocopy/packageInfoCopy/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986113134597, 2016511986113134593, 'packageInfoCopy_view', '查看', 'view', '/userPackInfo/userPackageInfoCopy/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983047098372, 2016511983047098369, 'performance_delete', '删除', 'delete', '/api/blade-user-performance/performance/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984091480068, 2016511984091480065, 'performanceBenefit_delete', '删除', 'delete', '/api/blade-user-performancebenefit/performanceBenefit/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984548659205, 2016511984548659202, 'performanceBenefitLog_delete', '删除', 'delete', '/api/blade-user-performancebenefitlog/performanceBenefitLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983634300933, 2016511983634300930, 'performanceLog_delete', '删除', 'delete', '/api/blade-user-performancelog/performanceLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993717407747, 2016511993717407746, 'tree_add', '新增', 'add', '/customer/userTree/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993717407748, 2016511993717407746, 'tree_edit', '修改', 'edit', '/customer/userTree/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993717407750, 2016511993717407746, 'tree_view', '查看', 'view', '/customer/userTree/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996271738882, 2016511996271738881, 'commissionOperationLog_add', '新增', 'add', '/cashAccount/userCommissionOperationLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996271738883, 2016511996271738881, 'commissionOperationLog_edit', '修改', 'edit', '/cashAccount/userCommissionOperationLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996271738884, 2016511996271738881, 'commissionOperationLog_delete', '删除', 'delete', '/api/blade-user-commissionoperationlog/commissionOperationLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996271738885, 2016511996271738881, 'commissionOperationLog_view', '查看', 'view', '/cashAccount/userCommissionOperationLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997844602885, 2016511997844602881, 'info_view', '查看', 'view', '/customer/appRegionsInfo/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997844602882, 2016511997844602881, 'info_add', '新增', 'add', '/customer/appRegionsInfo/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997844602883, 2016511997844602881, 'info_edit', '修改', 'edit', '/customer/appRegionsInfo/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993717407749, 2016511993717407746, 'tree_delete', '删除', 'delete', '/api/blade-user-tree/tree/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984091480069, 2016511984091480065, 'performanceBenefit_view', '查看', 'view', '/userPoint/userPerformanceBenefit/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984091480065, 2016446547672596482, 'performanceBenefit', '用户福利值业绩', 'menu', '/userPoint/userPerformanceBenefit', NULL, 11, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984091480067, 2016511984091480065, 'performanceBenefit_edit', '修改', 'edit', '/userPoint/userPerformanceBenefit/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984548659202, 2016446547672596482, 'performanceBenefitLog', '用户福利值业绩日志', 'menu', '/userPoint/userPerformanceLog', NULL, 13, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983047098371, 2016511983047098369, 'performance_edit', '修改', 'edit', '/userPoint/userPerformance/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984548659206, 2016511984548659202, 'performanceBenefitLog_view', '查看', 'view', '/userPoint/userPerformanceLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983634300934, 2016511983634300930, 'performanceLog_view', '查看', 'view', '/userPoint/userPerformanceLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984548659203, 2016511984548659202, 'performanceBenefitLog_add', '新增', 'add', '/userPoint/userPerformanceLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983634300931, 2016511983634300930, 'performanceLog_add', '新增', 'add', '/userPoint/userPerformanceLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996271738881, 2016445572647911425, 'commissionOperationLog', '5%运营佣金流水', 'menu', '/cashAccount/userCommissionOperationLog', NULL, 5, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984548659204, 2016511984548659202, 'performanceBenefitLog_edit', '修改', 'edit', '/userPoint/userPerformanceLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511984091480066, 2016511984091480065, 'performanceBenefit_add', '新增', 'add', '/userPoint/userPerformanceBenefit/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983634300932, 2016511983634300930, 'performanceLog_edit', '修改', 'edit', '/userPoint/userPerformanceLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983047098373, 2016511983047098369, 'performance_view', '查看', 'view', '/userPoint/userPerformance/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993717407746, 2016444412729917441, 'tree', '用户树结构', 'menu', '/customer/userTree', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997844602881, 2016444412729917441, 'info', '地区详情', 'menu', '/customer/appRegionsInfo', NULL, 6, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986113134593, 2016446332399943682, 'packageInfoCopy', '用户积分包详细信息', 'menu', '/userPackInfo/userPackageInfoCopy', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983634300930, 2016446547672596482, 'performanceLog', '用户现金业绩日志', 'menu', '/userPoint/userPerformanceLog', NULL, 10, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983047098370, 2016511983047098369, 'performance_add', '新增', 'add', '/userPoint/userPerformance/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016894266199486466, 2016445919294554113, 'category', '商品分类', 'menu', '/mall/category', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016894266199486467, 2016894266199486466, 'category_add', '新增', 'add', '/mall/category/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016894266199486468, 2016894266199486466, 'category_edit', '修改', 'edit', '/mall/category/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016894266199486469, 2016894266199486466, 'category_delete', '删除', 'delete', '/api/blade-category/category/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016894266199486470, 2016894266199486466, 'category_view', '查看', 'view', '/mall/category/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511999274860546, 2016446332399943682, 'ads', '广告', 'menu', '/userPackInfo/ads', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982136934401, 2016446547672596482, 'mallIntegral', '用户商城积分', 'menu', '/userPoint/userMallIntegral', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511991586701313, 2016445572647911425, 'commissionAccount', '用户佣金账户', 'menu', '/cashAccount/userCommissionAccount', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992614305793, 2016444412729917441, 'genealogy', '用户族谱', 'menu', '/customer/userGenealogy', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511996863135745, 2016445572647911425, 'commissionServiceProviderLog', '5%服务商佣金流水', 'menu', '/cashAccount/userCommissionServiceProviderLog', NULL, 7, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511985525932034, 2016446332399943682, 'packageInfo', '用户积分包信息', 'menu', '/userPackInfo/userPackageInfo', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511982589919234, 2016446547672596482, 'mallIntegralLog', '用户商城积分流水', 'menu', '/userPoint/userMallIntegralLog', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998809292801, 2016446547672596482, 'benefitLog', '用户福利值流水', 'menu', '/userPoint/userBenefitLog', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511998356307970, 2016446547672596482, 'cashLog', '用户现金券流水', 'menu', '/userPoint/userCashLog', NULL, 6, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511979599380482, 2016446547672596482, 'cash', '用户现金券', 'menu', '/userPoint/userCash', NULL, 5, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980115279873, 2016446547672596482, 'commission', '用户佣金', 'menu', '/userPoint/userCommission', NULL, 7, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511980631179266, 2016446547672596482, 'commissionLog', '用户佣金流水', 'menu', '/userPoint/userCommissionLog', NULL, 8, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511983047098369, 2016446547672596482, 'performance', '用户现金业绩', 'menu', '/userPoint/userPerformance', NULL, 9, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981159661570, 2016446547672596482, 'gainsDay', '用户每日加速福利值汇总', 'menu', '/userPoint/userGainsDay', NULL, 12, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511981612646402, 2016446547672596482, 'gainsDayLog', '用户每日加速福利值流水', 'menu', '/userPoint/userGainsDayLog', NULL, 14, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511986561925121, 2016444412729917441, 'level_info', '等级信息', 'menu', '/customer/levelInfo', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995743256577, 2016445572647911425, 'commissionGoodsCostLog', '25%商品成本佣金流水', 'menu', '/cashAccount/userCommissionGoodsCostLog', NULL, 2, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511995218968578, 2016445572647911425, 'commissionDirectPushLog', '10%直推人佣金流水', 'menu', '/cashAccount/userCommissionDirectPushLog', NULL, 4, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511993197314049, 2016444412729917441, 'increaseDay', '用户附加信息', 'menu', '/customer/userIncreaseDay', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511997387423746, 2016445572647911425, 'commissionUserPointLog', '30%购买人获取用户积分佣金流水', 'menu', '/cashAccount/userCommissionUserPointLog', NULL, 3, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987023298561, 2016444412729917441, 'dailySign', '用户看广告记录', 'menu', '/customer/userDailySign', NULL, 5, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511992102600705, 2016445572647911425, 'commissionAdvertisingLog', '5%广告补贴佣金流水', 'menu', '/cashAccount/userCommissionAdvertisingLog', NULL, 6, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994174586882, 2016445572647911425, 'commissionAgencyLog', '15%极差代理佣金流水', 'menu', '/cashAccount/userCommissionAgencyLog', NULL, 8, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511994694680577, 2016445572647911425, 'commissionCoCreatorLog', '5%联创佣金流水', 'menu', '/cashAccount/userCommissionCoCreatorLog', NULL, 9, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535723909122, 2016446332399943682, 'givePackLog', '划拨积分记录', 'menu', '/userPackInfo/givePackLog', NULL, 1, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535723909123, 2017499535723909122, 'givePackLog_add', '新增', 'add', '/userPackInfo/givePackLog/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535723909124, 2017499535723909122, 'givePackLog_edit', '修改', 'edit', '/userPackInfo/givePackLog/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535723909125, 2017499535723909122, 'givePackLog_delete', '删除', 'delete', '/api/blade-givepacklog/givePackLog/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535723909126, 2017499535723909122, 'givePackLog_view', '查看', 'view', '/userPackInfo/givePackLog/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499534536921090, 2017499534536921089, 'prizeSpu_add', '新增', 'add', '/mall/prizeSpu/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499534536921091, 2017499534536921089, 'prizeSpu_edit', '修改', 'edit', '/mall/prizeSpu/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499534536921092, 2017499534536921089, 'prizeSpu_delete', '删除', 'delete', '/api/blade-prizespu/prizeSpu/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499534536921093, 2017499534536921089, 'prizeSpu_view', '查看', 'view', '/mall/prizeSpu/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535132512258, 2017499535132512257, 'prizeSpuOrder_add', '新增', 'add', '/mall/prizeSpuOrder/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535132512259, 2017499535132512257, 'prizeSpuOrder_edit', '修改', 'edit', '/mall/prizeSpuOrder/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535132512260, 2017499535132512257, 'prizeSpuOrder_delete', '删除', 'delete', '/api/blade-prizespuorder/prizeSpuOrder/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535132512261, 2017499535132512257, 'prizeSpuOrder_view', '查看', 'view', '/mall/prizeSpuOrder/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987023298562, 2016511987023298561, 'dailySign_add', '新增', 'add', '/customer/userDailySign/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987023298563, 2016511987023298561, 'dailySign_edit', '修改', 'edit', '/customer/userDailySign/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987023298564, 2016511987023298561, 'dailySign_delete', '删除', 'delete', '/api/blade-dailysign/dailySign/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511987023298565, 2016511987023298561, 'dailySign_view', '查看', 'view', '/customer/userDailySign/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593495594790914, 2018593495594790913, 'banner_add', '新增', 'add', '/mall/banner/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593495594790915, 2018593495594790913, 'banner_edit', '修改', 'edit', '/mall/banner/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593495594790916, 2018593495594790913, 'banner_delete', '删除', 'delete', '/api/blade-banner/banner/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593495594790917, 2018593495594790913, 'banner_view', '查看', 'view', '/mall/banner/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593496119078914, 2018593496119078913, 'notice_add', '新增', 'add', '/customer/notice/add', 'plus', 1, 2, 1, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593495594790913, 2016445919294554113, 'banner', '首页轮播图', 'menu', '/mall/banner', NULL, 7, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593496119078913, 2016444412729917441, 'notice', '用户通知', 'menu', '/customer/notice', NULL, 8, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2016511978492084225, 2016444412729917441, 'levelLog', '用户等级日志', 'menu', '/customer/userLevelLog', NULL, 7, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593496119078915, 2018593496119078913, 'notice_edit', '修改', 'edit', '/customer/notice/edit', 'form', 2, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593496119078916, 2018593496119078913, 'notice_delete', '删除', 'delete', '/api/blade-notice/notice/remove', 'delete', 3, 2, 3, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2018593496119078917, 2018593496119078913, 'notice_view', '查看', 'view', '/customer/notice/view', 'file-text', 4, 2, 2, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499535132512257, 2016445919294554113, 'prizeSpuOrder', '奖池商品订单', 'menu', '/mall/prizeSpuOrder', NULL, 6, 1, 0, 1, NULL, NULL, 0);
INSERT INTO insert_blade_menu ("id", "parent_id", "code", "name", "alias", "path", "source", "sort", "category", "action", "is_open", "component", "remark", "is_deleted") VALUES (2017499534536921089, 2016445919294554113, 'prizeSpu', '奖池商品', 'menu', '/mall/prizeSpu', NULL, 5, 1, 0, 1, NULL, NULL, 0);

View File

@@ -1 +0,0 @@
INSERT INTO blade_oss ("id", "tenant_id", "category", "oss_code", "endpoint", "transform_endpoint", "access_key", "secret_key", "bucket_name", "app_id", "region", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017524776370114561, '000000', 3, 'alioss', 'https://oss-cn-beijing.aliyuncs.com', '', 'LTAI5tHgTPu3QbQkP3qPH8EM', 'UG1exiMCt31B6OoeSrw3BrW08izrJl', 'yicha1lu-app', '', '', '', 1123598821738675201, 1123598813738675201, '2026-01-31 17:06:05', 1123598821738675201, '2026-02-03 17:53:47.79', 2, 0);

View File

@@ -1,284 +0,0 @@
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2016775545220931585, 'app用户注册默认角色信息', 'yichayilu:app:register:role-info', '{"avatar":"https://tse1-mm.cn.bing.net/th/id/OIP-C.BM4bF8_qipHCQu014y_8UgAAAA?w=220&h=217&c=7&r=0&o=7&pid=1.7&rm=3","deptId":"1123598813738675201","postId":"1123598817738675208","roleId":"1123598816738675202"}', 'app用户注册默认角色信息-包含角色、部门、岗位、头像', NULL, NULL, '2026-01-29 15:28:54.508', NULL, '2026-01-29 15:28:54.508', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017183573497827329, '商城app订单类型', 'yichayilu:app:formal:order:model_type', '[{"code":"MALL","id":1,"name":"商城"}]', '商城app订单类型', NULL, NULL, '2026-01-30 18:30:16.033', NULL, '2026-01-30 18:30:16.033', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017184619259478018, '商城app订单现金兑换积分比例', 'yichayilu:app:formal:mall.cash.to.point.Rate', '0.3', '商城app订单现金兑换积分比例', NULL, NULL, '2026-01-30 18:34:25.363', NULL, '2026-01-30 18:34:25.363', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017185330957312002, '商城app随机立减比例范围', 'yichayilu:app:formal:mall.cut.amount.rang', '{"max":0.001,"min":0.01}', '商城app随机立减比例范围', NULL, NULL, '2026-01-30 18:37:15.043', NULL, '2026-01-30 18:37:15.043', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017186990513410049, '商城app支付类型', 'yichayilu:app:formal:pay.type', '{1:[{"code":"ALI","id":1,"name":"支付宝"},{"code":"WEI","id":2,"name":"微信"},{"code":"OFFLINE_PAY","id":3,"name":"线下支付"}]}', '商城app支付类型', NULL, NULL, '2026-01-30 18:43:50.713', NULL, '2026-01-30 18:43:50.713', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017835848230760450, '积分app是否看广告', 'yichayilu:app:dailysign.is.look.ads', 'true', '积分app是否看广告', NULL, NULL, '2026-02-01 13:42:10.446', NULL, '2026-02-01 13:42:10.446', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017836205065338882, '积分app看广告的时间范围', 'yichayilu:app:dailysign:watch.video.time.rang', '{"endTime":"22:00","startTime":"08:00"}', '积分app看广告的时间范围', NULL, NULL, '2026-02-01 13:43:35.522', NULL, '2026-02-01 13:43:35.522', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2018579715242532866, '商城app用户协议', 'yichayilu:app:formal:user:agreement', '商城app用户协议', '商城app用户协议', NULL, NULL, '2026-02-03 14:58:02.165', NULL, '2026-02-03 14:58:02.165', 1, 0);
INSERT INTO blade_param ("id", "param_name", "param_key", "param_value", "remark", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2016918730731626498, '商城app用户隐私政策', 'yichayilu:app:formal:user:privacy', '<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>成都心随云文化科技有限公司隐私政策</title>
<link rel="stylesheet" href="./css/style.css">
<link rel="stylesheet" href="https://unpkg.com/swiper/swiper-bundle.min.css" />
<!-- 引入样式 -->
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
<!-- 引入组件库 -->
<script src="https://unpkg.com/element-ui/lib/index.js"></script>
</head>
<style>
.privacy_policy{
margin-top: 50px;
}
.fly-text-color{
color: #ff0000;
font-weight: 700;
}
</style>
<body>
<!-- 头部 -->
<header>
<div id="menu-bar" class="el-icon-s-unfold"></div>
<a href="#" class="logo"><span>心</span>随云飘</a>
</header>
<section class="privacy_policy" id="privacy_policy">
<h2 style="text-align: center;">隐私政策(用户协议)</h3>
<h3 style="text-align: center;">发布日期: 2024 年 11 月 11 日</h3>
<h3 style="text-align: center;">生效日期: 2024 年 11 月 11 日</h3>
<p style=" margin-top: 50px"></p>
<span >&emsp;&emsp;【心随云飘】APP是由成都心随云文化科技有限公司开发,下文所有“我们”均指该公司。
如果您在【心随云飘】软件上或其他【心随云飘】提供的移动应用上进行访问,便视为您接受了以下隐私政策,请您仔细阅读以下内容,尤其是以下加粗字体。如果您不同意以下任何内容,请立刻停止访问/使用本app站或其他任何移动应用或软件。 “用户”以及“您”均指自愿接受本隐私政策的个体。<br></span>
<p style=" margin-top: 10px"></p>
<span >1、隐私政策的确认和接纳<br></span>
<span >&emsp;&emsp;尊重用户个人隐私是【心随云飘】的一项基本政策。【心随云飘】旅行攻略是将各旅行景区含餐饮、娱乐、洒店、出行、养生、教育、游戏信息汇集于【心随云飘】用户查阅,同时用户在浏览查阅同时即可获得平台产物。 您在使用我们的产品与 / 或服务前仔细阅读并确认您已经充分理解本隐私政策所写明的内容,并与成都心随云文化科技有限公司达成协议并接受所有的服务条款。<br></span>
<span >&emsp;&emsp;我们十分注重保护用户的个人信息及隐私安全,我们理解您通过【心随云飘】app向我们提供信息是建立在对我们信任的基础上,我们重视这种信任,也深知隐私对您的重要性,并尽最大努力全力保护您的隐私。<br></span>
<p style=" margin-top: 10px"></p>
<span >2 、信息收集<br></span>
<span >&emsp;&emsp;( 1 )为了更好地为您提供服务,【心随云飘】将遵循 “ 合理、相关、必要 ” 原则,且以您同意为前提收集信息,不会收集法律法规禁止收集的信息。考虑到【心随云飘】会员服务的重要性,用户同意,【心随云飘】将会收集您在【心随云飘】软件上输入的或者以其他方式提供给我们的所有信息,例如:<br></span>
&emsp;&emsp;①<span class="fly-text-color">在您注册为【心随云飘】会员时,需提供手机号码并设置密码,用以创建【心随云飘】账号。前述信息属于敏感信息,如果您拒绝提供,可能无法正常使用我们的服务。<br></span>
&emsp;&emsp;②<span class="fly-text-color">在您实名认证时,需提供身份证信息、人脸识别活体认证、银行卡信息或第三方支付机构信息以验证您的身份。前述信息属于敏感信息,如果您拒绝提供,可能无法正常使用我们的部分服务。<br></span>
&emsp;&emsp;③<span class="fly-text-color">在您购买产品时需要使用邮寄(发票、商品)服务时、需提供收货人的姓名、手机号、固定电话、配送地址信息,以便于您的订单能够送达。前述信息属于敏感信息,如果您拒绝提供,可能无法完成送达。<br></span>
&emsp;&emsp;④<span class="fly-text-color">在您购买产品进行支付结算时,需提供支付宝,微信,银行卡信息。前述信息属于敏感信息,如果您拒绝提供,可能无法完成支付。<br></span>
&emsp;&emsp;⑤<span class="fly-text-color">当您联系我们的客服以获得我们的客户服务时,您还需要提供您的会员资料来验证身份。其中可能涉及敏感信息,如果您拒绝提供,可能无法获得我们的客户服务。<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;( 2 )我们将在您使用【心随云飘】服务过程中,自动收集您的个人信息:<br></span>
<span >&emsp;&emsp;①日志信息,指您使用我们的服务时,系统可能通过cookies、app beacon或其他方式自动采集的信息,包括:<br></span>
<span >&emsp;&emsp;②设备信息或软件信息,例如您的IP地址和移动设备所用的版本和设备识别码(IDFA/IMEI)、移动设备用于接入我们服务的配置信息。这些是我们为提供服务必须收集的基础信息。<br></span>
<span >&emsp;&emsp;③在使用我们服务时搜索或浏览的信息,例如您使用的app页或app搜索词语、访问页面,以及您在使用我们服务时浏览或提供的其他信息。<br></span>
<span >&emsp;&emsp;④您通过我们的服务分享的内容所包含的信息,例如拍摄或上传的共享照片或评论,以及日期、时间。<br></span>
<span >&emsp;&emsp;⑤位置信息, 指您开启设备定位功能并使用我们基于位置提供的相关服务时,收集的有关您的位置信息,例如通过GPS或WLAN方式收集您的地理位置信息,或您提供账户信息中包含的您所在地区信息,您或其他人上传的显示您当前或曾经所处地理位置的共享信息。该信息属于敏感信息,您可以通过关闭定位功能,停止对您的地理位置信息的收集,但将无法使用我们提供的部分与位置信息相关的服务。<br></span>
<span >&emsp;&emsp;⑥传感器信息:在您使用App时,会获取方向传感器、陀螺仪设备传感器信息,用于鉴别您是否为真实用户。<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;(3)由于我们向您提供的产品和服务是不断更新的,如果某一产品或服务未在前述内容中说明且收集了您的信息,我们不会通过页面提示、交互流程、app站公告方式另行向您说明信息收集的内容,但您可以到个人中心隐私政策查看最新条款。该信息适用本隐私政策的约定。<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;(4)为识别您的设备并预防恶意程序及反作弊、提高服务安全性、保障运营质量及效率,我们会收集您的设备信息(设备序列号、OAID、MEID、AndroidID、IMSl、MAC、BSSID、SSID、WIFI、WIFI列表、MAC地址、收集软件列表、设备MAC地址、加速度传感器(BODY_SENSORS))、已安装APP信息(软件安装列表或软件列表)或运行中的进程信息。<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;(5)以上列明的基本为核心业务功能,对于第三方业务功能(例如第三方提供的金融业务功能)会通过页面提示、交互流程方式另行向您说明相应的个人信息收集和使用规则,并征得您的同意。<br></span>
<span class="fly-text-color">&emsp;&emsp;获取位置信息个人信息<br></span>
<span >&emsp;&emsp;用于附近店铺显示和当地天气数据获取<br></span>
<p style=" margin-top: 10px"></p>
<span class="fly-text-color">&emsp;&emsp;获取设备ID<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;在用户授权获取设备ID时, SDK根据不同系统分别调用不同的系统命令来获取设备ID,在 iOS 设备 中,SDK将会获取 IDFA ;在 Android 10以下版本的设备中,SDK将会获 取 IMEI 、 AndroidID ;在 Android 10以上版本的设备,SDK获取 OAID 。<br></span>
<p style=" margin-top: 10px"></p>
<span class="fly-text-color">&emsp;&emsp;获取设备GPS数据<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;在经过用户授权后,SDK将调用您设备的GPS接口,获取您的GPS坐标数据。<br></span>
<p style=" margin-top: 10px"></p>
<span class="fly-text-color">&emsp;&emsp;获取广告相关行为数据<br></span>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;在用户与广告进行交互时,如观看广告,点击广告链接等行为,SDK将会通过接口来获取这些数据。<br></span>
<p style=" margin-top: 20px"></p>
<h4>ADSet SDK隐私权限</h4>
<img src="./images/table/01.jpg" alt="" srcset="">
<p style=" margin-top: 20px"></p>
<h4>第三方SDK隐私权限</h4>
<span >&emsp;&emsp;AdSet SDK会调用其他SDK ,表为其他SDK隐私内容及隐私链接。<br></span>
<h4>高德地图 SDK</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/09.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<img src="./images/table/10.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<img src="./images/table/11.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<img src="./images/table/12.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<img src="./images/table/13.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<img src="./images/table/14.jpg" alt="" srcset="">
<h4>支付宝SDK(com.alipay.alipaysecuritysdk)</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/15.jpg" alt="" srcset="">
<h4>mPaaS</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/18.jpg" alt="" srcset="">
<h4>阿里乘车码</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/19.jpg" alt="" srcset="">
<h4>阿里芝麻信用实名认证</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/20.jpg" alt="" srcset="">
<h4>芝麻认证</h4>
<p style=" margin-top: 10px"></p>
<img src="./images/table/21.jpg" alt="" srcset="">
<h4>微信支付SDK</h4>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;为实现让用户在第三方应用中使用微信支付功能,<strong>我们会收集用户发起支付时第三方应用生成的微信支付订单标识并向微信APP传输,并在用户进行支付操作后向第三方应用传输本次支付是否成功的状态信息。</strong>请注意,微信支付功能由财付通支付科技有限公司(下称“财付通公司”)提供服务。<br></span>
<span >&emsp;&emsp;前述关于收集、使用个人信息的内容适用于iOS及Android系统。<br></span>
<span >&emsp;&emsp;特别说明,在Android系统中我们会验证用户设备上安装微信APP的状态,用于确认该设备是否能够实现Open SDK的相关能力,如设备上未安装微信APP,用户将无法使用微信Open SDK能力所实现的相关功能。<br></span>
<span >&emsp;&emsp;如用户使用iOS系统,为了在iOS系统设备中实现前述相关功能在不同设备下的表现适配,我们会收集用户的设备型号信息并保存在设备本地。<br></span>
<span >&emsp;&emsp;为实现SDK产品的相应功能所必需,在用户通过第三方应用使用微信Open SDK相关能力的过程中,我们会通过第三方应用申请以下权限:<br></span>
<span >&emsp;&emsp;如用户使用iOS系统,为了在iOS系统中实现前述相关功能所涉及的第三方应用与微信APP之间的信息传输,我们需调用iOS的剪切板权限,并在剪切板中写入、读取上述相关信息。<br></span>
<p style=" margin-top: 20px"></p>
<h4>阿里云金融及实人认证SDK</h4>
<p style=" margin-top: 10px"></p>
<h4>1、设备信息</h4>
<span >&emsp;&emsp;当您使用增强版实人认证时,为了确认SDK服务可用性和识别虚假设备,我们会获取最终用户的,<br></span>
<span >&emsp;&emsp;<strong>(1)设备基础信息:设备制造商、设备品牌、设备型号、设备名称、设备操作系统信息、设备配置信息、设备环境信息;</strong><br></span>
<span >&emsp;&emsp;<strong>(2)设备标识信息:Android ID、OAID、Google AID(Google广告ID)net.security.device,Android_ID,BODY_SENSORS ,READ_PHONE_STATE;</strong><br></span>
<span >&emsp;&emsp;<strong>(2)设备标识信息:Android ID、OAID、Google AID(Google广告ID)net.security.device,Android_ID,BODY_SENSORS ,READ_PHONE_STATE;</strong><br></span>
<span >&emsp;&emsp;<strong>(4)设备应用信息:SDK宿主APP信息(包括:应用名称、应用版本、安装时间)</strong><br></span>
<p style=" margin-top: 10px"></p>
<h4>2、最终用户上传的人脸及身份证图片</h4>
<span >&emsp;&emsp;在最终用户同意开启相机/摄像头权限后,我们会在您完成指定验证动作时,<strong>获取最终用户的人脸图片进行身份验证的比对。此外,当您使用实人认证OCR功能时,我们还将通过最终用户拍照上传的身份证图片获取最终用户的身份证字段信息,以进行安全验证。</strong>您及最终用户知晓,即使最终用户已同意开启相机权限,我们也仅会在您主动点击客户端内相机图标或录制视频时通过相机获取照片信息。<br></span>
<p style=" margin-top: 10px"></p>
<h4>3、终端权限信息</h4>
<span >&emsp;&emsp;为保障产品功能实现与安全稳定运行目的,我们可能会申请或使用最终用户操作系统的相关权限。<br></span>
<p style=" margin-top: 10px"></p>
<h4>4、日志信息</h4>
<span >&emsp;&emsp;当您使用我们增强版实人认证时,我们会自动收集您对我们服务的详细使用情况,作为有关操作日志保存,<strong>包括您的操作参数、操作时间、服务响应时间、操作步骤、验证结果、错误原因。</strong><br></span>
<p style=" margin-top: 20px"></p>
<h4>安卓操作系统应用权限列表</h4>
<img src="./images/table/16.jpg" alt="" srcset="">
<p style=" margin-top: 10px"></p>
<h4>iOS 操作系统应用权限列表</h4>
<img src="./images/table/17.jpg" alt="" srcset="">
<h4>讯飞SDK</h4>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;权限:设备号(IMEI号)、设备码(IMSI码)、IP地址、Android ID(安卓唯一设备ID)、中国移动UAID(仅限安卓设备)、OAID(仅限安卓设备)、UUID(仅限iOS设备)<br></span>
<span >&emsp;&emsp;是否不选:必选<br></span>
<span >&emsp;&emsp;申请目的:提供语音输入后的语音转文字、语音合成、语音评测服务。<br></span>
<span >&emsp;&emsp;权限:网络权限、麦克风权限<br></span>
<p style=" margin-top: 20px"></p>
<h4>3 、信息使用</h4>
<span >&emsp;&emsp;( 1 )一般来说,【心随云飘】出于以下目的收集、使用您的个人信息:<br></span>
&emsp;&emsp;①<span class="fly-text-color">账号管理:</span><span >您可以通过【心随云飘】APP创建账号,我们将使用您所提供的信息来管理您的账号,并为您提供一系列的实用功能,您可以使用您的账号进行多种操作,如管理订单、调整个人设置、查看历史订单信息、支付管理。<br></span>
&emsp;&emsp;②<span class="fly-text-color">答复您的问询和请求:</span><span >我们向您提供客户服务,以便在您需要的时候提供帮助。<br></span>
&emsp;&emsp;③<span class="fly-text-color">与您联系:</span><span >回复及处理您所提出的疑问或要求、发送与订单相关的信息、我们也可能会向您发送问卷调查或邀请您对我们的服务提供反馈。<br></span>
&emsp;&emsp;④<span class="fly-text-color">市场调研:</span><span >我们有时会邀请您参与市场调查,以衡量您对我们的产品、服务和app站的兴趣。<br></span>
<!-- &emsp;&emsp;⑤<span class="fly-text-color">数据分析:我们可能将您的数据用于分析,从而形成用户画像,以便让我们能够了解您所在的位置、偏好和人口统计信息,或与其他来源(包括第三方)的数据相匹配,从而开发我们的产品、服务或营销计划,改进我们的服务<br></span> -->
&emsp;&emsp;⑤<span class="fly-text-color">控制信用风险:</span><span >为了确保交易安全,【心随云飘】及关联公司、业务合作伙伴可能对用户信息进行数据分析,并对上述分析结果进行商业利用。<br></span>
&emsp;&emsp;⑥<span class="fly-text-color">日常运营:</span><span >包括但不限于订单管理、客户验证、技术支持、app络维护、故障排除、内部行政事务及内部政策和程序、生成内部报告。<br></span>
&emsp;&emsp;⑦<span class="fly-text-color">电话监测:</span><span >您接听和拨打我们的客服电话可能会被录音,我们可能会使用通话录音来监控我们的客服服务质量,检查您所提供的信息的准确性以防止欺诈,或为了我们内部人员培训的目的。录音在被保留一段时间后会自动删除,除非由于合规要求或合法利益需要为场景的保留<br></span>
&emsp;&emsp;⑧<span class="fly-text-color">法律目的:</span><span >我们可能需要使用您的信息来处理和解决法律纠纷,或遵循对我们具有约束力的任何法律法规或监管机构颁发的文件规定,以配合国家部门或监管机构调查和遵从法律法规的目的。<br></span>
<span >&emsp;&emsp;此外,我们可能会出于其他目的收集、使用和披露您的个人信息,并通过修订本声明的形式告知您。<br></span>
<span >&emsp;&emsp;如要改变个人信息的处理目的,我们将以推送通知方式再次征求您的授权同意。 <br></span>
<p style=" margin-top: 10px"></p>
<h4>( 2 )您充分知晓,以下情形中我们使用个人信息无需征得您的授权同意:</h4>
<span >&emsp;&emsp;①与国家安全、国防安全有关的;<br></span>
<span >&emsp;&emsp;②与公共安全、公共卫生、重大公共利益有关的;<br></span>
<span >&emsp;&emsp;③与犯罪侦查、起诉、审判和判决执行有关的;<br></span>
<span >&emsp;&emsp;④出于维护个人信息主体或其他个人的生命、财产重大合法权益但又很难得到本人同意的;<br></span>
<span >&emsp;&emsp;⑤所收集的个人信息是个人信息主体自行向社会公众公开的;<br></span>
<span >&emsp;&emsp;⑥从合法公开披露的信息中收集的您的个人信息的,如合法的新闻报道、政府信息公开渠道;<br></span>
<span >&emsp;&emsp;⑦用于维护所提供的产品与/或服务的安全稳定运行所必需的,例如发现、处置产品与/或服务的故障;<br></span>
<span >&emsp;&emsp;⑧为合法的新闻报道所必需的;<br></span>
<span >&emsp;&emsp;⑨学术研究机构基于公共利益开展统计或学术研究所必要,且对外提供学术研究或描述的结果时,对结果中所包含的个人信息进行去标识化处理的;<br></span>
<span >&emsp;&emsp;⑩法律法规规定的其他情形。<br></span>
<p style=" margin-top: 20px"></p>
<h4>4 、信息保存</h4>
<p style=" margin-top: 10px"></p>
<h4>(1)我们仅在本政策所述目的所必需期间和法律法规及监管规定的时限内保存您的个人信息。如我们停止运营【心随云飘】APP产品或服务,我们将及时停止继续收集您个人信息的活动,将停止运营的通知以逐一送达或公告的形式通知您,对所持有的个人信息进行删除或匿名化处理。</h4>
<p style=" margin-top: 10px"></p>
<h4>( 2 )您充分知晓,以下情形中我们使用个人信息无需征得您的授权同意:</h4>
<span >&emsp;&emsp;①法律法规有明确规定;<br></span>
<span >&emsp;&emsp;②获得您的明确授权<br></span>
<span >&emsp;&emsp;③您通过互联app进行跨境交易个人主动行为。<br></span>
<p style=" margin-top: 20px"></p>
<h4>5 、个人敏感信息提示</h4>
<span >&emsp;&emsp;某些特殊的个人信息可能被认为是个人敏感信息,这些个人敏感信息将受到严格保护。【心随云飘】隐私政策在此提醒您,您在使用【心随云飘】为您提供的产品及服务中所上传或发布的内容和信息可能会披露泄露您的个人敏感信息。 因此,您需要在使用我们为您提供的产品或服务前谨慎考虑。您同意这些个人敏感信息将按照本隐私政策阐明的目的和方式来进行处理。;<br></span>
<p style=" margin-top: 20px"></p>
<h4>6 、信息安全与保护</h4>
<p style=" margin-top: 10px"></p>
<span >&emsp;&emsp;(1)【心随云飘】非常重视信息安全,成立了专门的负责团队。<br></span>
<span >&emsp;&emsp;(2)我们从数据的生命周期角度出发,在数据收集、存储、显示、处理、使用、销毁各个环节建立了安全防护措施,根据信息敏感程度的级别采取不同的控制措施,包括但不限于访问控制、SSL加密传输、AES256bit或以上强度的加密算法进行加密存储。<br></span>
<span >&emsp;&emsp;(3)尽管有前述的安全措施,但同时也请您理解在app络上不存在“完善的安全措施”。我们会按现有的技术提供相应的安全措施来保护您的信息,提供合理的安全保障,我们将尽力做到使您的信息不被泄露、损毁或丢失。<br></span>
<span >&emsp;&emsp;(4)您的账户均有安全保护功能,请妥善保管您的账号及密码信息,切勿将密码告知他人,如果您发现自己的个人信息泄露,特别是您的账号和密码发生泄露,请您立即与我们的客服联系,以便我们采取相应的措施。;<br></span>
<span >&emsp;&emsp;(5)请您及时保存或备份您的文字、图片其他信息,您需理解并接受,您接入我们的服务所用的系统和通讯app络,有可能因我们可控范围外的因素而出现问题。<br></span>
<p style=" margin-top: 20px"></p>
<h4>7 、信息安全事件处置</h4>
<span >&emsp;&emsp;在不幸发生个人信息安全事件后,我们会启动应急预案,同时按照法律法规的要求向您告知:安全事件的基本情况和可能的影响、我们已采取或将要采取的处置措施、您可自主防范和降低风险的建议、对您的补救措施。事件相关情况我们将以推送通知方式告知您,难以逐一告知个人信息主体时,我们会采取合理、有效的方式发布公告。同时,我们还将按照监管部门要求,上报个人信息安全事件的处置情况。<br></span>
<p style=" margin-top: 20px"></p>
<h4>8 、用户个人信息管理</h4>
<span >&emsp;&emsp;(1)您可以随时登录【心随云飘】旅行攻略,查询、更正、删除自己的账户信息;修改个人资料、隐私设置、安全设置;修改地址、常用联系人信息使用【心随云飘】服务时您提供的个人信息。操作过程中如有问题,可以联系【心随云飘】客服。<br></span>
<span >&emsp;&emsp;(2)您可以通过删除您的个人信息、关闭设备功能、修改个人设置方式改变您授权我们继续收集个人信息的范围或撤回您的授权。<br></span>
<p style=" margin-top: 20px"></p>
<h4>9、从中国大陆地区以外访问我们的 app 站</h4>
<span >&emsp;&emsp;如果您是中国大陆以外地区的公民,或者从中国大陆以外地区访问我们的 app 站,请您注意,您的信息可能被传送至、存储于中国大陆,并且在中国大陆进行处理。中国大陆的数据保护法和其他法律可能与您所在国家 / 地区的法律不同,您继续使用我们的服务,意味着放弃适用您所在国家 / 地区的法律。选择使用我们的服务的同时,您了解并同意您的信息可能被传送至我们的 app 站,并如本隐私政策所述的与我们共享信息的第三方。<br></span>
<p style=" margin-top: 20px"></p>
<h4>10 、隐私政策的适用范围</h4>
<span >&emsp;&emsp;除某些特定服务外,我们所有的服务均适用本隐私政策。特定服务将适用特定的隐私政策。该特定服务的隐私政策构成本隐私政策的一部分。如任何特定服务的隐私政策与本隐私政策有不一致之处,则适用特定服务的隐私政策。请您注意,本隐私政策不适用于以下情况:通过我们的服务而接入的第三方服务(包括任何第三方app站)收集的信息;通过在我们服务中进行广告服务的其他公司和机构所收集的信息。<br></span>
<p style=" margin-top: 20px"></p>
<h4>11 、隐私政策的修改</h4>
<span >&emsp;&emsp;【心随云飘】会在必要时修改隐私政策,请您理解,我们可能会适时修订本隐私政策,我们将标注本隐私政策最近更新的日期。未经您明确同意,【心随云飘】不会减少您按照本隐私权政策所应享有的权利。对于重大变更,请您经常回访本隐私政策,以阅读最新版本。<br></span>
<p style=" margin-top: 20px"></p>
<h4>12 、如何联系我们</h4>
<span >&emsp;&emsp;如您有任何与个人信息保护或隐私保护相关的问题、意见或建议,以及相关的投诉、举报,您可以通过访问在线客服系统,或拨打【心随云飘】主页公示的客服电话与我们联系。一般情况下,我们将在核验您的身份无误后三十日内回复(联系方式:028-85109076)。<br></span>
<p style=" margin-top: 20px"></p>
<h4>13 、法律管辖</h4>
<span >&emsp;&emsp;本隐私政策之效力、解释、变更、执行与争议解决均适用中华人民共和国法律。因本协议产生的争议,均应依照中华人民共和国法律予以处理,并由被告住所地人民法院管辖。<br></span>
<p style=" margin-top: 20px"></p>
<h4>14、用户账号注销</h4>
<span >&emsp;&emsp;本平台用户可在APP“我的”页面点击头像进入“个人信息”页面,注销个人账号。<br></span>
</body>
</html>
', '商城app用户隐私政策', NULL, NULL, '2026-01-30 00:57:52.597', NULL, '2026-01-30 00:57:52.597', 1, 0);

View File

@@ -1,5 +0,0 @@
INSERT INTO level_info ("id", "name", "child_qty", "performance", "performance_benefit", "next_level_id", "is_lowest", "is_highest", "bonus_cash_day", "bonus_cash_all", "bonus_benefit", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (1, '社区经销商', 10, '10000.0000', '100000.0000', 2, 0, 0, '0.0500', '0.0000', '0.0800', 1, 1123598821738675201, 1123598813738675201, '2026-01-30 22:54:56.006', 1123598821738675201, '2026-01-30 22:54:56.006', 1, 0);
INSERT INTO level_info ("id", "name", "child_qty", "performance", "performance_benefit", "next_level_id", "is_lowest", "is_highest", "bonus_cash_day", "bonus_cash_all", "bonus_benefit", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (0, '普通用户', 0, '0.0000', '0.0000', 1, 1, 0, '0.0000', '0.0000', '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-30 22:54:56.006', 1123598821738675201, '2026-01-30 22:54:56.006', 1, 0);
INSERT INTO level_info ("id", "name", "child_qty", "performance", "performance_benefit", "next_level_id", "is_lowest", "is_highest", "bonus_cash_day", "bonus_cash_all", "bonus_benefit", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2, '社区经销商', 20, '1000000.0000', '1000000.0000', 3, 0, 0, '0.0500', '0.0000', '0.0600', 1, 1123598821738675201, 1123598813738675201, '2026-01-30 22:54:56.006', 1123598821738675201, '2026-01-30 22:54:56.006', 1, 0);
INSERT INTO level_info ("id", "name", "child_qty", "performance", "performance_benefit", "next_level_id", "is_lowest", "is_highest", "bonus_cash_day", "bonus_cash_all", "bonus_benefit", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (3, '社区经销商', 30, '5000000.0000', '5000000.0000', 4, 0, 0, '0.0500', '0.0000', '0.0400', 1, 1123598821738675201, 1123598813738675201, '2026-01-30 22:54:56.006', 1123598821738675201, '2026-01-30 22:54:56.006', 1, 0);
INSERT INTO level_info ("id", "name", "child_qty", "performance", "performance_benefit", "next_level_id", "is_lowest", "is_highest", "bonus_cash_day", "bonus_cash_all", "bonus_benefit", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (4, '社区经销商', 40, '20000000.0000', '20000000.0000', NULL, 0, 1, '0.0000', '0.0500', '0.0200', 1, 1123598821738675201, 1123598813738675201, '2026-01-30 22:54:56.006', 1123598821738675201, '2026-01-30 22:54:56.006', 1, 0);

View File

@@ -1,8 +0,0 @@
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017485441885196290, '商品成本账户', 'COMMISSION_GOODS_COST', '', '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:29:47', 1123598821738675201, '2026-01-31 14:30:16.04', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017485893100032002, '分发商城积分账户', 'COMMISSION_USER_POINT_LOG', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:31:34.663', 1123598821738675201, '2026-01-31 14:31:34.663', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486037128237058, '分发直推人佣金账户', 'COMMISSION_DIRECT_PUSH', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:32:08.998', 1123598821738675201, '2026-01-31 14:32:08.998', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486179294171138, '运营账户', 'COMMISSION_OPERATION', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:32:42.889', 1123598821738675201, '2026-01-31 14:32:42.889', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486299502923778, '分发广告补贴账户', 'COMMISSION_ADVERTISING', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:33:11.552', 1123598821738675201, '2026-01-31 14:33:11.552', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486437340336130, '分发服务商佣金账户', 'COMMISSION_SERVICE_PROVIDER', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:33:44.407', 1123598821738675201, '2026-01-31 14:33:44.407', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486568441696258, '分发极差代理佣金账户', 'COMMISSION_AGENCY', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:34:15.663', 1123598821738675201, '2026-01-31 14:34:15.663', 1, 0);
INSERT INTO user_commission_account ("id", "account_name", "account_number", "account_code", "amount", "version", "create_user", "create_dept", "create_time", "update_user", "update_time", "status", "is_deleted") VALUES (2017486664117964802, '联创佣金账户', 'COMMISSION_CO_CREATOR', NULL, '0.0000', 1, 1123598821738675201, 1123598813738675201, '2026-01-31 14:34:38.479', 1123598821738675201, '2026-01-31 14:34:38.479', 1, 0);

File diff suppressed because it is too large Load Diff

38
pom.xml
View File

@@ -233,10 +233,10 @@
<artifactId>blade-starter-powerjob</artifactId> <artifactId>blade-starter-powerjob</artifactId>
</dependency> </dependency>
<!-- 工作流 --> <!-- 工作流 -->
<dependency> <!-- <dependency>-->
<groupId>org.springblade</groupId> <!-- <groupId>org.springblade</groupId>-->
<artifactId>blade-starter-flowable</artifactId> <!-- <artifactId>blade-starter-flowable</artifactId>-->
</dependency> <!-- </dependency>-->
<!-- auto --> <!-- auto -->
<dependency> <dependency>
<groupId>org.springblade</groupId> <groupId>org.springblade</groupId>
@@ -264,36 +264,6 @@
<version>2.0.0</version> <version>2.0.0</version>
</dependency> </dependency>
<dependency>
<groupId>cn.hutool</groupId>
<artifactId>hutool-all</artifactId>
<version>5.8.40</version>
</dependency>
<dependency>
<groupId>com.xuxueli</groupId>
<artifactId>xxl-job-core</artifactId>
<version>3.3.2</version>
<exclusions>
<exclusion>
<groupId>io.netty</groupId>
<artifactId>netty-codec-http</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct</artifactId>
<version>${mapstruct.version}</version>
</dependency>
<dependency>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct-processor</artifactId>
<version>${mapstruct.version}</version>
</dependency>
</dependencies> </dependencies>

View File

@@ -1,121 +0,0 @@
package org.springblade.common.config;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.task.AsyncTaskExecutor;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import java.util.concurrent.ThreadPoolExecutor;
@Configuration
@Slf4j
public class AsyncConfiguration {
private static final int CORE_POOL_SIZE = Runtime.getRuntime().availableProcessors();
private static final int MAX_POOL_SIZE = CORE_POOL_SIZE * 2;
private static final int QUEUE_CAPACITY = 500;
private static final int KEEP_ALIVE_SECONDS = 60;
private static final int AWAIT_TERMINATION_SECONDS = 60;
@Bean("common")
public AsyncTaskExecutor commonAsyncExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setCorePoolSize(CORE_POOL_SIZE);
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setMaxPoolSize(MAX_POOL_SIZE);
//缓冲队列500:用来缓冲执行任务的队列
executor.setQueueCapacity(QUEUE_CAPACITY);
//允许线程的空闲时间60秒:当超过了核心线程出之外的线程在空闲时间到达之后会被销毁
executor.setKeepAliveSeconds(KEEP_ALIVE_SECONDS);
// CallerRunsPolicy策略:如果添加到线程池失败,那么主线程会自己去执行该任务,不会等待线程池中的线程去执行。
//当提交的任务个数大于QueueCapacity,就需要设置该参数,但spring提供的都不太满足业务场景,可以自定义一个,也可以注意不要超过QueueCapacity即可
executor.setRejectedExecutionHandler(new ThreadPoolExecutor.CallerRunsPolicy());
//调度器shutdown被调用时等待当前被调度的任务完成
executor.setWaitForTasksToCompleteOnShutdown(true);
//等待时长
executor.setAwaitTerminationSeconds(AWAIT_TERMINATION_SECONDS);
//线程池名的前缀:设置好了之后可以方便我们定位处理任务所在的线程池
executor.setThreadNamePrefix("common-Async-");
executor.initialize();
return executor;
}
@Bean("appRegisterExecutor")
public AsyncTaskExecutor appRegisterExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setCorePoolSize(CORE_POOL_SIZE);
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setMaxPoolSize(MAX_POOL_SIZE);
//缓冲队列500:用来缓冲执行任务的队列
executor.setQueueCapacity(QUEUE_CAPACITY);
//允许线程的空闲时间60秒:当超过了核心线程出之外的线程在空闲时间到达之后会被销毁
executor.setKeepAliveSeconds(KEEP_ALIVE_SECONDS);
// CallerRunsPolicy策略:如果添加到线程池失败,那么主线程会自己去执行该任务,不会等待线程池中的线程去执行。
//当提交的任务个数大于QueueCapacity,就需要设置该参数,但spring提供的都不太满足业务场景,可以自定义一个,也可以注意不要超过QueueCapacity即可
executor.setRejectedExecutionHandler(new ThreadPoolExecutor.CallerRunsPolicy());
//调度器shutdown被调用时等待当前被调度的任务完成
executor.setWaitForTasksToCompleteOnShutdown(true);
//等待时长
executor.setAwaitTerminationSeconds(AWAIT_TERMINATION_SECONDS);
//线程池名的前缀:设置好了之后可以方便我们定位处理任务所在的线程池
executor.setThreadNamePrefix("appRegister-Async-");
executor.initialize();
return executor;
}
@Bean("appRevokedExecutor")
public AsyncTaskExecutor appRevokedExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setCorePoolSize(CORE_POOL_SIZE);
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setMaxPoolSize(MAX_POOL_SIZE);
//缓冲队列500:用来缓冲执行任务的队列
executor.setQueueCapacity(QUEUE_CAPACITY);
//允许线程的空闲时间60秒:当超过了核心线程出之外的线程在空闲时间到达之后会被销毁
executor.setKeepAliveSeconds(KEEP_ALIVE_SECONDS);
// CallerRunsPolicy策略:如果添加到线程池失败,那么主线程会自己去执行该任务,不会等待线程池中的线程去执行。
//当提交的任务个数大于QueueCapacity,就需要设置该参数,但spring提供的都不太满足业务场景,可以自定义一个,也可以注意不要超过QueueCapacity即可
executor.setRejectedExecutionHandler(new ThreadPoolExecutor.CallerRunsPolicy());
//调度器shutdown被调用时等待当前被调度的任务完成
executor.setWaitForTasksToCompleteOnShutdown(true);
//等待时长
executor.setAwaitTerminationSeconds(AWAIT_TERMINATION_SECONDS);
//线程池名的前缀:设置好了之后可以方便我们定位处理任务所在的线程池
executor.setThreadNamePrefix("appRevoked-Async-");
executor.initialize();
return executor;
}
@Bean("appUserOrderrExecutor")
public AsyncTaskExecutor appUserOrderrExecutor() {
ThreadPoolTaskExecutor executor = new ThreadPoolTaskExecutor();
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setCorePoolSize(CORE_POOL_SIZE);
//核心线程数 cpuNum:线程池创建时候初始化的线程数
executor.setMaxPoolSize(MAX_POOL_SIZE);
//缓冲队列500:用来缓冲执行任务的队列
executor.setQueueCapacity(QUEUE_CAPACITY);
//允许线程的空闲时间60秒:当超过了核心线程出之外的线程在空闲时间到达之后会被销毁
executor.setKeepAliveSeconds(KEEP_ALIVE_SECONDS);
// CallerRunsPolicy策略:如果添加到线程池失败,那么主线程会自己去执行该任务,不会等待线程池中的线程去执行。
//当提交的任务个数大于QueueCapacity,就需要设置该参数,但spring提供的都不太满足业务场景,可以自定义一个,也可以注意不要超过QueueCapacity即可
executor.setRejectedExecutionHandler(new ThreadPoolExecutor.CallerRunsPolicy());
//调度器shutdown被调用时等待当前被调度的任务完成
executor.setWaitForTasksToCompleteOnShutdown(true);
//等待时长
executor.setAwaitTerminationSeconds(AWAIT_TERMINATION_SECONDS);
//线程池名的前缀:设置好了之后可以方便我们定位处理任务所在的线程池
executor.setThreadNamePrefix("appUserOrderr-Async-");
executor.initialize();
return executor;
}
}

View File

@@ -67,7 +67,6 @@ public class BladeConfiguration implements WebMvcConfigurer {
"/blade-flow/process/resource-view", "/blade-flow/process/resource-view",
"/blade-flow/process/diagram-view", "/blade-flow/process/diagram-view",
"/blade-flow/manager/check-upload", "/blade-flow/manager/check-upload",
"/blade-resource/sms/endpoint/send-validate",
"/doc.html", "/doc.html",
"/swagger-ui.html", "/swagger-ui.html",
"/static/**", "/static/**",

View File

@@ -1,25 +0,0 @@
package org.springblade.common.config;
import com.baomidou.mybatisplus.annotation.DbType;
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.OptimisticLockerInnerInterceptor;
import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Configuration
public class MybatisPlusConfig {
/**
* mybatis-plus.分页插件
* @return interceptor
*/
@Bean
public MybatisPlusInterceptor mybatisPlusInterceptor() {
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
interceptor.addInnerInterceptor(new PaginationInnerInterceptor(DbType.POSTGRE_SQL));
interceptor.addInnerInterceptor(new OptimisticLockerInnerInterceptor());
return interceptor;
}
}

View File

@@ -1,52 +0,0 @@
package org.springblade.common.config;
import com.xxl.job.core.executor.impl.XxlJobSpringExecutor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
@Slf4j
@Configuration
public class XxlJobConfig {
@Value("${xxl.job.admin.addresses}")
private String adminAddresses;
@Value("${xxl.job.accessToken}")
private String accessToken;
@Value("${xxl.job.executor.appname}")
private String appname;
@Value("${xxl.job.executor.address}")
private String address;
@Value("${xxl.job.executor.ip}")
private String ip;
@Value("${xxl.job.executor.port}")
private int port;
@Value("${xxl.job.executor.logpath}")
private String logPath;
@Value("${xxl.job.executor.logretentiondays}")
private int logRetentionDays;
@Bean
public XxlJobSpringExecutor xxlJobExecutor() {
XxlJobSpringExecutor xxlJobSpringExecutor = new XxlJobSpringExecutor();
xxlJobSpringExecutor.setAdminAddresses(adminAddresses);
xxlJobSpringExecutor.setAppname(appname);
xxlJobSpringExecutor.setAddress(address);
xxlJobSpringExecutor.setIp(ip);
xxlJobSpringExecutor.setPort(port);
xxlJobSpringExecutor.setAccessToken(accessToken);
xxlJobSpringExecutor.setLogPath(logPath);
xxlJobSpringExecutor.setLogRetentionDays(logRetentionDays);
return xxlJobSpringExecutor;
}
}

View File

@@ -90,4 +90,9 @@ public interface CommonConstant {
Integer API_SCOPE_CATEGORY = 2; Integer API_SCOPE_CATEGORY = 2;
String USER_DEFAULT_DEPT = "user.default.dept";
String USER_DEFAULT_POST = "user.default.post";
String USER_DEFAULT_ROLE = "user.default.role";
} }

View File

@@ -1,116 +0,0 @@
package org.springblade.common.handler;
import lombok.extern.slf4j.Slf4j;
import org.apache.ibatis.type.BaseTypeHandler;
import org.apache.ibatis.type.JdbcType;
import java.sql.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Objects;
@Slf4j
public class PostgresLongArrayTypeHandler extends BaseTypeHandler<List<Long>> {
@Override
public void setNonNullParameter(PreparedStatement ps, int i, List<Long> parameter, JdbcType jdbcType) throws SQLException {
java.sql.Array array = ps.getConnection().createArrayOf("bigint", parameter.toArray());
ps.setArray(i, array);
}
@Override
public List<Long> getNullableResult(ResultSet rs, String columnName) throws SQLException {
Object obj = rs.getObject(columnName);
return convertObjectToList(obj);
}
@Override
public List<Long> getNullableResult(ResultSet rs, int columnIndex) throws SQLException {
Object obj = rs.getObject(columnIndex);
return convertObjectToList(obj);
}
@Override
public List<Long> getNullableResult(CallableStatement cs, int columnIndex) throws SQLException {
Object obj = cs.getObject(columnIndex);
return convertObjectToList(obj);
}
private List<Long> convertObjectToList(Object obj) {
if (obj == null) {
return new ArrayList<>(); // 修改:返回空列表而不是null
}
// 处理 List 类型
if (obj instanceof List<?> rawList) {
return rawList.stream()
.filter(Objects::nonNull)
.map(this::convertToLong)
.collect(java.util.stream.Collectors.toList());
}
// 处理数组类型
if (obj.getClass().isArray()) {
Object[] array = (Object[]) obj;
return Arrays.stream(array)
.filter(Objects::nonNull)
.map(this::convertToLong)
.collect(java.util.stream.Collectors.toList());
}
// 处理 SQL Array 类型
if (obj instanceof Array sqlArray) {
try {
Object[] array = (Object[]) sqlArray.getArray();
return Arrays.stream(array)
.filter(Objects::nonNull)
.map(this::convertToLong)
.collect(java.util.stream.Collectors.toList());
} catch (SQLException e) {
return new ArrayList<>();
}
}
// 处理 PostgreSQL 数组字符串格式
if (obj instanceof String) {
return parsePostgreSQLArrayString((String) obj);
}
return new ArrayList<>();
}
private List<Long> parsePostgreSQLArrayString(String arrayStr) {
if (arrayStr == null || !arrayStr.startsWith("{") || !arrayStr.endsWith("}")) {
return new ArrayList<>();
}
String content = arrayStr.substring(1, arrayStr.length() - 1);
if (content.trim().isEmpty()) {
return new ArrayList<>();
}
String[] elements = content.split(",");
return Arrays.stream(elements)
.map(String::trim)
.filter(s -> !s.isEmpty() && !"null".equalsIgnoreCase(s))
.map(this::convertToLong)
.collect(java.util.stream.Collectors.toList());
}
private Long convertToLong(Object obj) {
if (obj instanceof Long) {
return (Long) obj;
} else if (obj instanceof Number) {
return ((Number) obj).longValue();
} else if (obj instanceof String) {
try {
return Long.valueOf(((String) obj));
} catch (NumberFormatException e) {
return 0L;
}
} else {
return Long.valueOf(obj.toString());
}
}
}

View File

@@ -23,16 +23,13 @@
* <p> * <p>
* Author: Chill Zhuang (bladejava@qq.com) * Author: Chill Zhuang (bladejava@qq.com)
*/ */
package org.springblade.flow.demo.leave.mapper; package org.springblade.common.utils;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springblade.flow.demo.leave.entity.ProcessLeave;
/** /**
* Mapper 接口 * 通用工具类
* *
* @author Chill * @author Chill
*/ */
public interface LeaveMapper extends BaseMapper<ProcessLeave> { public class CommonUtil {
} }

View File

@@ -1,24 +0,0 @@
package org.springblade.common.utils;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Random;
public class RandomAmountGenerator {
/**
* 生成指定范围内的随机金额
*
* @param min 最小值
* @param max 最大值
* @return 随机金额
*/
public static BigDecimal generateRandomAmount(BigDecimal min, BigDecimal max) {
Random random = new Random();
double range = max.subtract(min).doubleValue();
double randomValue = random.nextDouble() * range + min.doubleValue();
return BigDecimal.valueOf(randomValue).setScale(2, RoundingMode.HALF_UP);
}
}

View File

@@ -1,438 +0,0 @@
package org.springblade.common.utils.date;
import lombok.extern.slf4j.Slf4j;
import org.springframework.util.Assert;
import org.springframework.util.StringUtils;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.time.*;
import java.time.format.DateTimeFormatter;
import java.util.Calendar;
import java.util.Date;
import java.util.Locale;
@Slf4j
public class DateUtil {
private static final ThreadLocal<SimpleDateFormat> SIMPLE_DAY = ThreadLocal.withInitial(() -> new SimpleDateFormat("yyyy-MM-dd"));
private static final ThreadLocal<SimpleDateFormat> SIMPLE_DATE_FORMAT = ThreadLocal.withInitial(() -> new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"));
public static final ThreadLocal<DateTimeFormatter> THREAD_LOCAL_FORMAT = ThreadLocal.withInitial(() -> DateTimeFormatter.ofPattern("yyyy-MM-dd", Locale.CHINA));
public static final String yyyyMMddHHmmss = "yyyyMMddHHmmss";
public static final String yyyyMMdd = "yyyyMMdd";
/**
* 计算天数
*
* @param beginDate 开始时间
* @param endDate 结束时间
*/
public static Integer getDaySub(Date beginDate, Date endDate) {
try {
SimpleDateFormat sdf = SIMPLE_DAY.get();
Date start = sdf.parse(sdf.format(beginDate));
Date end = sdf.parse(sdf.format(endDate));
return Math.toIntExact((end.getTime() - start.getTime()) / (24 * 60 * 60 * 1000));
} catch (ParseException e) {
throw new RuntimeException(e);
}
}
public static Date geFirstDayOfThisMonth() {
Calendar calendar = Calendar.getInstance();
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
calendar.set(Calendar.DAY_OF_MONTH, 1);
return calendar.getTime();
}
/**
* 获取本月最后一天
*/
public static Date geLastDayOfThisMonth() {
Calendar cal = Calendar.getInstance();
cal.setTime(new Date());
cal.roll(Calendar.DAY_OF_MONTH, -1);
return cal.getTime();
}
public static Date getThirtyMinuteLate() {
Calendar now = Calendar.getInstance();
now.add(Calendar.MINUTE, 30);
return now.getTime();
}
public static Date getSecondsLate(Date date, int seconds) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.add(Calendar.SECOND, seconds);
return result.getTime();
}
public static Date getMinutesLate(Date date, int minutes) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.add(Calendar.MINUTE, minutes);
return result.getTime();
}
public static Date getHoursLate(Date date, int hours) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.add(Calendar.HOUR, hours);
return result.getTime();
}
public static Date getDaysLate(Date date, int days) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.add(Calendar.DAY_OF_MONTH, days);
return result.getTime();
}
public static Date getMonthsLate(Date date, int months) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.add(Calendar.MONTH, months);
return result.getTime();
}
public static Date getZeroTime(Date date) {
Calendar result = Calendar.getInstance();
result.setTime(date);
result.set(Calendar.HOUR_OF_DAY, 0);
result.set(Calendar.MINUTE, 0);
result.set(Calendar.SECOND, 0);
result.set(Calendar.MILLISECOND, 0);
return result.getTime();
}
public static boolean isExpireDays(Date date, int i) {
Calendar createDate = Calendar.getInstance();
createDate.setTime(date);
createDate.add(Calendar.DATE, i);
return createDate.before(new Date());
}
public static Integer getPersonAgeFromIdCard(String pensonnelIdCard) {
//截取身份证中出行人出生日期中的年、月、日
Integer personYear = Integer.parseInt(pensonnelIdCard.substring(6, 10));
Integer personMonth = Integer.parseInt(pensonnelIdCard.substring(10, 12));
Integer personDay = Integer.parseInt(pensonnelIdCard.substring(12, 14));
Calendar cal = Calendar.getInstance();
// 得到当前时间的年、月、日
Integer yearNow = cal.get(Calendar.YEAR);
Integer monthNow = cal.get(Calendar.MONTH) + 1;
Integer dayNow = cal.get(Calendar.DATE);
// 用当前年月日减去生日年月日
Integer yearMinus = yearNow - personYear;
Integer monthMinus = monthNow - personMonth;
Integer dayMinus = dayNow - personDay;
Integer age = yearMinus; //先大致赋值
if (yearMinus == 0) { //出生年份为当前年份
age = 0;
} else { //出生年份大于当前年份
if (monthMinus < 0) {//出生月份小于当前月份时,还没满周岁
age = age - 1;
}
if (monthMinus == 0) {//当前月份为出生月份时,判断日期
if (dayMinus < 0) {//出生日期小于当前月份时,没满周岁
age = age - 1;
}
}
}
return age;
}
public static Date getToday() {
Calendar calendar = Calendar.getInstance();
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Integer getYear() {
Calendar calendar = Calendar.getInstance();
return calendar.get(Calendar.YEAR);
}
public static Integer getMonth() {
Calendar calendar = Calendar.getInstance();
return calendar.get(Calendar.MONTH) + 1;
}
public static Integer getDay() {
Calendar calendar = Calendar.getInstance();
return calendar.get(Calendar.DATE);
}
public static Date getYesterday() {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, -1);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getBeForeYesterday() {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, -2);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date setDayToNum(int day) {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, day);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getLastWeek() {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, -7);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getSixDaysAgo() {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, -6);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getTomorrow() {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DATE, 1);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Integer getTimeHour() {
Calendar calendar = Calendar.getInstance();
return calendar.get(Calendar.HOUR_OF_DAY);
}
public static Date getTodayHour(String end) {
Calendar calendar = Calendar.getInstance();
calendar.set(Calendar.MILLISECOND, 0);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, Integer.parseInt(end));
return calendar.getTime();
}
public static Integer getTimeStampSec() {
return Integer.valueOf(String.valueOf(Instant.now().getEpochSecond()));
}
public static Date getDayOfMonth(Integer month) {
Calendar calendar = Calendar.getInstance();
calendar.set(Calendar.DAY_OF_MONTH, month);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
/**
* "starttime": "11:00",
* "endtime": "20:00",
*
* @param startTime
* @param endTime
* @return
*/
public static int verificationPeriod(String startTime, String endTime) {
int status = 0;
SimpleDateFormat sdf = SIMPLE_DAY.get();
SimpleDateFormat sdtf = SIMPLE_DATE_FORMAT.get();
if (StringUtils.hasLength(startTime) && StringUtils.hasLength(endTime) && startTime.length() == 5 && endTime.length() == 5) {
String currentDay = sdf.format(new Date());
Long current = System.currentTimeMillis();
//日期补全
String startStr = new StringBuilder(currentDay).append(" ").append(startTime).append(":00").toString();
String endStr = new StringBuilder(currentDay).append(" ").append(endTime).append(":00").toString();
synchronized (DateUtil.class) {
try {
Long start = sdtf.parse(startStr).getTime();
Long end = sdtf.parse(endStr).getTime();
//判断是否跨天
if (start > end) {
status = current - end >= 0 && current - start <= 0 ? 1 : 0;
} else {
status = start.equals(end) ? 0 : current - start >= 0 && current - end <= 0 ? 0 : 1;
}
} catch (Exception e) {
log.error("错误的日期格式 开始时间 {} 结束时间{}", startTime, endTime);
}
}
}
return status;
}
public static Date convertFromString(String dateString, String format) {
SimpleDateFormat ft = new SimpleDateFormat(format);
try {
return ft.parse(dateString);
} catch (Exception e) {
throw new RuntimeException(e.getMessage());
}
}
public static String convertFromDate(Date date, String format) {
SimpleDateFormat ft = new SimpleDateFormat(format);
return ft.format(date);
}
public static Date convertLocalDateTimeToDate(LocalDateTime localDateTime) {
ZoneId zoneId = ZoneId.systemDefault();
ZonedDateTime zdt = localDateTime.atZone(zoneId);
return Date.from(zdt.toInstant());
}
public static Integer getDays(Integer number, Integer type) {
int days = 0;
//计算包对应时长
switch (type) {
case 1: // 天
days = number;
break;
case 2: // 月
days = number * 30;
break;
case 3: //年
days = number * 365;
break;
default:
Assert.isTrue(false, "时间类型错误");
}
return days;
}
/**
* 指定日期后x天的日期
*
* @param start 日期
* @param day 天数
* @return
*/
public static Date getSpecifyDay(Date start, int day) {
Calendar calendar = Calendar.getInstance();
calendar.setTime(start);
calendar.add(Calendar.DATE, day);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getBegin(Date date) {
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getEnd(Date date) {
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
calendar.set(Calendar.SECOND, 59);
calendar.set(Calendar.MINUTE, 59);
calendar.set(Calendar.HOUR_OF_DAY, 23);
calendar.set(Calendar.MILLISECOND, 999);
return calendar.getTime();
}
public static Date getMonthBegin(Date date) {
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
calendar.add(Calendar.MONTH, 0);
calendar.set(Calendar.DAY_OF_MONTH, 1);
calendar.set(Calendar.SECOND, 0);
calendar.set(Calendar.MINUTE, 0);
calendar.set(Calendar.HOUR_OF_DAY, 0);
calendar.set(Calendar.MILLISECOND, 0);
return calendar.getTime();
}
public static Date getMonthEnd(Date date) {
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
calendar.set(Calendar.DAY_OF_MONTH, calendar.getActualMaximum(Calendar.DAY_OF_MONTH));
calendar.set(Calendar.SECOND, 59);
calendar.set(Calendar.MINUTE, 59);
calendar.set(Calendar.HOUR_OF_DAY, 23);
calendar.set(Calendar.MILLISECOND, 999);
return calendar.getTime();
}
public static Long getExpireSecondWithTimestamp(int seconds) {
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.SECOND, seconds);
return calendar.getTime().getTime();
}
/**
* 日期是否为周六/周日
*
* @param day
* @return
*/
public static Boolean dayOfWeek(String day) {
DateTimeFormatter formatter = THREAD_LOCAL_FORMAT.get();
LocalDate date = LocalDate.parse(day, formatter);
switch (date.getDayOfWeek()) {
case SATURDAY:
case SUNDAY:
return true;
default:
return false;
}
}
}

View File

@@ -1,34 +0,0 @@
package org.springblade.common.utils.jsonSerialize;
import com.fasterxml.jackson.core.JsonParser;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.DeserializationContext;
import com.fasterxml.jackson.databind.JsonDeserializer;
import com.fasterxml.jackson.databind.JsonNode;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
public class ArrayToStringDeserializer extends JsonDeserializer<String> {
@Override
public String deserialize(JsonParser p, DeserializationContext ctxt)
throws IOException, JsonProcessingException {
JsonNode node = p.getCodec().readTree(p);
if (node.isArray()) {
List<String> values = new ArrayList<>();
for (JsonNode element : node) {
values.add(element.asText());
}
// 将数组元素用逗号连接成字符串
return String.join(",", values);
} else if (node.isTextual()) {
return node.asText();
} else {
return node.toString();
}
}
}

View File

@@ -1,72 +0,0 @@
package org.springblade.common.utils.string;
/**
* 静态 String 池
*
* @author L.cm
*/
public interface StringPool {
String AMPERSAND = "&";
String AND = "and";
String AT = "@";
String ASTERISK = "*";
String STAR = ASTERISK;
String SLASH = "/";
String BACK_SLASH = "\\";
String DOUBLE_SLASH = "#//";
String COLON = ":";
String COMMA = ",";
String DASH = "-";
String DOLLAR = "$";
String DOT = ".";
String EMPTY = "";
String EMPTY_JSON = "{}";
String EQUALS = "=";
String FALSE = "false";
String HASH = "#";
String HAT = "^";
String LEFT_BRACE = "{";
String LEFT_BRACKET = "(";
String LEFT_CHEV = "<";
String NEWLINE = "\n";
String N = "n";
String NO = "no";
String NULL = "null";
String OFF = "off";
String ON = "on";
String PERCENT = "%";
String PIPE = "|";
String PLUS = "+";
String QUESTION_MARK = "?";
String EXCLAMATION_MARK = "!";
String QUOTE = "\"";
String RETURN = "\r";
String TAB = "\t";
String RIGHT_BRACE = "}";
String RIGHT_BRACKET = ")";
String RIGHT_CHEV = ">";
String SEMICOLON = ";";
String SINGLE_QUOTE = "'";
String BACKTICK = "`";
String SPACE = " ";
String TILDA = "~";
String LEFT_SQ_BRACKET = "[";
String RIGHT_SQ_BRACKET = "]";
String TRUE = "true";
String UNDERSCORE = "_";
String UTF_8 = "UTF-8";
String GBK = "GBK";
String ISO_8859_1 = "ISO-8859-1";
String Y = "y";
String YES = "yes";
String ONE = "1";
String ZERO = "0";
String MINUS_ONE = "-1";
String DOLLAR_LEFT_BRACE = "${";
String UNKNOWN = "unknown";
String GET = "GET";
String POST = "POST";
}

View File

@@ -1,155 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.business.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.flowable.engine.TaskService;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.tool.api.R;
import org.springblade.flow.business.service.FlowBusinessService;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.core.utils.TaskUtil;
import org.springblade.flow.engine.entity.FlowProcess;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springframework.web.bind.annotation.*;
/**
* 流程事务通用接口
*
* @author Chill
*/
@RestController
@AllArgsConstructor
@RequestMapping(AppConstant.APPLICATION_FLOW_NAME + "/work")
@Tag(name = "流程事务通用接口", description = "流程事务通用接口")
public class WorkController {
private final TaskService taskService;
private final FlowEngineService flowEngineService;
private final FlowBusinessService flowBusinessService;
/**
* 发起事务列表页
*/
@GetMapping("start-list")
@ApiOperationSupport(order = 1)
@Operation(summary = "发起事务列表页", description = "传入流程类型")
public R<IPage<FlowProcess>> startList(@Parameter(description = "流程类型") String category, Query query, @RequestParam(required = false, defaultValue = "1") Integer mode) {
IPage<FlowProcess> pages = flowEngineService.selectProcessPage(Condition.getPage(query), category, mode);
return R.data(pages);
}
/**
* 待签事务列表页
*/
@GetMapping("claim-list")
@ApiOperationSupport(order = 2)
@Operation(summary = "待签事务列表页", description = "传入流程信息")
public R<IPage<BladeFlow>> claimList(@Parameter(description = "流程信息") BladeFlow bladeFlow, Query query) {
IPage<BladeFlow> pages = flowBusinessService.selectClaimPage(Condition.getPage(query), bladeFlow);
return R.data(pages);
}
/**
* 待办事务列表页
*/
@GetMapping("todo-list")
@ApiOperationSupport(order = 3)
@Operation(summary = "待办事务列表页", description = "传入流程信息")
public R<IPage<BladeFlow>> todoList(@Parameter(description = "流程信息") BladeFlow bladeFlow, Query query) {
IPage<BladeFlow> pages = flowBusinessService.selectTodoPage(Condition.getPage(query), bladeFlow);
return R.data(pages);
}
/**
* 已发事务列表页
*/
@GetMapping("send-list")
@ApiOperationSupport(order = 4)
@Operation(summary = "已发事务列表页", description = "传入流程信息")
public R<IPage<BladeFlow>> sendList(@Parameter(description = "流程信息") BladeFlow bladeFlow, Query query) {
IPage<BladeFlow> pages = flowBusinessService.selectSendPage(Condition.getPage(query), bladeFlow);
return R.data(pages);
}
/**
* 办结事务列表页
*/
@GetMapping("done-list")
@ApiOperationSupport(order = 5)
@Operation(summary = "办结事务列表页", description = "传入流程信息")
public R<IPage<BladeFlow>> doneList(@Parameter(description = "流程信息") BladeFlow bladeFlow, Query query) {
IPage<BladeFlow> pages = flowBusinessService.selectDonePage(Condition.getPage(query), bladeFlow);
return R.data(pages);
}
/**
* 签收事务
*
* @param taskId 任务id
*/
@PostMapping("claim-task")
@ApiOperationSupport(order = 6)
@Operation(summary = "签收事务", description = "传入流程信息")
public R claimTask(@Parameter(description = "任务id") String taskId) {
taskService.claim(taskId, TaskUtil.getTaskUser());
return R.success("签收事务成功");
}
/**
* 完成任务
*
* @param flow 请假信息
*/
@PostMapping("complete-task")
@ApiOperationSupport(order = 7)
@Operation(summary = "完成任务", description = "传入流程信息")
public R completeTask(@Parameter(description = "任务信息") @RequestBody BladeFlow flow) {
return R.status(flowBusinessService.completeTask(flow));
}
/**
* 删除任务
*
* @param taskId 任务id
* @param reason 删除原因
*/
@PostMapping("delete-task")
@ApiOperationSupport(order = 8)
@Operation(summary = "删除任务", description = "传入流程信息")
public R deleteTask(@Parameter(description = "任务id") String taskId, @Parameter(description = "删除原因") String reason) {
taskService.deleteTask(taskId, reason);
return R.success("删除任务成功");
}
}

View File

@@ -1,81 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.business.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.springblade.flow.core.entity.BladeFlow;
/**
* 流程业务类
*
* @author Chill
*/
public interface FlowBusinessService {
/**
* 流程待签列表
*
* @param page 分页工具
* @param bladeFlow 流程类
* @return
*/
IPage<BladeFlow> selectClaimPage(IPage<BladeFlow> page, BladeFlow bladeFlow);
/**
* 流程待办列表
*
* @param page 分页工具
* @param bladeFlow 流程类
* @return
*/
IPage<BladeFlow> selectTodoPage(IPage<BladeFlow> page, BladeFlow bladeFlow);
/**
* 流程已发列表
*
* @param page 分页工具
* @param bladeFlow 流程类
* @return
*/
IPage<BladeFlow> selectSendPage(IPage<BladeFlow> page, BladeFlow bladeFlow);
/**
* 流程办结列表
*
* @param page 分页工具
* @param bladeFlow 流程类
* @return
*/
IPage<BladeFlow> selectDonePage(IPage<BladeFlow> page, BladeFlow bladeFlow);
/**
* 完成任务
*
* @param leave 请假信息
* @return boolean
*/
boolean completeTask(BladeFlow leave);
}

View File

@@ -1,86 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.business.service;
import org.springblade.flow.core.entity.BladeFlow;
import java.util.Map;
/**
* 工作流调用接口.
*
* @author Chill
*/
public interface IFlowService {
/**
* 开启流程
*
* @param processDefinitionId 流程id
* @param businessKey 业务key
* @param variables 参数
* @return BladeFlow
*/
BladeFlow startProcessInstanceById(String processDefinitionId, String businessKey, Map<String, Object> variables);
/**
* 开启流程
*
* @param processDefinitionKey 流程标识
* @param businessKey 业务key
* @param variables 参数
* @return BladeFlow
*/
BladeFlow startProcessInstanceByKey(String processDefinitionKey, String businessKey, Map<String, Object> variables);
/**
* 完成任务
*
* @param taskId 任务id
* @param processInstanceId 流程实例id
* @param comment 评论
* @param variables 参数
* @return R
*/
boolean completeTask(String taskId, String processInstanceId, String comment, Map<String, Object> variables);
/**
* 获取流程变量
*
* @param taskId 任务id
* @param variableName 变量名
* @return R
*/
Object taskVariable(String taskId, String variableName);
/**
* 获取流程变量集合
*
* @param taskId 任务id
* @return R
*/
Map<String, Object> taskVariables(String taskId);
}

View File

@@ -1,342 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.business.service.impl;
import com.baomidou.mybatisplus.core.metadata.IPage;
import lombok.AllArgsConstructor;
import org.flowable.engine.HistoryService;
import org.flowable.engine.TaskService;
import org.flowable.engine.history.HistoricProcessInstance;
import org.flowable.engine.history.HistoricProcessInstanceQuery;
import org.flowable.task.api.TaskQuery;
import org.flowable.task.api.history.HistoricTaskInstance;
import org.flowable.task.api.history.HistoricTaskInstanceQuery;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.support.Kv;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringPool;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.flow.business.service.FlowBusinessService;
import org.springblade.flow.core.constant.ProcessConstant;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.core.utils.TaskUtil;
import org.springblade.flow.engine.constant.FlowEngineConstant;
import org.springblade.flow.engine.entity.FlowProcess;
import org.springblade.flow.engine.utils.FlowCache;
import org.springframework.stereotype.Service;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
/**
* 流程业务实现类
*
* @author Chill
*/
@Service
@AllArgsConstructor
public class FlowBusinessServiceImpl implements FlowBusinessService {
private final TaskService taskService;
private final HistoryService historyService;
@Override
public IPage<BladeFlow> selectClaimPage(IPage<BladeFlow> page, BladeFlow bladeFlow) {
String taskUser = TaskUtil.getTaskUser();
String taskGroup = TaskUtil.getCandidateGroup();
List<BladeFlow> flowList = new LinkedList<>();
// 个人等待签收的任务
TaskQuery claimUserQuery = taskService.createTaskQuery().taskCandidateUser(taskUser)
.includeProcessVariables().active().orderByTaskCreateTime().desc();
// 定制流程等待签收的任务
TaskQuery claimRoleWithTenantIdQuery = taskService.createTaskQuery().taskTenantId(AuthUtil.getTenantId()).taskCandidateGroupIn(Func.toStrList(taskGroup))
.includeProcessVariables().active().orderByTaskCreateTime().desc();
// 通用流程等待签收的任务
TaskQuery claimRoleWithoutTenantIdQuery = taskService.createTaskQuery().taskWithoutTenantId().taskCandidateGroupIn(Func.toStrList(taskGroup))
.includeProcessVariables().active().orderByTaskCreateTime().desc();
// 构建列表数据
buildFlowTaskList(bladeFlow, flowList, claimUserQuery, FlowEngineConstant.STATUS_CLAIM);
buildFlowTaskList(bladeFlow, flowList, claimRoleWithTenantIdQuery, FlowEngineConstant.STATUS_CLAIM);
buildFlowTaskList(bladeFlow, flowList, claimRoleWithoutTenantIdQuery, FlowEngineConstant.STATUS_CLAIM);
// 计算总数
long count = claimUserQuery.count() + claimRoleWithTenantIdQuery.count() + claimRoleWithoutTenantIdQuery.count();
// 设置页数
page.setSize(count);
// 设置总数
page.setTotal(count);
// 设置数据
page.setRecords(flowList);
return page;
}
@Override
public IPage<BladeFlow> selectTodoPage(IPage<BladeFlow> page, BladeFlow bladeFlow) {
String taskUser = TaskUtil.getTaskUser();
List<BladeFlow> flowList = new LinkedList<>();
// 已签收的任务
TaskQuery todoQuery = taskService.createTaskQuery().taskAssignee(taskUser).active()
.includeProcessVariables().orderByTaskCreateTime().desc();
// 构建列表数据
buildFlowTaskList(bladeFlow, flowList, todoQuery, FlowEngineConstant.STATUS_TODO);
// 计算总数
long count = todoQuery.count();
// 设置页数
page.setSize(count);
// 设置总数
page.setTotal(count);
// 设置数据
page.setRecords(flowList);
return page;
}
@Override
public IPage<BladeFlow> selectSendPage(IPage<BladeFlow> page, BladeFlow bladeFlow) {
String taskUser = TaskUtil.getTaskUser();
List<BladeFlow> flowList = new LinkedList<>();
HistoricProcessInstanceQuery historyQuery = historyService.createHistoricProcessInstanceQuery().startedBy(taskUser).orderByProcessInstanceStartTime().desc();
if (bladeFlow.getCategory() != null) {
historyQuery.processDefinitionCategory(bladeFlow.getCategory());
}
if (bladeFlow.getProcessDefinitionName() != null) {
historyQuery.processDefinitionName(bladeFlow.getProcessDefinitionName());
}
if (bladeFlow.getBeginDate() != null) {
historyQuery.startedAfter(bladeFlow.getBeginDate());
}
if (bladeFlow.getEndDate() != null) {
historyQuery.startedBefore(bladeFlow.getEndDate());
}
// 查询列表
List<HistoricProcessInstance> historyList = historyQuery.listPage(Func.toInt((page.getCurrent() - 1) * page.getSize()), Func.toInt(page.getSize()));
historyList.forEach(historicProcessInstance -> {
BladeFlow flow = new BladeFlow();
// historicProcessInstance
flow.setCreateTime(historicProcessInstance.getStartTime());
flow.setEndTime(historicProcessInstance.getEndTime());
flow.setVariables(historicProcessInstance.getProcessVariables());
String[] businessKey = Func.toStrArray(StringPool.COLON, historicProcessInstance.getBusinessKey());
if (businessKey.length > 1) {
flow.setBusinessTable(businessKey[0]);
flow.setBusinessId(businessKey[1]);
}
flow.setHistoryActivityName(historicProcessInstance.getName());
flow.setProcessInstanceId(historicProcessInstance.getId());
flow.setHistoryProcessInstanceId(historicProcessInstance.getId());
// ProcessDefinition
FlowProcess processDefinition = FlowCache.getProcessDefinition(historicProcessInstance.getProcessDefinitionId());
flow.setProcessDefinitionId(processDefinition.getId());
flow.setProcessDefinitionName(processDefinition.getName());
flow.setProcessDefinitionVersion(processDefinition.getVersion());
flow.setProcessDefinitionKey(processDefinition.getKey());
flow.setCategory(processDefinition.getCategory());
flow.setCategoryName(FlowCache.getCategoryName(processDefinition.getCategory()));
flow.setProcessInstanceId(historicProcessInstance.getId());
// HistoricTaskInstance
List<HistoricTaskInstance> historyTasks = historyService.createHistoricTaskInstanceQuery().processInstanceId(historicProcessInstance.getId()).orderByHistoricTaskInstanceEndTime().desc().list();
if (Func.isNotEmpty(historyTasks)) {
HistoricTaskInstance historyTask = historyTasks.iterator().next();
flow.setTaskId(historyTask.getId());
flow.setTaskName(historyTask.getName());
flow.setTaskDefinitionKey(historyTask.getTaskDefinitionKey());
}
// Status
if (historicProcessInstance.getEndActivityId() != null) {
flow.setProcessIsFinished(FlowEngineConstant.STATUS_FINISHED);
} else {
flow.setProcessIsFinished(FlowEngineConstant.STATUS_UNFINISHED);
}
flow.setStatus(FlowEngineConstant.STATUS_FINISH);
flowList.add(flow);
});
// 计算总数
long count = historyQuery.count();
// 设置总数
page.setTotal(count);
page.setRecords(flowList);
return page;
}
@Override
public IPage<BladeFlow> selectDonePage(IPage<BladeFlow> page, BladeFlow bladeFlow) {
String taskUser = TaskUtil.getTaskUser();
List<BladeFlow> flowList = new LinkedList<>();
HistoricTaskInstanceQuery doneQuery = historyService.createHistoricTaskInstanceQuery().taskAssignee(taskUser).finished()
.includeProcessVariables().orderByHistoricTaskInstanceEndTime().desc();
if (bladeFlow.getCategory() != null) {
doneQuery.processCategoryIn(Func.toStrList(bladeFlow.getCategory()));
}
if (bladeFlow.getProcessDefinitionName() != null) {
doneQuery.processDefinitionName(bladeFlow.getProcessDefinitionName());
}
if (bladeFlow.getBeginDate() != null) {
doneQuery.taskCompletedAfter(bladeFlow.getBeginDate());
}
if (bladeFlow.getEndDate() != null) {
doneQuery.taskCompletedBefore(bladeFlow.getEndDate());
}
// 查询列表
List<HistoricTaskInstance> doneList = doneQuery.listPage(Func.toInt((page.getCurrent() - 1) * page.getSize()), Func.toInt(page.getSize()));
doneList.forEach(historicTaskInstance -> {
BladeFlow flow = new BladeFlow();
flow.setTaskId(historicTaskInstance.getId());
flow.setTaskDefinitionKey(historicTaskInstance.getTaskDefinitionKey());
flow.setTaskName(historicTaskInstance.getName());
flow.setAssignee(historicTaskInstance.getAssignee());
flow.setCreateTime(historicTaskInstance.getCreateTime());
flow.setExecutionId(historicTaskInstance.getExecutionId());
flow.setHistoryTaskEndTime(historicTaskInstance.getEndTime());
flow.setVariables(historicTaskInstance.getProcessVariables());
FlowProcess processDefinition = FlowCache.getProcessDefinition(historicTaskInstance.getProcessDefinitionId());
flow.setProcessDefinitionId(processDefinition.getId());
flow.setProcessDefinitionName(processDefinition.getName());
flow.setProcessDefinitionKey(processDefinition.getKey());
flow.setProcessDefinitionVersion(processDefinition.getVersion());
flow.setCategory(processDefinition.getCategory());
flow.setCategoryName(FlowCache.getCategoryName(processDefinition.getCategory()));
flow.setProcessInstanceId(historicTaskInstance.getProcessInstanceId());
flow.setHistoryProcessInstanceId(historicTaskInstance.getProcessInstanceId());
HistoricProcessInstance historicProcessInstance = getHistoricProcessInstance((historicTaskInstance.getProcessInstanceId()));
if (Func.isNotEmpty(historicProcessInstance)) {
String[] businessKey = Func.toStrArray(StringPool.COLON, historicProcessInstance.getBusinessKey());
flow.setBusinessTable(businessKey[0]);
flow.setBusinessId(businessKey[1]);
if (historicProcessInstance.getEndActivityId() != null) {
flow.setProcessIsFinished(FlowEngineConstant.STATUS_FINISHED);
} else {
flow.setProcessIsFinished(FlowEngineConstant.STATUS_UNFINISHED);
}
}
flow.setStatus(FlowEngineConstant.STATUS_FINISH);
flowList.add(flow);
});
// 计算总数
long count = doneQuery.count();
// 设置总数
page.setTotal(count);
page.setRecords(flowList);
return page;
}
@Override
public boolean completeTask(BladeFlow flow) {
String taskId = flow.getTaskId();
String processInstanceId = flow.getProcessInstanceId();
String comment = Func.toStr(flow.getComment(), ProcessConstant.PASS_COMMENT);
// 增加评论
if (StringUtil.isNoneBlank(processInstanceId, comment)) {
taskService.addComment(taskId, processInstanceId, comment);
}
// 创建变量
Map<String, Object> variables = flow.getVariables();
if (variables == null) {
variables = Kv.create();
}
variables.put(ProcessConstant.PASS_KEY, flow.isPass());
// 完成任务
taskService.complete(taskId, variables);
return true;
}
/**
* 构建流程
*
* @param bladeFlow 流程通用类
* @param flowList 流程列表
* @param taskQuery 任务查询类
* @param status 状态
*/
private void buildFlowTaskList(BladeFlow bladeFlow, List<BladeFlow> flowList, TaskQuery taskQuery, String status) {
if (bladeFlow.getCategory() != null) {
taskQuery.processCategoryIn(Func.toStrList(bladeFlow.getCategory()));
}
if (bladeFlow.getProcessDefinitionName() != null) {
taskQuery.processDefinitionName(bladeFlow.getProcessDefinitionName());
}
if (bladeFlow.getBeginDate() != null) {
taskQuery.taskCreatedAfter(bladeFlow.getBeginDate());
}
if (bladeFlow.getEndDate() != null) {
taskQuery.taskCreatedBefore(bladeFlow.getEndDate());
}
taskQuery.list().forEach(task -> {
BladeFlow flow = new BladeFlow();
flow.setTaskId(task.getId());
flow.setTaskDefinitionKey(task.getTaskDefinitionKey());
flow.setTaskName(task.getName());
flow.setAssignee(task.getAssignee());
flow.setCreateTime(task.getCreateTime());
flow.setClaimTime(task.getClaimTime());
flow.setExecutionId(task.getExecutionId());
flow.setVariables(task.getProcessVariables());
HistoricProcessInstance historicProcessInstance = getHistoricProcessInstance(task.getProcessInstanceId());
if (Func.isNotEmpty(historicProcessInstance)) {
String[] businessKey = Func.toStrArray(StringPool.COLON, historicProcessInstance.getBusinessKey());
flow.setBusinessTable(businessKey[0]);
flow.setBusinessId(businessKey[1]);
}
FlowProcess processDefinition = FlowCache.getProcessDefinition(task.getProcessDefinitionId());
flow.setCategory(processDefinition.getCategory());
flow.setCategoryName(FlowCache.getCategoryName(processDefinition.getCategory()));
flow.setProcessDefinitionId(processDefinition.getId());
flow.setProcessDefinitionName(processDefinition.getName());
flow.setProcessDefinitionKey(processDefinition.getKey());
flow.setProcessDefinitionVersion(processDefinition.getVersion());
flow.setProcessInstanceId(task.getProcessInstanceId());
flow.setStatus(status);
flowList.add(flow);
});
}
/**
* 获取历史流程
*
* @param processInstanceId 流程实例id
* @return HistoricProcessInstance
*/
private HistoricProcessInstance getHistoricProcessInstance(String processInstanceId) {
return historyService.createHistoricProcessInstanceQuery().processInstanceId(processInstanceId).singleResult();
}
}

View File

@@ -1,106 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.business.service.impl;
import lombok.AllArgsConstructor;
import org.flowable.engine.IdentityService;
import org.flowable.engine.RuntimeService;
import org.flowable.engine.TaskService;
import org.flowable.engine.runtime.ProcessInstance;
import org.springblade.core.tool.api.R;
import org.springblade.core.tool.support.Kv;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.flow.business.service.IFlowService;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.core.utils.TaskUtil;
import org.springframework.web.bind.annotation.RestController;
import java.util.Map;
/**
* 流程实现类
*
* @author Chill
*/
@RestController
@AllArgsConstructor
public class FlowServiceImpl implements IFlowService {
private final RuntimeService runtimeService;
private final IdentityService identityService;
private final TaskService taskService;
@Override
public BladeFlow startProcessInstanceById(String processDefinitionId, String businessKey, Map<String, Object> variables) {
// 设置流程启动用户
identityService.setAuthenticatedUserId(TaskUtil.getTaskUser());
// 开启流程
ProcessInstance processInstance = runtimeService.startProcessInstanceById(processDefinitionId, businessKey, variables);
// 组装流程通用类
BladeFlow flow = new BladeFlow();
flow.setProcessInstanceId(processInstance.getId());
return flow;
}
@Override
public BladeFlow startProcessInstanceByKey(String processDefinitionKey, String businessKey, Map<String, Object> variables) {
// 设置流程启动用户
identityService.setAuthenticatedUserId(TaskUtil.getTaskUser());
// 开启流程
ProcessInstance processInstance = runtimeService.startProcessInstanceByKey(processDefinitionKey, businessKey, variables);
// 组装流程通用类
BladeFlow flow = new BladeFlow();
flow.setProcessInstanceId(processInstance.getId());
return flow;
}
@Override
public boolean completeTask(String taskId, String processInstanceId, String comment, Map<String, Object> variables) {
// 增加评论
if (StringUtil.isNoneBlank(processInstanceId, comment)) {
taskService.addComment(taskId, processInstanceId, comment);
}
// 非空判断
if (Func.isEmpty(variables)) {
variables = Kv.create();
}
// 完成任务
taskService.complete(taskId, variables);
return true;
}
@Override
public Object taskVariable(String taskId, String variableName) {
return R.data(taskService.getVariable(taskId, variableName));
}
@Override
public Map<String, Object> taskVariables(String taskId) {
return taskService.getVariables(taskId);
}
}

View File

@@ -1,70 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.constant;
/**
* 流程常量.
*
* @author Chill
*/
public interface ProcessConstant {
/**
* 请假流程标识
*/
String LEAVE_KEY = "Leave";
/**
* 报销流程标识
*/
String EXPENSE_KEY = "Expense";
/**
* 同意标识
*/
String PASS_KEY = "pass";
/**
* 同意代号
*/
String PASS_ALIAS = "ok";
/**
* 同意默认批复
*/
String PASS_COMMENT = "同意";
/**
* 驳回默认批复
*/
String NOT_PASS_COMMENT = "驳回";
/**
* 创建人变量名
*/
String TASK_VARIABLE_CREATE_USER = "createUser";
}

View File

@@ -1,190 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.entity;
import lombok.Data;
import org.springblade.flow.core.constant.ProcessConstant;
import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
import java.util.Map;
/**
* 工作流通用实体类
*
* @author Chill
*/
@Data
public class BladeFlow implements Serializable {
@Serial
private static final long serialVersionUID = 1L;
/**
* 任务编号
*/
private String taskId;
/**
* 任务名称
*/
private String taskName;
/**
* 任务定义Key
*/
private String taskDefinitionKey;
/**
* 任务执行人编号
*/
private String assignee;
/**
* 任务执行人名称
*/
private String assigneeName;
/**
* 流程分类
*/
private String category;
/**
* 流程分类名
*/
private String categoryName;
/**
* 创建时间
*/
private Date createTime;
/**
* 结束时间
*/
private Date endTime;
/**
* 签收时间
*/
private Date claimTime;
/**
* 历史任务结束时间
*/
private Date historyTaskEndTime;
/**
* 执行ID
*/
private String executionId;
/**
* 流程实例ID
*/
private String processInstanceId;
/**
* 流程ID
*/
private String processDefinitionId;
/**
* 流程标识
*/
private String processDefinitionKey;
/**
* 流程名
*/
private String processDefinitionName;
/**
* 流程版本
*/
private int processDefinitionVersion;
/**
* 流程说明
*/
private String processDefinitionDesc;
/**
* 流程简图名
*/
private String processDefinitionDiagramResName;
/**
* 流程重命名
*/
private String processDefinitionResName;
/**
* 历史任务流程实例ID 查看流程图会用到
*/
private String historyProcessInstanceId;
/**
* 流程实例是否结束
*/
private String processIsFinished;
/**
* 历史活动ID
*/
private String historyActivityId;
/**
* 历史活动流程
*/
private String historyActivityName;
/**
* 历史活动耗时
*/
private String historyActivityDurationTime;
/**
* 业务绑定Table
*/
private String businessTable;
/**
* 业务绑定ID
*/
private String businessId;
/**
* 任务状态
*/
private String status;
/**
* 任务意见
*/
private String comment;
/**
* 是否通过
*/
private boolean isPass;
/**
* 是否通过代号
*/
private String flag;
/**
* 开始查询日期
*/
private Date beginDate;
/**
* 结束查询日期
*/
private Date endDate;
/**
* 流程参数
*/
private Map<String, Object> variables;
/**
* 获取是否通过
*/
public boolean isPass() {
return ProcessConstant.PASS_ALIAS.equals(flag) || ProcessConstant.PASS_COMMENT.equals(comment);
}
}

View File

@@ -1,52 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.mp.base.BaseEntity;
/**
* FlowEntity
*
* @author Chill
*/
@Data
@EqualsAndHashCode(callSuper = true)
public class FlowEntity extends BaseEntity {
@TableField(exist = false)
private BladeFlow flow;
public BladeFlow getFlow() {
if (flow == null) {
flow = new BladeFlow();
}
return flow;
}
}

View File

@@ -1,54 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.enums;
import lombok.AllArgsConstructor;
import lombok.Getter;
/**
* 流程类型枚举
*
* @author Chill
*/
@Getter
@AllArgsConstructor
public enum FlowModeEnum {
/**
* 通用流程
*/
COMMON("common", 1),
/**
* 定制流程
*/
CUSTOM("custom", 2),
;
final String name;
final int mode;
}

View File

@@ -1,76 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.utils;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringPool;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.flow.core.constant.ProcessConstant;
import java.util.HashMap;
import java.util.Map;
/**
* 工作流工具类
*
* @author Chill
*/
public class FlowUtil {
/**
* 定义流程key对应的表名
*/
private final static Map<String, String> BUSINESS_TABLE = new HashMap<>();
static {
BUSINESS_TABLE.put(ProcessConstant.LEAVE_KEY, "blade_process_leave");
}
/**
* 通过流程key获取业务表名
*
* @param key 流程key
*/
public static String getBusinessTable(String key) {
String businessTable = BUSINESS_TABLE.get(key);
if (Func.isEmpty(businessTable)) {
return StringPool.EMPTY;
}
return businessTable;
}
/**
* 获取业务标识
*
* @param businessTable 业务表
* @param businessId 业务表主键
* @return businessKey
*/
public static String getBusinessKey(String businessTable, String businessId) {
return StringUtil.format("{}:{}", businessTable, businessId);
}
}

View File

@@ -1,80 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.core.utils;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringUtil;
import static org.springblade.core.launch.constant.FlowConstant.TASK_USR_PREFIX;
/**
* 工作流任务工具类
*
* @author Chill
*/
public class TaskUtil {
/**
* 获取任务用户格式
*
* @return taskUser
*/
public static String getTaskUser() {
return StringUtil.format("{}{}", TASK_USR_PREFIX, AuthUtil.getUserId());
}
/**
* 获取任务用户格式
*
* @param userId 用户id
* @return taskUser
*/
public static String getTaskUser(String userId) {
return StringUtil.format("{}{}", TASK_USR_PREFIX, userId);
}
/**
* 获取用户主键
*
* @param taskUser 任务用户
* @return userId
*/
public static Long getUserId(String taskUser) {
return Func.toLong(StringUtil.removePrefix(taskUser, TASK_USR_PREFIX));
}
/**
* 获取用户组格式
*
* @return candidateGroup
*/
public static String getCandidateGroup() {
return AuthUtil.getUserRole();
}
}

View File

@@ -1,74 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.demo.leave.controller;
import io.swagger.v3.oas.annotations.Hidden;
import lombok.AllArgsConstructor;
import org.springblade.common.cache.UserCache;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.api.R;
import org.springblade.flow.demo.leave.entity.ProcessLeave;
import org.springblade.flow.demo.leave.service.ILeaveService;
import org.springframework.web.bind.annotation.*;
/**
* 控制器
*
* @author Chill
*/
@NonDS
@Hidden
@RestController
@RequestMapping(AppConstant.APPLICATION_DESK_NAME + "/process/leave")
@AllArgsConstructor
public class LeaveController {
private final ILeaveService leaveService;
/**
* 详情
*
* @param businessId 主键
*/
@GetMapping("detail")
public R<ProcessLeave> detail(Long businessId) {
ProcessLeave detail = leaveService.getById(businessId);
detail.getFlow().setAssigneeName(UserCache.getUser(detail.getCreateUser()).getName());
return R.data(detail);
}
/**
* 新增或修改
*
* @param leave 请假信息
*/
@PostMapping("start-process")
public R startProcess(@RequestBody ProcessLeave leave) {
return R.status(leaveService.startProcess(leave));
}
}

View File

@@ -1,78 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.demo.leave.entity;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.flow.core.entity.FlowEntity;
import java.io.Serial;
import java.util.Date;
/**
* 请假流程实体类
*
* @author Chill
*/
@Data
@TableName("blade_process_leave")
@EqualsAndHashCode(callSuper = true)
public class ProcessLeave extends FlowEntity {
@Serial
private static final long serialVersionUID = 1L;
/**
* 流程定义id
*/
private String processDefinitionId;
/**
* 流程实例id
*/
private String processInstanceId;
/**
* 请假开始时间
*/
private Date startTime;
/**
* 请假结束时间
*/
private Date endTime;
/**
* 请假理由
*/
private String reason;
/**
* 审批人
*/
private String taskUser;
/**
* 流程申请时间
*/
private Date applyTime;
}

View File

@@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.springblade.flow.demo.leave.mapper.LeaveMapper">
</mapper>

View File

@@ -1,46 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.demo.leave.service;
import org.springblade.core.mp.base.BaseService;
import org.springblade.flow.demo.leave.entity.ProcessLeave;
/**
* 服务类
*
* @author Chill
*/
public interface ILeaveService extends BaseService<ProcessLeave> {
/**
* 开启流程
*
* @param leave 请假实体
* @return boolean
*/
boolean startProcess(ProcessLeave leave);
}

View File

@@ -1,91 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.demo.leave.service.impl;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.support.Kv;
import org.springblade.core.tool.utils.DateUtil;
import org.springblade.core.tool.utils.Func;
import org.springblade.flow.business.service.IFlowService;
import org.springblade.flow.core.constant.ProcessConstant;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.core.utils.FlowUtil;
import org.springblade.flow.core.utils.TaskUtil;
import org.springblade.flow.demo.leave.entity.ProcessLeave;
import org.springblade.flow.demo.leave.mapper.LeaveMapper;
import org.springblade.flow.demo.leave.service.ILeaveService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
/**
* 服务实现类
*
* @author Chill
*/
@Slf4j
@Service
@AllArgsConstructor
public class LeaveServiceImpl extends BaseServiceImpl<LeaveMapper, ProcessLeave> implements ILeaveService {
private final IFlowService flowService;
@Override
@Transactional(rollbackFor = Exception.class)
public boolean startProcess(ProcessLeave leave) {
String businessTable = FlowUtil.getBusinessTable(ProcessConstant.LEAVE_KEY);
if (Func.isEmpty(businessTable)) {
throw new ServiceException("流程启动失败,未找到相关业务表");
}
if (Func.isEmpty(leave.getId())) {
// 保存leave
leave.setApplyTime(DateUtil.now());
save(leave);
// 启动流程
Kv variables = Kv.create()
.set(ProcessConstant.TASK_VARIABLE_CREATE_USER, AuthUtil.getUserName())
.set("taskUser", TaskUtil.getTaskUser(leave.getTaskUser()))
.set("days", DateUtil.between(leave.getStartTime(), leave.getEndTime()).toDays());
BladeFlow flow = flowService.startProcessInstanceById(leave.getProcessDefinitionId(), FlowUtil.getBusinessKey(businessTable, String.valueOf(leave.getId())), variables);
if (Func.isNotEmpty(flow)) {
log.debug("流程已启动,流程ID:" + flow.getProcessInstanceId());
// 返回流程id写入leave
leave.setProcessInstanceId(flow.getProcessInstanceId());
updateById(leave);
} else {
throw new ServiceException("开启流程失败");
}
} else {
updateById(leave);
}
return true;
}
}

View File

@@ -1,6 +0,0 @@
/**
* Created by Blade.
*
* @author zhuangqian
*/
package org.springblade.flow.demo;

View File

@@ -1,53 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.config;
import lombok.AllArgsConstructor;
import org.flowable.spring.SpringProcessEngineConfiguration;
import org.flowable.spring.boot.EngineConfigurationConfigurer;
import org.flowable.spring.boot.FlowableProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;
/**
* Flowable配置类
*
* @author Chill
*/
@Configuration(proxyBeanMethods = false)
@AllArgsConstructor
@EnableConfigurationProperties(FlowableProperties.class)
public class FlowableConfiguration implements EngineConfigurationConfigurer<SpringProcessEngineConfiguration> {
private final FlowableProperties flowableProperties;
@Override
public void configure(SpringProcessEngineConfiguration engineConfiguration) {
engineConfiguration.setActivityFontName(flowableProperties.getActivityFontName());
engineConfiguration.setLabelFontName(flowableProperties.getLabelFontName());
engineConfiguration.setAnnotationFontName(flowableProperties.getAnnotationFontName());
}
}

View File

@@ -1,61 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.constant;
/**
* 流程常量.
*
* @author zhuangqian
*/
public interface FlowEngineConstant {
String FLOWABLE_BASE_PACKAGES = "org.flowable.ui";
String SUFFIX = ".bpmn20.xml";
String ACTIVE = "active";
String SUSPEND = "suspend";
String STATUS_TODO = "todo";
String STATUS_CLAIM = "claim";
String STATUS_SEND = "send";
String STATUS_DONE = "done";
String STATUS_FINISHED = "finished";
String STATUS_UNFINISHED = "unfinished";
String STATUS_FINISH = "finish";
String START_EVENT = "startEvent";
String END_EVENT = "endEvent";
}

View File

@@ -1,83 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.secure.annotation.IsAdministrator;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.api.R;
import org.springblade.flow.engine.entity.FlowExecution;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springframework.web.bind.annotation.*;
/**
* 流程状态控制器
*
* @author Chill
*/
@Hidden
@NonDS
@RestController
@AllArgsConstructor
@IsAdministrator
@RequestMapping(AppConstant.APPLICATION_FLOW_NAME + "/follow")
@Tag(name = "流程状态接口", description = "流程状态接口")
public class FlowFollowController {
private final FlowEngineService flowEngineService;
/**
* 流程状态列表
*/
@GetMapping("list")
@ApiOperationSupport(order = 1)
@Operation(summary = "分页", description = "传入notice")
public R<IPage<FlowExecution>> list(Query query, @Parameter(description = "流程实例id") String processInstanceId, @Parameter(description = "流程key") String processDefinitionKey) {
IPage<FlowExecution> pages = flowEngineService.selectFollowPage(Condition.getPage(query), processInstanceId, processDefinitionKey);
return R.data(pages);
}
/**
* 删除流程实例
*/
@PostMapping("delete-process-instance")
@ApiOperationSupport(order = 2)
@Operation(summary = "删除", description = "传入主键集合")
public R deleteProcessInstance(@Parameter(description = "流程实例id") @RequestParam String processInstanceId, @Parameter(description = "删除原因") @RequestParam String deleteReason) {
boolean temp = flowEngineService.deleteProcessInstance(processInstanceId, deleteReason);
return R.status(temp);
}
}

View File

@@ -1,133 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.secure.annotation.IsAdministrator;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.api.R;
import org.springblade.core.tool.support.Kv;
import org.springblade.core.tool.utils.Func;
import org.springblade.flow.engine.constant.FlowEngineConstant;
import org.springblade.flow.engine.entity.FlowProcess;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import java.util.List;
import java.util.Objects;
/**
* 流程管理接口
*
* @author Chill
*/
@Hidden
@NonDS
@RestController
@AllArgsConstructor
@IsAdministrator
@RequestMapping(AppConstant.APPLICATION_FLOW_NAME + "/manager")
@Tag(name = "流程管理接口", description = "流程管理接口")
public class FlowManagerController {
private final FlowEngineService flowEngineService;
/**
* 分页
*/
@GetMapping("list")
@ApiOperationSupport(order = 1)
@Operation(summary = "分页", description = "传入流程类型")
public R<IPage<FlowProcess>> list(@Parameter(description = "流程类型") String category, Query query, @RequestParam(required = false, defaultValue = "1") Integer mode) {
IPage<FlowProcess> pages = flowEngineService.selectProcessPage(Condition.getPage(query), category, mode);
return R.data(pages);
}
/**
* 变更流程状态
*
* @param state 状态
* @param processId 流程id
*/
@PostMapping("change-state")
@ApiOperationSupport(order = 2)
@Operation(summary = "变更流程状态", description = "传入state,processId")
public R changeState(@RequestParam String state, @RequestParam String processId) {
String msg = flowEngineService.changeState(state, processId);
return R.success(msg);
}
/**
* 删除部署流程
*
* @param deploymentIds 部署流程id集合
*/
@PostMapping("delete-deployment")
@ApiOperationSupport(order = 3)
@Operation(summary = "删除部署流程", description = "部署流程id集合")
public R deleteDeployment(String deploymentIds) {
return R.status(flowEngineService.deleteDeployment(deploymentIds));
}
/**
* 检查流程文件格式
*
* @param file 流程文件
*/
@PostMapping("check-upload")
@ApiOperationSupport(order = 4)
@Operation(summary = "上传部署流程文件", description = "传入文件")
public R checkUpload(@RequestParam MultipartFile file) {
boolean temp = Objects.requireNonNull(file.getOriginalFilename()).endsWith(FlowEngineConstant.SUFFIX);
return R.data(Kv.create().set("name", file.getOriginalFilename()).set("success", temp));
}
/**
* 上传部署流程文件
*
* @param files 流程文件
* @param category 类型
*/
@PostMapping("deploy-upload")
@ApiOperationSupport(order = 5)
@Operation(summary = "上传部署流程文件", description = "传入文件")
public R deployUpload(@RequestParam List<MultipartFile> files,
@RequestParam String category,
@RequestParam(required = false, defaultValue = "") String tenantIds) {
return R.status(flowEngineService.deployUpload(files, category, Func.toStrList(tenantIds)));
}
}

View File

@@ -1,134 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.Parameters;
import io.swagger.v3.oas.annotations.enums.ParameterIn;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.secure.annotation.IsAdministrator;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.api.R;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.xss.annotation.XssIgnore;
import org.springblade.flow.engine.entity.FlowModel;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springframework.web.bind.annotation.*;
import java.util.Map;
/**
* 流程模型控制器
*
* @author Chill
*/
@Hidden
@NonDS
@RestController
@AllArgsConstructor
@IsAdministrator
@RequestMapping(AppConstant.APPLICATION_FLOW_NAME + "/model")
@Tag(name = "流程模型管理接口", description = "流程模型管理接口")
public class FlowModelController {
private final FlowEngineService flowEngineService;
/**
* 分页
*/
@GetMapping("/list")
@Parameters({
@Parameter(name = "modelKey", description = "模型标识", in = ParameterIn.QUERY, schema = @Schema(type = "string")),
@Parameter(name = "name", description = "模型名称", in = ParameterIn.QUERY, schema = @Schema(type = "string"))
})
@ApiOperationSupport(order = 1)
@Operation(summary = "分页", description = "传入notice")
public R<IPage<FlowModel>> list(@Parameter(hidden = true) @RequestParam Map<String, Object> flow, Query query) {
IPage<FlowModel> pages = flowEngineService.page(Condition.getPage(query), Condition.getQueryWrapper(flow, FlowModel.class)
.select("id,model_key modelKey,name,description,version,created,last_updated lastUpdated")
.orderByDesc("last_updated"));
return R.data(pages);
}
/**
* 删除
*/
@PostMapping("/remove")
@ApiOperationSupport(order = 2)
@Operation(summary = "删除", description = "传入主键集合")
public R remove(@Parameter(description = "主键集合") @RequestParam String ids) {
boolean temp = flowEngineService.removeByIds(Func.toStrList(ids));
return R.status(temp);
}
/**
* 部署
*/
@PostMapping("/deploy")
@ApiOperationSupport(order = 3)
@Operation(summary = "部署", description = "传入模型id和分类")
public R deploy(@Parameter(description = "模型id") @RequestParam String modelId,
@Parameter(description = "工作流分类") @RequestParam String category,
@Parameter(description = "租户ID") @RequestParam(required = false, defaultValue = "") String tenantIds) {
boolean temp = flowEngineService.deployModel(modelId, category, Func.toStrList(tenantIds));
return R.status(temp);
}
@XssIgnore
@PostMapping("submit")
@ApiOperationSupport(order = 4)
@Operation(summary = "保存/编辑")
@Parameters({
@Parameter(name = "id", description = "模型id"),
@Parameter(name = "name", description = "模型名称", required = true),
@Parameter(name = "modelKey", description = "模型key", required = true),
@Parameter(name = "description", description = "模型描述"),
@Parameter(name = "xml", description = "模型xml", required = true),
})
public R<FlowModel> submit(@RequestBody @Parameter(hidden = true) FlowModel model) {
return R.data(flowEngineService.submitModel(model));
}
@GetMapping("detail")
@Operation(summary = "详情")
@ApiOperationSupport(order = 5)
@Parameters({
@Parameter(name = "id", description = "模型id", required = true),
})
public R<FlowModel> detail(String id) {
return R.data(flowEngineService.getById(id));
}
}

View File

@@ -1,109 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.controller;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.servlet.http.HttpServletResponse;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springblade.core.launch.constant.AppConstant;
import org.springblade.core.tenant.annotation.NonDS;
import org.springblade.core.tool.api.R;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* 流程通用控制器
*
* @author Chill
*/
@Hidden
@NonDS
@Slf4j
@RestController
@AllArgsConstructor
@RequestMapping(AppConstant.APPLICATION_FLOW_NAME + "/process")
@Tag(name = "流程通用接口", description = "流程通用接口")
public class FlowProcessController {
private static final String IMAGE_NAME = "image";
private final FlowEngineService flowEngineService;
/**
* 获取流转历史列表
*
* @param processInstanceId 流程实例id
* @param startActivityId 开始节点id
* @param endActivityId 结束节点id
*/
@GetMapping(value = "history-flow-list")
public R<List<BladeFlow>> historyFlowList(@RequestParam String processInstanceId, String startActivityId, String endActivityId) {
return R.data(flowEngineService.historyFlowList(processInstanceId, startActivityId, endActivityId));
}
/**
* 流程节点进程图
*
* @param processDefinitionId 流程id
* @param processInstanceId 流程实例id
*/
@GetMapping(value = "model-view")
public R modelView(String processDefinitionId, String processInstanceId) {
return R.data(flowEngineService.modelView(processDefinitionId, processInstanceId));
}
/**
* 流程节点进程图
*
* @param processInstanceId 流程实例id
* @param httpServletResponse http响应
*/
@GetMapping(value = "diagram-view")
public void diagramView(String processInstanceId, HttpServletResponse httpServletResponse) {
flowEngineService.diagramView(processInstanceId, httpServletResponse);
}
/**
* 流程图展示
*
* @param processDefinitionId 流程id
* @param processInstanceId 实例id
* @param resourceType 资源类型
* @param response 响应
*/
@GetMapping("resource-view")
public void resourceView(@RequestParam String processDefinitionId, String processInstanceId, @RequestParam(defaultValue = IMAGE_NAME) String resourceType, HttpServletResponse response) {
flowEngineService.resourceView(processDefinitionId, processInstanceId, resourceType, response);
}
}

View File

@@ -1,61 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.entity;
import lombok.Data;
import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
/**
* 运行实体类
*
* @author Chill
*/
@Data
public class FlowExecution implements Serializable {
@Serial
private static final long serialVersionUID = 1L;
private String id;
private String name;
private String startUserId;
private String startUser;
private Date startTime;
private String taskDefinitionId;
private String taskDefinitionKey;
private String category;
private String categoryName;
private String processInstanceId;
private String processDefinitionId;
private String processDefinitionKey;
private String activityId;
private int suspensionState;
private String executionId;
}

View File

@@ -1,69 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.entity;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
/**
* 流程模型
*
* @author Chill
*/
@Data
@TableName("ACT_DE_MODEL")
public class FlowModel implements Serializable {
@Serial
private static final long serialVersionUID = 1L;
public static final int MODEL_TYPE_BPMN = 0;
public static final int MODEL_TYPE_FORM = 2;
public static final int MODEL_TYPE_APP = 3;
public static final int MODEL_TYPE_DECISION_TABLE = 4;
public static final int MODEL_TYPE_CMMN = 5;
private String id;
private String name;
private String modelKey;
private String description;
private Date created;
private Date lastUpdated;
private String createdBy;
private String lastUpdatedBy;
private Integer version;
private String modelEditorJson;
private String modelComment;
private Integer modelType;
private String tenantId;
private byte[] thumbnail;
private String modelEditorXml;
}

View File

@@ -1,74 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.entity;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.flowable.engine.impl.persistence.entity.ProcessDefinitionEntityImpl;
import org.springblade.flow.engine.utils.FlowCache;
import java.io.Serializable;
import java.util.Date;
/**
* FlowProcess
*
* @author Chill
*/
@Data
@NoArgsConstructor
public class FlowProcess implements Serializable {
private String id;
private String tenantId;
private String name;
private String key;
private String category;
private String categoryName;
private Integer version;
private String deploymentId;
private String resourceName;
private String diagramResourceName;
private Integer suspensionState;
private Date deploymentTime;
public FlowProcess(ProcessDefinitionEntityImpl entity) {
if (entity != null) {
this.id = entity.getId();
this.tenantId = entity.getTenantId();
this.name = entity.getName();
this.key = entity.getKey();
this.category = entity.getCategory();
this.categoryName = FlowCache.getCategoryName(entity.getCategory());
this.version = entity.getVersion();
this.deploymentId = entity.getDeploymentId();
this.resourceName = entity.getResourceName();
this.diagramResourceName = entity.getDiagramResourceName();
this.suspensionState = entity.getSuspensionState();
}
}
}

View File

@@ -1,55 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.springblade.flow.engine.entity.FlowModel;
import java.util.List;
/**
* FlowMapper.
*
* @author Chill
*/
public interface FlowMapper extends BaseMapper<FlowModel> {
/**
* 自定义分页
* @param page
* @param flowModel
* @return
*/
List<FlowModel> selectFlowPage(IPage page, FlowModel flowModel);
/**
* 获取模型
* @param parentModelId
* @return
*/
List<FlowModel> findByParentModelId(String parentModelId);
}

View File

@@ -1,53 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.springblade.flow.engine.mapper.FlowMapper">
<!-- 通用查询映射结果 -->
<resultMap id="flowModelResultMap" type="org.springblade.flow.engine.entity.FlowModel">
<result column="id" property="id"/>
<result column="name" property="name"/>
<result column="model_key" property="modelKey"/>
<result column="description" property="description"/>
<result column="model_comment" property="modelComment"/>
<result column="created" property="created"/>
<result column="created_by" property="createdBy"/>
<result column="last_updated" property="lastUpdated"/>
<result column="last_updated_by" property="lastUpdatedBy"/>
<result column="version" property="version"/>
<result column="model_editor_json" property="modelEditorJson"/>
<result column="thumbnail" property="thumbnail"/>
<result column="model_type" property="modelType"/>
<result column="tenant_id" property="tenantId"/>
</resultMap>
<select id="selectFlowPage" resultMap="flowModelResultMap">
SELECT
a.id,
a.name,
a.model_key,
a.description,
a.model_comment,
a.created,
a.created_by,
a.last_updated,
a.last_updated_by,
a.version,
a.model_editor_json,
a.thumbnail,
a.model_type,
a.tenant_id
FROM
ACT_DE_MODEL a
WHERE
1 = 1
ORDER BY
a.created DESC
</select>
<select id="findByParentModelId" parameterType="string" resultMap="flowModelResultMap">
select model.* from ACT_DE_MODEL_RELATION modelrelation
inner join ACT_DE_MODEL model on modelrelation.model_id = model.id
where modelrelation.parent_model_id = #{_parameter}
</select>
</mapper>

View File

@@ -1,174 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.engine.entity.FlowExecution;
import org.springblade.flow.engine.entity.FlowModel;
import org.springblade.flow.engine.entity.FlowProcess;
import org.springframework.web.multipart.MultipartFile;
import jakarta.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Map;
/**
* FlowEngineService
*
* @author Chill
*/
public interface FlowEngineService extends IService<FlowModel> {
/**
* 自定义分页
*
* @param page 分页工具
* @param flowModel 流程模型
* @return
*/
IPage<FlowModel> selectFlowPage(IPage<FlowModel> page, FlowModel flowModel);
/**
* 流程管理列表
*
* @param page 分页工具
* @param category 分类
* @param mode 形态
* @return
*/
IPage<FlowProcess> selectProcessPage(IPage<FlowProcess> page, String category, Integer mode);
/**
* 流程管理列表
*
* @param page 分页工具
* @param processInstanceId 流程实例id
* @param processDefinitionKey 流程key
* @return
*/
IPage<FlowExecution> selectFollowPage(IPage<FlowExecution> page, String processInstanceId, String processDefinitionKey);
/**
* 获取流转历史列表
*
* @param processInstanceId 流程实例id
* @param startActivityId 开始节点id
* @param endActivityId 结束节点id
* @return
*/
List<BladeFlow> historyFlowList(String processInstanceId, String startActivityId, String endActivityId);
/**
* 变更流程状态
*
* @param state 状态
* @param processId 流程ID
* @return
*/
String changeState(String state, String processId);
/**
* 删除部署流程
*
* @param deploymentIds 部署流程id集合
* @return
*/
boolean deleteDeployment(String deploymentIds);
/**
* 上传部署流程
*
* @param files 流程配置文件
* @param category 流程分类
* @param tenantIdList 租户id集合
* @return
*/
boolean deployUpload(List<MultipartFile> files, String category, List<String> tenantIdList);
/**
* 部署流程
*
* @param modelId 模型id
* @param category 分类
* @param tenantIdList 租户id集合
* @return
*/
boolean deployModel(String modelId, String category, List<String> tenantIdList);
/**
* 删除流程实例
*
* @param processInstanceId 流程实例id
* @param deleteReason 删除原因
* @return
*/
boolean deleteProcessInstance(String processInstanceId, String deleteReason);
/**
* 保存/更新模型
*
* @param model 模型
* @return 模型
*/
FlowModel submitModel(FlowModel model);
/**
* 流程节点进程图
*
* @param processDefinitionId
* @param processInstanceId
* @return
*/
Map<String, Object> modelView(String processDefinitionId, String processInstanceId);
/**
* 流程节点进程图
*
* @param processInstanceId
* @param httpServletResponse
*/
void diagramView(String processInstanceId, HttpServletResponse httpServletResponse);
/**
* 流程图展示
*
* @param processDefinitionId
* @param processInstanceId
* @param resourceType
* @param response
*/
void resourceView(String processDefinitionId, String processInstanceId, String resourceType, HttpServletResponse response);
/**
* 获取XML
*
* @param model
* @return
*/
byte[] getModelEditorXML(FlowModel model);
}

View File

@@ -1,568 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.service.impl;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.node.ObjectNode;
import jakarta.servlet.http.HttpServletResponse;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.flowable.bpmn.converter.BpmnXMLConverter;
import org.flowable.bpmn.model.BpmnModel;
import org.flowable.bpmn.model.Process;
import org.flowable.common.engine.impl.util.IoUtil;
import org.flowable.common.engine.impl.util.io.StringStreamSource;
import org.flowable.editor.language.json.converter.BpmnJsonConverter;
import org.flowable.editor.language.json.converter.BpmnJsonConverterContext;
import org.flowable.editor.language.json.converter.CustomBpmnJsonConverterContext;
import org.flowable.engine.*;
import org.flowable.engine.history.HistoricActivityInstance;
import org.flowable.engine.history.HistoricProcessInstance;
import org.flowable.engine.impl.persistence.entity.ExecutionEntityImpl;
import org.flowable.engine.impl.persistence.entity.ProcessDefinitionEntityImpl;
import org.flowable.engine.repository.Deployment;
import org.flowable.engine.repository.ProcessDefinition;
import org.flowable.engine.repository.ProcessDefinitionQuery;
import org.flowable.engine.runtime.ProcessInstance;
import org.flowable.engine.runtime.ProcessInstanceQuery;
import org.flowable.engine.task.Comment;
import org.flowable.image.ProcessDiagramGenerator;
import org.springblade.common.cache.UserCache;
import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.utils.DateUtil;
import org.springblade.core.tool.utils.FileUtil;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.flow.core.entity.BladeFlow;
import org.springblade.flow.core.enums.FlowModeEnum;
import org.springblade.flow.core.utils.TaskUtil;
import org.springblade.flow.engine.constant.FlowEngineConstant;
import org.springblade.flow.engine.entity.FlowExecution;
import org.springblade.flow.engine.entity.FlowModel;
import org.springblade.flow.engine.entity.FlowProcess;
import org.springblade.flow.engine.mapper.FlowMapper;
import org.springblade.flow.engine.service.FlowEngineService;
import org.springblade.flow.engine.utils.FlowCache;
import org.springblade.modules.system.pojo.entity.User;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.*;
/**
* 工作流服务实现类
*
* @author Chill
*/
@Slf4j
@Service
@AllArgsConstructor
public class FlowEngineServiceImpl extends ServiceImpl<FlowMapper, FlowModel> implements FlowEngineService {
private static final String ALREADY_IN_STATE = "already in state";
private static final String USR_TASK = "userTask";
private static final String IMAGE_NAME = "image";
private static final String XML_NAME = "xml";
private static final Integer INT_1024 = 1024;
private static final BpmnJsonConverter BPMN_JSON_CONVERTER = new BpmnJsonConverter();
private static final BpmnXMLConverter BPMN_XML_CONVERTER = new BpmnXMLConverter();
private final ObjectMapper objectMapper;
private final RepositoryService repositoryService;
private final RuntimeService runtimeService;
private final HistoryService historyService;
private final TaskService taskService;
private final ProcessEngine processEngine;
@Override
public IPage<FlowModel> selectFlowPage(IPage<FlowModel> page, FlowModel flowModel) {
return page.setRecords(baseMapper.selectFlowPage(page, flowModel));
}
@Override
public IPage<FlowProcess> selectProcessPage(IPage<FlowProcess> page, String category, Integer mode) {
ProcessDefinitionQuery processDefinitionQuery = repositoryService.createProcessDefinitionQuery().latestVersion().orderByProcessDefinitionKey().asc();
// 通用流程
if (mode == FlowModeEnum.COMMON.getMode()) {
processDefinitionQuery.processDefinitionWithoutTenantId();
}
// 定制流程
else if (!AuthUtil.isAdministrator()) {
processDefinitionQuery.processDefinitionTenantId(AuthUtil.getTenantId());
}
if (StringUtils.isNotEmpty(category)) {
processDefinitionQuery.processDefinitionCategory(category);
}
List<ProcessDefinition> processDefinitionList = processDefinitionQuery.listPage(Func.toInt((page.getCurrent() - 1) * page.getSize()), Func.toInt(page.getSize()));
List<FlowProcess> flowProcessList = new ArrayList<>();
processDefinitionList.forEach(processDefinition -> {
String deploymentId = processDefinition.getDeploymentId();
Deployment deployment = repositoryService.createDeploymentQuery().deploymentId(deploymentId).singleResult();
FlowProcess flowProcess = new FlowProcess((ProcessDefinitionEntityImpl) processDefinition);
flowProcess.setDeploymentTime(deployment.getDeploymentTime());
flowProcessList.add(flowProcess);
});
page.setTotal(processDefinitionQuery.count());
page.setRecords(flowProcessList);
return page;
}
@Override
public IPage<FlowExecution> selectFollowPage(IPage<FlowExecution> page, String processInstanceId, String processDefinitionKey) {
ProcessInstanceQuery processInstanceQuery = runtimeService.createProcessInstanceQuery();
if (StringUtil.isNotBlank(processInstanceId)) {
processInstanceQuery.processInstanceId(processInstanceId);
}
if (StringUtil.isNotBlank(processDefinitionKey)) {
processInstanceQuery.processDefinitionKey(processDefinitionKey);
}
List<FlowExecution> flowList = new ArrayList<>();
List<ProcessInstance> procInsList = processInstanceQuery.listPage(Func.toInt((page.getCurrent() - 1) * page.getSize()), Func.toInt(page.getSize()));
procInsList.forEach(processInstance -> {
ExecutionEntityImpl execution = (ExecutionEntityImpl) processInstance;
FlowExecution flowExecution = new FlowExecution();
flowExecution.setId(execution.getId());
flowExecution.setName(execution.getName());
flowExecution.setStartUserId(execution.getStartUserId());
User taskUser = UserCache.getUserByTaskUser(execution.getStartUserId());
if (taskUser != null) {
flowExecution.setStartUser(taskUser.getName());
}
flowExecution.setStartTime(execution.getStartTime());
flowExecution.setExecutionId(execution.getId());
flowExecution.setProcessInstanceId(execution.getProcessInstanceId());
flowExecution.setProcessDefinitionId(execution.getProcessDefinitionId());
flowExecution.setProcessDefinitionKey(execution.getProcessDefinitionKey());
flowExecution.setSuspensionState(execution.getSuspensionState());
FlowProcess processDefinition = FlowCache.getProcessDefinition(execution.getProcessDefinitionId());
flowExecution.setCategory(processDefinition.getCategory());
flowExecution.setCategoryName(FlowCache.getCategoryName(processDefinition.getCategory()));
flowList.add(flowExecution);
});
page.setTotal(processInstanceQuery.count());
page.setRecords(flowList);
return page;
}
@Override
public List<BladeFlow> historyFlowList(String processInstanceId, String startActivityId, String endActivityId) {
List<BladeFlow> flowList = new LinkedList<>();
List<HistoricActivityInstance> historicActivityInstanceList = historyService.createHistoricActivityInstanceQuery().processInstanceId(processInstanceId).orderByHistoricActivityInstanceStartTime().asc().orderByHistoricActivityInstanceEndTime().asc().list();
boolean start = false;
Map<String, Integer> activityMap = new HashMap<>(16);
for (int i = 0; i < historicActivityInstanceList.size(); i++) {
HistoricActivityInstance historicActivityInstance = historicActivityInstanceList.get(i);
// 过滤开始节点前的节点
if (StringUtil.isNotBlank(startActivityId) && startActivityId.equals(historicActivityInstance.getActivityId())) {
start = true;
}
if (StringUtil.isNotBlank(startActivityId) && !start) {
continue;
}
// 显示开始节点和结束节点,并且执行人不为空的任务
if (StringUtils.equals(USR_TASK, historicActivityInstance.getActivityType())
|| FlowEngineConstant.START_EVENT.equals(historicActivityInstance.getActivityType())
|| FlowEngineConstant.END_EVENT.equals(historicActivityInstance.getActivityType())) {
// 给节点增加序号
activityMap.computeIfAbsent(historicActivityInstance.getActivityId(), k -> activityMap.size());
BladeFlow flow = new BladeFlow();
flow.setHistoryActivityId(historicActivityInstance.getActivityId());
flow.setHistoryActivityName(historicActivityInstance.getActivityName());
flow.setCreateTime(historicActivityInstance.getStartTime());
flow.setEndTime(historicActivityInstance.getEndTime());
String durationTime = DateUtil.secondToTime(Func.toLong(historicActivityInstance.getDurationInMillis(), 0L) / 1000);
flow.setHistoryActivityDurationTime(durationTime);
// 获取流程发起人名称
if (FlowEngineConstant.START_EVENT.equals(historicActivityInstance.getActivityType())) {
List<HistoricProcessInstance> processInstanceList = historyService.createHistoricProcessInstanceQuery().processInstanceId(processInstanceId).orderByProcessInstanceStartTime().asc().list();
if (!processInstanceList.isEmpty()) {
if (StringUtil.isNotBlank(processInstanceList.get(0).getStartUserId())) {
String taskUser = processInstanceList.get(0).getStartUserId();
User user = UserCache.getUser(TaskUtil.getUserId(taskUser));
if (user != null) {
flow.setAssignee(historicActivityInstance.getAssignee());
flow.setAssigneeName(user.getName());
}
}
}
}
// 获取任务执行人名称
if (StringUtil.isNotBlank(historicActivityInstance.getAssignee())) {
User user = UserCache.getUser(TaskUtil.getUserId(historicActivityInstance.getAssignee()));
if (user != null) {
flow.setAssignee(historicActivityInstance.getAssignee());
flow.setAssigneeName(user.getName());
}
}
// 获取意见评论内容
if (StringUtil.isNotBlank(historicActivityInstance.getTaskId())) {
List<Comment> commentList = taskService.getTaskComments(historicActivityInstance.getTaskId());
if (!commentList.isEmpty()) {
flow.setComment(commentList.get(0).getFullMessage());
}
}
flowList.add(flow);
}
// 过滤结束节点后的节点
if (StringUtils.isNotBlank(endActivityId) && endActivityId.equals(historicActivityInstance.getActivityId())) {
boolean temp = false;
Integer activityNum = activityMap.get(historicActivityInstance.getActivityId());
// 该活动节点,后续节点是否在结束节点之前,在后续节点中是否存在
for (int j = i + 1; j < historicActivityInstanceList.size(); j++) {
HistoricActivityInstance hi = historicActivityInstanceList.get(j);
Integer activityNumA = activityMap.get(hi.getActivityId());
boolean numberTemp = activityNumA != null && activityNumA < activityNum;
boolean equalsTemp = StringUtils.equals(hi.getActivityId(), historicActivityInstance.getActivityId());
if (numberTemp || equalsTemp) {
temp = true;
}
}
if (!temp) {
break;
}
}
}
return flowList;
}
@Override
public String changeState(String state, String processId) {
try {
if (state.equals(FlowEngineConstant.ACTIVE)) {
repositoryService.activateProcessDefinitionById(processId, true, null);
return StringUtil.format("激活ID为 [{}] 的流程成功", processId);
} else if (state.equals(FlowEngineConstant.SUSPEND)) {
repositoryService.suspendProcessDefinitionById(processId, true, null);
return StringUtil.format("挂起ID为 [{}] 的流程成功", processId);
} else {
return "暂无流程变更";
}
} catch (Exception e) {
if (e.getMessage().contains(ALREADY_IN_STATE)) {
return StringUtil.format("ID为 [{}] 的流程已是此状态,无需操作", processId);
}
return e.getMessage();
}
}
@Override
public boolean deleteDeployment(String deploymentIds) {
Func.toStrList(deploymentIds).forEach(deploymentId -> repositoryService.deleteDeployment(deploymentId, true));
return true;
}
@Override
public boolean deployUpload(List<MultipartFile> files, String category, List<String> tenantIdList) {
files.forEach(file -> {
try {
String fileName = file.getOriginalFilename();
InputStream fileInputStream = file.getInputStream();
byte[] bytes = FileUtil.copyToByteArray(fileInputStream);
if (Func.isNotEmpty(tenantIdList)) {
tenantIdList.forEach(tenantId -> {
Deployment deployment = repositoryService.createDeployment().addBytes(fileName, bytes).tenantId(tenantId).deploy();
deploy(deployment, category);
});
} else {
Deployment deployment = repositoryService.createDeployment().addBytes(fileName, bytes).deploy();
deploy(deployment, category);
}
} catch (IOException e) {
e.printStackTrace();
}
});
return true;
}
@Override
public boolean deployModel(String modelId, String category, List<String> tenantIdList) {
FlowModel model = this.getById(modelId);
if (model == null) {
throw new ServiceException("未找到模型 id: " + modelId);
}
byte[] bytes = getBpmnXML(model);
String processName = model.getName();
if (!StringUtil.endsWithIgnoreCase(processName, FlowEngineConstant.SUFFIX)) {
processName += FlowEngineConstant.SUFFIX;
}
String finalProcessName = processName;
if (Func.isNotEmpty(tenantIdList)) {
tenantIdList.forEach(tenantId -> {
Deployment deployment = repositoryService.createDeployment().addBytes(finalProcessName, bytes).name(model.getName()).key(model.getModelKey()).tenantId(tenantId).deploy();
deploy(deployment, category);
});
} else {
Deployment deployment = repositoryService.createDeployment().addBytes(finalProcessName, bytes).name(model.getName()).key(model.getModelKey()).deploy();
deploy(deployment, category);
}
return true;
}
@Override
public boolean deleteProcessInstance(String processInstanceId, String deleteReason) {
runtimeService.deleteProcessInstance(processInstanceId, deleteReason);
return true;
}
private void deploy(Deployment deployment, String category) {
log.debug("流程部署--------deploy: " + deployment + " 分类---------->" + category);
List<ProcessDefinition> list = repositoryService.createProcessDefinitionQuery().deploymentId(deployment.getId()).list();
StringBuilder logBuilder = new StringBuilder(500);
List<Object> logArgs = new ArrayList<>();
// 设置流程分类
for (ProcessDefinition processDefinition : list) {
if (StringUtil.isNotBlank(category)) {
repositoryService.setProcessDefinitionCategory(processDefinition.getId(), category);
}
logBuilder.append("部署成功,流程ID={} \n");
logArgs.add(processDefinition.getId());
}
if (list.isEmpty()) {
throw new ServiceException("部署失败,未找到流程");
} else {
log.info(logBuilder.toString(), logArgs.toArray());
}
}
@Override
public FlowModel submitModel(FlowModel model) {
FlowModel flowModel = new FlowModel();
flowModel.setId(model.getId());
flowModel.setVersion(Func.toInt(model.getVersion(), 0) + 1);
flowModel.setName(model.getName());
flowModel.setModelKey(model.getModelKey());
flowModel.setModelType(FlowModel.MODEL_TYPE_BPMN);
flowModel.setCreatedBy(TaskUtil.getTaskUser());
flowModel.setDescription(model.getDescription());
flowModel.setLastUpdated(Calendar.getInstance().getTime());
flowModel.setLastUpdatedBy(TaskUtil.getTaskUser());
flowModel.setTenantId(AuthUtil.getTenantId());
flowModel.setModelEditorXml(model.getModelEditorXml());
if (StringUtil.isBlank(model.getId())) {
flowModel.setCreated(Calendar.getInstance().getTime());
}
if (StringUtil.isNotBlank(model.getModelEditorXml())) {
flowModel.setModelEditorJson(getBpmnJson(model.getModelEditorXml()));
}
this.saveOrUpdate(flowModel);
return flowModel;
}
@Override
public Map<String, Object> modelView(String processDefinitionId, String processInstanceId) {
Map<String, Object> result = new HashMap<>();
// 节点标记
if (StringUtil.isNotBlank(processInstanceId)) {
result.put("flow", this.historyFlowList(processInstanceId, null, null));
HistoricProcessInstance processInstance = historyService.createHistoricProcessInstanceQuery()
.processInstanceId(processInstanceId)
.singleResult();
processDefinitionId = processInstance.getProcessDefinitionId();
}
BpmnModel bpmnModel = repositoryService.getBpmnModel(processDefinitionId);
// 流程图展示
result.put("xml", new String(new BpmnXMLConverter().convertToXML(bpmnModel)));
return result;
}
@Override
public void diagramView(String processInstanceId, HttpServletResponse httpServletResponse) {
// 获得当前活动的节点
String processDefinitionId;
// 如果流程已经结束,则得到结束节点
if (this.isFinished(processInstanceId)) {
HistoricProcessInstance pi = historyService.createHistoricProcessInstanceQuery().processInstanceId(processInstanceId).singleResult();
processDefinitionId = pi.getProcessDefinitionId();
} else {
// 如果流程没有结束,则取当前活动节点
// 根据流程实例ID获得当前处于活动状态的ActivityId合集
ProcessInstance pi = runtimeService.createProcessInstanceQuery().processInstanceId(processInstanceId).singleResult();
processDefinitionId = pi.getProcessDefinitionId();
}
List<String> highLightedActivities = new ArrayList<>();
// 获得活动的节点
List<HistoricActivityInstance> highLightedActivityList = historyService.createHistoricActivityInstanceQuery().processInstanceId(processInstanceId).orderByHistoricActivityInstanceStartTime().asc().list();
for (HistoricActivityInstance tempActivity : highLightedActivityList) {
String activityId = tempActivity.getActivityId();
highLightedActivities.add(activityId);
}
List<String> flows = new ArrayList<>();
// 获取流程图
BpmnModel bpmnModel = repositoryService.getBpmnModel(processDefinitionId);
ProcessEngineConfiguration engConf = processEngine.getProcessEngineConfiguration();
ProcessDiagramGenerator diagramGenerator = engConf.getProcessDiagramGenerator();
InputStream in = diagramGenerator.generateDiagram(bpmnModel, "bmp", highLightedActivities, flows, engConf.getActivityFontName(),
engConf.getLabelFontName(), engConf.getAnnotationFontName(), engConf.getClassLoader(), 1.0, true);
OutputStream out = null;
byte[] buf = new byte[1024];
int length;
try {
out = httpServletResponse.getOutputStream();
while ((length = in.read(buf)) != -1) {
out.write(buf, 0, length);
}
} catch (IOException e) {
log.error("操作异常", e);
} finally {
IoUtil.closeSilently(out);
IoUtil.closeSilently(in);
}
}
@Override
public void resourceView(String processDefinitionId, String processInstanceId, String resourceType, HttpServletResponse response) {
if (StringUtil.isAllBlank(processDefinitionId, processInstanceId)) {
return;
}
if (StringUtil.isBlank(processDefinitionId)) {
ProcessInstance processInstance = runtimeService.createProcessInstanceQuery().processInstanceId(processInstanceId).singleResult();
processDefinitionId = processInstance.getProcessDefinitionId();
}
ProcessDefinition processDefinition = repositoryService.createProcessDefinitionQuery().processDefinitionId(processDefinitionId).singleResult();
String resourceName = "";
if (resourceType.equals(IMAGE_NAME)) {
resourceName = processDefinition.getDiagramResourceName();
} else if (resourceType.equals(XML_NAME)) {
resourceName = processDefinition.getResourceName();
}
try {
InputStream resourceAsStream = repositoryService.getResourceAsStream(processDefinition.getDeploymentId(), resourceName);
byte[] b = new byte[1024];
int len;
while ((len = resourceAsStream.read(b, 0, INT_1024)) != -1) {
response.getOutputStream().write(b, 0, len);
}
} catch (Exception exception) {
exception.printStackTrace();
}
}
@Override
public byte[] getModelEditorXML(FlowModel model) {
return getBpmnXML(model);
}
/**
* 是否已完结
*
* @param processInstanceId 流程实例id
* @return bool
*/
private boolean isFinished(String processInstanceId) {
return historyService.createHistoricProcessInstanceQuery().finished()
.processInstanceId(processInstanceId).count() > 0;
}
/**
* xml转bpmn json
*
* @param xml xml
* @return json
*/
private String getBpmnJson(String xml) {
return BPMN_JSON_CONVERTER.convertToJson(getBpmnModel(xml)).toString();
}
/**
* xml转bpmnModel
*
* @param xml xml
* @return bpmnModel
*/
private BpmnModel getBpmnModel(String xml) {
return BPMN_XML_CONVERTER.convertToBpmnModel(new StringStreamSource(xml), false, false);
}
private byte[] getBpmnXML(FlowModel model) {
BpmnModel bpmnModel = getBpmnModel(model);
return getBpmnXML(bpmnModel);
}
private byte[] getBpmnXML(BpmnModel bpmnModel) {
for (Process process : bpmnModel.getProcesses()) {
if (StringUtils.isNotEmpty(process.getId())) {
char firstCharacter = process.getId().charAt(0);
if (Character.isDigit(firstCharacter)) {
process.setId("a" + process.getId());
}
}
}
return BPMN_XML_CONVERTER.convertToXML(bpmnModel);
}
private BpmnModel getBpmnModel(FlowModel model) {
BpmnModel bpmnModel;
try {
Map<String, FlowModel> formMap = new HashMap<>(16);
Map<String, FlowModel> decisionTableMap = new HashMap<>(16);
List<FlowModel> referencedModels = baseMapper.findByParentModelId(model.getId());
for (FlowModel childModel : referencedModels) {
if (FlowModel.MODEL_TYPE_FORM == childModel.getModelType()) {
formMap.put(childModel.getId(), childModel);
} else if (FlowModel.MODEL_TYPE_DECISION_TABLE == childModel.getModelType()) {
decisionTableMap.put(childModel.getId(), childModel);
}
}
bpmnModel = getBpmnModel(model, formMap, decisionTableMap);
} catch (Exception e) {
log.error("Could not generate BPMN 2.0 model for {}", model.getId(), e);
throw new ServiceException("Could not generate BPMN 2.0 model");
}
return bpmnModel;
}
private BpmnModel getBpmnModel(FlowModel model, Map<String, FlowModel> formMap, Map<String, FlowModel> decisionTableMap) {
try {
ObjectNode editorJsonNode = (ObjectNode) objectMapper.readTree(model.getModelEditorJson());
Map<String, String> formKeyMap = new HashMap<>(16);
for (FlowModel formModel : formMap.values()) {
formKeyMap.put(formModel.getId(), formModel.getModelKey());
}
Map<String, String> decisionTableKeyMap = new HashMap<>(16);
for (FlowModel decisionTableModel : decisionTableMap.values()) {
decisionTableKeyMap.put(decisionTableModel.getId(), decisionTableModel.getModelKey());
}
BpmnJsonConverterContext converterContext = new CustomBpmnJsonConverterContext(formKeyMap, decisionTableKeyMap);
return BPMN_JSON_CONVERTER.convertToBpmnModel(editorJsonNode, converterContext);
} catch (Exception e) {
log.error("Could not generate BPMN 2.0 model for {}", model.getId(), e);
throw new ServiceException("Could not generate BPMN 2.0 model");
}
}
}

View File

@@ -1,89 +0,0 @@
/**
* BladeX Commercial License Agreement
* Copyright (c) 2018-2099, https://bladex.cn. All rights reserved.
* <p>
* Use of this software is governed by the Commercial License Agreement
* obtained after purchasing a license from BladeX.
* <p>
* 1. This software is for development use only under a valid license
* from BladeX.
* <p>
* 2. Redistribution of this software's source code to any third party
* without a commercial license is strictly prohibited.
* <p>
* 3. Licensees may copyright their own code but cannot use segments
* from this software for such purposes. Copyright of this software
* remains with BladeX.
* <p>
* Using this software signifies agreement to this License, and the software
* must not be used for illegal purposes.
* <p>
* THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY. The author is
* not liable for any claims arising from secondary or illegal development.
* <p>
* Author: Chill Zhuang (bladejava@qq.com)
*/
package org.springblade.flow.engine.utils;
import org.flowable.engine.RepositoryService;
import org.flowable.engine.impl.persistence.entity.ProcessDefinitionEntityImpl;
import org.flowable.engine.repository.ProcessDefinition;
import org.springblade.common.cache.DictCache;
import org.springblade.core.cache.utils.CacheUtil;
import org.springblade.core.tool.utils.BeanUtil;
import org.springblade.core.tool.utils.Func;
import org.springblade.core.tool.utils.SpringUtil;
import org.springblade.core.tool.utils.StringPool;
import org.springblade.flow.engine.entity.FlowProcess;
/**
* 流程缓存
*
* @author Chill
*/
public class FlowCache {
private static final String FLOW_CACHE = "flow:process";
private static final String FLOW_DEFINITION_ID = "definition:id";
private static RepositoryService repositoryService;
private static RepositoryService getRepositoryService() {
if (repositoryService == null) {
repositoryService = SpringUtil.getBean(RepositoryService.class);
}
return repositoryService;
}
/**
* 获得流程定义对象
*
* @param processDefinitionId 流程对象id
* @return
*/
public static FlowProcess getProcessDefinition(String processDefinitionId) {
return CacheUtil.get(FLOW_CACHE, FLOW_DEFINITION_ID, processDefinitionId, () -> {
ProcessDefinition processDefinition = getRepositoryService().createProcessDefinitionQuery().processDefinitionId(processDefinitionId).singleResult();
ProcessDefinitionEntityImpl processDefinitionEntity = BeanUtil.copyProperties(processDefinition, ProcessDefinitionEntityImpl.class);
return new FlowProcess(processDefinitionEntity);
});
}
/**
* 获取流程类型名
*
* @param category 流程类型
* @return
*/
public static String getCategoryName(String category) {
if (Func.isEmpty(category)) {
return StringPool.EMPTY;
}
String[] categoryArr = category.split(StringPool.UNDERSCORE);
if (categoryArr.length <= 1) {
return StringPool.EMPTY;
} else {
return DictCache.getValue(category.split(StringPool.UNDERSCORE)[0], Func.toInt(category.split(StringPool.UNDERSCORE)[1]));
}
}
}

View File

@@ -0,0 +1,32 @@
package org.springblade.modules.app.controller;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.tool.api.R;
import org.springblade.modules.system.service.IUserService;
import org.springframework.web.bind.annotation.*;
@Hidden
@RestController
@AllArgsConstructor
@RequestMapping("/app-common")
@Tag(name = "APP基础接口", description = "APP基础接口")
public class APPCommonController {
private final IUserService userService;
/**
* 最新版本
*/
@GetMapping("/latest-version")
@ApiOperationSupport(order = 1)
@Operation(summary = "最新版本")
public R<Boolean> hasChangedPassword() {
return R.data(userService.hasChangedPassword());
}
}

View File

@@ -0,0 +1,17 @@
package org.springblade.modules.app.controller;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.*;
@Hidden
@RestController
@AllArgsConstructor
@RequestMapping("/app-mall")
@Tag(name = "APP用户接口", description = "APP用户接口")
public class APPMallController {
}

View File

@@ -0,0 +1,54 @@
package org.springblade.modules.app.controller;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import io.swagger.v3.oas.annotations.Hidden;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.validation.Valid;
import lombok.AllArgsConstructor;
import org.springblade.core.tool.api.R;
import org.springblade.modules.develop.pojo.entity.Code;
import org.springblade.modules.system.service.IUserService;
import org.springframework.web.bind.annotation.*;
@Hidden
@RestController
@AllArgsConstructor
@RequestMapping("/app-user")
@Tag(name = "APP用户接口", description = "APP用户接口")
public class APPUserController {
private final IUserService userService;
/**
* 是否修改过密码
*/
@GetMapping("/has-changed")
@ApiOperationSupport(order = 1)
@Operation(summary = "是否修改过密码")
public R<Boolean> hasChangedPassword() {
return R.data(userService.hasChangedPassword());
}
/**
* 修改登录密码
*/
@PostMapping("/change-password")
@ApiOperationSupport(order = 2)
@Operation(summary = "修改登录密码", description = "传入String")
public R submit(@RequestBody String password) {
return R.status(userService.changePassword(password));
}
/**
* 邀请码
*/
@GetMapping("/invite-code")
@ApiOperationSupport(order = 3)
@Operation(summary = "是否修改过密码")
public R<String> inviteCode() {
return R.data(userService.inviteCode());
}
}

View File

@@ -1,92 +0,0 @@
package org.springblade.modules.appFormal.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.redis.ratelimiter.RateLimiter;
import org.springblade.core.tool.api.R;
import org.springblade.modules.appFormal.dto.PayOrderDicDTO;
import org.springblade.modules.appFormal.manager.FormalAppBaseManager;
import org.springblade.modules.appFormal.manager.FormalAppCustomerManager;
import org.springblade.modules.appFormal.manager.FormalAppMallManager;
import org.springblade.modules.appFormal.request.CustomerSmsRequest;
import org.springblade.modules.appFormal.vo.AppFormalBannerVO;
import org.springblade.modules.appFormal.vo.AppFormalMallSpuVO;
import org.springblade.modules.appFormal.vo.MallCategoryVO;
import org.springblade.modules.mall.pojo.vo.MallSpuVO;
import org.springframework.web.bind.annotation.*;
import java.util.List;
import java.util.concurrent.TimeUnit;
@RestController
@AllArgsConstructor
@RequestMapping("formal-app/base")
@Tag(name = "基本信息", description = "基本信息接口")
public class FormalBaseController {
private final FormalAppBaseManager appBaseManager;
private final FormalAppCustomerManager formalAppCustomerManager;
private final FormalAppMallManager mallProductManager;
@Operation(summary = "隐私政策")
@GetMapping("/formal-app-privacy")
public R<String> formalAppPrivacy() {
return R.data(appBaseManager.formalAppPrivacy());
}
@Operation(summary = "用户协议")
@GetMapping("/formal-app-agreement")
public R<String> formalAppAgreement() {
return R.data(appBaseManager.formalAppAgreement());
}
@RateLimiter(value = "yichayilu:sms:send", param = "#request.getPhone()", max =3, ttl = 12, timeUnit = TimeUnit.HOURS)
@Operation(summary = "发送验证码")
@PostMapping("/send-sms-code")
public R<Boolean> sendSmsCode(@RequestBody CustomerSmsRequest request) {
return R.data(formalAppCustomerManager.sendSmsCode(request.getPhone()));
}
/**
* 分类
*/
@Operation(summary = "商品类别")
@GetMapping("/find-category")
public R<List<MallCategoryVO>> findCategories() {
return R.data(mallProductManager.findCategories());
}
/**
* 商品列表
*/
@Operation(summary = "商品分页")
@GetMapping("/spu-list")
public R<IPage<AppFormalMallSpuVO>> list(Query query , AppFormalMallSpuVO spuVO) {
return R.data(mallProductManager.getSpuPage(Condition.getPage(query), spuVO));
}
@Operation(summary = "获得主banner")
@GetMapping("/find-main-banner")
public R<List<AppFormalBannerVO>> findMainBanner() {
return R.data(appBaseManager.findMainBanner());
}
@Operation(summary = "获得商城banner")
@GetMapping("/find-mall-banner")
public R<List<AppFormalBannerVO>> findMallBanner() {
return R.data(appBaseManager.findMallBanner());
}
}

View File

@@ -1,114 +0,0 @@
package org.springblade.modules.appFormal.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.qiniu.util.Auth;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.redis.ratelimiter.RateLimiter;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.api.R;
import org.springblade.modules.appFormal.manager.FormalAppCustomerManager;
import org.springblade.modules.appFormal.request.CustomerSmsRequest;
import org.springblade.modules.appFormal.request.UpdatePasswordRequest;
import org.springblade.modules.appFormal.vo.AppUserNoticeVO;
import org.springblade.modules.appFormal.vo.MallIntegralLogVO;
import org.springblade.modules.appFormal.vo.MallIntegralVO;
import org.springblade.modules.appFormal.vo.UserInfoVO;
import org.springblade.modules.desk.pojo.vo.NoticeVO;
import org.springframework.web.bind.annotation.*;
import java.util.concurrent.TimeUnit;
@RestController
@AllArgsConstructor
@RequestMapping("formal-app/customer")
@Tag(name = "用户信息", description = "用户信息接口")
public class FormalCustomerController {
private final FormalAppCustomerManager formalAppCustomerManager;
//用户相关
@Operation(summary = "校验短信")
@PostMapping("/check-sms-code")
public R<Boolean> checkSmsCode(@RequestBody CustomerSmsRequest request) {
return R.data(formalAppCustomerManager.checkSmsCode(request));
}
@Operation(summary = "查询用户信息")
@GetMapping("/find-userInfo")
public R<UserInfoVO> findUserInfo() {
return R.data(formalAppCustomerManager.findUserInfo(AuthUtil.getUserId()));
}
@Operation(summary = "修改密码")
@PutMapping("/update-password")
public R<Boolean> updatePassword(@RequestBody UpdatePasswordRequest request) {
return R.data(formalAppCustomerManager.updatePassword(request.setId(AuthUtil.getUserId())));
}
@Operation(summary = "修改密码")
@PutMapping("/update-password-non-code")
public R<Boolean> updatePasswordNonCode(@RequestBody UpdatePasswordRequest request) {
return R.data(formalAppCustomerManager.updatePasswordNonCode(request.setId(AuthUtil.getUserId())));
}
@Operation(summary = "用户退出登录")
@PostMapping("/userLogout")
public R<Boolean> userLogout() {
return R.data(formalAppCustomerManager.userLogout());
}
@Operation(summary = "账号注销")
@DeleteMapping("/delete-account")
public R<Boolean> deleteAccount() {
return R.data(formalAppCustomerManager.deleteAccount(AuthUtil.getUserId()));
}
// 商城积分相关
@Operation(summary = "查询商城积分")
@GetMapping("/find-mall-integral")
public R<MallIntegralVO> findMallIntegral() {
return R.data(formalAppCustomerManager.findMallIntegral(AuthUtil.getUserId()));
}
@Operation(summary = "查询商城积分流水")
@GetMapping("/mall-integral-log-page")
public R<IPage<MallIntegralLogVO>> findMallIntegralFlow(Query query , MallIntegralLogVO logVO) {
return R.data(formalAppCustomerManager.findMallIntegralFlow(Condition.getPage(query), logVO, AuthUtil.getUserId()));
}
@Operation(summary = "查询用户通知")
@GetMapping("/find-user-notice-page")
public R<IPage<AppUserNoticeVO>> findUserNoticePage(Query query , AppUserNoticeVO userNotice) {
return R.data(formalAppCustomerManager.findUserNoticePage(Condition.getPage(query), userNotice, AuthUtil.getUserId()));
}
@Operation(summary = "查询用户通知")
@PostMapping("/read-user-notice")
public R<Boolean> readUserNotice(AppUserNoticeVO userNotice) {
return R.status(formalAppCustomerManager.readUserNotice(userNotice.getId()));
}
@Operation(summary = "未读消息总数")
@GetMapping("/not-read-notice-count")
public R<Integer> notReadNoticeCount(AppUserNoticeVO userNotice) {
return R.data(formalAppCustomerManager.notReadNoticeCount(userNotice ,AuthUtil.getUserId()));
}
}

View File

@@ -1,97 +0,0 @@
package org.springblade.modules.appFormal.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.api.R;
import org.springblade.modules.appFormal.manager.FormalAppMallManager;
import org.springblade.modules.appFormal.request.AddressRemoveRequest;
import org.springblade.modules.appFormal.request.AddressSubmitRequest;
import org.springblade.modules.appFormal.request.MallCartRemoveRequest;
import org.springblade.modules.appFormal.request.MallCartRequest;
import org.springblade.modules.appFormal.vo.*;
import org.springblade.modules.mall.pojo.vo.MallSpuVO;
import org.springframework.web.bind.annotation.*;
import java.util.List;
@RestController
@AllArgsConstructor
@RequestMapping("formal-app/mall")
@Tag(name = "商城信息", description = "商城信息接口")
public class FormalMallController {
private final FormalAppMallManager mallProductManager;
//购物车相关
@Operation(summary = "购物车列表")
@GetMapping("/cart-list")
public R<IPage<AppFormalMallCartVO>> cartList(Query query, AppFormalMallCartVO cartVO) {
return R.data(mallProductManager.cartList(Condition.getPage( query), cartVO , AuthUtil.getUserId()));
}
@Operation(summary = "添加购物车")
@PostMapping("/add-cart")
public R<AppFormalMallCartInfoVO> addCart(@RequestBody MallCartRequest request) {
return R.data(mallProductManager.addCart(request.setUserId(AuthUtil.getUserId())));
}
@Operation(summary = "添加购物车(创建订单之前调用)")
@PostMapping("/add-cart-to-order")
public R<AppFormalMallCartInfoVO> addCartToOrder(@RequestBody MallCartRequest request) {
return R.data(mallProductManager.addCartToOrder(request.setUserId(AuthUtil.getUserId())));
}
@Operation(summary = "删除购物车")
@DeleteMapping("/delete-cart")
public R<Boolean> deleteCart(@RequestBody MallCartRemoveRequest request) {
return R.status(mallProductManager.deleteCart(request.getIds()));
}
@Operation(summary = "购物车修改数量")
@PostMapping("/update-cart-quantity")
public R<Boolean> updateCartQuantity(@RequestBody MallCartRequest request) {
return R.status(mallProductManager.updateCartQuantity(request));
}
//收货地址相关
@Operation(summary = "省市区列表")
@GetMapping("/region-list")
public R<List<AppFormalRegionInfoVO>> regionInfoList(@RequestParam Integer level, @RequestParam Long pid) {
return R.data(mallProductManager.regionInfoList(level , pid));
}
@Operation(summary = "添加收货地址")
@PostMapping("/add-address")
public R<Boolean> addAddressInfo(@RequestBody AddressSubmitRequest request){
return R.data(mallProductManager.submitAddressInfo(request));
}
@Operation(summary = "修改收货地址")
@PostMapping("/update-address")
public R<Boolean> updateAddressInfo(@RequestBody AddressSubmitRequest request){
return R.data(mallProductManager.submitAddressInfo(request));
}
@Operation(summary = "删除收货地址")
@DeleteMapping("/delete-address")
public R<Boolean> deleteAddressInfo( @RequestBody AddressRemoveRequest request){
return R.data(mallProductManager.deleteAddressInfo(request.getIds()));
}
@Operation(summary = "收货地址列表")
@GetMapping("/address-list")
public R<List<AppFormalAddressVO>> addressInfoList(){
return R.data(mallProductManager.addressInfoList(AuthUtil.getUserId()));
}
}

View File

@@ -1,99 +0,0 @@
package org.springblade.modules.appFormal.controller;
import com.baomidou.mybatisplus.core.metadata.IPage;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import org.springblade.core.mp.support.Condition;
import org.springblade.core.mp.support.Query;
import org.springblade.core.secure.utils.AuthUtil;
import org.springblade.core.tool.api.R;
import org.springblade.modules.appFormal.dto.PayOrderDicDTO;
import org.springblade.modules.appFormal.manager.FormalAppBaseManager;
import org.springblade.modules.appFormal.manager.FormalAppOrderManager;
import org.springblade.modules.appFormal.request.*;
import org.springblade.modules.appFormal.vo.*;
import org.springframework.web.bind.annotation.*;
import java.util.List;
@RestController
@AllArgsConstructor
@RequestMapping("formal-app/order")
@Tag(name = "订单信息", description = "订单信息接口")
public class FormalOrderController {
private final FormalAppOrderManager formalAppOrderManager;
private final FormalAppBaseManager appBaseManager;
/**
* 订单类型列表
* @return
*/
@Operation(summary = "订单类型列表")
@GetMapping("/find-orderBizModel")
public R<List<PayOrderDicDTO>> orderBizModel(){
return R.data(formalAppOrderManager.orderBizModel());
}
/**
* 订单列表分页
*/
@Operation(summary = "订单列表分页")
@GetMapping("/order-list")
public R<IPage<AppFormalOrderVO>> orderList(Query query, AppFormalOrderVO orderVO) {
return R.data(formalAppOrderManager.getOrderList(Condition.getPage( query), orderVO));
}
@Operation(summary = "商城订单详情")
@GetMapping("/mall-order-detail")
public R<AppFormalMallOrderVO> mallOrderDetail(Long id) {
return R.data(formalAppOrderManager.mallOrderDetail(id));
}
/**
* 提交订单
*/
@PostMapping("/mall-make-order")
public R<AppFormalPreviewOrderVO> mallMakeOrder( @RequestBody AppFormalPreviewOrderRequest request) {
return R.data(formalAppOrderManager.mallMakeOrder(request, AuthUtil.getUserId()));
}
/**
* 取消订单
*/
@PostMapping("/mall-cancel-order")
public R<Boolean> mallCancelOrder( @RequestBody AppForOrderIdRequest request) {
return R.data(formalAppOrderManager.mallCancelOrder(request.getId(), AuthUtil.getUserId()));
}
/**
* 确认收货
*/
@PostMapping("/mall-confirm-receipt")
public R<Boolean> mallConfirmReceipt( @RequestBody AppForOrderIdRequest request) {
return R.data(formalAppOrderManager.mallConfirmReceipt(request.getId(), AuthUtil.getUserId()));
}
/**
* 支付类型
* @return
*/
@Operation(summary = "获取支付类型")
@GetMapping("/find-payType")
public R<List<PayOrderDicDTO>> payType(Integer payModel){
return R.data(appBaseManager.payType(payModel));
}
}

View File

@@ -1,28 +0,0 @@
package org.springblade.modules.appFormal.convert;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;
import org.springblade.modules.appFormal.vo.AppFormalBannerVO;
import org.springblade.modules.appFormal.vo.AppUserNoticeVO;
import org.springblade.modules.appFormal.vo.MallIntegralLogVO;
import org.springblade.modules.customer.pojo.entity.UserNoticeEntity;
import org.springblade.modules.mall.pojo.entity.AppBannerEntity;
import org.springblade.modules.userPoint.pojo.entity.UserMallIntegralLogEntity;
import java.util.List;
/**
* @author jack
*/
@Mapper
public interface AppBaseConvert {
AppBaseConvert INSTANCE = Mappers.getMapper(AppBaseConvert.class);
List<AppFormalBannerVO> convertBannerListToVO(List<AppBannerEntity> bannerEntityList);
AppUserNoticeVO convertUserNoticePageToVO(UserNoticeEntity userNoticeEntity);
}

View File

@@ -1,48 +0,0 @@
package org.springblade.modules.appFormal.convert;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;
import org.springblade.modules.appFormal.request.AddressSubmitRequest;
import org.springblade.modules.appFormal.vo.*;
import org.springblade.modules.mall.pojo.entity.MallCartEntity;
import org.springblade.modules.mall.pojo.entity.MallSpuEntity;
import org.springblade.modules.mall.pojo.entity.UserAddressEntity;
import org.springblade.modules.mall.pojo.entity.YsCategoryEntity;
import org.springblade.modules.userPoint.pojo.entity.UserMallIntegralLogEntity;
import java.util.List;
/**
* @author jack
*/
@Mapper
public interface AppFormalMallConvert {
AppFormalMallConvert INSTANCE = Mappers.getMapper(AppFormalMallConvert.class);
AppFormalMallSpuVO convertMallSpuToVO(MallSpuEntity entity);
List<AppFormalMallSpuVO> convertMallSpuListToVO(List<MallSpuEntity> list);
Page<AppFormalMallSpuVO> convertMallSpuPageToVO(Page<MallSpuEntity> page);
MallCategoryVO convertMallCategoryToVO(YsCategoryEntity entity);
List<MallCategoryVO> convertMallCategoryListToVO(List<YsCategoryEntity> list);
AppFormalMallCartVO convertMallCartToVO(MallCartEntity entity);
List<AppFormalMallCartVO> convertMallCartListToVO(List<MallCartEntity> list);
Page<AppFormalMallCartVO> convertMallCartPageToVO(Page<MallCartEntity> page);
UserAddressEntity convertRequestToPo(AddressSubmitRequest request);
AppFormalAddressVO convertPoToVO(UserAddressEntity address);
List<AppFormalAddressVO> convertPoListToVoList(List<UserAddressEntity> addressList);
}

View File

@@ -1,27 +0,0 @@
package org.springblade.modules.appFormal.convert;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;
import org.springblade.modules.appFormal.vo.MallIntegralLogVO;
import org.springblade.modules.userPoint.pojo.entity.UserMallIntegralLogEntity;
import java.util.List;
/**
* @author jack
*/
@Mapper
public interface AppUserInfoConvert {
AppUserInfoConvert INSTANCE = Mappers.getMapper(AppUserInfoConvert.class);
MallIntegralLogVO convertIntegralToVO(UserMallIntegralLogEntity entity);
List<MallIntegralLogVO> convertIntegralListToVO(List<UserMallIntegralLogEntity> list);
Page<MallIntegralLogVO> convertIntegralPageToVO(Page<UserMallIntegralLogEntity> page);
}

View File

@@ -1,46 +0,0 @@
package org.springblade.modules.appFormal.convert;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.Named;
import org.mapstruct.factory.Mappers;
import org.springblade.modules.appFormal.dto.PreviewDTO;
import org.springblade.modules.appFormal.enums.BizTypeEnum;
import org.springblade.modules.appFormal.event.OrderEvent;
import org.springblade.modules.appFormal.vo.AppFormalMallDetailOrderVO;
import org.springblade.modules.appFormal.vo.AppFormalMallOrderVO;
import org.springblade.modules.appFormal.vo.AppFormalOrderVO;
import org.springblade.modules.appFormal.vo.AppFormalPreviewOrderVO;
import org.springblade.modules.order.pojo.entity.MallDetailOrderEntity;
import org.springblade.modules.order.pojo.entity.MallSummaryOrderEntity;
import org.springblade.modules.order.pojo.entity.UserOrderEntity;
/**
* @author jack
*/
@Mapper
public interface AppUserOrderConvert {
AppUserOrderConvert INSTANCE = Mappers.getMapper(AppUserOrderConvert.class);
AppFormalOrderVO convertOrderToVO(UserOrderEntity order);
AppFormalMallOrderVO convertMallOrderToVO(MallSummaryOrderEntity order);
AppFormalMallDetailOrderVO convertEntityToVO(MallDetailOrderEntity order);
AppFormalPreviewOrderVO convertPreviewDTOToVO(PreviewDTO previewDTO);
MallSummaryOrderEntity convertPreviewDTOToOrder(PreviewDTO previewDTO);
MallDetailOrderEntity convertSkuDTOToDetailOrder(PreviewDTO.SkuDTO sku);
UserOrderEntity convertEventToOrder(OrderEvent event);
}

View File

@@ -1,12 +0,0 @@
package org.springblade.modules.appFormal.dto;
import lombok.Data;
import java.math.BigDecimal;
@Data
public class CutAmountRangDTO {
private BigDecimal min;
private BigDecimal max;
}

View File

@@ -1,40 +0,0 @@
package org.springblade.modules.appFormal.dto;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import java.math.BigDecimal;
/**
* 字典
*
* @author ganwu
*/
@Data
@Accessors(chain = true)
public class PayOrderDicDTO {
/**
* 主键
*/
private Integer id;
/**
* 标识
*/
private String code;
/**
* 名称
*/
private String name;
/**
* 描述
*/
private BigDecimal des;
}

View File

@@ -1,105 +0,0 @@
package org.springblade.modules.appFormal.dto;
import lombok.Data;
import lombok.experimental.Accessors;
import org.springblade.modules.mall.pojo.entity.UserAddressEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Collections;
import java.util.List;
@Data
@Accessors(chain = true)
public class PreviewDTO implements Serializable {
private List<SkuDTO> skuList = Collections.emptyList();
private BigDecimal freight = BigDecimal.ZERO;
private Long vendorRegionsId;
private Long addressId;
private UserAddressEntity address;
private Long userId;
private BigDecimal orderAmount = BigDecimal.ZERO;
private BigDecimal freightAmount = BigDecimal.ZERO;
private BigDecimal regularAmount = BigDecimal.ZERO;
private BigDecimal totalAmount = BigDecimal.ZERO;
private BigDecimal costAmount = BigDecimal.ZERO;
@Data
public static class SkuDTO implements Serializable {
private Long spuId = -1L;
/**
* 商品编码
*/
private String spuSn;
/**
* 商品名称
*/
private String spuName;
/**
* 主图
*/
private String mainImg;
/**
* 详情图(多图,逗号分割)
*/
private String detailImg;
/**
* 顶图(多图,逗号分割)
*/
private String topImg;
/**
* cate_id分类
*/
private String cateId;
/**
* cate_id分类
*/
private String cateIds;
private BigDecimal costPrice;
/**
* 原价
*/
private BigDecimal originalPrice;
/**
* 销售价
*/
private BigDecimal retailPrice;
/**
* 销量
*/
private Integer sales;
/**
* 库存
*/
private Integer spuQty;
/**
* 标签(多标签,逗号分割 )
*/
private String tags;
private Integer quantity;
}
}

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