Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nbya
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
haoyanbin
nbya
Commits
2a4b51ec
Commit
2a4b51ec
authored
Jan 22, 2022
by
haoyanbin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
68b0ced1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
org_player.go
app/mobile/router/org_player.go
+2
-0
org_player.go
app/mobile/service/org_player.go
+4
-5
No files found.
app/mobile/router/org_player.go
View file @
2a4b51ec
...
@@ -17,6 +17,8 @@ func registerOrgPlayerRouter(v1 *gin.RouterGroup) {
...
@@ -17,6 +17,8 @@ func registerOrgPlayerRouter(v1 *gin.RouterGroup) {
r
.
GET
(
""
,
api
.
GetPage
)
r
.
GET
(
""
,
api
.
GetPage
)
r
.
GET
(
"/:id"
,
api
.
Get
)
r
.
GET
(
"/:id"
,
api
.
Get
)
r
.
GET
(
"/info/:id"
,
api
.
GetInfo
)
r
.
GET
(
"/info/:id"
,
api
.
GetInfo
)
r
.
GET
(
"/get-match-season"
,
api
.
GetOrgMatchSeason
)
r
.
GET
(
"/evaluate"
,
api
.
GetOrgMatchEvaluate
)
r
.
GET
(
"/evaluate"
,
api
.
GetOrgMatchEvaluate
)
r
.
GET
(
"/get-rounds"
,
api
.
GetOrgRounds
)
}
}
}
}
app/mobile/service/org_player.go
View file @
2a4b51ec
...
@@ -299,16 +299,15 @@ func (e *OrgPlayer) GetSeasonRoundsScoring(playerId string, matchId []string, da
...
@@ -299,16 +299,15 @@ func (e *OrgPlayer) GetSeasonRoundsScoring(playerId string, matchId []string, da
func
(
e
*
OrgPlayer
)
GetOrgRounds
(
c
*
dto
.
GetRoundsReq
,
list
*
[]
dto
.
GetRoundsReply
,
count
*
int64
)
error
{
func
(
e
*
OrgPlayer
)
GetOrgRounds
(
c
*
dto
.
GetRoundsReq
,
list
*
[]
dto
.
GetRoundsReply
,
count
*
int64
)
error
{
var
err
error
var
err
error
err
=
e
.
Orm
.
Table
(
"org_match_evaluate as ome"
)
.
err
=
e
.
Orm
.
Table
(
"org_match_team_player as omtp"
)
.
Select
(
"op.id,op.player_name,op.player_number,op.player_img,op.position,op.sex,op.status"
)
.
Select
(
"omtp.id,omtp.match_id,om.rounds,om.league_id,om.division_id,om.season_id,ol.league_name,od.division_name,os.season_name"
)
.
Joins
(
"left join org_match_evaluate as ome on omtp.player_id = ome.player_id"
)
.
Joins
(
"left join org_match as om on omtp.match_id = om.id and omtp.rounds = om.rounds"
)
.
Joins
(
"left join org_match as om on omtp.match_id = om.id and omtp.rounds = om.rounds"
)
.
Joins
(
"left join org_league as ol on ol.id = om.league_id"
)
.
Joins
(
"left join org_league as ol on ol.id = om.league_id"
)
.
Joins
(
"left join org_division as od on od.id = om.division_id"
)
.
Joins
(
"left join org_division as od on od.id = om.division_id"
)
.
Joins
(
"left join org_season as os on os.id = om.season_id"
)
.
Joins
(
"left join org_season as os on os.id = om.season_id"
)
.
Scopes
(
Scopes
(
cDto
.
PassDel
(
"op"
),
cDto
.
PassDel
(
"o
mt
p"
),
cDto
.
SetWhere
(
"op"
,
"player_id"
,
c
.
PlayerId
),
cDto
.
SetWhere
(
"o
mt
p"
,
"player_id"
,
c
.
PlayerId
),
)
.
)
.
Find
(
list
)
.
Find
(
list
)
.
Count
(
count
)
.
Error
Count
(
count
)
.
Error
...
...
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