Jelajahi Sumber

1、处理问题

yys 1 bulan lalu
induk
melakukan
5d40f0c9c3

+ 2 - 2
fs-admin/src/main/java/com/fs/his/controller/FsDoctorController.java

@@ -141,8 +141,8 @@ public class FsDoctorController extends BaseController
     @PutMapping
     public AjaxResult edit(@RequestBody FsDoctor fsDoctor)
     {
-        if(fsDoctor.getDoctorType()==1){
-            if (fsDoctor.getIsPrescribeDoctor()==1){
+        if (fsDoctor.getDoctorType() != null && fsDoctor.getDoctorType() == 1) {
+            if (fsDoctor.getIsPrescribeDoctor() != null && fsDoctor.getIsPrescribeDoctor() == 1) {
                 fsDoctor.setPrescribeDoctorId(fsDoctor.getDoctorId());
             }
         }

+ 1 - 1
fs-service/src/main/java/com/fs/his/mapper/FsDoctorMapper.java

@@ -97,7 +97,7 @@ public interface FsDoctorMapper
         "            <if test=\"speed != null \"> and speed = #{speed}</if>\n" +
         "            <if test=\"mobile != null  and mobile != ''\"> and doc.mobile = #{mobile}</if>\n" +
         "            <if test=\"doctorType != null \"> and doc.doctor_type = #{doctorType}</if>\n" +
-        "            <if test=\"sex != null \"> and sex = #{sex}</if>\n" +
+        "            <if test=\"sex != null \"> and doc.sex = #{sex}</if>\n" +
         "            <if test=\"bitthday != null \"> and doc.bitthday = #{bitthday}</if>\n" +
         "            <if test=\"idCard != null  and idCard != ''\"> and doc.id_card = #{idCard}</if>\n" +
         "            <if test=\"idCardFrontUrl != null  and idCardFrontUrl != ''\"> and doc.id_card_front_url = #{idCardFrontUrl}</if>\n" +