liukangdong
2024-05-27 efcdc8c49b0452d9c7f192ab351da09bf8aafc80
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/VisitsServiceImpl.java
@@ -616,13 +616,15 @@
        }
        //访客报备
        if(visits.getType().equals(Constants.TWO)
         && (StringUtils.isBlank( visits.getName())
            && (StringUtils.isBlank( visits.getName())
                ||  StringUtils.isBlank( visits.getPhone())
                ||  StringUtils.isBlank( visits.getCompanyName()))
                ||  StringUtils.isBlank( visits.getCarNos())
                ||  Objects.isNull( visits.getMemberNum())
        ){
            throw  new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "对不起,信息填写不正确!");
        }else if(visits.getType().equals(Constants.ONE) && StringUtils.isBlank(visits.getConstructionReason())){
            throw  new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "对不起,未填写施工事由!");
        }
        if(visits.getEndtime().getTime() < System.currentTimeMillis()){
            throw  new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "对不起,入厂时间必须大于当前时间!");//