迭代 注册方法1.3

master
冯凯 2023-10-20 20:52:39 +08:00
parent 8d0aea5bc6
commit eec30adb9a
1 changed files with 5 additions and 7 deletions

View File

@ -186,7 +186,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<choose>
<when test="roleId==1">
insert into tb_patient(
<if test="patientId!=null"> patient_id,</if>
<if test="patientId!=null">patient_id,</if>
<if test="name!=null and name!=''">patient_name,</if>
<if test="password!=null and password!=''">password,</if>
<if test="email!=null and email!=''">email,</if>
@ -198,20 +198,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="age!=null">age,</if>
<if test="wechatNumber!=null and wechatNumber!=''">wechat_number,</if>
)
values
(
<if test="patientId!=null"> #{patientId},</if>
values(
<if test="patientId!=null">#{patientId},</if>
<if test="name!=null and name!=''">#{name},</if>
<if test="password!=null and password!=''">#{password},</if>
<if test="email!=null and email!=''">#{email},</if>
<if test="inviteCode!=null and inviteCode!=''">#{inviteCode},</if>
<if test="avatar!=null and avatar!=''"> #{avatar},</if>
<if test="avatar!=null and avatar!=''">#{avatar},</if>
<if test="gender!=null">#{gender},</if>
<if test="height!=null">#{height},</if>
<if test="weight!=null">#{weight},</if>
<if test="age!=null">#{age},</if>
<if test="wechatNumber!=null and wechatNumber!=''">#{wechatNumber},</if>
)
<if test="wechatNumber!=null and wechatNumber!=''">#{wechatNumber},</if>)
</when>
<otherwise>
insert into tb_doctor