From 55b97c14d6c52c343ccce01dc40e50f9ae543cc2 Mon Sep 17 00:00:00 2001 From: hshansha Date: Wed, 18 Jun 2025 08:58:23 +0800 Subject: [PATCH] =?UTF-8?q?=E5=91=98=E5=B7=A5=E6=B3=A8=E5=86=8C=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E5=AF=86=E7=A0=81=E5=8A=A0=E5=AF=86=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-admin/src/main/resources/application-dev.yml | 2 +- .../com/ruoyi/pay/service/impl/PayEmployeeInfoServiceImpl.java | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ruoyi-admin/src/main/resources/application-dev.yml b/ruoyi-admin/src/main/resources/application-dev.yml index 7ff9dc9..167b0f8 100644 --- a/ruoyi-admin/src/main/resources/application-dev.yml +++ b/ruoyi-admin/src/main/resources/application-dev.yml @@ -51,7 +51,7 @@ spring: # rewriteBatchedStatements=true 批处理优化 大幅提升批量插入更新删除性能(对数据库有性能损耗 使用批量操作应考虑性能问题) url: jdbc:mysql://localhost:3306/pay?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&nullCatalogMeansCurrent=true username: pay - password: hs123456 + password: CATAj3kmZTWdt8sA # 从库数据源 # slave: # lazy: true diff --git a/ruoyi-pay/src/main/java/com/ruoyi/pay/service/impl/PayEmployeeInfoServiceImpl.java b/ruoyi-pay/src/main/java/com/ruoyi/pay/service/impl/PayEmployeeInfoServiceImpl.java index 3ca0afa..d8ce216 100644 --- a/ruoyi-pay/src/main/java/com/ruoyi/pay/service/impl/PayEmployeeInfoServiceImpl.java +++ b/ruoyi-pay/src/main/java/com/ruoyi/pay/service/impl/PayEmployeeInfoServiceImpl.java @@ -1,5 +1,6 @@ package com.ruoyi.pay.service.impl; +import cn.dev33.satoken.secure.BCrypt; import cn.hutool.core.bean.BeanUtil; import com.ruoyi.common.core.domain.entity.SysRole; import com.ruoyi.common.core.domain.entity.SysUser; @@ -113,7 +114,7 @@ public class PayEmployeeInfoServiceImpl implements IPayEmployeeInfoService { SysUser sysUser = new SysUser(); sysUser.setNickName(bo.getName()); sysUser.setUserName(bo.getPhone()); - sysUser.setPassword(bo.getPhone()); + sysUser.setPassword(BCrypt.hashpw(bo.getPhone())); sysUser.setDeptId(bo.getDeptId()); sysUser.setSex(bo.getSex()); sysUser.setPhonenumber(bo.getPhone());