Browse Source

Merge pull request #611 from rockwang465/master

Update changePassword swagger method
main
奇淼(piexlmax 3 years ago
committed by GitHub
parent
commit
5dd71f4dde
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      server/api/v1/system/sys_user.go
  2. 10
      server/docs/docs.go
  3. 10
      server/docs/swagger.json
  4. 8
      server/docs/swagger.yaml

2
server/api/v1/system/sys_user.go

@ -142,7 +142,7 @@ func (b *BaseApi) Register(c *gin.Context) {
// @Produce application/json // @Produce application/json
// @Param data body systemReq.ChangePasswordStruct true "用户名, 原密码, 新密码" // @Param data body systemReq.ChangePasswordStruct true "用户名, 原密码, 新密码"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"修改成功"}" // @Success 200 {string} string "{"success":true,"data":{},"msg":"修改成功"}"
// @Router /user/changePassword [put]
// @Router /user/changePassword [post]
func (b *BaseApi) ChangePassword(c *gin.Context) { func (b *BaseApi) ChangePassword(c *gin.Context) {
var user systemReq.ChangePasswordStruct var user systemReq.ChangePasswordStruct
_ = c.ShouldBindJSON(&user) _ = c.ShouldBindJSON(&user)

10
server/docs/docs.go

@ -1554,9 +1554,7 @@ var doc = `{
} }
], ],
"responses": { "responses": {
"200": {
"description": ""
}
"200": {}
} }
} }
}, },
@ -1589,9 +1587,7 @@ var doc = `{
} }
], ],
"responses": { "responses": {
"200": {
"description": ""
}
"200": {}
} }
} }
}, },
@ -3280,7 +3276,7 @@ var doc = `{
} }
}, },
"/user/changePassword": { "/user/changePassword": {
"put": {
"post": {
"security": [ "security": [
{ {
"ApiKeyAuth": [] "ApiKeyAuth": []

10
server/docs/swagger.json

@ -1538,9 +1538,7 @@
} }
], ],
"responses": { "responses": {
"200": {
"description": ""
}
"200": {}
} }
} }
}, },
@ -1573,9 +1571,7 @@
} }
], ],
"responses": { "responses": {
"200": {
"description": ""
}
"200": {}
} }
} }
}, },
@ -3264,7 +3260,7 @@
} }
}, },
"/user/changePassword": { "/user/changePassword": {
"put": {
"post": {
"security": [ "security": [
{ {
"ApiKeyAuth": [] "ApiKeyAuth": []

8
server/docs/swagger.yaml

@ -1857,8 +1857,7 @@ paths:
produces: produces:
- application/json - application/json
responses: responses:
"200":
description: ""
"200": {}
security: security:
- ApiKeyAuth: [] - ApiKeyAuth: []
summary: 下载模板 summary: 下载模板
@ -1878,8 +1877,7 @@ paths:
produces: produces:
- application/octet-stream - application/octet-stream
responses: responses:
"200":
description: ""
"200": {}
security: security:
- ApiKeyAuth: [] - ApiKeyAuth: []
summary: 导出Excel summary: 导出Excel
@ -2924,7 +2922,7 @@ paths:
tags: tags:
- System - System
/user/changePassword: /user/changePassword:
put:
post:
parameters: parameters:
- description: 用户名, 原密码, 新密码 - description: 用户名, 原密码, 新密码
in: body in: body

Loading…
Cancel
Save