|
|
@@ -124,6 +124,22 @@ func TurnChain(eg *xorm.Engine, officialEg, zhimengEg *xorm.Engine, args map[str |
|
|
|
} |
|
|
|
if PlatType == "" { |
|
|
|
|
|
|
|
} |
|
|
|
replaceAll := []string{"(", ")", "\\", "/"} |
|
|
|
reqCount2 := reqCount |
|
|
|
|
|
|
|
for _, v := range replaceAll { |
|
|
|
reqCount2 = strings.ReplaceAll(reqCount2, v, "") |
|
|
|
} |
|
|
|
split1 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{6,15}").FindAllString(reqCount2, -1) |
|
|
|
split3 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{4,6}").FindAllString(reqCount2, -1) |
|
|
|
split2 := regexp.MustCompile("[a-zA-Z0-9]{6,15}").FindAllString(reqCount2, -1) |
|
|
|
if strings.Contains(reqCount2, "http") { |
|
|
|
split2 = make([]string, 0) |
|
|
|
} |
|
|
|
isTao2 := 0 |
|
|
|
if len(split1) > 0 || len(split3) > 0 || len(split2) == 2 || strings.Count(reqCount2, "€") >= 1 || strings.Contains(reqCount2, "tb.cn") || ((strings.Contains(reqCount2, "taobao.com") || strings.Contains(reqCount2, "tmall.com")) && strings.Contains(reqCount2, "id=") == false) { |
|
|
|
isTao2 = 1 |
|
|
|
} |
|
|
|
for k, v := range split { |
|
|
|
if v == "" { |
|
|
@@ -133,11 +149,46 @@ func TurnChain(eg *xorm.Engine, officialEg, zhimengEg *xorm.Engine, args map[str |
|
|
|
if k > 0 && tcPrase.GID != "" { |
|
|
|
isFirst = 0 |
|
|
|
} |
|
|
|
if strings.Contains(v, "m.tb") || strings.Contains(reqCount, "taobao.com") || strings.Contains(reqCount, "tmall.com") { |
|
|
|
repV := v |
|
|
|
for _, v2 := range replaceAll { |
|
|
|
repV = strings.ReplaceAll(repV, v2, "") |
|
|
|
} |
|
|
|
split1 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{6,15}").FindAllString(repV, -1) |
|
|
|
split3 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{4,6}").FindAllString(repV, -1) |
|
|
|
split2 := regexp.MustCompile("[a-zA-Z0-9]{6,15}").FindAllString(repV, -1) |
|
|
|
if strings.Contains(repV, "http") { |
|
|
|
split2 = make([]string, 0) |
|
|
|
} |
|
|
|
isTao1 := 0 |
|
|
|
if len(split1) > 0 || len(split3) > 0 || len(split2) == 2 || strings.Count(repV, "€") >= 1 || strings.Contains(repV, "tb.cn") || ((strings.Contains(repV, "taobao.com") || strings.Contains(repV, "tmall.com")) && strings.Contains(repV, "id=") == false) { |
|
|
|
isTao1 = 1 |
|
|
|
} |
|
|
|
if isTao2 == 1 && isTao1 == 0 { |
|
|
|
continue |
|
|
|
} |
|
|
|
if strings.Contains(v, "m.tb") || strings.Contains(v, "taobao.com") || strings.Contains(v, "tmall.com") || isTao1 == 1 { |
|
|
|
// 淘口令 |
|
|
|
//fmt.Println(s) |
|
|
|
pvd, goodsId, tklWord, _ = svc.FindTaobaoWord(eg, officialEg, zhimengEg, args, v, user) |
|
|
|
if len(split3) > 0 || len(split1) > 0 { |
|
|
|
split5 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{6,15}").FindAllString(v, -1) |
|
|
|
split6 := regexp.MustCompile("[a-zA-Z0-9]{6,15} [a-zA-Z0-9]{4,6}").FindAllString(v, -1) |
|
|
|
if len(split5) == 0 && len(split6) == 0 { |
|
|
|
split4 := regexp.MustCompile("[a-zA-Z0-9]{8,15}").FindAllString(repV, -1) |
|
|
|
v = split4[0] |
|
|
|
} else { |
|
|
|
if len(split3) > 0 { |
|
|
|
v = split3[0] |
|
|
|
} |
|
|
|
if len(split1) > 0 { |
|
|
|
v = split1[0] |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
tcPrase, reqCount = svc.CommGetGoods(eg, officialEg, zhimengEg, args, tcPrase, isFirst, reqCount, pvd, goodsId, v, tklWord, "0") |
|
|
|
if pvd == "tb_activity" && tklWord != "" { |
|
|
|
continue |
|
|
|
} |
|
|
|
} |
|
|
|
if strings.Contains(v, "haohuo.jinritemai.") { |
|
|
|
//https://haohuo.jinritemai.com/ecommerce/trade/detail/index.html?id=3556342393857024570&ins_activity_param=yNAkhfs&origin_type=pc_buyin_group&pick_source=v.6nZos |
|
|
|