xiangpei
2025-05-14 47cd9ecc0eff38ffe6b3b794b2bf197e958f4403
src/main/java/com/mindskip/xzs/configuration/spring/security/RestAuthenticationSuccessHandler.java
@@ -4,6 +4,7 @@
import com.mindskip.xzs.domain.UserEventLog;
import com.mindskip.xzs.event.UserEvent;
import com.mindskip.xzs.service.UserService;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.security.core.Authentication;
@@ -55,6 +56,8 @@
                com.mindskip.xzs.domain.User newUser = new com.mindskip.xzs.domain.User();
                newUser.setUserName(user.getUserName());
                newUser.setImagePath(user.getImagePath());
                // 返回是否部门管理员的标识 1是部门管理员
                newUser.setDeptAdmin(user.getRole().equals(-1) ? "1" : "0");
                RestUtil.response(response, SystemCode.OK.getCode(), SystemCode.OK.getMessage(), newUser);
            }
        } else {