浏览代码

医生id改为自己生成

liaoyongfei 4 年之前
父节点
当前提交
b712ac1f9b
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      ymall/src/main/java/com/liangjian11/ymall/service/impl/DoctorServiceImpl.java

+ 1 - 0
ymall/src/main/java/com/liangjian11/ymall/service/impl/DoctorServiceImpl.java

@@ -410,6 +410,7 @@ public class DoctorServiceImpl extends ServiceImpl<DoctorMapper, Doctor> impleme
       return null;
     JSONObject jsonDoctor = jsonObject.getJSONObject("data").getJSONArray("doctorList").getJSONObject(0);
     Doctor doctor = new Doctor();
+    doctor.setId(UUID.randomUUID().toString().toLowerCase());
     doctor.setCreateTime(new Date());
     doctor.setDoctorName(jsonDoctor.getString("doctorName"));
     doctor.setNickName(jsonDoctor.getString("doctorName"));