新增用户ID列表获取方法
This commit is contained in:
parent
74d242e122
commit
49f0a73cb4
@ -160,4 +160,11 @@ public interface IUserBaseService {
|
|||||||
*/
|
*/
|
||||||
List<UserDTO> listByKeywords(String keywords);
|
List<UserDTO> listByKeywords(String keywords);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户ID列表
|
||||||
|
*
|
||||||
|
* @param userDTOs
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<String> listUserIds(List<UserDTO> userDTOs);
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,6 @@ import ink.wgink.common.enums.RoleDataRightEnum;
|
|||||||
import ink.wgink.exceptions.AccessTokenException;
|
import ink.wgink.exceptions.AccessTokenException;
|
||||||
import ink.wgink.exceptions.AppTokenException;
|
import ink.wgink.exceptions.AppTokenException;
|
||||||
import ink.wgink.exceptions.SearchException;
|
import ink.wgink.exceptions.SearchException;
|
||||||
import ink.wgink.exceptions.TokenException;
|
|
||||||
import ink.wgink.interfaces.consts.ISystemConstant;
|
import ink.wgink.interfaces.consts.ISystemConstant;
|
||||||
import ink.wgink.pojo.app.AppTokenUser;
|
import ink.wgink.pojo.app.AppTokenUser;
|
||||||
import ink.wgink.pojo.bos.UserInfoBO;
|
import ink.wgink.pojo.bos.UserInfoBO;
|
||||||
@ -166,6 +165,21 @@ public class DefaultBaseService {
|
|||||||
return code;
|
return code;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取关键词
|
||||||
|
*
|
||||||
|
* @param params
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
protected String getKeywords(Map<String, Object> params) {
|
||||||
|
String keywords = null;
|
||||||
|
if (params.get("keywords") != null) {
|
||||||
|
keywords = params.get("keywords").toString();
|
||||||
|
}
|
||||||
|
params.remove("keywords");
|
||||||
|
return keywords;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取session
|
* 获取session
|
||||||
*
|
*
|
||||||
|
@ -17,8 +17,7 @@ import org.springframework.stereotype.Service;
|
|||||||
|
|
||||||
import java.io.UnsupportedEncodingException;
|
import java.io.UnsupportedEncodingException;
|
||||||
import java.net.URLEncoder;
|
import java.net.URLEncoder;
|
||||||
import java.util.List;
|
import java.util.*;
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @ClassName: UserServiceImpl
|
* @ClassName: UserServiceImpl
|
||||||
@ -139,6 +138,18 @@ public class UserServiceImpl extends DefaultBaseService implements IUserService
|
|||||||
return list(params);
|
return list(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<String> listUserIds(List<UserDTO> userDTOs) {
|
||||||
|
if (userDTOs.isEmpty()) {
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
|
Set<String> userIdSet = new HashSet<>();
|
||||||
|
for (UserDTO userDTO : userDTOs) {
|
||||||
|
userIdSet.add(userDTO.getUserId());
|
||||||
|
}
|
||||||
|
return new ArrayList<>(userIdSet);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updatePassword(UpdatePasswordVO updatePasswordVO) {
|
public void updatePassword(UpdatePasswordVO updatePasswordVO) {
|
||||||
userRemoteService.updatePassword(apiPathProperties.getUserCenter(), securityComponent.getCurrentUser().getUserId(), OAuth2ClientTokenManager.getInstance().getToken().getAccessToken(), updatePasswordVO);
|
userRemoteService.updatePassword(apiPathProperties.getUserCenter(), securityComponent.getCurrentUser().getUserId(), OAuth2ClientTokenManager.getInstance().getToken().getAccessToken(), updatePasswordVO);
|
||||||
|
@ -53,10 +53,7 @@ import javax.servlet.http.HttpServletRequest;
|
|||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.io.*;
|
import java.io.*;
|
||||||
import java.net.URLEncoder;
|
import java.net.URLEncoder;
|
||||||
import java.util.ArrayList;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When you feel like quitting. Think about why you started
|
* When you feel like quitting. Think about why you started
|
||||||
@ -540,6 +537,18 @@ public class UserServiceImpl extends DefaultBaseService implements IUserService
|
|||||||
return list(params);
|
return list(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<String> listUserIds(List<UserDTO> userDTOs) {
|
||||||
|
if (userDTOs.isEmpty()) {
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
|
Set<String> userIdSet = new HashSet<>();
|
||||||
|
for (UserDTO userDTO : userDTOs) {
|
||||||
|
userIdSet.add(userDTO.getUserId());
|
||||||
|
}
|
||||||
|
return new ArrayList<>(userIdSet);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Excel导入错误对象
|
* Excel导入错误对象
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user