Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
加钱居士.
foot
提交
85c1ea15
F
foot
项目概览
加钱居士.
/
foot
通知
3
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
F
foot
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
85c1ea15
编写于
1月 17, 2020
作者:
S
shi.zeyuan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1.修复bug .2.增加作废选项
上级
35a903c7
变更
24
隐藏空白更改
内联
并排
Showing
24 changed file
with
131 addition
and
129 deletion
+131
-129
.gitignore
.gitignore
+2
-1
FC003Leisu.go
FC003Leisu.go
+0
-0
FC004Wechat.go
FC004Wechat.go
+17
-0
assets/wechat/html/month.html
assets/wechat/html/month.html
+1
-11
assets/wechat/html/stable.html
assets/wechat/html/stable.html
+1
-11
assets/wechat/html/today.html
assets/wechat/html/today.html
+1
-11
assets/wechat/html/today_a1.html
assets/wechat/html/today_a1.html
+6
-12
assets/wechat/html/today_c1.html
assets/wechat/html/today_c1.html
+6
-12
assets/wechat/html/today_tbs.html
assets/wechat/html/today_tbs.html
+6
-12
assets/wechat/html/week.html
assets/wechat/html/week.html
+1
-11
conf/app.ini
conf/app.ini
+2
-2
foot-api/module/analy/pojo/AnalyResult.go
foot-api/module/analy/pojo/AnalyResult.go
+3
-0
foot-core/module/analy/constants/Constant.go
foot-core/module/analy/constants/Constant.go
+23
-0
foot-core/module/analy/service/A1Service.go
foot-core/module/analy/service/A1Service.go
+5
-4
foot-core/module/analy/service/AnalyService.go
foot-core/module/analy/service/AnalyService.go
+8
-7
foot-core/module/analy/service/C1Service.go
foot-core/module/analy/service/C1Service.go
+6
-7
foot-core/module/analy/service/E1Service.go
foot-core/module/analy/service/E1Service.go
+5
-4
foot-core/module/analy/service/E2Service.go
foot-core/module/analy/service/E2Service.go
+8
-7
foot-core/module/analy/service/Q1Service.go
foot-core/module/analy/service/Q1Service.go
+5
-4
foot-core/module/wechat/service/MaterialService.go
foot-core/module/wechat/service/MaterialService.go
+2
-2
foot-core/module/wechat/service/SuggestMonthService.go
foot-core/module/wechat/service/SuggestMonthService.go
+3
-2
foot-core/module/wechat/service/SuggestTodayService.go
foot-core/module/wechat/service/SuggestTodayService.go
+17
-7
foot-core/module/wechat/service/SuggestWeekService.go
foot-core/module/wechat/service/SuggestWeekService.go
+3
-2
logs/foot.err
logs/foot.err
+0
-0
未找到文件。
.gitignore
浏览文件 @
85c1ea15
...
...
@@ -14,4 +14,5 @@ bin
# Output of the go coverage tool, specifically when used with LiteIDE
*.out
.idea/
\ No newline at end of file
.idea/
logs/
\ No newline at end of file
FC003
PubApplication
.go
→
FC003
Leisu
.go
浏览文件 @
85c1ea15
文件已移动
FC004Wechat.go
0 → 100644
浏览文件 @
85c1ea15
package
main
import
(
"tesou.io/platform/foot-parent/foot-api/common/base"
_
"tesou.io/platform/foot-parent/foot-core/common/fliters"
_
"tesou.io/platform/foot-parent/foot-core/common/routers"
"tesou.io/platform/foot-parent/foot-core/module/wechat/controller"
"time"
)
func
main
()
{
materialController
:=
new
(
controller
.
MaterialController
)
materialController
.
ModifyNewsOnly
()
base
.
Log
.
Info
(
"--------发布公众号周期结束--------"
)
time
.
Sleep
(
10
*
time
.
Minute
)
}
assets/wechat/html/month.html
浏览文件 @
85c1ea15
...
...
@@ -42,17 +42,7 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
<td
style=
"background-color: {{resultColor .Result}}"
>
{{preResultStr .PreResult .AlFlag}}
</td>
...
...
assets/wechat/html/stable.html
浏览文件 @
85c1ea15
...
...
@@ -44,17 +44,7 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
<td
style=
"background-color: {{resultColor .Result}}"
>
{{preResultStr .PreResult .AlFlag}}
</td>
...
...
assets/wechat/html/today.html
浏览文件 @
85c1ea15
...
...
@@ -50,17 +50,7 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
<td
style=
"background-color: {{resultColor .Result}}"
>
{{preResultStr .PreResult .AlFlag}}
</td>
...
...
assets/wechat/html/today_a1.html
浏览文件 @
85c1ea15
...
...
@@ -47,18 +47,12 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
{{preResultStr .PreResult .AlFlag}}
<td
style=
"background-color: {{resultColor .Result}}"
>
{{if .TOVoid}}
<del>
{{preResultStr .PreResult .AlFlag}}
</del>
{{else}}
{{preResultStr .PreResult .AlFlag}}
{{end}}
</td>
</tr>
{{end}}
...
...
assets/wechat/html/today_c1.html
浏览文件 @
85c1ea15
...
...
@@ -48,18 +48,12 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
{{preResultStr .PreResult .AlFlag}}
<td
style=
"background-color: {{resultColor .Result}}"
>
{{if .TOVoid}}
<del>
{{preResultStr .PreResult .AlFlag}}
</del>
{{else}}
{{preResultStr .PreResult .AlFlag}}
{{end}}
</td>
</tr>
{{end}}
...
...
assets/wechat/html/today_tbs.html
浏览文件 @
85c1ea15
...
...
@@ -47,18 +47,12 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
{{preResultStr .PreResult .AlFlag}}
<td
style=
"background-color: {{resultColor .Result}}"
>
{{if .TOVoid}}
<del>
{{preResultStr .PreResult .AlFlag}}
</del>
{{else}}
{{preResultStr .PreResult .AlFlag}}
{{end}}
</td>
</tr>
{{end}}
...
...
assets/wechat/html/week.html
浏览文件 @
85c1ea15
...
...
@@ -42,17 +42,7 @@
<td>
{{.MainTeamGoal}}:{{.GuestTeamGoal}}
</td>
<td
{{
if
eq
.
Result
"
正确
"}}
style=
"background-color: red"
{{
else
if
eq
.
Result
"
错误
"}}
style=
"background-color: gray"
{{
else
if
eq
.
Result
"
走盘
"}}
style=
"background-color: greenyellow"
{{
else
}}
{{
end
}}
>
<td
style=
"background-color: {{resultColor .Result}}"
>
{{preResultStr .PreResult .AlFlag}}
</td>
...
...
conf/app.ini
浏览文件 @
85c1ea15
[mysql]
#
url=root:Meta.123@tcp(mysql.io:3306)/foot?charset=utf8
url
=
root:awe.FOG5188@tcp(39.108.212.245:3306)/foot?charset=utf8
url
=
root:Meta.123@tcp(mysql.io:3306)/foot?charset=utf8
#
url=root:awe.FOG5188@tcp(39.108.212.245:3306)/foot?charset=utf8
maxIdle
=
10
maxConn
=
50
[cookies]
...
...
foot-api/module/analy/pojo/AnalyResult.go
浏览文件 @
85c1ea15
...
...
@@ -30,6 +30,9 @@ type AnalyResult struct {
AlSeq
string
`xorm:" comment('算法批次') index"`
//C1模型计算出的合理让球
MyLetBall
float64
`xorm:" comment('C1模型计算出的合理让球') index"`
//是否己经作废,因后续结果不符合要求
TOVoid
bool
`xorm:"bool notnull comment('是否己经作废') index"`
TOVoidDesc
string
`xorm:" comment('作废备注') index"`
pojo
.
BasePojo
`xorm:"extends"`
}
foot-core/module/analy/constants/Constant.go
浏览文件 @
85c1ea15
...
...
@@ -2,4 +2,27 @@ package constants
const
(
SECTION_NAME
=
"analy"
/**
C1算法,参考的亚赔公司-- 澳门,Bet365,18Bet
*/
C1_REFER_ASIA
=
"Bet365"
)
const
(
//胜
WIN
=
3
//平
DRAW
=
1
//负
LOST
=
0
//命中
HIT
=
"命中"
HIT_1
=
"正确"
//未命中
UNHIT
=
"错误"
//待定
UNCERTAIN
=
"待定"
//走盘
WALKING_PLATE
=
"走盘"
)
foot-core/module/analy/service/A1Service.go
浏览文件 @
85c1ea15
...
...
@@ -43,16 +43,17 @@ func (this *A1Service) Analy_Near() {
}
func
(
this
*
A1Service
)
Analy_Process
(
matchList
[]
*
pojo
.
MatchLast
)
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data_list_slice
:=
make
([]
interface
{},
0
)
data_modify_list_slice
:=
make
([]
interface
{},
0
)
for
_
,
v
:=
range
matchList
{
stub
,
data
:=
this
.
analyStub
(
v
)
if
stub
==
0
||
stub
==
1
{
data
.
TOVoid
=
false
hours
:=
v
.
MatchDate
.
Sub
(
time
.
Now
())
.
Hours
()
if
hours
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data
.
THitCount
=
hit_count
}
else
{
data
.
THitCount
=
1
...
...
@@ -65,10 +66,10 @@ func (this *A1Service) Analy_Process(matchList []*pojo.MatchLast) {
}
else
{
if
stub
!=
-
2
{
data
=
this
.
Find
(
v
.
Id
,
this
.
ModelName
())
}
else
{
data
.
TOVoid
=
true
}
if
len
(
data
.
Id
)
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
if
data
.
HitCount
>=
hit_count
{
data
.
HitCount
=
(
hit_count
/
2
)
-
1
}
else
{
...
...
foot-core/module/analy/service/AnalyService.go
浏览文件 @
85c1ea15
...
...
@@ -10,6 +10,7 @@ import (
entity2
"tesou.io/platform/foot-parent/foot-api/module/match/pojo"
entity3
"tesou.io/platform/foot-parent/foot-api/module/odds/pojo"
"tesou.io/platform/foot-parent/foot-core/common/base/service/mysql"
"tesou.io/platform/foot-parent/foot-core/module/analy/constants"
service3
"tesou.io/platform/foot-parent/foot-core/module/elem/service"
service2
"tesou.io/platform/foot-parent/foot-core/module/match/service"
"tesou.io/platform/foot-parent/foot-core/module/odds/service"
...
...
@@ -157,13 +158,13 @@ func (this *AnalyService) IsRight(v *entity2.MatchLast, analy *entity5.AnalyResu
globalResult
:=
this
.
ActualResult
(
v
,
analy
)
var
resultFlag
string
if
globalResult
==
-
1
{
resultFlag
=
"待定"
resultFlag
=
constants
.
UNCERTAIN
}
else
if
globalResult
==
analy
.
PreResult
{
resultFlag
=
"正确"
resultFlag
=
constants
.
HIT
}
else
if
globalResult
==
1
{
resultFlag
=
"走盘"
resultFlag
=
constants
.
WALKING_PLATE
}
else
{
resultFlag
=
"错误"
resultFlag
=
constants
.
UNHIT
}
//打印数据
...
...
@@ -197,11 +198,11 @@ func (this *AnalyService) ActualResult(v *entity2.MatchLast, analy *entity5.Anal
// result = 1
//}
if
mainTeamGoals
>
float64
(
v
.
GuestTeamGoals
)
{
result
=
3
result
=
constants
.
WIN
}
else
if
mainTeamGoals
<
float64
(
v
.
GuestTeamGoals
)
{
result
=
0
result
=
constants
.
LOST
}
else
{
result
=
1
result
=
constants
.
DRAW
}
return
result
}
...
...
foot-core/module/analy/service/C1Service.go
浏览文件 @
85c1ea15
...
...
@@ -50,16 +50,17 @@ func (this *C1Service) Analy_Near() {
}
func
(
this
*
C1Service
)
Analy_Process
(
matchList
[]
*
pojo
.
MatchLast
)
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data_list_slice
:=
make
([]
interface
{},
0
)
data_modify_list_slice
:=
make
([]
interface
{},
0
)
for
_
,
v
:=
range
matchList
{
stub
,
data
:=
this
.
analyStub
(
v
)
if
stub
==
0
||
stub
==
1
{
data
.
TOVoid
=
false
hours
:=
v
.
MatchDate
.
Sub
(
time
.
Now
())
.
Hours
()
if
hours
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data
.
THitCount
=
hit_count
}
else
{
data
.
THitCount
=
1
...
...
@@ -72,10 +73,10 @@ func (this *C1Service) Analy_Process(matchList []*pojo.MatchLast) {
}
else
{
if
stub
!=
-
2
{
data
=
this
.
Find
(
v
.
Id
,
this
.
ModelName
())
}
else
{
data
.
TOVoid
=
true
}
if
len
(
data
.
Id
)
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
if
data
.
HitCount
>=
hit_count
{
data
.
HitCount
=
(
hit_count
/
2
)
-
1
}
else
{
...
...
@@ -104,9 +105,7 @@ func (this *C1Service) analyStub(v *pojo.MatchLast) (int, *entity5.AnalyResult)
//声明使用变量
var
a18betData
*
entity3
.
AsiaHis
//亚赔
//aList := this.AsiaHisService.FindByMatchIdCompId(matchId, "澳门")
aList
:=
this
.
AsiaHisService
.
FindByMatchIdCompId
(
matchId
,
"Bet365"
)
//aList := this.AsiaHisService.FindByMatchIdCompId(matchId, "18Bet")
aList
:=
this
.
AsiaHisService
.
FindByMatchIdCompId
(
matchId
,
constants
.
C1_REFER_ASIA
)
if
len
(
aList
)
<
1
{
return
-
1
,
nil
}
...
...
foot-core/module/analy/service/E1Service.go
浏览文件 @
85c1ea15
...
...
@@ -36,16 +36,17 @@ func (this *E1Service) Analy_Near() {
}
func
(
this
*
E1Service
)
Analy_Process
(
matchList
[]
*
pojo
.
MatchLast
)
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data_list_slice
:=
make
([]
interface
{},
0
)
data_modify_list_slice
:=
make
([]
interface
{},
0
)
for
_
,
v
:=
range
matchList
{
stub
,
data
:=
this
.
analyStub
(
v
)
if
stub
==
0
||
stub
==
1
{
data
.
TOVoid
=
false
hours
:=
v
.
MatchDate
.
Sub
(
time
.
Now
())
.
Hours
()
if
hours
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data
.
THitCount
=
hit_count
}
else
{
data
.
THitCount
=
1
...
...
@@ -58,10 +59,10 @@ func (this *E1Service) Analy_Process(matchList []*pojo.MatchLast) {
}
else
{
if
stub
!=
-
2
{
data
=
this
.
Find
(
v
.
Id
,
this
.
ModelName
())
}
else
{
data
.
TOVoid
=
true
}
if
len
(
data
.
Id
)
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
if
data
.
HitCount
>=
hit_count
{
data
.
HitCount
=
(
hit_count
/
2
)
-
1
}
else
{
...
...
foot-core/module/analy/service/E2Service.go
浏览文件 @
85c1ea15
...
...
@@ -40,16 +40,17 @@ func (this *E2Service) Analy_Near() {
}
func
(
this
*
E2Service
)
Analy_Process
(
matchList
[]
*
pojo
.
MatchLast
)
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data_list_slice
:=
make
([]
interface
{},
0
)
data_modify_list_slice
:=
make
([]
interface
{},
0
)
for
_
,
v
:=
range
matchList
{
stub
,
data
:=
this
.
analyStub
(
v
)
if
stub
==
0
||
stub
==
1
{
data
.
TOVoid
=
false
hours
:=
v
.
MatchDate
.
Sub
(
time
.
Now
())
.
Hours
()
if
hours
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data
.
THitCount
=
hit_count
}
else
{
data
.
THitCount
=
1
...
...
@@ -62,10 +63,10 @@ func (this *E2Service) Analy_Process(matchList []*pojo.MatchLast) {
}
else
{
if
stub
!=
-
2
{
data
=
this
.
Find
(
v
.
Id
,
this
.
ModelName
())
}
else
{
data
.
TOVoid
=
true
}
if
len
(
data
.
Id
)
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
if
data
.
HitCount
>=
hit_count
{
data
.
HitCount
=
(
hit_count
/
2
)
-
1
}
else
{
...
...
@@ -187,11 +188,11 @@ func (this *E2Service) IsRight(v *pojo.MatchLast, analy *entity5.AnalyResult) st
}
var
resultFlag
string
if
globalResult
==
-
1
{
resultFlag
=
"待定"
resultFlag
=
constants
.
UNCERTAIN
}
else
if
globalResult
==
analy
.
PreResult
||
globalResult
==
1
{
resultFlag
=
"正确"
resultFlag
=
constants
.
HIT
}
else
{
resultFlag
=
"错误"
resultFlag
=
constants
.
UNHIT
}
//打印数据
...
...
foot-core/module/analy/service/Q1Service.go
浏览文件 @
85c1ea15
...
...
@@ -35,16 +35,17 @@ func (this *Q1Service) Analy_Near() {
}
func
(
this
*
Q1Service
)
Analy_Process
(
matchList
[]
*
pojo
.
MatchLast
)
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data_list_slice
:=
make
([]
interface
{},
0
)
data_modify_list_slice
:=
make
([]
interface
{},
0
)
for
_
,
v
:=
range
matchList
{
stub
,
data
:=
this
.
analyStub
(
v
)
if
stub
==
0
||
stub
==
1
{
data
.
TOVoid
=
false
hours
:=
v
.
MatchDate
.
Sub
(
time
.
Now
())
.
Hours
()
if
hours
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
data
.
THitCount
=
hit_count
}
else
{
data
.
THitCount
=
1
...
...
@@ -57,10 +58,10 @@ func (this *Q1Service) Analy_Process(matchList []*pojo.MatchLast) {
}
else
{
if
stub
!=
-
2
{
data
=
this
.
Find
(
v
.
Id
,
this
.
ModelName
())
}
else
{
data
.
TOVoid
=
true
}
if
len
(
data
.
Id
)
>
0
{
hit_count_str
:=
utils
.
GetVal
(
constants
.
SECTION_NAME
,
"hit_count"
)
hit_count
,
_
:=
strconv
.
Atoi
(
hit_count_str
)
if
data
.
HitCount
>=
hit_count
{
data
.
HitCount
=
(
hit_count
/
2
)
-
1
}
else
{
...
...
foot-core/module/wechat/service/MaterialService.go
浏览文件 @
85c1ea15
...
...
@@ -11,11 +11,11 @@ type MaterialService struct {
}
func
(
this
*
MaterialService
)
ModifyNews
(
wcClient
*
core
.
Client
)
{
this
.
SuggestTodayService
.
ModifyToday
(
wcClient
)
this
.
SuggestTodayService
.
ModifyTodayDetail
(
wcClient
)
this
.
SuggestTodayService
.
ModifyTodayTbs
(
wcClient
)
this
.
SuggestTodayService
.
ModifyTodayA1
(
wcClient
)
this
.
SuggestTodayService
.
ModifyTodayC1
(
wcClient
)
this
.
SuggestTodayService
.
ModifyToday
(
wcClient
)
this
.
SuggestTodayService
.
ModifyTodayDetail
(
wcClient
)
this
.
SuggestWeekService
.
ModifyWeek
(
wcClient
)
this
.
SuggestMonthService
.
ModifyMonth
(
wcClient
)
...
...
foot-core/module/wechat/service/SuggestMonthService.go
浏览文件 @
85c1ea15
...
...
@@ -12,6 +12,7 @@ import (
"tesou.io/platform/foot-parent/foot-api/module/suggest/vo"
"tesou.io/platform/foot-parent/foot-core/common/base/service/mysql"
"tesou.io/platform/foot-parent/foot-core/common/utils"
constants2
"tesou.io/platform/foot-parent/foot-core/module/analy/constants"
"tesou.io/platform/foot-parent/foot-core/module/analy/service"
"tesou.io/platform/foot-parent/foot-core/module/spider/constants"
service2
"tesou.io/platform/foot-parent/foot-core/module/suggest/service"
...
...
@@ -75,11 +76,11 @@ func (this *SuggestMonthService) ModifyMonth(wcClient *core.Client) {
var
redCount
,
walkCount
,
blackCount
,
linkRedCount
,
tempLinkRedCount
,
linkBlackCount
,
tempLinkBlackCount
int64
temp
.
DataList
=
make
([]
vo
.
SuggestVO
,
len
(
tempList
))
for
i
,
e
:=
range
tempList
{
if
strings
.
EqualFold
(
"正确"
,
e
.
Result
)
{
if
strings
.
EqualFold
(
constants2
.
HIT
,
e
.
Result
)
||
strings
.
EqualFold
(
constants2
.
HIT_1
,
e
.
Result
)
{
redCount
++
tempLinkRedCount
++
tempLinkBlackCount
=
0
}
else
if
strings
.
EqualFold
(
"错误"
,
e
.
Result
)
{
}
else
if
strings
.
EqualFold
(
constants2
.
UNHIT
,
e
.
Result
)
{
blackCount
++
tempLinkBlackCount
++
tempLinkRedCount
=
0
...
...
foot-core/module/wechat/service/SuggestTodayService.go
浏览文件 @
85c1ea15
...
...
@@ -10,6 +10,7 @@ import (
"tesou.io/platform/foot-parent/foot-api/module/suggest/vo"
"tesou.io/platform/foot-parent/foot-core/common/base/service/mysql"
"tesou.io/platform/foot-parent/foot-core/common/utils"
constants2
"tesou.io/platform/foot-parent/foot-core/module/analy/constants"
"tesou.io/platform/foot-parent/foot-core/module/analy/service"
"tesou.io/platform/foot-parent/foot-core/module/spider/constants"
service2
"tesou.io/platform/foot-parent/foot-core/module/suggest/service"
...
...
@@ -32,7 +33,7 @@ func preResultStr(val int, al_flag string) string {
}
else
if
0
==
val
{
result
=
"负平"
}
}
else
{
}
else
{
if
3
==
val
{
result
=
"主"
}
else
if
1
==
val
{
...
...
@@ -47,7 +48,7 @@ func preResultStr(val int, al_flag string) string {
func
color
(
str
string
)
string
{
if
"A1"
==
str
{
return
"orange"
}
else
if
"C1"
==
str
{
}
else
if
"C1"
==
str
{
return
"yellow"
}
else
if
"E1"
==
str
{
return
"blue"
...
...
@@ -59,10 +60,22 @@ func color(str string) string {
return
"XX"
}
func
resultColor
(
str
string
)
string
{
if
str
==
constants2
.
HIT
||
str
==
constants2
.
HIT_1
{
return
"red"
}
else
if
str
==
constants2
.
UNHIT
{
return
"gray"
}
else
if
str
==
constants2
.
WALKING_PLATE
{
return
"greenyellow"
}
return
"XX"
}
func
getFuncMap
()
map
[
string
]
interface
{}
{
funcMap
:=
template
.
FuncMap
{
"preResultStr"
:
preResultStr
,
"color"
:
color
,
"resultColor"
:
resultColor
,
}
return
funcMap
}
...
...
@@ -269,7 +282,7 @@ func (this *SuggestTodayService) ModifyTodayTbs(wcClient *core.Client) {
h12
,
_
=
time
.
ParseDuration
(
"24h"
)
endDate
:=
now
.
Add
(
h12
)
param
.
EndDateStr
=
endDate
.
Format
(
"2006-01-02 15:04:05"
)
param
.
AlFlags
=
[]
string
{
"E1"
,
"E2"
,
"Q1"
}
param
.
AlFlags
=
[]
string
{
"E1"
,
"E2"
,
"Q1"
}
tempList
:=
this
.
SuggestService
.
QueryTbs
(
param
)
//更新推送
first
:=
material
.
Article
{}
...
...
@@ -306,7 +319,6 @@ func (this *SuggestTodayService) ModifyTodayTbs(wcClient *core.Client) {
}
}
/**
今日A1待选池比赛
*/
...
...
@@ -356,8 +368,6 @@ func (this *SuggestTodayService) ModifyTodayA1(wcClient *core.Client) {
}
}
/**
今日C1待选池比赛
*/
...
...
@@ -405,4 +415,4 @@ func (this *SuggestTodayService) ModifyTodayC1(wcClient *core.Client) {
if
err
!=
nil
{
base
.
Log
.
Error
(
err
)
}
}
\ No newline at end of file
}
foot-core/module/wechat/service/SuggestWeekService.go
浏览文件 @
85c1ea15
...
...
@@ -12,6 +12,7 @@ import (
"tesou.io/platform/foot-parent/foot-api/module/suggest/vo"
"tesou.io/platform/foot-parent/foot-core/common/base/service/mysql"
"tesou.io/platform/foot-parent/foot-core/common/utils"
constants2
"tesou.io/platform/foot-parent/foot-core/module/analy/constants"
"tesou.io/platform/foot-parent/foot-core/module/analy/service"
"tesou.io/platform/foot-parent/foot-core/module/spider/constants"
service2
"tesou.io/platform/foot-parent/foot-core/module/suggest/service"
...
...
@@ -75,11 +76,11 @@ func (this *SuggestWeekService) ModifyWeek(wcClient *core.Client) {
var
redCount
,
walkCount
,
blackCount
,
linkRedCount
,
tempLinkRedCount
,
linkBlackCount
,
tempLinkBlackCount
int64
temp
.
DataList
=
make
([]
vo
.
SuggestVO
,
len
(
tempList
))
for
i
,
e
:=
range
tempList
{
if
strings
.
EqualFold
(
"正确"
,
e
.
Result
)
{
if
strings
.
EqualFold
(
constants2
.
HIT
,
e
.
Result
)
||
strings
.
EqualFold
(
constants2
.
HIT_1
,
e
.
Result
)
{
redCount
++
tempLinkRedCount
++
tempLinkBlackCount
=
0
}
else
if
strings
.
EqualFold
(
"错误"
,
e
.
Result
)
{
}
else
if
strings
.
EqualFold
(
constants2
.
UNHIT
,
e
.
Result
)
{
blackCount
++
tempLinkBlackCount
++
tempLinkRedCount
=
0
...
...
logs/foot.err
已删除
100644 → 0
浏览文件 @
35a903c7
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录