zoujiajian 1 년 전
부모
커밋
20fb34ebf3
1개의 변경된 파일과 1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      wholesale/src/main/java/com/yhlxj/service/code/impl/ExchangeCodeServiceImpl.java

+ 1 - 1
wholesale/src/main/java/com/yhlxj/service/code/impl/ExchangeCodeServiceImpl.java

@@ -52,7 +52,7 @@ public class ExchangeCodeServiceImpl implements ExchangeCodeService {
 		if (webWholesaleOrderDonCodeRelate == null) {
 			throw BusinessRuntimeException.getInstance("兑换码不存在");
 		}
-		if (webWholesaleOrderDonCodeRelate.getDhUserId() != 0) {
+		if (webWholesaleOrderDonCodeRelate.getDhUserId() != null && webWholesaleOrderDonCodeRelate.getDhUserId() != 0) {
 			throw BusinessRuntimeException.getInstance("兑换码已使用");
 		}
 		Long orderId = webWholesaleOrderDonCodeRelate.getOrderId();