diff --git a/src/main/java/cokr/xit/adds/biz/nims/service/bean/BizNimsServiceBean.java b/src/main/java/cokr/xit/adds/biz/nims/service/bean/BizNimsServiceBean.java index 681ebae..31cd40a 100644 --- a/src/main/java/cokr/xit/adds/biz/nims/service/bean/BizNimsServiceBean.java +++ b/src/main/java/cokr/xit/adds/biz/nims/service/bean/BizNimsServiceBean.java @@ -111,7 +111,7 @@ public class BizNimsServiceBean extends AbstractServiceBean implements BizNimsSe d.setRgtr(reqDto.getUserId()); bizNimsMapper.mergeBsshInfoSt(d); // 대표자 검색조건이 있는 경우 - if (isRprsntvNm && d.getRprsntvNm().contains(reqDto.getRprsntvNm())) { + if (isRprsntvNm && !isEmpty(d.getRprsntvNm()) && d.getRprsntvNm().contains(reqDto.getRprsntvNm())) { list.add(d); } } @@ -217,17 +217,18 @@ public class BizNimsServiceBean extends AbstractServiceBean implements BizNimsSe } }else { list.addAll(curList); - list.sort((a, b) -> { - if (isEmpty(a.getPrdValidDe()) && isEmpty(b.getPrdValidDe())) - return 0; - if (isEmpty(a.getPrdValidDe())) - return -1; - if (isEmpty(b.getPrdValidDe())) - return 1; - return a.getPrdValidDe().compareTo(b.getPrdValidDe()); - }); } + list.sort((a, b) -> { + if (isEmpty(a.getPrdValidDe()) && isEmpty(b.getPrdValidDe())) + return 0; + if (isEmpty(a.getPrdValidDe())) + return -1; + if (isEmpty(b.getPrdValidDe())) + return 1; + return a.getPrdValidDe().compareTo(b.getPrdValidDe()); + }); + ApiBaseResponse> res = ApiBaseResponse.of(list); res.setTotalCount(rslt.getBody().getTotalCount()); return res;