From d67891153f82b9d7606f91bd2db0f8dd4d2a258d Mon Sep 17 00:00:00 2001
From: 陈昶聿 <chychen@nbjetron.com>
Date: 星期四, 02 七月 2026 17:44:45 +0800
Subject: [PATCH] 【市一】任务组调试
---
ruoyi-quartz/src/main/java/com/ruoyi/quartz/task/RyTask.java | 56 +++++++++++++++++++++++++++++++++++++++++++++++++-------
1 files changed, 49 insertions(+), 7 deletions(-)
diff --git a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/task/RyTask.java b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/task/RyTask.java
index ec9250f..f31c02d 100644
--- a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/task/RyTask.java
+++ b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/task/RyTask.java
@@ -179,6 +179,9 @@
@Autowired
private SysConfigMapper sysConfigMapper;
+ @Autowired
+ private IServiceTaskScheduleService serviceTaskScheduleService;
+
public void ryMultipleParams(String s, Boolean b, Long l, Double d, Integer i) {
System.out.println(StringUtils.format("鎵ц澶氬弬鏂规硶锛� 瀛楃涓茬被鍨媨}锛屽竷灏旂被鍨媨}锛岄暱鏁村瀷{}锛屾诞鐐瑰瀷{}锛屾暣褰}", s, b, l, d, i));
}
@@ -560,17 +563,17 @@
}
/**
- * 澶勭悊鎮h�呬俊鎭紝杩涘叆瀛愪换鍔¤〃
+ * 澶勭悊鎮h�呬俊鎭紝杩涘叆瀛愪换鍔¤〃(浠诲姟缁�)
*/
- public void dealOutHospInfoByDimension() {
+ public void dealOutHospInfoBySchedule() {
String config = configService.selectConfigByKey("visit.early.day");
if (port.equals("8095")) {
//鍑洪櫌琛�
- iPatMedInhospService.dealOutHospInfoByDimension(config);
+ iPatMedInhospService.dealOutHospInfoBySchedule(config);
//闂ㄨ瘖琛�(鏂板崕鐨勬殏鏃朵笉鍋氶棬璇婇殢璁�)
- if (!active.equals("xh")) {
- //iPatMedOuthospService.dealOutpatientInfo();
- }
+// if (!active.equals("xh")) {
+// //iPatMedOuthospService.dealOutpatientInfo();
+// }
}
}
@@ -1346,7 +1349,7 @@
Map<String, String> headerMap = new HashMap<>();
headerMap.put("sign", encode);
String result = HttpUtils.sendPostByHeader(wxqqxx.get(3), body, headerMap);
-
+ log.info("銆恎etWXCode銆戝井淇″叕浼楀彿杩斿洖鍙傛暟锛歿}", result);
JSONObject jsonObject = JSONObject.parseObject(result);
String code = (String) jsonObject.toString();
return code;
@@ -1497,4 +1500,43 @@
int result = QwenLLMUtil.matchRegex(questionText, voiceText, value, regexText);
return result;
}
+
+ /**
+ * 浠诲姟缁勶紙appltype=5锛夐杞撼鍏ワ細鎵弿鏂板嚭闄㈡偅鑰咃紝鎸� schedule 缁戝畾鐨勭淮搴﹀尮閰嶄换鍔$粍锛�
+ * 涓哄懡涓殑鎮h�呮寜璁″垝鏄庣粏涓�娆℃�х敓鎴愮 0 杞� N 鏉� subtask锛屽苟缃� schedulecheck_flag=1銆�
+ * 鍚庣画杞鐢� {@link #rollTaskGroupCycle()} 璐熻矗銆�
+ * <p>
+ * 涓庝富鎵弿 dealOutHospInfo 鍒嗙锛屼簰涓嶅共鎵般�傚缓璁瘡 30 鍒嗛挓鎵ц涓�娆°��
+ */
+ public void dealTaskGroupOutHosp() {
+ log.info("銆恉ealTaskGroupOutHosp銆戝紑濮嬫壂鎻忎换鍔$粍鏂板嚭闄㈡偅鑰�");
+ if (!port.equals("8095")) {
+ return;
+ }
+ try {
+ String config = configService.selectConfigByKey("visit.early.day");
+ iPatMedInhospService.dealOutHospInfoBySchedule(config);
+ log.info("銆恉ealTaskGroupOutHosp銆戜换鍔$粍棣栬疆绾冲叆鎵弿瀹屾垚");
+ } catch (Exception e) {
+ log.error("銆恉ealTaskGroupOutHosp銆戜换鍔$粍鎵弿寮傚父", e);
+ }
+ }
+
+ /**
+ * 浠诲姟缁勶紙appltype=5锛夊惊鐜换鍔℃粴鍔ㄨ皟搴︺��
+ * <p>
+ * 鎵弿鎵�鏈� schedule_style=1 鐨勮鍒掞紝鑻ユ湰杞� subtask 鍏ㄩ儴 finalize锛坰endstate 鈭� 1/2/3锛夛紝
+ * 鍒欏厠闅嗘湰杞偅鑰呭埌涓嬩竴杞紝鎺ㄨ繘 current_loop_count 涓� visit_time銆�
+ * <p>
+ * 寤鸿姣忓皬鏃舵垨姣忓崐灏忔椂鎵ц涓�娆★紝閬垮厤杞绉帇銆�
+ */
+ public void rollTaskGroupCycle() {
+ log.info("銆恟ollTaskGroupCycle銆戝紑濮嬫壂鎻忓惊鐜换鍔$粍");
+ try {
+ int rolled = serviceTaskScheduleService.rollCycleTasks();
+ log.info("銆恟ollTaskGroupCycle銆戞湰娆℃帹杩� {} 涓鍒�", rolled);
+ } catch (Exception e) {
+ log.error("銆恟ollTaskGroupCycle銆戞粴鍔ㄨ皟搴﹀紓甯�", e);
+ }
+ }
}
--
Gitblit v1.9.3