Commit b6a5f8b3 by mushishixian

单位问题

parent 8709c3b6
...@@ -33,7 +33,7 @@ func MatchGoodsNameByAttrs(bomItems []model.BomItem) (result []model.BomItem, er ...@@ -33,7 +33,7 @@ func MatchGoodsNameByAttrs(bomItems []model.BomItem) (result []model.BomItem, er
if item.GoodsName != "" && item.Attrs == "" { if item.GoodsName != "" && item.Attrs == "" {
search = searchAttr(item, search) search = searchAttr(item, search)
searchFlag = true searchFlag = true
}else{ } else {
search = searchAttr(item, search) search = searchAttr(item, search)
searchFlag = true searchFlag = true
} }
...@@ -120,6 +120,7 @@ func searchAttr(bomItem model.BomItem, search *es.MultiSearchService) (result *e ...@@ -120,6 +120,7 @@ func searchAttr(bomItem model.BomItem, search *es.MultiSearchService) (result *e
} }
} }
} }
//fmt.Println(attrsSlice)
query := getQuery(attrsSlice) query := getQuery(attrsSlice)
//如果ZyBrandId不为空,则代表匹配到了映射id //如果ZyBrandId不为空,则代表匹配到了映射id
if bomItem.ZyBrandId != "" && len(attrsSlice) > 0 { if bomItem.ZyBrandId != "" && len(attrsSlice) > 0 {
......
...@@ -9,7 +9,9 @@ var KeywordRegular = map[string]string{ ...@@ -9,7 +9,9 @@ var KeywordRegular = map[string]string{
`(欧姆|欧|O|o|R|r)$`: "Ω", `(欧姆|欧|O|o|R|r)$`: "Ω",
`(Uf|uf|μf|uF|UF)$`: "μF", `(Uf|uf|μf|uF|UF)$`: "μF",
`(Nf|NF)$`: "nF", `(Nf|NF|nf)$`: "nF",
`(Pf|PF|pf)$`: "pF",
`(Mf|MF|mf)$`: "mF",
`(Uh|uh|μh|uH|UH)$`: "μH", `(Uh|uh|μh|uH|UH)$`: "μH",
`K$`: "nF", `K$`: "nF",
`v$`: "V", `v$`: "V",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment