2 Star 15 Fork 17

王布衣/engine

Create your Gitee Account
Explore and code with more than 14 million developers,Free private repositories !:)
Sign up
文件
Clone or Download
task_update_rzrq.go 723 Bytes
Copy Edit Raw Blame History
王布衣 authored 2024-04-11 17:52 +08:00 . misc增加融资余额占比字段
package services
import (
"gitee.com/quant1x/engine/cache"
"gitee.com/quant1x/engine/factors"
"gitee.com/quant1x/engine/market"
"gitee.com/quant1x/gox/logger"
)
func jobUpdateMarginTrading() {
logger.Infof("同步融资融券...")
updateMarginTrading()
logger.Infof("同步融资融券...OK")
}
func updateMarginTrading() {
date := cache.DefaultCanReadDate()
factors.MarginTradingTargetInit(date)
allCodes := market.GetCodeList()
for _, securityCode := range allCodes {
misc := factors.GetL5Misc(securityCode)
if misc == nil {
continue
}
rzrq, ok := factors.GetMarginTradingTarget(securityCode)
if ok {
misc.RZYEZB = rzrq.RZYEZB
factors.UpdateL5Misc(misc)
}
}
factors.RefreshL5Misc()
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/quant1x/engine.git
git@gitee.com:quant1x/engine.git
quant1x
engine
engine
v1.8.18

Search