From e0ff252a9ad4ca646e5e3e94a66c1309ec0b7c54 Mon Sep 17 00:00:00 2001
From: nickchange <126672920+nickchange@users.noreply.github.com>
Date: 星期五, 20 十月 2023 09:35:03 +0800
Subject: [PATCH] 10.20
---
cloud-server-competition/src/main/java/com/dsh/competition/service/impl/ParticipantServiceImpl.java | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/ParticipantServiceImpl.java b/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/ParticipantServiceImpl.java
index f4da84b..f90ee7a 100644
--- a/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/ParticipantServiceImpl.java
+++ b/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/ParticipantServiceImpl.java
@@ -66,6 +66,7 @@
Participant participant = new Participant();
BeanUtils.copyProperties(addParticipant, participant);
+ participant.setHeight(Double.valueOf(addParticipant.getHeight()).intValue());
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
if(ToolUtil.isNotEmpty(addParticipant.getBirthday())){
Date parse = sdf.parse(addParticipant.getBirthday());
@@ -97,7 +98,7 @@
participantVo.setIdcard(participant.getIdcard());
Integer age = Integer.valueOf(sdf_year.format(new Date())) - Integer.valueOf(sdf_year.format(participant.getBirthday()));
participantVo.setAge(age);
- Student student = studentClient.queryStudentByPhone(participant.getPhone());
+ Student student = studentClient.queryStudentByPhone(participant.getPhone()==null?"0":participant.getPhone());
if(null != student){
Integer integer = coursePackagePaymentClient.queryResidueClassHour(student.getId());
participantVo.setResidueClassHour(integer);
--
Gitblit v1.7.1