This commit is contained in:
2026-05-05 14:12:36 +08:00
parent 8cacfb1c49
commit f78dfaec74
2 changed files with 17 additions and 6 deletions
+4 -3
View File
@@ -1,10 +1,11 @@
package service
import (
"gorm.io/gorm"
"level_go/internal/model"
"math"
"sort"
"gorm.io/gorm"
"level_go/internal/model"
)
type StockService struct {
@@ -37,7 +38,7 @@ func (s *StockService) AnalyzePerformance(startDate, endDate string) ([]model.An
}
// 查询涨停股
query := `SELECT l.ts_code, l.name, d.open, d.high FROM stock_limit_data l
query := `SELECT l.ts_code, l.name, d.open, d.high FROM stock_limit_data l
LEFT JOIN stock_daily d ON l.ts_code = d.ts_code AND l.trade_date = d.trade_date
WHERE l.trade_date = ? AND l.status = 1`