From b4400a06b5f801bc7a85320680d0b6c45c547ff0 Mon Sep 17 00:00:00 2001 From: wangpengfei <274878379@qq.com> Date: 星期五, 28 七月 2023 10:21:33 +0800 Subject: [PATCH] fix --- api/v1/serviceContract.go | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/api/v1/serviceContract.go b/api/v1/serviceContract.go index 47a2e06..8cb3e92 100644 --- a/api/v1/serviceContract.go +++ b/api/v1/serviceContract.go @@ -154,8 +154,8 @@ // @Tags ServiceContract // @Summary 鐢熸垚璁″垝鍒楄〃 // @Produce application/json -// @Param object body request.GetServiceContractList true "鍙傛暟" -// @Success 200 {object} contextx.Response{data=response.ServiceContractsResponse} +// @Param object body request.GetServiceContractList true "鍙傛暟" +// @Success 200 {object} contextx.Response{data=response.ServiceContractsResponse} // @Router /api/serviceContract/list [post] func (con *ServiceContractApi) List(c *gin.Context) { var params request.GetServiceContractList @@ -164,7 +164,7 @@ return } - serviceContracts, errCode := serviceContractService.GetServiceContractList(params.Page, params.PageSize, params.Keyword) + serviceContracts, total, errCode := serviceContractService.GetServiceContractList(params.Page, params.PageSize, params.Keyword) if errCode != ecode.OK { ctx.Fail(errCode) return @@ -172,6 +172,6 @@ ctx.OkWithDetailed(response.ServiceContractsResponse{ List: serviceContracts, - Count: len(serviceContracts), + Count: int(total), }) -} +} \ No newline at end of file -- Gitblit v1.8.0