脱敏数据库bugfix

wushunjie
杜函宇 6 months ago
parent 235603393a
commit ac9701509b

@ -89,7 +89,7 @@ public class JSmartRemindersController extends BaseController {
@PreAuthorize("@ss.hasAnyRoles('ent')") @PreAuthorize("@ss.hasAnyRoles('ent')")
@ApiOperation(value = "企业端首页智能提醒查询所有数据", response = JSmartDeclaration.class) @ApiOperation(value = "企业端首页智能提醒查询所有数据", response = JSmartDeclaration.class)
@GetMapping("/enterpriseAll") @GetMapping("/enterpriseAll")
public AjaxResult enterpriseAll(Page<HomeRequestSmart> page) { public AjaxResult enterpriseAll(Page<HomeRequestSmart> page,String alertContent) {
// 获取当前登录用户是否是企业端 // 获取当前登录用户是否是企业端
boolean admin = false; boolean admin = false;
String str = null; String str = null;
@ -101,7 +101,7 @@ public class JSmartRemindersController extends BaseController {
if (admin) { if (admin) {
str = null; str = null;
} }
return success(jSmartDeclarationService.selectEnterpriseAllList(page,str)); return success(jSmartDeclarationService.selectEnterpriseAllList(page,str,alertContent));
} }

@ -22,7 +22,7 @@ public interface JSmartDeclarationMapper extends BaseMapper<JSmartDeclaration> {
* *
* @return * @return
*/ */
Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,@Param("userName") String userName); Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,@Param("userName") String userName,@Param("alertContent") String alertContent);
/** /**
* *

@ -22,7 +22,7 @@ public interface JSmartDeclarationService extends IService<JSmartDeclaration> {
* *
* @return * @return
*/ */
Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,String userName); Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,String userName,String alertContent);
/** /**

@ -26,8 +26,8 @@ public class JSmartDeclarationServiceImpl extends ServiceImpl<JSmartDeclarationM
* @return * @return
*/ */
@Override @Override
public Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,String userName) { public Page<HomeRequestSmart> selectEnterpriseAllList(Page<HomeRequestSmart> page,String userName,String alertContent) {
return baseMapper.selectEnterpriseAllList(page,userName); return baseMapper.selectEnterpriseAllList(page,userName,alertContent);
} }
/** /**

@ -0,0 +1,110 @@
# 数据源配置
spring:
datasource:
type: com.alibaba.druid.pool.DruidDataSource
driverClassName: com.mysql.cj.jdbc.Driver
druid:
# 主库数据源
master:
# url: jdbc:mysql://localhost:3306/jingji_hu?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
url: jdbc:mysql://39.101.188.84:3307/jingji_hu_test?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
username: root
# password: root
password: Admin123@
# 从库数据源
slave:
# 从数据源开关/默认关闭
enabled: false
url:
username:
password:
# 初始连接数
initialSize: 5
# 最小连接池数量
minIdle: 10
# 最大连接池数量
maxActive: 20
# 配置获取连接等待超时的时间
maxWait: 60000
# 配置连接超时时间
connectTimeout: 30000
# 配置网络超时时间
socketTimeout: 60000
# 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
timeBetweenEvictionRunsMillis: 60000
# 配置一个连接在池中最小生存的时间,单位是毫秒
minEvictableIdleTimeMillis: 300000
# 配置一个连接在池中最大生存的时间,单位是毫秒
maxEvictableIdleTimeMillis: 900000
# 配置检测连接是否有效
validationQuery: SELECT 1 FROM DUAL
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
webStatFilter:
enabled: true
statViewServlet:
enabled: true
# 设置白名单,不填则允许所有访问
allow:
url-pattern: /druid/*
# 控制台管理用户名和密码
login-username: ruoyi
login-password: 123456
filter:
stat:
enabled: true
# 慢SQL记录
log-slow-sql: true
slow-sql-millis: 1000
merge-sql: true
wall:
config:
multi-statement-allow: true
#自己客户端地址
returnUrl: http://39.101.188.84:9999/demo/JinJiHuTest
#returnUrl: http://192.168.0.113:80
#定时任务更新企业信息和联系人的开启
isTiming: false
# 开发环境配置
server:
# 服务器的HTTP端口默认为8080
port: 9031
servlet:
# 应用的访问路径
context-path: /
tomcat:
# tomcat的URI编码
uri-encoding: UTF-8
# 连接数满后的排队数默认为100
accept-count: 1000
threads:
# tomcat最大线程数默认为200
max: 800
# Tomcat启动初始化的线程数默认值10
min-spare: 100
#企业端测试环境应用系统编号
enterpriseAppId: BwAWS8uh
# 应用私钥
enterpriseAppsecret: 03f70874-39e9-11ef-bbd6-fa163e2b2e10
#企业端单点登陆url
url: https://qytt.sipac.gov.cn/api/usercenter/User/ssoLogin
#企业端用户信息url
infoUrl: https://qytt.sipac.gov.cn/api/usercenter/User/getInfo
#短信发送接口
smsSend: http://zwyyone.sipac.gov.cn/ebus/szyqznzs/dx
#短信接收人号码新增
smsPhoneAdd: http://zwyyone.sipac.gov.cn/ebus/szyqznzs/dxhm
#测试类型
paramType: cs
#测试授权码
smsV: oVFPU1y1wYJIatvqrGoTAE5ycguUyjaY
#工单编号
code: SC24071600001
#短信PaaSID
paaSID: xdfwy
#短信token
smsToken: iM89cd4b0cGNVYAqKu7jl7EONyHgTa0N

@ -34,7 +34,7 @@ spring:
# 国际化资源文件路径 # 国际化资源文件路径
basename: i18n/messages basename: i18n/messages
profiles: profiles:
active: druid active: test
# 文件上传 # 文件上传
servlet: servlet:
multipart: multipart:

@ -42,8 +42,15 @@
FROM FROM
bms_enterprise_basic_info a bms_enterprise_basic_info a
LEFT JOIN j_business_revenue b ON a.tyshxydm = b.tyshxydm COLLATE utf8mb4_general_ci LEFT JOIN j_business_revenue b ON a.tyshxydm = b.tyshxydm COLLATE utf8mb4_general_ci
WHERE <where>
a.type = 1 a.type = 1
<if test="req.qymc != null and req.qymc != '' ">
and a.qymc like concat('%',#{req.qymc},'%')
</if>
<if test="req.tyshxydm != null and req.tyshxydm != '' ">
and a.tyshxydm = #{req.tyshxydm}
</if>
</where>
</select> </select>
<select id="selectAllServicesCount" <select id="selectAllServicesCount"
resultType="com.ruoyi.jjh.ent.entity.response.JServicesListCountResponse"> resultType="com.ruoyi.jjh.ent.entity.response.JServicesListCountResponse">

@ -26,6 +26,9 @@
<if test="userName != null and userName != '' "> <if test="userName != null and userName != '' ">
and a.tyshxydm = #{userName} and a.tyshxydm = #{userName}
</if> </if>
<if test="alertContent != null and alertContent != '' ">
and c.alert_content like concat('%',#{alertContent},'%')
</if>
and a.alert_time &lt; NOW() and a.alert_time &lt; NOW()
</where> </where>
order by a.alert_time desc order by a.alert_time desc

Loading…
Cancel
Save