From d0c46176de41a02f4e34c3c363294163834ebaa9 Mon Sep 17 00:00:00 2001
From: XinWei <2718030729@qq.com>
Date: Mon, 8 Jul 2024 20:11:39 +0800
Subject: [PATCH] =?UTF-8?q?=E6=8A=BD=E6=95=B0=E6=A8=A1=E5=9D=97=E5=92=8C?=
=?UTF-8?q?=E6=95=B4=E5=90=88xxl-job?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../xxl/job/admin/api/info/JobInfoApi.java | 2 +
.../job/admin/controller/IndexController.java | 1 -
.../admin/controller/JobApiController.java | 2 +-
.../admin/controller/JobCodeController.java | 2 +-
.../admin/controller/JobGroupController.java | 2 +-
.../admin/controller/JobInfoController.java | 2 +-
.../admin/controller/JobLogController.java | 2 +-
.../job/admin/controller/UserController.java | 2 +-
.../src/main/resources/bootstrap.yaml | 4 +-
.../ludu-module-sampling-biz/pom.xml | 5 +-
.../rpc/config/RpcConfiguration.java | 4 +-
.../yudao/module/sampling/job/DemoJob.java | 33 -----
.../module/sampling/service/SamplingJob.java | 61 --------
.../ticketing/TicketingSamplingJob.java | 132 ++++++++++++++++++
.../ticketing/vo/TicketingSamplingReqVO.java | 26 ++++
.../ticketing/vo/TicketingSamplingRespVO.java | 29 ++++
.../api/checkticket/TicketCheckTicketApi.java | 9 +-
.../dto/CheckTicketSaveReqDTO.java | 40 ++++++
.../api/saledata/TicketSaleDataApi.java | 8 ++
.../api/saledata/dto/SaleDataSaveReqDTO.java | 64 +++++++++
.../checkticket/TicketCheckTicketApiImpl.java | 8 ++
.../api/saledata/TicketSaleDataApiImpl.java | 10 ++
.../vo/vo/CheckTicketSaveReqVO.java | 2 +
.../admin/saledata/vo/SaleDataPageReqVO.java | 4 +-
.../admin/saledata/vo/SaleDataRespVO.java | 4 +-
.../admin/saledata/vo/SaleDataSaveReqVO.java | 7 +-
.../ticket/dal/dataobject/asset/AssetDO.java | 7 +-
.../dataobject/checkticket/CheckTicketDO.java | 5 +-
.../dal/dataobject/saledata/SaleDataDO.java | 5 +
pom.xml | 1 -
.../ludu-job-core}/pom.xml | 2 +-
.../java/com/xxl/job/core/biz/AdminBiz.java | 0
.../com/xxl/job/core/biz/ExecutorBiz.java | 0
.../job/core/biz/client/AdminBizClient.java | 0
.../core/biz/client/ExecutorBizClient.java | 0
.../job/core/biz/impl/ExecutorBizImpl.java | 0
.../core/biz/model/HandleCallbackParam.java | 0
.../xxl/job/core/biz/model/IdleBeatParam.java | 0
.../com/xxl/job/core/biz/model/KillParam.java | 0
.../com/xxl/job/core/biz/model/LogParam.java | 0
.../com/xxl/job/core/biz/model/LogResult.java | 0
.../xxl/job/core/biz/model/RegistryParam.java | 0
.../com/xxl/job/core/biz/model/ReturnT.java | 0
.../xxl/job/core/biz/model/TriggerParam.java | 0
.../xxl/job/core/context/XxlJobContext.java | 0
.../xxl/job/core/context/XxlJobHelper.java | 0
.../core/enums/ExecutorBlockStrategyEnum.java | 0
.../xxl/job/core/enums/RegistryConfig.java | 0
.../xxl/job/core/executor/XxlJobExecutor.java | 0
.../executor/impl/XxlJobSimpleExecutor.java | 0
.../executor/impl/XxlJobSpringExecutor.java | 0
.../com/xxl/job/core/glue/GlueFactory.java | 0
.../com/xxl/job/core/glue/GlueTypeEnum.java | 0
.../job/core/glue/impl/SpringGlueFactory.java | 0
.../com/xxl/job/core/handler/IJobHandler.java | 0
.../core/handler/annotation/JobHandler.java | 0
.../job/core/handler/annotation/XxlJob.java | 0
.../job/core/handler/impl/GlueJobHandler.java | 0
.../core/handler/impl/MethodJobHandler.java | 0
.../core/handler/impl/ScriptJobHandler.java | 0
.../xxl/job/core/log/XxlJobFileAppender.java | 0
.../com/xxl/job/core/server/EmbedServer.java | 0
.../core/thread/ExecutorRegistryThread.java | 0
.../core/thread/JobLogFileCleanThread.java | 0
.../com/xxl/job/core/thread/JobThread.java | 0
.../core/thread/TriggerCallbackThread.java | 0
.../java/com/xxl/job/core/util/DateUtil.java | 0
.../java/com/xxl/job/core/util/FileUtil.java | 0
.../java/com/xxl/job/core/util/GsonTool.java | 0
.../java/com/xxl/job/core/util/IpUtil.java | 0
.../xxl/job/core/util/JdkSerializeTool.java | 0
.../java/com/xxl/job/core/util/NetUtil.java | 0
.../com/xxl/job/core/util/ScriptUtil.java | 0
.../com/xxl/job/core/util/ShardingUtil.java | 0
.../com/xxl/job/core/util/ThrowableUtil.java | 0
.../xxl/job/core/util/XxlJobRemotingUtil.java | 0
yudao-framework/pom.xml | 1 +
.../common/util/date/TickingDateUtils.java | 38 +++++
.../YudaoWebSecurityConfigurerAdapter.java | 1 +
.../yudao-module-infra-biz/pom.xml | 11 +-
.../controller/admin/job/JobController.java | 10 +-
.../api/address/MemberAddressApiImpl.java | 3 +-
.../convert/address/AddressConvert.java | 2 +-
.../convert}/address/MemberAddressApi.java | 4 +-
.../address/dto/MemberAddressRespDTO.java | 2 +-
85 files changed, 427 insertions(+), 130 deletions(-)
delete mode 100644 ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/job/DemoJob.java
delete mode 100644 ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/SamplingJob.java
create mode 100644 ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/TicketingSamplingJob.java
create mode 100644 ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/vo/TicketingSamplingReqVO.java
create mode 100644 ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/vo/TicketingSamplingRespVO.java
create mode 100644 ludu-module-ticket-manager/ludu-module-ticket-manager-api/src/main/java/cn/iocoder/yudao/module/ticket/api/checkticket/dto/CheckTicketSaveReqDTO.java
create mode 100644 ludu-module-ticket-manager/ludu-module-ticket-manager-api/src/main/java/cn/iocoder/yudao/module/ticket/api/saledata/dto/SaleDataSaveReqDTO.java
rename {ludu-job-core => yudao-framework/ludu-job-core}/pom.xml (98%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/AdminBiz.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/ExecutorBiz.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/client/AdminBizClient.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/client/ExecutorBizClient.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/impl/ExecutorBizImpl.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/HandleCallbackParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/IdleBeatParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/KillParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/LogParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/LogResult.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/RegistryParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/ReturnT.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/biz/model/TriggerParam.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/context/XxlJobContext.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/context/XxlJobHelper.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/enums/ExecutorBlockStrategyEnum.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/enums/RegistryConfig.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/executor/XxlJobExecutor.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/executor/impl/XxlJobSimpleExecutor.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/executor/impl/XxlJobSpringExecutor.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/glue/GlueFactory.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/glue/GlueTypeEnum.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/glue/impl/SpringGlueFactory.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/IJobHandler.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/annotation/JobHandler.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/annotation/XxlJob.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/impl/GlueJobHandler.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/impl/MethodJobHandler.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/handler/impl/ScriptJobHandler.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/log/XxlJobFileAppender.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/server/EmbedServer.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/thread/ExecutorRegistryThread.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/thread/JobLogFileCleanThread.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/thread/JobThread.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/thread/TriggerCallbackThread.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/DateUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/FileUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/GsonTool.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/IpUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/JdkSerializeTool.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/NetUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/ScriptUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/ShardingUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/ThrowableUtil.java (100%)
rename {ludu-job-core => yudao-framework/ludu-job-core}/src/main/java/com/xxl/job/core/util/XxlJobRemotingUtil.java (100%)
create mode 100644 yudao-framework/yudao-common/src/main/java/cn/iocoder/yudao/framework/common/util/date/TickingDateUtils.java
rename yudao-module-member/{yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api => yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert}/address/MemberAddressApi.java (91%)
rename yudao-module-member/{yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api => yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert}/address/dto/MemberAddressRespDTO.java (95%)
diff --git a/ludu-job-admin/ludu-job-admin-api/src/main/java/com/xxl/job/admin/api/info/JobInfoApi.java b/ludu-job-admin/ludu-job-admin-api/src/main/java/com/xxl/job/admin/api/info/JobInfoApi.java
index abc74ca4c..1b32799c1 100644
--- a/ludu-job-admin/ludu-job-admin-api/src/main/java/com/xxl/job/admin/api/info/JobInfoApi.java
+++ b/ludu-job-admin/ludu-job-admin-api/src/main/java/com/xxl/job/admin/api/info/JobInfoApi.java
@@ -9,6 +9,7 @@ import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import java.util.List;
@@ -19,6 +20,7 @@ import java.util.Map;
*/
@FeignClient(name = ApiConstants.NAME)
@Tag(name = "RPC 服务 - 任务信息管理")
+@RequestMapping("")
public interface JobInfoApi {
String PREFIX = ApiConstants.PREFIX + "/info";
@GetMapping(PREFIX + "/page")
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/IndexController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/IndexController.java
index f6d364d5a..eb63f0bd4 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/IndexController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/IndexController.java
@@ -27,7 +27,6 @@ import java.util.Map;
* @author xuxueli 2015-12-19 16:13:16
*/
@Controller
-@RequestMapping("/xxl-job-admin")
public class IndexController {
@Resource
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobApiController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobApiController.java
index 1370ea617..aa51e7390 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobApiController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobApiController.java
@@ -22,7 +22,7 @@ import java.util.List;
* Created by xuxueli on 17/5/10.
*/
@Controller
-@RequestMapping("/xxl-job-admin/api")
+@RequestMapping("/api")
public class JobApiController {
@Resource
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobCodeController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobCodeController.java
index d3d7710f8..fe4a0e848 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobCodeController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobCodeController.java
@@ -22,7 +22,7 @@ import java.util.List;
* @author xuxueli 2015-12-19 16:13:16
*/
@Controller
-@RequestMapping("/xxl-job-admin/jobcode")
+@RequestMapping("/jobcode")
public class JobCodeController {
@Resource
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobGroupController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobGroupController.java
index 5ca97419b..8e0c5a4d5 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobGroupController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobGroupController.java
@@ -24,7 +24,7 @@ import java.util.*;
* @author xuxueli 2016-10-02 20:52:56
*/
@Controller
-@RequestMapping("/xxl-job-admin/jobgroup")
+@RequestMapping("/jobgroup")
public class JobGroupController {
@Resource
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobInfoController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobInfoController.java
index a0978d750..516dce418 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobInfoController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobInfoController.java
@@ -33,7 +33,7 @@ import java.util.*;
* @author xuxueli 2015-12-19 16:13:16
*/
@Controller
-@RequestMapping("/xxl-job-admin/jobinfo")
+@RequestMapping("/jobinfo")
public class JobInfoController {
private static Logger logger = LoggerFactory.getLogger(JobInfoController.class);
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobLogController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobLogController.java
index 302a88909..bff91989e 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobLogController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/JobLogController.java
@@ -38,7 +38,7 @@ import java.util.Map;
* @author xuxueli 2015-12-19 16:13:16
*/
@Controller
-@RequestMapping("/xxl-job-admin/joblog")
+@RequestMapping("/joblog")
public class JobLogController {
private static Logger logger = LoggerFactory.getLogger(JobLogController.class);
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/UserController.java b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/UserController.java
index 11a301aaa..3f4c7559b 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/UserController.java
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/java/com/xxl/job/admin/controller/UserController.java
@@ -26,7 +26,7 @@ import java.util.Map;
* @author xuxueli 2019-05-04 16:39:50
*/
@Controller
-@RequestMapping("/xxl-job-admin/user")
+@RequestMapping("/user")
public class UserController {
@Resource
diff --git a/ludu-job-admin/ludu-job-admin-biz/src/main/resources/bootstrap.yaml b/ludu-job-admin/ludu-job-admin-biz/src/main/resources/bootstrap.yaml
index 184587608..79517ff5c 100644
--- a/ludu-job-admin/ludu-job-admin-biz/src/main/resources/bootstrap.yaml
+++ b/ludu-job-admin/ludu-job-admin-biz/src/main/resources/bootstrap.yaml
@@ -7,8 +7,8 @@ spring:
server:
port: 9090
-# servlet:
-# context-path: /xxl-job-admin
+ servlet:
+ context-path: /xxl-job-admin
# 日志文件配置。注意,如果 logging.file.name 不放在 bootstrap.yaml 配置文件,而是放在 application.yaml 中,会导致出现 LOG_FILE_IS_UNDEFINED 文件
logging:
diff --git a/ludu-module-sampling/ludu-module-sampling-biz/pom.xml b/ludu-module-sampling/ludu-module-sampling-biz/pom.xml
index d2b88d27a..b020ba28f 100644
--- a/ludu-module-sampling/ludu-module-sampling-biz/pom.xml
+++ b/ludu-module-sampling/ludu-module-sampling-biz/pom.xml
@@ -13,11 +13,12 @@
${project.artifactId}
- ticket 模块,我们票务业务。
- 例如说:设备管理等等
+ sampling 模块,我们抽数模块。
+ 例如说:检票和售票的数据抽数等等
+
cn.iocoder.cloud
ludu-job-core
diff --git a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/framework/rpc/config/RpcConfiguration.java b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/framework/rpc/config/RpcConfiguration.java
index 30407d965..ea646b821 100644
--- a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/framework/rpc/config/RpcConfiguration.java
+++ b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/framework/rpc/config/RpcConfiguration.java
@@ -1,6 +1,8 @@
package cn.iocoder.yudao.module.sampling.framework.rpc.config;
import cn.iocoder.yudao.module.ticket.api.asset.TicketAssetApi;
+import cn.iocoder.yudao.module.ticket.api.checkticket.TicketCheckTicketApi;
+import cn.iocoder.yudao.module.ticket.api.saledata.TicketSaleDataApi;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Configuration;
@@ -8,6 +10,6 @@ import org.springframework.context.annotation.Configuration;
* @Description TODO
*/
@Configuration(proxyBeanMethods = false)
-@EnableFeignClients(clients = {TicketAssetApi.class})
+@EnableFeignClients(clients = {TicketAssetApi.class, TicketSaleDataApi.class, TicketCheckTicketApi.class})
public class RpcConfiguration {
}
diff --git a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/job/DemoJob.java b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/job/DemoJob.java
deleted file mode 100644
index ac3679b8c..000000000
--- a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/job/DemoJob.java
+++ /dev/null
@@ -1,33 +0,0 @@
-package cn.iocoder.yudao.module.sampling.job;
-
-import com.xxl.job.core.biz.model.ReturnT;
-import com.xxl.job.core.handler.IJobHandler;
-import com.xxl.job.core.handler.annotation.XxlJob;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.stereotype.Component;
-
-import java.util.concurrent.atomic.AtomicInteger;
-
-/**
- * @Description TODO
- */
-@Component
-public class DemoJob extends IJobHandler {
-
- private Logger logger = LoggerFactory.getLogger(getClass());
-
- private final AtomicInteger counts = new AtomicInteger();
- @XxlJob("demoJob")
- public ReturnT demoJobHandler(String param) throws Exception {
- logger.info("XXL-JOB, Hello World.");
- System.out.println("zxxxx");
- logger.info("XXL-JOB, Hello World end.");
- return ReturnT.SUCCESS;
- }
-
- @Override
- public void execute() throws Exception {
-
- }
-}
diff --git a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/SamplingJob.java b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/SamplingJob.java
deleted file mode 100644
index 5c5cf4817..000000000
--- a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/SamplingJob.java
+++ /dev/null
@@ -1,61 +0,0 @@
-package cn.iocoder.yudao.module.sampling.service;
-
-import cn.hutool.http.HttpUtil;
-import cn.hutool.json.JSONUtil;
-import com.fasterxml.jackson.databind.ObjectMapper;
-import com.xxl.job.core.context.XxlJobHelper;
-import com.xxl.job.core.handler.annotation.XxlJob;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.stereotype.Component;
-
-import java.math.BigDecimal;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.concurrent.TimeUnit;
-
-/**
- * @Description 抽数服务
- */
-@Component
-public class SamplingJob {
- private static Logger logger = LoggerFactory.getLogger(SamplingJob.class);
- @XxlJob("getSaleData")
- public void demoJobHandler() throws Exception {
- XxlJobHelper.log("XXL-JOB, Hello World.");
- Map map = new HashMap<>();
- map.put("service", "apiSaleService");
- map.put("method", "SaleDetail");
- map.put("queryDate", "20240704");
- map.put("pageNumber", 1);
- map.put("pageSize", 2000);
- String str = HttpUtil.post("http://shinanlundu.pro.jiutianda.com/joytime-erp-eportal/console/openapi/handler", JSONUtil.toJsonStr(map));
-
- /*System.out.println(str);
- ObjectMapper objectMapper = new ObjectMapper();
- com.example.snlundu.domain.Test data = objectMapper.readValue(str, com.example.snlundu.domain.Test.class);
-// HeartbeatLog data = objectMapper.readValue(str, HeartbeatLog.class);
- for (Map stringObjectMap : data.getDataMapList()) {
- SaleData saleData=new SaleData();
- saleData.setDataId((String)stringObjectMap.get("dataId"));
- saleData.setSdno((String)stringObjectMap.get("sdno"));
- saleData.setTransactiontypeno((String)stringObjectMap.get("transactiontypeno"));
- saleData.setSddate((String)stringObjectMap.get("sddate"));
- saleData.setSdtime((String)stringObjectMap.get("sdtime"));
- BigDecimal amountString = new BigDecimal(stringObjectMap.get("amount").toString());
- saleData.setAmount(amountString);
- Integer quantity = (Integer) stringObjectMap.get("quantity");
- saleData.setQuantity(quantity);
- saleData.setCertificatetype((String)stringObjectMap.get("certificatetype"));
- saleData.setCertificateno((String)stringObjectMap.get("certificateno"));
- saleData.setProductbatchno((String)stringObjectMap.get("productbatchno"));
- saleData.setItem((String)stringObjectMap.get("item"));
- saleData.setItemtypename((String)stringObjectMap.get("itemtypename"));
- saleData.setItemtype((String)stringObjectMap.get("itemtype"));
- saleData.setItemname((String)stringObjectMap.get("itemname"));
- saleData.setSalepropetyvaluename((String)stringObjectMap.get("salepropetyvaluename"));
- saleDataRepository.save(saleData);
- }*/
- // default success
- }
-}
diff --git a/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/TicketingSamplingJob.java b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/TicketingSamplingJob.java
new file mode 100644
index 000000000..51ff21635
--- /dev/null
+++ b/ludu-module-sampling/ludu-module-sampling-biz/src/main/java/cn/iocoder/yudao/module/sampling/service/ticketing/TicketingSamplingJob.java
@@ -0,0 +1,132 @@
+package cn.iocoder.yudao.module.sampling.service.ticketing;
+
+import cn.hutool.http.HttpUtil;
+import cn.hutool.json.JSONUtil;
+import cn.iocoder.yudao.framework.common.util.date.TickingDateUtils;
+import cn.iocoder.yudao.module.sampling.service.ticketing.vo.TicketingSamplingReqVO;
+import cn.iocoder.yudao.module.sampling.service.ticketing.vo.TicketingSamplingRespVO;
+import cn.iocoder.yudao.module.ticket.api.checkticket.TicketCheckTicketApi;
+import cn.iocoder.yudao.module.ticket.api.checkticket.dto.CheckTicketSaveReqDTO;
+import cn.iocoder.yudao.module.ticket.api.saledata.TicketSaleDataApi;
+import cn.iocoder.yudao.module.ticket.api.saledata.dto.SaleDataSaveReqDTO;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.xxl.job.core.context.XxlJobHelper;
+import com.xxl.job.core.handler.annotation.XxlJob;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.Resource;
+import java.math.BigDecimal;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * @Description 抽数服务
+ */
+@Component
+public class TicketingSamplingJob {
+ private static Logger logger = LoggerFactory.getLogger(TicketingSamplingJob.class);
+
+ private static final int PAGE_SIZE = 500;
+ @Resource
+ private TicketSaleDataApi ticketSaleDataApi;
+
+ @Resource
+ private TicketCheckTicketApi ticketCheckTicketApi;
+
+ @XxlJob("getSaleData")
+ public void getSaleDataHandler() throws Exception {
+ int failedCount = 0;
+ int pageNumber = 1;
+ XxlJobHelper.log("抽数服务:销售数据开始抽数...");
+ // 准备请求参数
+ TicketingSamplingReqVO ticketingSamplingReqVO = new TicketingSamplingReqVO();
+ ticketingSamplingReqVO.setService("apiSaleService");
+ ticketingSamplingReqVO.setMethod("SaleDetail");
+ ticketingSamplingReqVO.setQueryDate(TickingDateUtils.getNowDayFormat());
+ ticketingSamplingReqVO.setPageNumber(pageNumber);
+ ticketingSamplingReqVO.setPageSize(PAGE_SIZE);
+ // 先发起第一次请求
+ String str = HttpUtil.post("http://shinanlundu.pro.jiutianda.com/joytime-erp-eportal/console/openapi/handler", JSONUtil.toJsonStr(ticketingSamplingReqVO));
+ // 解析读取响应数据
+ TicketingSamplingRespVO ticketingSamplingRespVO = new ObjectMapper().readValue(str, TicketingSamplingRespVO.class);
+ // 如果访问失败则让调度中心重新调用
+ if (!ticketingSamplingRespVO.isPassflag()) {
+ // 让调度中心重新调用
+ XxlJobHelper.log("抽数服务:销售数据抽数失败,返回消息:" + ticketingSamplingRespVO.getRtnMsg());
+ XxlJobHelper.handleFail("销售数据抽数失败,请重试");
+ return;
+ }
+ int totalRows = ticketingSamplingRespVO.getTotalRows();
+ List
+
+ cn.iocoder.cloud
+ ludu-job-core
+ ${revision}
+
org.springframework.cloud
@@ -97,11 +102,7 @@
cn.iocoder.cloud
yudao-spring-boot-starter-job
-
- cn.iocoder.cloud
- ludu-job-core
- ${revision}
-
+
diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java
index 10d3b6ad3..6ec7146ff 100644
--- a/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java
+++ b/yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java
@@ -30,8 +30,8 @@ import static cn.iocoder.yudao.framework.common.pojo.CommonResult.error;
@RequestMapping("/infra/job")
@Validated
public class JobController {
- @Resource
- private JobInfoApi jobInfoApi;
+ /*@Resource
+ private JobInfoApi jobInfoApi;*/
// private static final String XXL_JOB_URL = "http://127.0.0.1:9090/xxl-job-admin";
// private static final String USERNAME = "admin"; // TODO 可以直接读取配置中的账号和密码
@@ -53,13 +53,13 @@ public class JobController {
// TODO 如果登录失败,则不会有Set-Cookie的值,抛出异常,使用全局异常处理类
}
}*/
-
- @GetMapping("/page")
+ // TODO 出现未知错误 JobInfoApi 无法创建 bean
+ /*@GetMapping("/page")
@Operation(summary = "获得定时任务分页")
@PreAuthorize("@ss.hasPermission('infra:job:query')")
public CommonResult> getJobPage(@RequestParam(value = "pageNo") Integer pageNo, @RequestParam(value = "pageSize") Integer pageSize, @RequestParam(required = false, value = "name") String name, @RequestParam(required = false, value = "status") Integer status, @RequestParam(required = false, value = "handlerName") String handlerName) {
return jobInfoApi.getPage(pageNo, pageSize, name, status, handlerName);
- }
+ }*/
}
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApiImpl.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApiImpl.java
index f81b297f8..de8bb0b5f 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApiImpl.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApiImpl.java
@@ -1,7 +1,8 @@
package cn.iocoder.yudao.module.member.api.address;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
-import cn.iocoder.yudao.module.member.api.address.dto.MemberAddressRespDTO;
+import cn.iocoder.yudao.module.member.convert.address.MemberAddressApi;
+import cn.iocoder.yudao.module.member.convert.address.dto.MemberAddressRespDTO;
import cn.iocoder.yudao.module.member.convert.address.AddressConvert;
import cn.iocoder.yudao.module.member.service.address.AddressService;
import org.springframework.validation.annotation.Validated;
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/AddressConvert.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/AddressConvert.java
index 39dc9fa98..783e1be6a 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/AddressConvert.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/AddressConvert.java
@@ -1,7 +1,7 @@
package cn.iocoder.yudao.module.member.convert.address;
import cn.iocoder.yudao.framework.ip.core.utils.AreaUtils;
-import cn.iocoder.yudao.module.member.api.address.dto.MemberAddressRespDTO;
+import cn.iocoder.yudao.module.member.convert.address.dto.MemberAddressRespDTO;
import cn.iocoder.yudao.module.member.controller.admin.address.vo.AddressRespVO;
import cn.iocoder.yudao.module.member.controller.app.address.vo.AppAddressCreateReqVO;
import cn.iocoder.yudao.module.member.controller.app.address.vo.AppAddressRespVO;
diff --git a/yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApi.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/MemberAddressApi.java
similarity index 91%
rename from yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApi.java
rename to yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/MemberAddressApi.java
index 5dd696a72..93648a565 100644
--- a/yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/MemberAddressApi.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/MemberAddressApi.java
@@ -1,7 +1,7 @@
-package cn.iocoder.yudao.module.member.api.address;
+package cn.iocoder.yudao.module.member.convert.address;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
-import cn.iocoder.yudao.module.member.api.address.dto.MemberAddressRespDTO;
+import cn.iocoder.yudao.module.member.convert.address.dto.MemberAddressRespDTO;
import cn.iocoder.yudao.module.member.enums.ApiConstants;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
diff --git a/yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/dto/MemberAddressRespDTO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/dto/MemberAddressRespDTO.java
similarity index 95%
rename from yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/dto/MemberAddressRespDTO.java
rename to yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/dto/MemberAddressRespDTO.java
index e2b88744a..70f375df5 100644
--- a/yudao-module-member/yudao-module-member-api/src/main/java/cn/iocoder/yudao/module/member/api/address/dto/MemberAddressRespDTO.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/convert/address/dto/MemberAddressRespDTO.java
@@ -1,4 +1,4 @@
-package cn.iocoder.yudao.module.member.api.address.dto;
+package cn.iocoder.yudao.module.member.convert.address.dto;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;