Commit 6a398291 authored by hanfeng's avatar hanfeng

修改获取片区接口

parent f2cf11e1
...@@ -13,6 +13,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -13,6 +13,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.List; import java.util.List;
import java.util.Objects;
import static com.github.wxiaoqi.security.auth.common.constatns.CommonConstants.DATA_ALL_FALSE; import static com.github.wxiaoqi.security.auth.common.constatns.CommonConstants.DATA_ALL_FALSE;
...@@ -48,8 +49,12 @@ public class AreaBiz extends BaseBiz<AreaMapper, Area> implements UserRestInterf ...@@ -48,8 +49,12 @@ public class AreaBiz extends BaseBiz<AreaMapper, Area> implements UserRestInterf
return RestResponse.suc(mapper.findAllByIds(list)); return RestResponse.suc(mapper.findAllByIds(list));
} else { } else {
Area area = mapper.selectByPrimaryKey(ids);
if (Objects.isNull(area)){
return null;
}
List<Area> areas = Lists.newArrayList(); List<Area> areas = Lists.newArrayList();
areas.add(mapper.selectByPrimaryKey(ids)); areas.add(area);
return RestResponse.suc(areas); return RestResponse.suc(areas);
} }
} else { //拥有全部权限 } else { //拥有全部权限
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment