全部转换为自增id

master
chen 2 years ago
parent af5e89cb23
commit a5bc0662e2
  1. 2
      src/main/java/com/huoran/iasf/entity/SysPermission.java
  2. 2
      src/main/java/com/huoran/iasf/service/impl/PermissionServiceImpl.java

@ -45,7 +45,7 @@ public class SysPermission implements Serializable {
@NotNull(message = "所属菜单不能为空")
@ApiModelProperty(value = "父级菜单权限id")
private String pid;
private Integer pid;
@ApiModelProperty(value = "排序")
private Integer orderNum;

@ -251,7 +251,7 @@ public class PermissionServiceImpl extends ServiceImpl<SysPermissionMapper, SysP
private static List<SysPermission> build(List<SysPermission> treeNodes) {
List<SysPermission> trees = new ArrayList<>();
for (SysPermission treeNode : treeNodes) {
if ("0".equals(treeNode.getPid())) {
if (treeNode.getPid()==0) {
treeNode.setLevel(1);
trees.add(findChildren(treeNode,treeNodes));
}

Loading…
Cancel
Save