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
b17ad4e2
Commit
b17ad4e2
authored
Jan 15, 2022
by
haoyanbin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
team
parent
6f7e1417
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
232 additions
and
87 deletions
+232
-87
org_club.go
app/operate/apis/org_club.go
+1
-0
org_club_team.go
app/operate/apis/org_club_team.go
+1
-1
org_match.go
app/operate/apis/org_match.go
+1
-1
org_team.go
app/operate/apis/org_team.go
+2
-1
org_team_match.go
app/operate/apis/org_team_match.go
+1
-1
org_team_team.go
app/operate/apis/org_team_team.go
+1
-1
org_club.go
app/operate/service/dto/org_club.go
+3
-3
org_match.go
app/operate/service/dto/org_match.go
+5
-5
org_team.go
app/operate/service/dto/org_team.go
+11
-2
org_team.go
app/operate/service/org_team.go
+4
-2
docs.go
docs/docs.go
+75
-26
swagger.json
docs/swagger.json
+75
-26
swagger.yaml
docs/swagger.yaml
+52
-18
No files found.
app/operate/apis/org_club.go
View file @
b17ad4e2
...
...
@@ -27,6 +27,7 @@ type OrgClub struct {
// @Tags <俱乐部>俱乐部
// @Param pageSize query int false "页条数"
// @Param pageIndex query int false "页码"
// @Param data body dto.OrgClubGetPageReq true "data"
// @Success 200 {string} string "{"code": 200, "data": [...]}"
// @Router /api/v1/org-club [get]
// @Security Bearer
...
...
app/operate/apis/org_club_team.go
View file @
b17ad4e2
...
...
@@ -233,7 +233,7 @@ func (e OrgClubTeam) GetInfo(c *gin.Context) {
//球队列表
sOrgTeam
:=
service
.
OrgTeam
{}
listOrgTeam
:=
make
([]
models
.
OrgTeam
,
0
)
listOrgTeam
:=
make
([]
dto
.
OrgTeamGetPageReply
,
0
)
var
countOrgTeam
int64
=
0
err
=
e
.
MakeContext
(
c
)
.
MakeOrm
()
.
MakeService
(
&
sOrgTeam
.
Service
)
.
Errors
...
...
app/operate/apis/org_match.go
View file @
b17ad4e2
...
...
@@ -142,7 +142,7 @@ func (e OrgMatch) GetInfo(c *gin.Context) {
//球队列表
sOrgTeam
:=
service
.
OrgTeam
{}
listOrgTeam
:=
make
([]
models
.
OrgTeam
,
0
)
listOrgTeam
:=
make
([]
dto
.
OrgTeamGetPageReply
,
0
)
var
countOrgTeam
int64
=
0
err
=
e
.
MakeContext
(
c
)
.
MakeOrm
()
.
MakeService
(
&
sOrgTeam
.
Service
)
.
Errors
...
...
app/operate/apis/org_team.go
View file @
b17ad4e2
...
...
@@ -24,6 +24,7 @@ type OrgTeam struct {
// @Tags <球队>球队
// @Param pageSize query int false "页条数"
// @Param pageIndex query int false "页码"
// @Param data body dto.OrgTeamGetPageReq true "data"
// @Success 200 {string} string "{"code": 200, "data": [...]}"
// @Router /api/v1/org-team [get]
// @Security Bearer
...
...
@@ -42,7 +43,7 @@ func (e OrgTeam) GetPage(c *gin.Context) {
}
p
:=
actions
.
GetPermissionFromContext
(
c
)
list
:=
make
([]
models
.
OrgTeam
,
0
)
list
:=
make
([]
dto
.
OrgTeamGetPageReply
,
0
)
var
count
int64
err
=
s
.
GetPage
(
&
req
,
p
,
&
list
,
&
count
)
...
...
app/operate/apis/org_team_match.go
View file @
b17ad4e2
...
...
@@ -323,7 +323,7 @@ func (e OrgTeamMatch) GetInfo(c *gin.Context) {
//球队列表
sOrgTeam
:=
service
.
OrgTeam
{}
listOrgTeam
:=
make
([]
models
.
OrgTeam
,
0
)
listOrgTeam
:=
make
([]
dto
.
OrgTeamGetPageReply
,
0
)
var
countOrgTeam
int64
=
0
err
=
e
.
MakeContext
(
c
)
.
MakeOrm
()
.
MakeService
(
&
sOrgTeam
.
Service
)
.
Errors
...
...
app/operate/apis/org_team_team.go
View file @
b17ad4e2
...
...
@@ -77,7 +77,7 @@ func (e OrgTeamTeam) GetPageMatch(c *gin.Context) {
}
p
:=
actions
.
GetPermissionFromContext
(
c
)
list
:=
make
([]
models
.
OrgTeam
,
0
)
list
:=
make
([]
dto
.
OrgTeamGetPageReply
,
0
)
var
count
int64
err
=
s
.
GetPage
(
&
req
,
p
,
&
list
,
&
count
)
...
...
app/operate/service/dto/org_club.go
View file @
b17ad4e2
...
...
@@ -8,9 +8,9 @@ import (
type
OrgClubGetPageReq
struct
{
dto
.
Pagination
`search:"-"`
ClubName
string
`form:"clubName" json:"clubName" search:"type:contains;column:club_name;table:org_club" comment:"俱乐部名称"`
CreateStartTime
string
`form:"createStartTime" search:"type:gte;column:create_at;table:org_club" comment:"开始时间"`
CreateEndTime
string
`form:"createEndTime" search:"type:lte;column:create_at;table:org_club" comment:"结束时间"`
ClubName
string
`form:"clubName" json:"clubName" search:"type:contains;column:club_name;table:org_club" comment:"俱乐部名称"`
//俱乐部名称
CreateStartTime
string
`form:"createStartTime" search:"type:gte;column:create_at;table:org_club" comment:"开始时间"`
//开始时间
CreateEndTime
string
`form:"createEndTime" search:"type:lte;column:create_at;table:org_club" comment:"结束时间"`
//结束时间
}
func
(
m
*
OrgClubGetPageReq
)
GetNeedSearch
()
interface
{}
{
...
...
app/operate/service/dto/org_match.go
View file @
b17ad4e2
...
...
@@ -39,11 +39,11 @@ type OrgMatchGetInfoReq struct {
}
type
OrgMatchGetInfoReply
struct
{
OrgMatch
models
.
OrgMatch
`form:"orgMatch"`
OrgLeagueList
[]
models
.
OrgLeague
`form:"orgLeagueList"`
OrgSeasonList
[]
models
.
OrgSeason
`form:"orgSeasonList"`
OrgDivisionList
[]
models
.
OrgDivision
`form:"orgDivisionList"`
OrgTeamList
[]
models
.
OrgTeam
`form:"orgTeamList"`
OrgMatch
models
.
OrgMatch
`form:"orgMatch"`
OrgLeagueList
[]
models
.
OrgLeague
`form:"orgLeagueList"`
OrgSeasonList
[]
models
.
OrgSeason
`form:"orgSeasonList"`
OrgDivisionList
[]
models
.
OrgDivision
`form:"orgDivisionList"`
OrgTeamList
[]
OrgTeamGetPageReply
`form:"orgTeamList"`
}
type
OrgMatchOrder
struct
{
...
...
app/operate/service/dto/org_team.go
View file @
b17ad4e2
...
...
@@ -8,8 +8,17 @@ import (
)
type
OrgTeamGetPageReq
struct
{
dto
.
Pagination
`search:"-"`
OrgTeamOrder
dto
.
Pagination
`search:"-"`
TeamName
string
`form:"teamName" json:"teamName" search:"type:contains;column:team_name;table:ot" comment:"球队名称"`
//球队名称
CreateStartTime
string
`form:"createStartTime" search:"type:gte;column:created_at;table:ot" comment:"开始时间"`
//开始时间
CreateEndTime
string
`form:"createEndTime" search:"type:lte;column:created_at;table:ot" comment:"结束时间"`
//结束时间
}
type
OrgTeamGetPageReply
struct
{
Id
string
`json:"id" comment:"球队id"`
//球队id
ClubName
string
`json:"clubName" comment:"俱乐部名称"`
TeamName
string
`json:"teamName" comment:"球队名称"`
CreatedAt
string
`json:"createdAt" comment:"球队创建时间"`
}
type
OrgTeamOrder
struct
{
...
...
app/operate/service/org_team.go
View file @
b17ad4e2
...
...
@@ -17,11 +17,13 @@ type OrgTeam struct {
}
// GetPage 获取OrgTeam列表
func
(
e
*
OrgTeam
)
GetPage
(
c
*
dto
.
OrgTeamGetPageReq
,
p
*
actions
.
DataPermission
,
list
*
[]
models
.
OrgTeam
,
count
*
int64
)
error
{
func
(
e
*
OrgTeam
)
GetPage
(
c
*
dto
.
OrgTeamGetPageReq
,
p
*
actions
.
DataPermission
,
list
*
[]
dto
.
OrgTeamGetPageReply
,
count
*
int64
)
error
{
var
err
error
var
data
models
.
OrgTeam
err
=
e
.
Orm
.
Model
(
&
data
)
.
err
=
e
.
Orm
.
Table
(
"org_team as ot"
)
.
Select
(
"ot.id,oc.club_name,ot.team_name,ot.created_at"
)
.
Joins
(
"left join org_club as oc on ot.club_id=oc.id"
)
.
Scopes
(
cDto
.
MakeCondition
(
c
.
GetNeedSearch
()),
cDto
.
Paginate
(
c
.
GetPageSize
(),
c
.
GetPageIndex
()),
...
...
docs/docs.go
View file @
b17ad4e2
...
...
@@ -1221,6 +1221,15 @@ var doc = `{
"description": "页码",
"name": "pageIndex",
"in": "query"
},
{
"description": "data",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/dto.OrgClubGetPageReq"
}
}
],
"responses": {
...
...
@@ -3402,6 +3411,15 @@ var doc = `{
"description": "页码",
"name": "pageIndex",
"in": "query"
},
{
"description": "data",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/dto.OrgTeamGetPageReq"
}
}
],
"responses": {
...
...
@@ -6335,6 +6353,29 @@ var doc = `{
}
}
},
"dto.OrgClubGetPageReq": {
"type": "object",
"properties": {
"clubName": {
"description": "俱乐部名称",
"type": "string"
},
"createEndTime": {
"description": "结束时间",
"type": "string"
},
"createStartTime": {
"description": "开始时间",
"type": "string"
},
"pageIndex": {
"type": "integer"
},
"pageSize": {
"type": "integer"
}
}
},
"dto.OrgClubInsertReq": {
"type": "object",
"properties": {
...
...
@@ -6356,7 +6397,7 @@ var doc = `{
"clubQrcode": {
"type": "string"
},
"clubUser
N
ame": {
"clubUser
n
ame": {
"type": "string"
},
"createBy": {
...
...
@@ -6388,7 +6429,7 @@ var doc = `{
"clubQrcode": {
"type": "string"
},
"clubUser
N
ame": {
"clubUser
n
ame": {
"type": "string"
},
"createBy": {
...
...
@@ -7125,6 +7166,29 @@ var doc = `{
}
}
},
"dto.OrgTeamGetPageReq": {
"type": "object",
"properties": {
"createEndTime": {
"description": "结束时间",
"type": "string"
},
"createStartTime": {
"description": "开始时间",
"type": "string"
},
"pageIndex": {
"type": "integer"
},
"pageSize": {
"type": "integer"
},
"teamName": {
"description": "球队名称",
"type": "string"
}
}
},
"dto.OrgTeamInsertReq": {
"type": "object",
"properties": {
...
...
@@ -7218,6 +7282,12 @@ var doc = `{
"name": {
"type": "string"
},
"name_en": {
"type": "string"
},
"roleId": {
"type": "string"
},
"sex": {
"type": "string"
},
...
...
@@ -7235,6 +7305,9 @@ var doc = `{
},
"userImg": {
"type": "string"
},
"userName": {
"type": "string"
}
}
},
...
...
@@ -8364,21 +8437,9 @@ var doc = `{
"action": {
"type": "string"
},
"apis": {
"type": "array",
"items": {
"type": "integer"
}
},
"breadcrumb": {
"type": "string"
},
"children": {
"type": "array",
"items": {
"$ref": "#/definitions/models.SysMenu"
}
},
"component": {
"type": "string"
},
...
...
@@ -8388,18 +8449,12 @@ var doc = `{
"createdAt": {
"type": "string"
},
"dataScope": {
"type": "string"
},
"icon": {
"type": "string"
},
"isFrame": {
"type": "string"
},
"is_select": {
"type": "boolean"
},
"menuId": {
"type": "integer"
},
...
...
@@ -8412,9 +8467,6 @@ var doc = `{
"noCache": {
"type": "boolean"
},
"params": {
"type": "string"
},
"parentId": {
"type": "integer"
},
...
...
@@ -8427,9 +8479,6 @@ var doc = `{
"permission": {
"type": "string"
},
"roleId": {
"type": "integer"
},
"sort": {
"type": "integer"
},
...
...
docs/swagger.json
View file @
b17ad4e2
...
...
@@ -1204,6 +1204,15 @@
"description"
:
"页码"
,
"name"
:
"pageIndex"
,
"in"
:
"query"
},
{
"description"
:
"data"
,
"name"
:
"data"
,
"in"
:
"body"
,
"required"
:
true
,
"schema"
:
{
"$ref"
:
"#/definitions/dto.OrgClubGetPageReq"
}
}
],
"responses"
:
{
...
...
@@ -3385,6 +3394,15 @@
"description"
:
"页码"
,
"name"
:
"pageIndex"
,
"in"
:
"query"
},
{
"description"
:
"data"
,
"name"
:
"data"
,
"in"
:
"body"
,
"required"
:
true
,
"schema"
:
{
"$ref"
:
"#/definitions/dto.OrgTeamGetPageReq"
}
}
],
"responses"
:
{
...
...
@@ -6318,6 +6336,29 @@
}
}
},
"dto.OrgClubGetPageReq"
:
{
"type"
:
"object"
,
"properties"
:
{
"clubName"
:
{
"description"
:
"俱乐部名称"
,
"type"
:
"string"
},
"createEndTime"
:
{
"description"
:
"结束时间"
,
"type"
:
"string"
},
"createStartTime"
:
{
"description"
:
"开始时间"
,
"type"
:
"string"
},
"pageIndex"
:
{
"type"
:
"integer"
},
"pageSize"
:
{
"type"
:
"integer"
}
}
},
"dto.OrgClubInsertReq"
:
{
"type"
:
"object"
,
"properties"
:
{
...
...
@@ -6339,7 +6380,7 @@
"clubQrcode"
:
{
"type"
:
"string"
},
"clubUser
N
ame"
:
{
"clubUser
n
ame"
:
{
"type"
:
"string"
},
"createBy"
:
{
...
...
@@ -6371,7 +6412,7 @@
"clubQrcode"
:
{
"type"
:
"string"
},
"clubUser
N
ame"
:
{
"clubUser
n
ame"
:
{
"type"
:
"string"
},
"createBy"
:
{
...
...
@@ -7108,6 +7149,29 @@
}
}
},
"dto.OrgTeamGetPageReq"
:
{
"type"
:
"object"
,
"properties"
:
{
"createEndTime"
:
{
"description"
:
"结束时间"
,
"type"
:
"string"
},
"createStartTime"
:
{
"description"
:
"开始时间"
,
"type"
:
"string"
},
"pageIndex"
:
{
"type"
:
"integer"
},
"pageSize"
:
{
"type"
:
"integer"
},
"teamName"
:
{
"description"
:
"球队名称"
,
"type"
:
"string"
}
}
},
"dto.OrgTeamInsertReq"
:
{
"type"
:
"object"
,
"properties"
:
{
...
...
@@ -7201,6 +7265,12 @@
"name"
:
{
"type"
:
"string"
},
"name_en"
:
{
"type"
:
"string"
},
"roleId"
:
{
"type"
:
"string"
},
"sex"
:
{
"type"
:
"string"
},
...
...
@@ -7218,6 +7288,9 @@
},
"userImg"
:
{
"type"
:
"string"
},
"userName"
:
{
"type"
:
"string"
}
}
},
...
...
@@ -8347,21 +8420,9 @@
"action"
:
{
"type"
:
"string"
},
"apis"
:
{
"type"
:
"array"
,
"items"
:
{
"type"
:
"integer"
}
},
"breadcrumb"
:
{
"type"
:
"string"
},
"children"
:
{
"type"
:
"array"
,
"items"
:
{
"$ref"
:
"#/definitions/models.SysMenu"
}
},
"component"
:
{
"type"
:
"string"
},
...
...
@@ -8371,18 +8432,12 @@
"createdAt"
:
{
"type"
:
"string"
},
"dataScope"
:
{
"type"
:
"string"
},
"icon"
:
{
"type"
:
"string"
},
"isFrame"
:
{
"type"
:
"string"
},
"is_select"
:
{
"type"
:
"boolean"
},
"menuId"
:
{
"type"
:
"integer"
},
...
...
@@ -8395,9 +8450,6 @@
"noCache"
:
{
"type"
:
"boolean"
},
"params"
:
{
"type"
:
"string"
},
"parentId"
:
{
"type"
:
"integer"
},
...
...
@@ -8410,9 +8462,6 @@
"permission"
:
{
"type"
:
"string"
},
"roleId"
:
{
"type"
:
"integer"
},
"sort"
:
{
"type"
:
"integer"
},
...
...
docs/swagger.yaml
View file @
b17ad4e2
...
...
@@ -54,6 +54,22 @@ definitions:
userId
:
type
:
string
type
:
object
dto.OrgClubGetPageReq
:
properties
:
clubName
:
description
:
俱乐部名称
type
:
string
createEndTime
:
description
:
结束时间
type
:
string
createStartTime
:
description
:
开始时间
type
:
string
pageIndex
:
type
:
integer
pageSize
:
type
:
integer
type
:
object
dto.OrgClubInsertReq
:
properties
:
clubContacts
:
...
...
@@ -68,7 +84,7 @@ definitions:
type
:
string
clubQrcode
:
type
:
string
clubUser
N
ame
:
clubUser
n
ame
:
type
:
string
createBy
:
type
:
integer
...
...
@@ -89,7 +105,7 @@ definitions:
type
:
string
clubQrcode
:
type
:
string
clubUser
N
ame
:
clubUser
n
ame
:
type
:
string
createBy
:
type
:
integer
...
...
@@ -576,6 +592,22 @@ definitions:
updateBy
:
type
:
integer
type
:
object
dto.OrgTeamGetPageReq
:
properties
:
createEndTime
:
description
:
结束时间
type
:
string
createStartTime
:
description
:
开始时间
type
:
string
pageIndex
:
type
:
integer
pageSize
:
type
:
integer
teamName
:
description
:
球队名称
type
:
string
type
:
object
dto.OrgTeamInsertReq
:
properties
:
clubId
:
...
...
@@ -637,6 +669,10 @@ definitions:
type
:
integer
name
:
type
:
string
name_en
:
type
:
string
roleId
:
type
:
string
sex
:
type
:
string
signImg
:
...
...
@@ -649,6 +685,8 @@ definitions:
type
:
string
userImg
:
type
:
string
userName
:
type
:
string
type
:
object
dto.PassWord
:
properties
:
...
...
@@ -1418,28 +1456,16 @@ definitions:
properties
:
action
:
type
:
string
apis
:
items
:
type
:
integer
type
:
array
breadcrumb
:
type
:
string
children
:
items
:
$ref
:
'
#/definitions/models.SysMenu'
type
:
array
component
:
type
:
string
createBy
:
type
:
integer
createdAt
:
type
:
string
dataScope
:
type
:
string
icon
:
type
:
string
is_select
:
type
:
boolean
isFrame
:
type
:
string
menuId
:
...
...
@@ -1450,8 +1476,6 @@ definitions:
type
:
string
noCache
:
type
:
boolean
params
:
type
:
string
parentId
:
type
:
integer
path
:
...
...
@@ -1460,8 +1484,6 @@ definitions:
type
:
string
permission
:
type
:
string
roleId
:
type
:
integer
sort
:
type
:
integer
sysApi
:
...
...
@@ -2429,6 +2451,12 @@ paths:
in
:
query
name
:
pageIndex
type
:
integer
-
description
:
data
in
:
body
name
:
data
required
:
true
schema
:
$ref
:
'
#/definitions/dto.OrgClubGetPageReq'
responses
:
"
200"
:
description
:
'
{"code":
200,
"data":
[...]}'
...
...
@@ -3760,6 +3788,12 @@ paths:
in
:
query
name
:
pageIndex
type
:
integer
-
description
:
data
in
:
body
name
:
data
required
:
true
schema
:
$ref
:
'
#/definitions/dto.OrgTeamGetPageReq'
responses
:
"
200"
:
description
:
'
{"code":
200,
"data":
[...]}'
...
...
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