From 2e64c232ab6b51b2cecf1ee96e1e9b709234f326 Mon Sep 17 00:00:00 2001 From: huanghongfa <huanghongfa123456> Date: 星期六, 21 八月 2021 16:35:14 +0800 Subject: [PATCH] 随手拍改版接口开发 --- springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComStreetServiceImpl.java | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComStreetServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComStreetServiceImpl.java index 20bd18e..dd8a675 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComStreetServiceImpl.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComStreetServiceImpl.java @@ -21,7 +21,6 @@ import org.springframework.util.ObjectUtils; import javax.annotation.Resource; -import java.util.ArrayList; import java.util.List; /** @@ -55,7 +54,7 @@ param.eq(ComStreetDO::getAreaCode, comStreetVO.getAreaCode()); Integer integer = comStreetDAO.selectCount(param); if (integer > 0) { - return R.fail("街道已经存在"); + return R.fail(500, "街道已经存在"); } BeanUtils.copyProperties(comStreetVO, comStreetDO); int insert = comStreetDAO.insert(comStreetDO); @@ -64,7 +63,7 @@ BeanUtils.copyProperties(comStreetDO1, comStreetVO); return R.ok(comStreetVO); } - return R.fail(); + return R.fail(500, ""); } @@ -126,10 +125,10 @@ Long pageNum = pageComStreetDTO.getPageNum(); Long pageSize = pageComStreetDTO.getPageSize(); if (null == pageNum || 0 == pageNum) { - pageNum = 1l; + pageNum = 1L; } if (null == pageSize || 0 == pageSize) { - pageSize = 10l; + pageSize = 10L; } page.setSize(pageSize); page.setCurrent(pageNum); @@ -163,6 +162,5 @@ } return R.fail(); } - } -- Gitblit v1.7.1