From 372d7e12cf7e9c037466cb6785121bc22ee051b8 Mon Sep 17 00:00:00 2001 From: luozhun <2025254074@qq.com> Date: Wed, 20 Nov 2024 17:26:04 +0800 Subject: [PATCH] =?UTF-8?q?refactor(open-platform):=20=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BF=9D=E5=AE=89=E5=8D=95=E4=BD=8D=E4=BF=A1=E6=81=AF=E5=B1=95?= =?UTF-8?q?=E7=A4=BA=E4=BD=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将保安单位相关字段从 SecurityUnitUseStatisticsDTO 类中移至内部类 _ServiceProjectVo - 更新 OpenApiMapper.xml,将对应字段移至 JSON 数组内- 移除前端无用的示例代码 --- .../dto/SecurityUnitUseStatisticsDTO.java | 25 +++++++++-------- .../main/resources/mapper/OpenApiMapper.xml | 16 +++++------ .../src/views/openPlatform/index.vue | 27 ++++--------------- 3 files changed, 23 insertions(+), 45 deletions(-) diff --git a/policeSecurityServer/src/main/java/com/changhu/pojo/dto/SecurityUnitUseStatisticsDTO.java b/policeSecurityServer/src/main/java/com/changhu/pojo/dto/SecurityUnitUseStatisticsDTO.java index 406f5c8..ad95b65 100644 --- a/policeSecurityServer/src/main/java/com/changhu/pojo/dto/SecurityUnitUseStatisticsDTO.java +++ b/policeSecurityServer/src/main/java/com/changhu/pojo/dto/SecurityUnitUseStatisticsDTO.java @@ -38,19 +38,6 @@ public class SecurityUnitUseStatisticsDTO { @Schema(description = "公安单位名称") private String policeUnitName; - @Schema(description = "保安单位id") - private Long securityUnitId; - @Schema(description = "保安单位名称") - private String securityUnitName; - @Schema(description = "保安单位法人信息") - private LegalPersonInfo securityUnitLegalPersonInfo; - - @Schema(description = "项目经理") - private String serviceProjectManager; - @Schema(description = "项目经理联系方式") - private String serviceProjectManagerTelephone; - - @Data static class _ServiceProjectVo { @Schema(description = "服务项目id") @@ -74,6 +61,18 @@ public class SecurityUnitUseStatisticsDTO { @Schema(description = "持证保安数量") private Integer haveCardSecurityUserCount; + @Schema(description = "保安单位id") + private Long securityUnitId; + @Schema(description = "保安单位名称") + private String securityUnitName; + @Schema(description = "保安单位法人信息") + private LegalPersonInfo securityUnitLegalPersonInfo; + + @Schema(description = "项目经理") + private String serviceProjectManager; + @Schema(description = "项目经理联系方式") + private String serviceProjectManagerTelephone; + } } diff --git a/policeSecurityServer/src/main/resources/mapper/OpenApiMapper.xml b/policeSecurityServer/src/main/resources/mapper/OpenApiMapper.xml index 5b788ad..af35578 100644 --- a/policeSecurityServer/src/main/resources/mapper/OpenApiMapper.xml +++ b/policeSecurityServer/src/main/resources/mapper/OpenApiMapper.xml @@ -29,10 +29,6 @@ order by eu.create_time desc - { const accessKey = "w2wzi0wefmmo6s735z2el8tfzitya5gj" const secretKey = "db1b5214-02ee-497f-957c-88323b4351bf" const now = Date.now() - // const params = { - // name: 'zhangsan', - // age: 14, - // addr: '湖南省长沙市' - // } - - // const sign = generatedSign(params, now, accessKey, secretKey) - - // const headers = { - // 'Access-Key': accessKey, - // 'Time-Stamp': now, - // 'Sign': sign - // } - // axios.get('http://127.0.0.1:8765/open/dataView', { - // params, - // headers - // }) - - const params2 = { + const params = { code: 'SSP001', level: 5 } - const sign2 = generatedSign(params2, now, accessKey, secretKey) + const sign = generatedSign(params, now, accessKey, secretKey) const headers2 = { 'Access-Key': accessKey, 'Time-Stamp': now, - 'Sign': sign2 + 'Sign': sign } + console.log(headers2); axios.get('http://127.0.0.1:8765/open/dataView', { - params: params2, + params: params, headers: { ...headers2 }