bug 修改
This commit is contained in:
parent
5f53206f33
commit
fb226e657a
|
|
@ -196,7 +196,7 @@ public class SysLoginService {
|
|||
* @return 登录用户信息
|
||||
*/
|
||||
private LoginUser handleUsernamePasswordLogin(String username, String password, long startTime) {
|
||||
validateLoginParameters(username, password, startTime); // 验证登录参数
|
||||
//validateLoginParameters(username, password, startTime); // 验证登录参数
|
||||
validateIpBlacklist(username, startTime); // IP黑名单校验
|
||||
R<LoginUser> userResult = remoteUserService.getUserInfo(username, SecurityConstants.INNER);
|
||||
validateUserResult(username, userResult, startTime); // 验证用户查询结果
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ public class ValidateUtils {
|
|||
/**
|
||||
* 密码校验规则
|
||||
*/
|
||||
public static int MAX_LENGTH=26;
|
||||
public static int MAX_LENGTH=20;
|
||||
|
||||
public static int MIN_LENGTH=8;
|
||||
|
||||
|
|
|
|||
|
|
@ -173,6 +173,9 @@ public class AecDecryptParamFilter extends AbstractGatewayFilterFactory {
|
|||
throw new CaptchaException("请求参数不正确");
|
||||
}
|
||||
String encrypt = Sm3Util.encrypt(query);
|
||||
System.err.println(encrypt);
|
||||
System.err.println(query);
|
||||
System.err.println(providedHmac);
|
||||
log.debug("加密后的参数: {}", encrypt);
|
||||
log.debug("请求头中的 Params-Hash: {}", providedHmac);
|
||||
if (!encrypt.equals(providedHmac)) {
|
||||
|
|
|
|||
|
|
@ -18,11 +18,11 @@ spring:
|
|||
discovery:
|
||||
# 服务注册地址
|
||||
server-addr: 192.168.0.14:8848
|
||||
namespace: f648524d-0a7b-449e-8f92-64e05236fd51
|
||||
namespace: f0e6fc14-465e-4268-adc8-cb33c3d4d755
|
||||
config:
|
||||
# 配置中心地址
|
||||
server-addr: 192.168.0.14:8848
|
||||
namespace: f648524d-0a7b-449e-8f92-64e05236fd51
|
||||
namespace: f0e6fc14-465e-4268-adc8-cb33c3d4d755
|
||||
# 配置文件格式
|
||||
file-extension: yml
|
||||
# 共享配置
|
||||
|
|
@ -50,7 +50,7 @@ spring:
|
|||
|
||||
#系统 自动 加解密开关
|
||||
system:
|
||||
encryptEnabled: false
|
||||
encryptEnabled: true
|
||||
decryptEnabled: true
|
||||
#加密组件
|
||||
jasypt:
|
||||
|
|
|
|||
|
|
@ -132,8 +132,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.updateRole(role));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -150,8 +150,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.authDataScope(role));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -168,8 +168,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.updateRoleStatus(role));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -185,8 +185,9 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.deleteRoleByIds(roleIds));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -201,8 +202,8 @@ public class SysRoleController extends BaseController
|
|||
return success(roleService.selectRoleAll());
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
}
|
||||
/**
|
||||
|
|
@ -250,8 +251,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.deleteAuthUser(userRole));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -266,8 +267,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.deleteAuthUsers(roleId, userIds));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -283,8 +284,8 @@ public class SysRoleController extends BaseController
|
|||
return toAjax(roleService.insertAuthUsers(roleId, userIds));
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -300,7 +301,7 @@ public class SysRoleController extends BaseController
|
|||
return ajax;
|
||||
}catch (Exception e){
|
||||
logger.error(e.toString(),e);
|
||||
return error(e.getMessage());
|
||||
}
|
||||
return error("系统异常,请联系管理员");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ package com.bonus.system.domain.vo;
|
|||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonInclude;
|
||||
import com.bonus.system.api.domain.SysDept;
|
||||
import com.bonus.system.domain.SysMenu;
|
||||
|
|
@ -12,66 +13,75 @@ import com.bonus.system.domain.SysMenu;
|
|||
*
|
||||
* @author bonus
|
||||
*/
|
||||
public class TreeSelect implements Serializable
|
||||
{
|
||||
public class TreeSelect implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 节点ID */
|
||||
/**
|
||||
* 节点ID
|
||||
*/
|
||||
private Long id;
|
||||
|
||||
/** 节点名称 */
|
||||
/**
|
||||
* 节点名称
|
||||
*/
|
||||
private String label;
|
||||
|
||||
/** 子节点 */
|
||||
private String status;
|
||||
|
||||
|
||||
/**
|
||||
* 子节点
|
||||
*/
|
||||
@JsonInclude(JsonInclude.Include.NON_EMPTY)
|
||||
private List<TreeSelect> children;
|
||||
|
||||
public TreeSelect()
|
||||
{
|
||||
public TreeSelect() {
|
||||
|
||||
}
|
||||
|
||||
public TreeSelect(SysDept dept)
|
||||
{
|
||||
public TreeSelect(SysDept dept) {
|
||||
this.id = dept.getDeptId();
|
||||
this.status = dept.getStatus();
|
||||
this.label = dept.getDeptName();
|
||||
this.children = dept.getChildren().stream().map(TreeSelect::new).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
public TreeSelect(SysMenu menu)
|
||||
{
|
||||
public TreeSelect(SysMenu menu) {
|
||||
this.id = menu.getMenuId();
|
||||
this.label = menu.getMenuName();
|
||||
this.status = menu.getStatus();
|
||||
this.children = menu.getChildren().stream().map(TreeSelect::new).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getLabel()
|
||||
{
|
||||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public void setLabel(String label)
|
||||
{
|
||||
public void setLabel(String label) {
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
public List<TreeSelect> getChildren()
|
||||
{
|
||||
public List<TreeSelect> getChildren() {
|
||||
return children;
|
||||
}
|
||||
|
||||
public void setChildren(List<TreeSelect> children)
|
||||
{
|
||||
public void setChildren(List<TreeSelect> children) {
|
||||
this.children = children;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue