feat(REQ-3282): 修复job查询问题

This commit is contained in:
周敏 2024-12-26 10:03:40 +08:00
parent b9d296f004
commit 6a7a78027a
2 changed files with 59 additions and 2 deletions

View File

@ -52,7 +52,6 @@ public class NodeUserServiceImpl implements NodeUserService {
private final NodeUserFoundationService nodeUserFoundationService;
@Override
public NodeUserProcessor.ProcessResult process(ProcessNodeUserReq req) {
// 通用check
@ -92,7 +91,7 @@ public class NodeUserServiceImpl implements NodeUserService {
if (jobIds.isEmpty()) {
return emptyPage;
}
req.setOrganizationalJobIds(QueryConditionAssembler.assemble(req.getOrganizationalJobIds(), jobIds));
listReq.setOrganizationalJobIds(QueryConditionAssembler.assemble(req.getOrganizationalJobIds(), jobIds));
}
PageResp<NodeUserQueryRepository.NodeUserResp> page = nodeUserQueryRepository.page(listReq);
List<NodeUserDTO> records = BeanUtil.copyToList(CollUtil.emptyIfNull(page.getData()), NodeUserDTO.class);

View File

@ -0,0 +1,58 @@
package cn.axzo.orgmanax;
import lombok.extern.log4j.Log4j2;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.ApplicationContext;
import org.springframework.core.env.Environment;
import org.springframework.scheduling.annotation.EnableAsync;
/**
*/
@SpringBootApplication(scanBasePackages = "cn.axzo", exclude = {
org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration.class,
})
@EnableFeignClients(basePackages = {"cn.axzo"})
@Log4j2
@EnableAsync
public class MaokaiTestApplication {
public static void main(String[] args) throws Exception {
System.setProperty("rocket.consumer.listeners.disable", "true");
System.setProperty("spring.profiles.active", "test");
System.setProperty("NACOS_HOST", "https://test-nacos.axzo.cn");
System.setProperty("NACOS_NAMESPACE_ID","f3c0f0d2-bac4-4498-bee7-9c3636b3afdf");
System.setProperty("CUSTOM_ENV","test");
System.setProperty("NACOS_PORT", "443");
System.setProperty("spring.redis.port","6379");
System.setProperty("spring.redis.host","172.16.2.149");
System.setProperty("rocketmq.name-server", "172.16.2.82:9876");
System.setProperty("logback.path", "/tmp");
SpringApplication application = new SpringApplication(MaokaiTestApplication.class);
ApplicationContext applicationContext = application.run(args);
Environment env = applicationContext.getEnvironment();
log.info(
"--------------------------------------------------------------------------------------------------------------------\n" +
"Application 【{}】 is running on 【{}】 environment!\n" +
"Api Local: \thttp://127.0.0.1:{}\n" +
"Mysql: \t{}\t username:{}\n" +
"Redis: \t{}:{}\t database:{}\n" +
"RabbitMQ: \t{}\t username:{}",
env.getProperty("spring.application.name"),
env.getProperty("spring.profiles.active"),
env.getProperty("server.port"),
env.getProperty("spring.datasource.url"),
env.getProperty("spring.datasource.username"),
env.getProperty("spring.redis.host"),
env.getProperty("spring.redis.port"),
env.getProperty("spring.redis.database"),
env.getProperty("spring.rabbitmq.addresses"),
env.getProperty("spring.rabbitmq.username") +
"\n----------------------------------------------------------");
}
}