소스 검색

修改BUG

zhou.xiaoning 1 년 전
부모
커밋
96e9208eb8
7개의 변경된 파일25개의 추가작업 그리고 78개의 파일을 삭제
  1. 16 20
      controllers/asign/test.go
  2. 4 4
      controllers/guangzuan/tradeService.go
  3. 0 20
      docs/docs.go
  4. 0 20
      docs/swagger.json
  5. 0 8
      docs/swagger.yaml
  6. 4 5
      routers/router.go
  7. 1 1
      services/asign/api.go

+ 16 - 20
controllers/asign/test.go

@@ -11,15 +11,14 @@ import (
 )
 
 // BankCard4 银行卡四要素认证(测试)
-// @Summary  银行卡四要素认证(测试)
-// @Produce  json
-// @Security ApiKeyAuth
-// @accept   application/json
-// @Param    data body     asignService.APICompanyBankCard4Req true "入参"
-// @Success  200  {object} asignService.APIBankCard4Rsp
-// @Failure  500  {object} app.Response
-// @Router   /Asign/TestBankCard4 [post]
-// @Tags     爱签
+// @Summary 银行卡四要素认证(测试)
+// @Produce json
+// @accept  application/json
+// @Param   data body     asignService.APICompanyBankCard4Req true "入参"
+// @Success 200  {object} asignService.APIBankCard4Rsp
+// @Failure 500  {object} app.Response
+// @Router  /Asign/TestBankCard4 [post]
+// @Tags    爱签
 func TestBankCard4(c *gin.Context) {
 	appG := app.Gin{C: c}
 
@@ -42,14 +41,13 @@ func TestBankCard4(c *gin.Context) {
 // CaptcaResend 重新发送认证验证码(测试)
 // @Summary     重新发送认证验证码(测试)
 // @Description 在实名认证的过程中,因用户手机原因未收到短信验证码或原验证码超过15分钟有效期而过期时,可以调用此接口重新发送短信验证码。若1分钟内多次调用此接口,则仅会发送一次短信验证码,15分钟内重新发送短信验证码不会变化。
-// @Produce  json
-// @Security ApiKeyAuth
-// @accept   application/json
+// @Produce json
+// @accept  application/json
 // @Param       data body     asignService.APICaptchaResendReq true "入参"
 // @Success     200  {object} app.Response
-// @Failure  500  {object} app.Response
+// @Failure 500  {object} app.Response
 // @Router      /Asign/TestCaptcaResend [post]
-// @Tags     爱签
+// @Tags    爱签
 func TestCaptcaResend(c *gin.Context) {
 	appG := app.Gin{C: c}
 
@@ -73,7 +71,6 @@ func TestCaptcaResend(c *gin.Context) {
 // @Summary     认证验证码校验(测试)
 // @Description 验证码认证成功后会调用爱签添加用户接口,同时调用交易系统JAVA实名认证接口
 // @Produce     json
-// @Security    ApiKeyAuth
 // @accept      application/json
 // @Param       data body     asignService.APICaptchaVerifyReq true "入参"
 // @Success     200  {object} asignService.APICaptchaVerifyRsp
@@ -100,14 +97,13 @@ func TestCaptchaVerify(c *gin.Context) {
 }
 
 // CaptchaVerify 添加企业用户(V2)(测试)
-// @Summary  添加企业用户(V2)(测试)
+// @Summary 添加企业用户(V2)(测试)
 // @Produce     json
-// @Security    ApiKeyAuth
 // @accept      application/json
-// @Param    data body     asignService.APIAddEnterpriseUserReq true "入参"
-// @Success  200  {object} asignService.APIAddUserRsp
+// @Param   data body     asignService.APIAddEnterpriseUserReq true "入参"
+// @Success 200  {object} asignService.APIAddUserRsp
 // @Failure     500  {object} app.Response
-// @Router   /Asign/TestAddEnterpriseUser [post]
+// @Router  /Asign/TestAddEnterpriseUser [post]
 // @Tags        爱签
 func TestAddEnterpriseUser(c *gin.Context) {
 	appG := app.Gin{C: c}

+ 4 - 4
controllers/guangzuan/tradeService.go

@@ -18,8 +18,8 @@ import (
 // @Security Group
 // @Param    userid   query    int    true  "用户ID"
 // @Param    executestatus query    int false "执行状态 - 1:未生效 2:进行中 3:已结束"
-// @Param    page     query    int    false "页码"
-// @Param    pagesize query    int    false "每页条数"
+// @Param    page          query    int false "页码"
+// @Param    pagesize      query    int false "每页条数"
 // @Success  200           {array}  models.GzcjjcorderM
 // @Failure  500     {object} app.Response
 // @Router   /Guangzuan/QueryGZCJJCOrder [get]
@@ -39,8 +39,8 @@ func QueryGZCJJCOrder(c *gin.Context) {
 // @Security Group
 // @Param    userid        query    int true  "用户ID"
 // @Param    orderid  query    string false "单据ID"
-// @Param    page          query    int false "页码"
-// @Param    pagesize      query    int false "每页条数"
+// @Param    page     query    int    false "页码"
+// @Param    pagesize query    int    false "每页条数"
 // @Success  200      {array}  models.GzcjjcorderdetailM
 // @Failure  500           {object} app.Response
 // @Router   /Guangzuan/QueryGZCJJCOrderDetail [get]

+ 0 - 20
docs/docs.go

@@ -351,11 +351,6 @@ const docTemplate = `{
         },
         "/Asign/TestAddEnterpriseUser": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "consumes": [
                     "application/json"
                 ],
@@ -395,11 +390,6 @@ const docTemplate = `{
         },
         "/Asign/TestBankCard4": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "consumes": [
                     "application/json"
                 ],
@@ -439,11 +429,6 @@ const docTemplate = `{
         },
         "/Asign/TestCaptcaResend": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "description": "在实名认证的过程中,因用户手机原因未收到短信验证码或原验证码超过15分钟有效期而过期时,可以调用此接口重新发送短信验证码。若1分钟内多次调用此接口,则仅会发送一次短信验证码,15分钟内重新发送短信验证码不会变化。",
                 "consumes": [
                     "application/json"
@@ -484,11 +469,6 @@ const docTemplate = `{
         },
         "/Asign/TestCaptchaVerify": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "description": "验证码认证成功后会调用爱签添加用户接口,同时调用交易系统JAVA实名认证接口",
                 "consumes": [
                     "application/json"

+ 0 - 20
docs/swagger.json

@@ -342,11 +342,6 @@
         },
         "/Asign/TestAddEnterpriseUser": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "consumes": [
                     "application/json"
                 ],
@@ -386,11 +381,6 @@
         },
         "/Asign/TestBankCard4": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "consumes": [
                     "application/json"
                 ],
@@ -430,11 +420,6 @@
         },
         "/Asign/TestCaptcaResend": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "description": "在实名认证的过程中,因用户手机原因未收到短信验证码或原验证码超过15分钟有效期而过期时,可以调用此接口重新发送短信验证码。若1分钟内多次调用此接口,则仅会发送一次短信验证码,15分钟内重新发送短信验证码不会变化。",
                 "consumes": [
                     "application/json"
@@ -475,11 +460,6 @@
         },
         "/Asign/TestCaptchaVerify": {
             "post": {
-                "security": [
-                    {
-                        "ApiKeyAuth": []
-                    }
-                ],
                 "description": "验证码认证成功后会调用爱签添加用户接口,同时调用交易系统JAVA实名认证接口",
                 "consumes": [
                     "application/json"

+ 0 - 8
docs/swagger.yaml

@@ -31389,8 +31389,6 @@ paths:
           description: Internal Server Error
           schema:
             $ref: '#/definitions/app.Response'
-      security:
-      - ApiKeyAuth: []
       summary: 添加企业用户(V2)(测试)
       tags:
       - 爱签
@@ -31416,8 +31414,6 @@ paths:
           description: Internal Server Error
           schema:
             $ref: '#/definitions/app.Response'
-      security:
-      - ApiKeyAuth: []
       summary: 银行卡四要素认证(测试)
       tags:
       - 爱签
@@ -31444,8 +31440,6 @@ paths:
           description: Internal Server Error
           schema:
             $ref: '#/definitions/app.Response'
-      security:
-      - ApiKeyAuth: []
       summary: 重新发送认证验证码(测试)
       tags:
       - 爱签
@@ -31472,8 +31466,6 @@ paths:
           description: Internal Server Error
           schema:
             $ref: '#/definitions/app.Response'
-      security:
-      - ApiKeyAuth: []
       summary: 认证验证码校验(测试)
       tags:
       - 爱签

+ 4 - 5
routers/router.go

@@ -853,6 +853,10 @@ func InitRouter() *gin.Engine {
 		asignR.Use().POST("SyncContractStatus", asign.SyncContractStatus)
 		asignR.Use().POST("HandleASignCompleted", asign.HandleASignCompleted)
 
+		asignR.Use().POST("TestBankCard4", asign.TestBankCard4)
+		asignR.Use().POST("TestCaptcaResend", asign.TestCaptcaResend)
+		asignR.Use().POST("TestCaptchaVerify", asign.TestCaptchaVerify)
+		asignR.Use().POST("TestAddEnterpriseUser", asign.TestAddEnterpriseUser)
 		asignR.Use().POST("CreateSeal", asign.CreateSeal)
 
 		asignR.Use(token.Auth()).POST("BankCard4", asign.BankCard4)
@@ -860,11 +864,6 @@ func InitRouter() *gin.Engine {
 		asignR.Use(token.Auth()).POST("CaptchaVerify", asign.CaptchaVerify)
 		asignR.Use(token.Auth()).GET("QueryUsereSignRecords", asign.QueryUsereSignRecords)
 		asignR.Use(token.Auth()).POST("CreateContract", asign.CreateContract)
-
-		asignR.Use(token.Auth()).POST("TestBankCard4", asign.TestBankCard4)
-		asignR.Use(token.Auth()).POST("TestCaptcaResend", asign.TestCaptcaResend)
-		asignR.Use(token.Auth()).POST("TestCaptchaVerify", asign.TestCaptchaVerify)
-		asignR.Use(token.Auth()).POST("TestAddEnterpriseUser", asign.TestAddEnterpriseUser)
 	}
 
 	return r

+ 1 - 1
services/asign/api.go

@@ -32,7 +32,7 @@ func APIPost[T1 APIReqData, T2 APIRspData](req APIReq[T1], apiPort APIURL) (rsp
 
 	var rspBody []byte
 	if len(req.Datas) > 0 {
-		// 数组入参
+		// 切片入参
 		reqArray := make([]map[string]interface{}, 0)
 		for _, item := range req.Datas {
 			reqArray = append(reqArray, structs.Map(item))