add mock order.

This commit is contained in:
yanweidong
2026-02-09 18:28:00 +08:00
parent 8a6b129ba6
commit b9f522b101
10 changed files with 141 additions and 13 deletions

View File

@@ -30,6 +30,7 @@ func main() {
app.Use(middleware.Cors())
app.Use(gin.Recovery())
app.GET("/", restful.Ping)
app.GET("/start/strategy", restful.Starter)
// 启动HTTP服务器
err := app.Run(fmt.Sprintf(":%s", config.Spec.Port))

View File

@@ -22,9 +22,10 @@ func main() {
config.New(ServiceKey)
impl.NewImpl()
ymd := models.GetYmd()
for _, code := range strategy.GetStocks() {
strategy.InitCacheByCode(code)
model := models.NewStratModel("selector", code)
model := models.NewStratModel("selector", code, ymd)
stratRule := rule.NewRule(model)
{
stratRule.RunUpDate(strategy.Cache[code].Basic.ListDate)