Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hilo-common
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujiebin
hilo-common
Commits
685f3f58
Commit
685f3f58
authored
Mar 13, 2023
by
hujiebin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
5922a58b
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
75 additions
and
29 deletions
+75
-29
test_game_banner.go
script/test_game_banner.go
+8
-2
user_charge.go
script/user_charge.go
+67
-27
No files found.
script/test_game_
charge
.go
→
script/test_game_
banner
.go
View file @
685f3f58
...
@@ -14,10 +14,16 @@ type Msg struct {
...
@@ -14,10 +14,16 @@ type Msg struct {
GameType
int
`json:"gameType"`
GameType
int
`json:"gameType"`
}
}
var
GameTypeMap
=
map
[
int
]
string
{
0
:
"slot"
,
5
:
"幸运盒子"
,
6
:
"水果机"
,
}
func
main
()
{
func
main
()
{
var
rpcLogs
[]
RpcLog
var
rpcLogs
[]
RpcLog
if
err
:=
mysql
.
ProdReadOnlyDB
.
Table
(
"rpc_log_202303 "
)
.
Where
(
"`type` = 146"
)
.
if
err
:=
mysql
.
ProdReadOnlyDB
.
Table
(
"rpc_log_202303 "
)
.
Where
(
"`type` = 146"
)
.
Where
(
"created_time >= ? and created_time < ?"
,
"2023-03-0
8"
,
"2023-03-09
"
)
.
Find
(
&
rpcLogs
)
.
Error
;
err
!=
nil
{
Where
(
"created_time >= ? and created_time < ?"
,
"2023-03-0
9"
,
"2023-03-13
"
)
.
Find
(
&
rpcLogs
)
.
Error
;
err
!=
nil
{
panic
(
err
)
panic
(
err
)
}
}
var
data
=
make
(
map
[
int
]
int
)
var
data
=
make
(
map
[
int
]
int
)
...
@@ -29,6 +35,6 @@ func main() {
...
@@ -29,6 +35,6 @@ func main() {
data
[
msg
.
GameType
]
++
data
[
msg
.
GameType
]
++
}
}
for
gameType
,
count
:=
range
data
{
for
gameType
,
count
:=
range
data
{
println
(
gameType
,
count
)
println
(
GameTypeMap
[
gameType
]
,
count
)
}
}
}
}
script/user_charge.go
View file @
685f3f58
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment