Browse Source

bug修复

master
laishajiang 2 years ago
parent
commit
46e680ec6f
  1. 4
      mailbox-lan/src/main/java/com/biutag/lan/controller/HotController.java
  2. 8
      mailbox-outer-admin/src/main/java/com/biutag/outeradmin/service/HotService.java

4
mailbox-lan/src/main/java/com/biutag/lan/controller/HotController.java

@ -63,7 +63,11 @@ public class HotController {
newhot.setContactName(hot.get("contactName").toString()); newhot.setContactName(hot.get("contactName").toString());
newhot.setContent(hot.get("content").toString()); newhot.setContent(hot.get("content").toString());
DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"); DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
if (hot.get("phoneTime").toString().equals("")||hot.get("phoneTime").toString()==null){
newhot.setPhoneTime(null);
}else {
newhot.setPhoneTime(LocalDateTime.parse(hot.get("phoneTime").toString(),dateFormat)); newhot.setPhoneTime(LocalDateTime.parse(hot.get("phoneTime").toString(),dateFormat));
}
newhot.setContactType(hot.get("contactType").toString()); newhot.setContactType(hot.get("contactType").toString());
newhot.setContactPhone(hot.get("contactPhone").toString()); newhot.setContactPhone(hot.get("contactPhone").toString());
newhot.setSource(hot.get("source").toString()); newhot.setSource(hot.get("source").toString());

8
mailbox-outer-admin/src/main/java/com/biutag/outeradmin/service/HotService.java

@ -17,6 +17,7 @@ import org.springframework.transaction.annotation.Transactional;
import java.text.ParseException; import java.text.ParseException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.Date; import java.util.Date;
@Service @Service
@ -47,7 +48,12 @@ public class HotService extends ServiceImpl<HotMapper, Hot> {
hot.setContactPhone(mailBo.getString("contactPhone")); hot.setContactPhone(mailBo.getString("contactPhone"));
hot.setContactIdCard(mailBo.getString("contactIdCard")); hot.setContactIdCard(mailBo.getString("contactIdCard"));
hot.setContent(mailBo.getString("content")); hot.setContent(mailBo.getString("content"));
hot.setPhoneTime(LocalDateTime.parse(mailBo.getString("phoneTime"))); DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
if (mailBo.getString("phoneTime").equals("")||mailBo.getString("phoneTime")==null){
hot.setPhoneTime(null);
}else{
hot.setPhoneTime(LocalDateTime.parse(mailBo.getString("phoneTime"),dateFormat));
}
hot.setContactType(mailBo.getString("contactType")); hot.setContactType(mailBo.getString("contactType"));
hot.setCaseType(mailBo.getString("caseType")); hot.setCaseType(mailBo.getString("caseType"));
hot.setSource(mailBo.getString("source")); hot.setSource(mailBo.getString("source"));

Loading…
Cancel
Save