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
9d94b31c
Commit
9d94b31c
authored
Dec 07, 2023
by
hujiebin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2
parent
cf2e1015
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
group_room_visit500.go
script/group_room_visit500.go
+2
-1
No files found.
script/group_room_visit500.go
View file @
9d94b31c
...
@@ -68,7 +68,7 @@ func getArea(country string) string {
...
@@ -68,7 +68,7 @@ func getArea(country string) string {
func
getConsume
(
groupId
string
)
string
{
func
getConsume
(
groupId
string
)
string
{
var
result
int64
var
result
int64
if
err
:=
mysql
.
ProdReadOnlyDB
.
Table
(
"room_day_consume"
)
.
Where
(
"group_id = ?"
,
groupId
)
.
Select
(
"SUM(diamond)"
)
.
Scan
(
&
result
)
.
Error
;
err
!=
nil
{
if
err
:=
mysql
.
ProdReadOnlyDB
.
Table
(
"room_day_consume"
)
.
Where
(
"group_id = ?"
,
groupId
)
.
Select
(
"SUM(diamond)"
)
.
Scan
(
&
result
)
.
Error
;
err
!=
nil
{
panic
(
err
)
//
panic(err)
}
}
return
cast
.
ToString
(
result
)
return
cast
.
ToString
(
result
)
}
}
...
@@ -98,6 +98,7 @@ func main() {
...
@@ -98,6 +98,7 @@ func main() {
d
.
Country
=
country
d
.
Country
=
country
d
.
Area
=
area
d
.
Area
=
area
d
.
Consume
=
consume
d
.
Consume
=
consume
data
=
append
(
data
,
d
)
}
}
excelFileName
:=
fmt
.
Sprintf
(
"./房间500热度.xlsx"
)
excelFileName
:=
fmt
.
Sprintf
(
"./房间500热度.xlsx"
)
xlFile
:=
xlsx
.
NewFile
()
xlFile
:=
xlsx
.
NewFile
()
...
...
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