Compare commits

...

2 Commits

Author SHA1 Message Date
9376a85673 Merge remote-tracking branch 'origin/master'
# Conflicts:
#	bocai.db
#	src/main/java/com/tem/bocai/util/HttpClientExample.java
2026-02-04 09:55:37 +08:00
3f4e0b8f8f 调整金额 2026-02-04 09:55:09 +08:00
6 changed files with 8 additions and 19 deletions

BIN
bocai.db

Binary file not shown.

View File

@@ -62,9 +62,6 @@ public class ChartController {
List<String> labels = new ArrayList<>();
List<Double> data = new ArrayList<>();
// 计算累计盈亏
double totalProfit = 0.0;
// 遍历每5分钟间隔
Calendar intervalCalendar = (Calendar) calendar.clone();
while (intervalCalendar.getTime().before(currentTime)) {
@@ -79,20 +76,12 @@ public class ChartController {
intervalProfit += item.getResultAmount();
}
}
// 更新总盈亏
totalProfit = intervalProfit;
data.add(totalProfit);
data.add(intervalProfit);
// 增加5分钟
intervalCalendar.add(Calendar.MINUTE, 5);
}
// 添加当前时间点的数据
if (!labels.isEmpty()) {
String currentTimeLabel = DateFormatUtils.format(currentTime, "HH:mm");
labels.add(currentTimeLabel);
data.add(totalProfit);
}
// 如果没有今日数据生成默认的5分钟间隔数据

View File

@@ -41,7 +41,7 @@ public class BetSchedule {
private BetRecordRepository betRecordRepository;
// 从7:02分钟起每5分钟执行一次
@Scheduled(cron = "30 2/5 * * * ?")
// @Scheduled(cron = "30 2/5 * * * ?")
public void placeBet() {
LocalDateTime now = LocalDateTime.now();
int hour = now.getHour();

View File

@@ -38,7 +38,7 @@ public class CrawlerSchedule {
/*@Scheduled(cron = "0 6-59/5 7-23 * * ?")
@Scheduled(cron = "0 0-55/5 0-6 * * ?")*/
// 从7:00分30秒起每5分钟执行一次
@Scheduled(cron = "30 0/5 * * * ?")
// @Scheduled(cron = "30 0/5 * * * ?")
public void executeLotteryDraw() {
log.info("开始爬取开奖结果");
int retryCount = 0;
@@ -105,7 +105,7 @@ public class CrawlerSchedule {
}
@Scheduled(cron = "55 0/5 * * * ?")
// @Scheduled(cron = "55 0/5 * * * ?")
//@Scheduled(cron = "*/9 * * * * ?")
public void executePksHistory() {
log.info("开始获取历史开奖结果");

View File

@@ -125,7 +125,7 @@ public class ExBetScriptSchedule {
}
// 从7:01分钟起每5分钟执行一次
@Scheduled(cron = "30 1/5 * * * ?")
// @Scheduled(cron = "30 1/5 * * * ?")
public void executePythonScript() {
LocalDateTime now = LocalDateTime.now();
int hour = now.getHour();

View File

@@ -10,4 +10,4 @@ spring.jpa.show-sql=true
spring.jpa.database-platform=org.hibernate.community.dialect.SQLiteDialect
spring.jpa.properties.hibernate.jdbc.lob.non_contextual_creation=true
pypath:c:/py/PyModel
pypath:D:/py/PyModel