2 Commits bb66f0072d ... 8f4776d68f

Auteur SHA1 Bericht Datum
  Lgx 8f4776d68f Merge branch 'master' of http://192.168.20.122:3000/pzc/appcenter.git 4 jaren geleden
  Lgx a71393210d Signed-off-by: Lgx <361400959> 4 jaren geleden

+ 4 - 2
oauth2-shiro-jwt/src/main/java/com/liangjian11/ums/controller/ums/ResourceUmsController.java

@@ -211,8 +211,10 @@ public class ResourceUmsController extends BaseController {
         List<Role> roles = this.roleService.selectList(new EntityWrapper<Role>());
         for(Role role : roles)
         {
-            Option option = new Option( role.getRoleName(),role.getId(), role.getRecordState() == 2?false:true );
-            options.add(option);
+            if(role!=null){
+                Option option = new Option( role.getRoleName(),role.getId(), (role.getRecordState()!=null && role.getRecordState() == 2)?false:true );
+                options.add(option);
+            }
         }
         return ResultUtil.createSuccess(200,  options);
     }