From 5185625770fa3593f7530fcf9362d057f7638121 Mon Sep 17 00:00:00 2001 From: x_z Date: Tue, 7 Jun 2022 14:07:49 +0800 Subject: [PATCH] =?UTF-8?q?1.=E8=B0=83=E6=95=B4=E4=BB=A3=E7=A0=81=E6=A0=BC?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/controller/device/DeviceController.java | 14 +++++++------- .../udplat/UdplatManufactureController.java | 2 +- .../admin/converter/LongList2StringConverter.java | 5 +++-- .../admin/converter/String2LongListConverter.java | 5 ++--- .../converter/String2StringListConverter.java | 5 ++--- .../com/glxp/udidl/admin/util/ResultVOUtils.java | 9 +++++++-- 6 files changed, 22 insertions(+), 18 deletions(-) diff --git a/src/main/java/com/glxp/udidl/admin/controller/device/DeviceController.java b/src/main/java/com/glxp/udidl/admin/controller/device/DeviceController.java index 53ffc0e..39a3a40 100644 --- a/src/main/java/com/glxp/udidl/admin/controller/device/DeviceController.java +++ b/src/main/java/com/glxp/udidl/admin/controller/device/DeviceController.java @@ -141,7 +141,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @GetMapping("warehouse/device/unionSearch") public BaseResponse search(@Valid DeviceSearchRequest deviceSearchRequest, BindingResult bindingResult) { if (bindingResult.hasErrors()) { @@ -157,7 +157,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @GetMapping("warehouse/device/combineSearch") public BaseResponse combineSearch(@Valid DeviceSearchRequest deviceSearchRequest, BindingResult bindingResult) { @@ -183,7 +183,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @PostMapping("warehouse/device/loadsingle") public BaseResponse downLoadDiii(@RequestBody DeviceDiRequest deviceRequest) { DownloadDeviceHelper downloadDeviceHelper = new DownloadDeviceHelper(companyService, udiCompanyService); @@ -206,7 +206,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @PostMapping("warehouse/device/downLoadHisory") public BaseResponse downLoadHisory(@RequestBody DeviceDiRequest deviceRequest) { DownloadDeviceHelper downloadDeviceHelper = new DownloadDeviceHelper(companyService, udiCompanyService); @@ -234,7 +234,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @PostMapping("warehouse/device/loadudid") public BaseResponse downLoadAll(DownloadDeviceRequest downloadDeviceRequest, BindingResult bindingResult) { DownloadDeviceHelper downloadDeviceHelper = new DownloadDeviceHelper(companyService, udiCompanyService); @@ -286,7 +286,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @GetMapping("warehouse/device/stop") public BaseResponse stopDown() { Devicedownload devicedownload = devicedownloadMapper.selectByPrimaryKey("udid"); @@ -296,7 +296,7 @@ public class DeviceController { } @Deprecated - @ApiOperation(value = "",hidden = true) + @ApiOperation(value = "", hidden = true) @GetMapping("warehouse/device/progress") public BaseResponse getProgress() { Devicedownload devicedownload = devicedownloadMapper.selectByPrimaryKey("udid"); diff --git a/src/main/java/com/glxp/udidl/admin/controller/udplat/UdplatManufactureController.java b/src/main/java/com/glxp/udidl/admin/controller/udplat/UdplatManufactureController.java index 5afa908..b555b9e 100644 --- a/src/main/java/com/glxp/udidl/admin/controller/udplat/UdplatManufactureController.java +++ b/src/main/java/com/glxp/udidl/admin/controller/udplat/UdplatManufactureController.java @@ -22,7 +22,7 @@ public class UdplatManufactureController { @Autowired private UdplatManufactureService udplatManufactureService; - @ApiOperation(value = "查询生产企业信息",response = UdplatManufacture.class) + @ApiOperation(value = "查询生产企业信息", response = UdplatManufacture.class) @AuthRuleAnnotation("udplat/manufacture/list") @PostMapping("/list") public BaseResponse getList(@RequestBody BaseParam param) { diff --git a/src/main/java/com/glxp/udidl/admin/converter/LongList2StringConverter.java b/src/main/java/com/glxp/udidl/admin/converter/LongList2StringConverter.java index bb1f34b..fb6230f 100644 --- a/src/main/java/com/glxp/udidl/admin/converter/LongList2StringConverter.java +++ b/src/main/java/com/glxp/udidl/admin/converter/LongList2StringConverter.java @@ -8,12 +8,13 @@ import java.util.List; import java.util.Set; /** - * Long 类型的 List 转为字符串 + * Long 类型的 List 转为字符串 */ public class LongList2StringConverter { /** * Long 类型的 List 转为字符串 + * * @param longList * @param regex * @return @@ -24,7 +25,7 @@ public class LongList2StringConverter { return null; } Set stringSet = new HashSet<>(); - for (Long value: longList){ + for (Long value : longList) { stringSet.add(value.toString()); } if (stringSet.isEmpty()) { diff --git a/src/main/java/com/glxp/udidl/admin/converter/String2LongListConverter.java b/src/main/java/com/glxp/udidl/admin/converter/String2LongListConverter.java index afebd86..ccf838d 100644 --- a/src/main/java/com/glxp/udidl/admin/converter/String2LongListConverter.java +++ b/src/main/java/com/glxp/udidl/admin/converter/String2LongListConverter.java @@ -11,9 +11,8 @@ import java.util.List; public class String2LongListConverter { /** - * * @param string - * @param regex 切割的字符 + * @param regex 切割的字符 * @return */ public static List convert(String string, String regex) { @@ -31,7 +30,7 @@ public class String2LongListConverter { longList.add(Long.valueOf(str)); } return longList; - }catch (Exception e) { + } catch (Exception e) { return Collections.emptyList(); } } diff --git a/src/main/java/com/glxp/udidl/admin/converter/String2StringListConverter.java b/src/main/java/com/glxp/udidl/admin/converter/String2StringListConverter.java index 373700a..013e94b 100644 --- a/src/main/java/com/glxp/udidl/admin/converter/String2StringListConverter.java +++ b/src/main/java/com/glxp/udidl/admin/converter/String2StringListConverter.java @@ -12,9 +12,8 @@ import java.util.List; public class String2StringListConverter { /** - * * @param string - * @param regex 切割的字符 + * @param regex 切割的字符 * @return */ public static List convert(String string, String regex) { @@ -27,7 +26,7 @@ public class String2StringListConverter { return Collections.emptyList(); } return new ArrayList<>(Arrays.asList(strings)); - }catch (Exception e) { + } catch (Exception e) { return Collections.emptyList(); } } diff --git a/src/main/java/com/glxp/udidl/admin/util/ResultVOUtils.java b/src/main/java/com/glxp/udidl/admin/util/ResultVOUtils.java index 7c4f3f1..f53e1fe 100644 --- a/src/main/java/com/glxp/udidl/admin/util/ResultVOUtils.java +++ b/src/main/java/com/glxp/udidl/admin/util/ResultVOUtils.java @@ -14,6 +14,7 @@ public class ResultVOUtils { /** * 成功时返回 + * * @param data 返回的data对象 * @return {@link BaseResponse} */ @@ -27,6 +28,7 @@ public class ResultVOUtils { /** * 成功时返回 + * * @return {@link BaseResponse} */ public static BaseResponse success() { @@ -36,7 +38,8 @@ public class ResultVOUtils { /** * 错误时返回 - * @param code 错误码 + * + * @param code 错误码 * @param message 错误信息 * @return {@link BaseResponse} */ @@ -51,6 +54,7 @@ public class ResultVOUtils { /** * 错误时返回 + * * @param resultEnum 错误枚举类 * @return {@link BaseResponse} */ @@ -60,8 +64,9 @@ public class ResultVOUtils { /** * 错误时返回 + * * @param resultEnum 错误枚举类 - * @param message 错误的信息 + * @param message 错误的信息 * @return {@link BaseResponse} */ public static BaseResponse error(ResultEnum resultEnum, String message) {