Esempio n. 1
0
 private Role convert(RoleDto roleDto) {
   Role role = new Role();
   role.setRoleId(roleDto.getRoleId());
   role.setRoleName(roleDto.getName());
   role.setNotes(roleDto.getDescription());
   return role;
 }
Esempio n. 2
0
 @Override
 @OperationSuccessInfo(category = LogCategoryConsts.SYS, content = "修改角色")
 public void updateRole(RoleUpdateEvent roleUpdateEvent) throws SecurityException {
   RoleDto role = new RoleDto();
   role.setRoleId(roleUpdateEvent.getRoleId());
   role.setName(roleUpdateEvent.getName());
   role.setDescription(roleUpdateEvent.getDescription());
   validatorTools.validate(role);
   roleCommandService.update(convert(role));
 }