Skip to content

Commit

Permalink
Merge pull request #328 from actiontech/2752-12
Browse files Browse the repository at this point in the history
chore:rename id and desc
  • Loading branch information
LordofAvernus authored Nov 15, 2024
2 parents a93f768 + 7bf7d43 commit ea05346
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
10 changes: 5 additions & 5 deletions api/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -1530,8 +1530,8 @@
"tags": [
"Project"
],
"summary": "check if the project db_services is connectable.",
"operationId": "DBServicesConnections",
"summary": "check if the global db_services is connectable.",
"operationId": "CheckGlobalDBServicesConnections",
"parameters": [
{
"description": "check db_services is connectable",
Expand Down Expand Up @@ -2892,8 +2892,8 @@
"tags": [
"DBService"
],
"summary": "check if the db_services is connectable.",
"operationId": "CheckDBServiceIsConnectableByIds",
"summary": "check if the project db_services is connectable.",
"operationId": "CheckProjectDBServicesConnections",
"parameters": [
{
"type": "string",
Expand Down Expand Up @@ -9720,7 +9720,7 @@
"x-go-name": "Uid"
}
},
"x-go-package": "github.com/actiontech/dms/api/dms/service/v1"
"x-go-package": "github.com/actiontech/dms/pkg/dms-common/api/dms/v1"
},
"UpdateCompanyNotice": {
"description": "A companynotice",
Expand Down
10 changes: 5 additions & 5 deletions api/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4093,7 +4093,7 @@ definitions:
type: string
x-go-name: Uid
type: object
x-go-package: github.com/actiontech/dms/api/dms/service/v1
x-go-package: github.com/actiontech/dms/pkg/dms-common/api/dms/v1
UpdateCompanyNotice:
description: A companynotice
properties:
Expand Down Expand Up @@ -6583,7 +6583,7 @@ paths:
- DBService
/v1/dms/projects/{project_uid}/db_services/connections:
post:
operationId: CheckDBServiceIsConnectableByIds
operationId: CheckProjectDBServicesConnections
parameters:
- description: project id
in: path
Expand All @@ -6604,7 +6604,7 @@ paths:
description: GenericResp
schema:
$ref: '#/definitions/GenericResp'
summary: check if the db_services is connectable.
summary: check if the project db_services is connectable.
tags:
- DBService
/v1/dms/projects/{project_uid}/db_services/import:
Expand Down Expand Up @@ -7097,7 +7097,7 @@ paths:
- Project
/v1/dms/projects/db_services_connections:
post:
operationId: DBServicesConnections
operationId: CheckGlobalDBServicesConnections
parameters:
- description: check db_services is connectable
in: body
Expand All @@ -7113,7 +7113,7 @@ paths:
description: GenericResp
schema:
$ref: '#/definitions/GenericResp'
summary: check if the project db_services is connectable.
summary: check if the global db_services is connectable.
tags:
- Project
/v1/dms/projects/export:
Expand Down
12 changes: 6 additions & 6 deletions internal/apiserver/service/dms_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -366,9 +366,9 @@ func (d *DMSController) CheckDBServiceIsConnectableById(c echo.Context) error {
return NewOkRespWithReply(c, reply)
}

// swagger:operation POST /v1/dms/projects/{project_uid}/db_services/connections DBService CheckDBServiceIsConnectableByIds
// swagger:operation POST /v1/dms/projects/{project_uid}/db_services/connections DBService CheckProjectDBServicesConnections
//
// check if the db_services is connectable.
// check if the project db_services is connectable.
//
// ---
// parameters:
Expand All @@ -391,7 +391,7 @@ func (d *DMSController) CheckDBServiceIsConnectableById(c echo.Context) error {
// description: GenericResp
// schema:
// "$ref": "#/definitions/GenericResp"
func (d *DMSController) CheckDBServiceIsConnectableByIds(c echo.Context) error {
func (d *DMSController) CheckProjectDBServicesConnections(c echo.Context) error {
return nil
}

Expand Down Expand Up @@ -2066,9 +2066,9 @@ func (a *DMSController) DBServicesConnection(c echo.Context) error {
return NewOkRespWithReply(c, reply)
}

// swagger:operation POST /v1/dms/projects/db_services_connections Project DBServicesConnections
// swagger:operation POST /v1/dms/projects/db_services_connections Project CheckGlobalDBServicesConnections
//
// check if the project db_services is connectable.
// check if the global db_services is connectable.
//
// ---
// parameters:
Expand All @@ -2086,7 +2086,7 @@ func (a *DMSController) DBServicesConnection(c echo.Context) error {
// description: GenericResp
// schema:
// "$ref": "#/definitions/GenericResp"
func (a *DMSController) DBServicesConnections(c echo.Context) error {
func (a *DMSController) CheckGlobalDBServicesConnections(c echo.Context) error {
return nil
}

Expand Down
4 changes: 2 additions & 2 deletions internal/apiserver/service/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (s *APIServer) initRouter() error {
dbServiceV1.PUT("/:db_service_uid", s.DMSController.UpdateDBService)
dbServiceV1.POST("/connection", s.DMSController.CheckDBServiceIsConnectable)
dbServiceV1.POST("/:db_service_uid/connection", s.DMSController.CheckDBServiceIsConnectableById)
dbServiceV1.POST("/connections", s.DMSController.CheckDBServiceIsConnectableByIds)
dbServiceV1.POST("/connections", s.DMSController.CheckProjectDBServicesConnections)
dbServiceV1.POST("/import_check", s.DMSController.ImportDBServicesOfOneProjectCheck)
dbServiceV1.POST("/import", s.DMSController.ImportDBServicesOfOneProject)

Expand Down Expand Up @@ -123,7 +123,7 @@ func (s *APIServer) initRouter() error {
projectV1.POST("/import_db_services_check", s.DMSController.ImportDBServicesOfProjectsCheck)
projectV1.POST("/import_db_services", s.DMSController.ImportDBServicesOfProjects)
projectV1.POST("/db_services_connection", s.DMSController.DBServicesConnection)
projectV1.POST("/db_services_connections", s.DMSController.DBServicesConnections)
projectV1.POST("/db_services_connections", s.DMSController.CheckGlobalDBServicesConnections)

// oauth2 interface does not require login authentication
oauth2V1 := v1.Group("/dms/oauth2")
Expand Down

0 comments on commit ea05346

Please sign in to comment.