Merge remote-tracking branch 'origin/dev' into dev

dev
huwei 2026-08-04 16:02:34 +08:00
commit 4cfb569fed
4 changed files with 33 additions and 1 deletions

View File

@ -13,6 +13,7 @@ import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import javax.annotation.Resource;
import java.util.List;
/**
* Controller
@ -75,4 +76,10 @@ public class OrgPersonnelController {
public SingleResponse<String> importTemplate() {
return orgPersonnelApi.importTemplate();
}
@ApiOperation("人员查询")
@GetMapping("/getOrgPersonnel")
public SingleResponse<List<OrgPersonnelCO>> getOrgPersonnel() {
return orgPersonnelApi.getOrgPersonnel();
}
}

View File

@ -16,6 +16,7 @@ import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import java.util.Objects;
/**
* Controller
@ -33,7 +34,9 @@ public class AppQualFilingCommitmentController {
@ApiOperation("分页查询法定代表人承诺书")
@GetMapping("/page")
public PageResponse<QualFilingCommitmentCO> page(@Validated QualFilingCommitmentPageQuery query) {
if (Objects.isNull(query.getLegalRepPersonnelId())) {
query.setLegalRepPersonnelId(AuthUserContextAdapter.getCurrentUserId());
}
return qualFilingCommitmentApi.page(query);
}

View File

@ -26,9 +26,12 @@ import org.qinan.safetyeval.domain.service.OrgPositionDomainService;
import org.qinan.safetyeval.infrastructure.adapter.ThreadLocalUserInfoAdapter;
import org.qinan.safetyeval.infrastructure.adapter.auth.AuthUserContextAdapter;
import org.qinan.safetyeval.infrastructure.adapter.gbs.GbsUserFacadeClient;
import org.qinan.safetyeval.infrastructure.dataobject.OrgPersonnelDO;
import org.qinan.safetyeval.infrastructure.mapper.OrgPersonnelMapper;
import org.qinan.safetyeval.infrastructure.support.UserOrgIdResolver;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Lazy;
@ -41,6 +44,7 @@ import java.math.BigDecimal;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.stream.Collectors;
/**
* App
@ -92,6 +96,8 @@ public class OrgPersonnelExecutor implements OrgPersonnelApi {
private boolean gbsUserSyncFailFast;
@Value("${template.personnel.import.url:}")
private String personImportTemplateUrl;
@Autowired
private OrgPersonnelMapper orgPersonnelMapper;
@Override
@ -295,4 +301,15 @@ public class OrgPersonnelExecutor implements OrgPersonnelApi {
public SingleResponse<String> importTemplate() {
return SingleResponse.success(personImportTemplateUrl);
}
@Override
public SingleResponse<List<OrgPersonnelCO>> getOrgPersonnel() {
List<OrgPersonnelDO> orgPersonnelDOS = orgPersonnelMapper.selectList(null);
List<OrgPersonnelCO> orgPersonnelCOS = orgPersonnelDOS.stream().map(item -> {
OrgPersonnelCO orgPersonnelCO = new OrgPersonnelCO();
BeanUtils.copyProperties(item, orgPersonnelCO);
return orgPersonnelCO;
}).collect(Collectors.toList());
return SingleResponse.success(orgPersonnelCOS);
}
}

View File

@ -12,6 +12,7 @@ import org.qinan.safetyeval.client.dto.OrgPersonnelUpdateOriginFaceCmd;
import org.springframework.web.multipart.MultipartFile;
import java.math.BigDecimal;
import java.util.List;
/**
* Client
@ -50,4 +51,8 @@ public interface OrgPersonnelApi {
* @return
*/
SingleResponse<String> importTemplate();
SingleResponse<List<OrgPersonnelCO>> getOrgPersonnel();
}