Commit 5f338c27f108d70ac449ef36ea27c5cf52914e25

Authored by zhangdaihao
1 parent 0d96572e

解决bug; demo redis测试功能,对象未序列号

jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/config/ShiroConfig.java
... ... @@ -68,6 +68,8 @@ public class ShiroConfig {
68 68 filterChainDefinitionMap.put("/actuator/metrics/**", "anon");
69 69 filterChainDefinitionMap.put("/actuator/httptrace/**", "anon");
70 70 filterChainDefinitionMap.put("/actuator/redis/**", "anon");
  71 + filterChainDefinitionMap.put("/test/jeecgDemo/demo3", "anon"); //模板测试
  72 + filterChainDefinitionMap.put("/test/jeecgDemo/redisDemo/**", "anon"); //redis测试
71 73  
72 74  
73 75 // 添加自己的过滤器并且取名为jwt
... ...
jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/test/entity/JeecgDemo.java
1 1 package org.jeecg.modules.demo.test.entity;
2 2  
  3 +import java.io.Serializable;
  4 +
3 5 import org.jeecg.common.system.base.entity.JeecgEntity;
4 6 import org.jeecgframework.poi.excel.annotation.Excel;
5 7 import org.springframework.format.annotation.DateTimeFormat;
... ... @@ -24,8 +26,8 @@ import lombok.experimental.Accessors;
24 26 @Accessors(chain = true)
25 27 @ApiModel(value="测试DEMO对象", description="测试DEMO")
26 28 @TableName("demo")
27   -public class JeecgDemo extends JeecgEntity {
28   -
  29 +public class JeecgDemo extends JeecgEntity implements Serializable {
  30 + private static final long serialVersionUID = 1L;
29 31 /** 部门编码 */
30 32 @Excel(name="部门编码",width=25)
31 33 @ApiModelProperty(value = "部门编码")
... ...
jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/system/service/impl/SysPermissionServiceImpl.java
... ... @@ -166,7 +166,9 @@ public class SysPermissionServiceImpl extends ServiceImpl<SysPermissionMapper, S
166 166 //b.判断老的菜单下是否还有其他子菜单,没有的话则设置为叶子节点
167 167 int cc = this.count(new QueryWrapper<SysPermission>().lambda().eq(SysPermission::getParentId, p.getParentId()));
168 168 if(cc==0) {
169   - this.sysPermissionMapper.setMenuLeaf(p.getParentId(), 1);
  169 + if(oConvertUtils.isNotEmpty(p.getParentId())) {
  170 + this.sysPermissionMapper.setMenuLeaf(p.getParentId(), 1);
  171 + }
170 172 }
171 173  
172 174 }
... ...