zj
2025-02-25 dd315d5732e14fcf3df71e0cf213cc442bd8607b
src/main/java/project/web/api/RealtimeController.java
@@ -2,6 +2,7 @@
import java.math.RoundingMode;
import java.text.DecimalFormat;
import java.text.SimpleDateFormat;
import java.util.*;
import java.util.stream.Collectors;
@@ -89,7 +90,11 @@
         Map<String, Object> map = new HashMap<String, Object>();
         map.put("symbol", realtime.getSymbol());
         map.put("ts", realtime.getTs());
         map.put("current_time", realtime.getCurrent_time());
         String currentTime = realtime.getCurrent_time();
         SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss a", Locale.ENGLISH);
         // 设置时区为台湾(Asia/Taipei)
         sdf.setTimeZone(TimeZone.getTimeZone("Asia/Taipei"));
         map.put("current_time",sdf.format(currentTime));
         map.put("name", realtime.getName());
         map.put("change_ratio", realtime.getChange_ratio());
         Item item = this.itemService.cacheBySymbol(realtime.getSymbol(), true);