Commit cf9e2d63 by 墨竹

feat:新增根据员工id查询openid接口

parent c7ff2841
......@@ -167,7 +167,6 @@ public class FriendSyncNewOperation implements BaseSyncOperation {
private String dealMerge(ExternalUserDTO externalUserDTO, TabHaobanPreDealLog dataPre) {
String wxEnterpriseId = dataPre.getWxEnterpriseId();
String wxUserId = dataPre.getpDataId();
String taskId = dataPre.getTaskId();
if (externalUserDTO.getFriendType() == 2) {
return "不是微信好友,是企业微信好友:" + externalUserDTO.getFriendType();
......
......@@ -10,6 +10,7 @@ import com.gic.clerk.api.service.ClerkNewService;
import com.gic.clerk.api.service.ClerkService;
import com.gic.commons.util.DateUtil;
import com.gic.commons.util.EntityUtil;
import com.gic.commons.webapi.reponse.RestResponse;
import com.gic.enterprise.api.dto.EnterpriseDTO;
import com.gic.enterprise.api.dto.StoreDTO;
import com.gic.enterprise.api.service.EnterpriseService;
......@@ -1257,4 +1258,18 @@ public class ClerkController extends WebBaseController {
return resultResponse(HaoBanErrCode.ERR_1, clerkList.size());
}
/**
* 根据员工id获取openId
*
* @return {@link RestResponse }
* @author mozhu
* @date 2021-12-29 10:42:24
*/
@RequestMapping("getOpenIdByStaffId")
public RestResponse<String> getOpenIdByStaffId() {
String staffId = this.getLoginUser().getStaffId();
String openId = "";
return RestResponse.successResult(openId);
}
}
package com.gic.haoban.manage.web.controller;
import com.gic.haoban.auth.api.dto.DisplayRelationShortInfoDTO;
import com.gic.haoban.auth.api.dto.UserRightDetailDTO;
import com.gic.haoban.common.utils.AuthRequestUtil;
import com.gic.haoban.common.utils.AuthRequestWellDoneUtil;
import com.gic.haoban.common.utils.HaobanResponse;
import com.gic.haoban.manage.api.dto.WellDoneLoginDTO;
import com.gic.haoban.manage.web.errCode.HaoBanErrCode;
import org.apache.commons.collections.CollectionUtils;
......@@ -49,8 +49,8 @@ public class WebBaseController {
*
* @return
*/
protected UserRightDetailDTO getLoginUser() {
return (UserRightDetailDTO) AuthRequestUtil.getSessionUser();
protected WellDoneLoginDTO getLoginUser() {
return (WellDoneLoginDTO) AuthRequestWellDoneUtil.getLoginUser();
}
public boolean haveRight(List<DisplayRelationShortInfoDTO> list){
......@@ -71,9 +71,6 @@ public class WebBaseController {
clerkList.add(showDto.getClerkId());
}
}
if(CollectionUtils.isEmpty(groupList) && CollectionUtils.isEmpty(storeList) && CollectionUtils.isEmpty(clerkList)){
return false;
}
return true;
return !CollectionUtils.isEmpty(groupList) || !CollectionUtils.isEmpty(storeList) || !CollectionUtils.isEmpty(clerkList);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment