增加判断是否是股票代码的判断

This commit is contained in:
injoyai
2025-02-21 10:44:30 +08:00
parent 6e920c7330
commit 859ea71e8d
2 changed files with 9 additions and 0 deletions

View File

@@ -195,6 +195,7 @@ func getVolume(val uint32) (volume float64) {
return
}
// IsStock 是否是股票,示例sz000001
func IsStock(code string) bool {
if len(code) != 8 {
return false