|
@@ -12,23 +12,24 @@ import com.sqx.modules.app.entity.UserEntity;
|
|
|
import com.sqx.modules.app.service.MsgService;
|
|
import com.sqx.modules.app.service.MsgService;
|
|
|
import com.sqx.modules.app.service.UserService;
|
|
import com.sqx.modules.app.service.UserService;
|
|
|
import com.sqx.modules.common.service.CommonInfoService;
|
|
import com.sqx.modules.common.service.CommonInfoService;
|
|
|
|
|
+import com.sqx.modules.firstLogin.entity.HrEntity;
|
|
|
|
|
+import com.sqx.modules.firstLogin.service.HrService;
|
|
|
import com.sqx.modules.message.entity.MessageInfo;
|
|
import com.sqx.modules.message.entity.MessageInfo;
|
|
|
import com.sqx.modules.message.service.MessageService;
|
|
import com.sqx.modules.message.service.MessageService;
|
|
|
import com.sqx.modules.resumes.dao.CompanyDao;
|
|
import com.sqx.modules.resumes.dao.CompanyDao;
|
|
|
import com.sqx.modules.resumes.entity.Company;
|
|
import com.sqx.modules.resumes.entity.Company;
|
|
|
|
|
+import com.sqx.modules.resumes.entity.CompanyUser;
|
|
|
import com.sqx.modules.resumes.entity.PostPush;
|
|
import com.sqx.modules.resumes.entity.PostPush;
|
|
|
import com.sqx.modules.resumes.service.CompanyService;
|
|
import com.sqx.modules.resumes.service.CompanyService;
|
|
|
|
|
+import com.sqx.modules.resumes.service.CompanyUserService;
|
|
|
import com.sqx.modules.resumes.service.PostPushService;
|
|
import com.sqx.modules.resumes.service.PostPushService;
|
|
|
-import com.sqx.modules.resumes.vo.CompanyListVo;
|
|
|
|
|
import com.sqx.modules.utils.SenInfoCheckUtil;
|
|
import com.sqx.modules.utils.SenInfoCheckUtil;
|
|
|
import com.sqx.modules.utils.excel.ExcelData;
|
|
import com.sqx.modules.utils.excel.ExcelData;
|
|
|
import org.apache.commons.lang.StringUtils;
|
|
import org.apache.commons.lang.StringUtils;
|
|
|
-import org.postgresql.copy.CopyManager;
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
import java.util.*;
|
|
import java.util.*;
|
|
|
-import java.util.stream.Collectors;
|
|
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 企业
|
|
* 企业
|
|
@@ -46,6 +47,10 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyDao, Company> impleme
|
|
|
private CommonInfoService commonInfoService;
|
|
private CommonInfoService commonInfoService;
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private PostPushService postPushService;
|
|
private PostPushService postPushService;
|
|
|
|
|
+ @Autowired
|
|
|
|
|
+ private HrService hrService;
|
|
|
|
|
+ @Autowired
|
|
|
|
|
+ private CompanyUserService companyUserService;
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
@@ -143,7 +148,24 @@ public class CompanyServiceImpl extends ServiceImpl<CompanyDao, Company> impleme
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
|
public Company selectCompanyByCompanyId(Long companyId) {
|
|
public Company selectCompanyByCompanyId(Long companyId) {
|
|
|
- return baseMapper.selectCompanyByCompanyId(companyId);
|
|
|
|
|
|
|
+ Company company = baseMapper.selectById(companyId);
|
|
|
|
|
+ QueryWrapper<CompanyUser> queryWrapper = new QueryWrapper<>();
|
|
|
|
|
+ queryWrapper.eq("company_id", companyId).eq("is_use", 1);
|
|
|
|
|
+ List<CompanyUser> companyUserList = companyUserService.getBaseMapper().selectList(queryWrapper);
|
|
|
|
|
+ List<HrEntity> hrList = new ArrayList<>();
|
|
|
|
|
+ List<UserEntity> userEntities = new ArrayList<>();
|
|
|
|
|
+ if (companyUserList != null && !companyUserList.isEmpty()) {
|
|
|
|
|
+ for (CompanyUser companyUser : companyUserList) {
|
|
|
|
|
+ Long userId = companyUser.getUserId();
|
|
|
|
|
+ HrEntity hr = hrService.getByUserId(String.valueOf(userId));
|
|
|
|
|
+ UserEntity userEntity = userService.getById(userId);
|
|
|
|
|
+ hrList.add(hr);
|
|
|
|
|
+ userEntities.add(userEntity);
|
|
|
|
|
+ }
|
|
|
|
|
+ company.setHr(hrList);
|
|
|
|
|
+ company.setUserEntities(userEntities);
|
|
|
|
|
+ }
|
|
|
|
|
+ return company;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|