张延森 3 years ago
parent
commit
16c3a2b1fe
2 changed files with 4 additions and 8 deletions
  1. 1
    1
      pom.xml
  2. 3
    7
      src/main/java/com/yunzhi/gnyy/controller/TaPersonController.java

+ 1
- 1
pom.xml View File

10
 	</parent>
10
 	</parent>
11
 	<groupId>com.yunzhi</groupId>
11
 	<groupId>com.yunzhi</groupId>
12
 	<artifactId>gnyy</artifactId>
12
 	<artifactId>gnyy</artifactId>
13
-	<version>0.0.3</version>
13
+	<version>0.0.4</version>
14
 	<name>qrcode</name>
14
 	<name>qrcode</name>
15
 	<description>Demo project for Spring Boot</description>
15
 	<description>Demo project for Spring Boot</description>
16
 
16
 

+ 3
- 7
src/main/java/com/yunzhi/gnyy/controller/TaPersonController.java View File

129
      * 获取条码
129
      * 获取条码
130
      * @param id  实体ID
130
      * @param id  实体ID
131
      */
131
      */
132
-    @RequestMapping(value="/wx/{clientId}/person/{id}/barcode",method= RequestMethod.GET)
133
-    @ApiOperation(value="详情", notes = "详情", httpMethod = "GET", response = ResponseBean.class)
132
+    @RequestMapping(value="/wx/{clientId}/person/{id}/barcode",method= RequestMethod.POST)
133
+    @ApiOperation(value="详情", notes = "详情", httpMethod = "POST", response = ResponseBean.class)
134
     public ResponseBean getBarCode(@ApiParam("对象ID") @PathVariable String id,
134
     public ResponseBean getBarCode(@ApiParam("对象ID") @PathVariable String id,
135
                                    @ApiParam("接口参数") @RequestBody Map<String, Object> params) throws Exception{
135
                                    @ApiParam("接口参数") @RequestBody Map<String, Object> params) throws Exception{
136
         TaPerson taPerson = iTaPersonService.getById(id);
136
         TaPerson taPerson = iTaPersonService.getById(id);
143
         String today = DateUtils.toString(LocalDateTime.now(), "yyyy-MM-dd");
143
         String today = DateUtils.toString(LocalDateTime.now(), "yyyy-MM-dd");
144
 
144
 
145
         SysSetting sysSetting = iSysSettingService.getById(Constants.SETTING_BARCODE_URL);
145
         SysSetting sysSetting = iSysSettingService.getById(Constants.SETTING_BARCODE_URL);
146
-        String url = String.format("%s?createDate=%s&idNo=%s",
147
-                sysSetting.getContent(),
148
-                StringUtils.urlEncode(today),
149
-                StringUtils.urlEncode(taPerson.getIdNo()));
150
-
146
+        String url = String.format("%s?%s", sysSetting.getContent(), queryStr);
151
         return ResponseBean.success(httpUtils.get(url));
147
         return ResponseBean.success(httpUtils.get(url));
152
     }
148
     }
153
 }
149
 }