mybatis-plus如果属性为空,则不查询
如题,如果插入部门-用xml方式则是:
<insert id="insertDept" parameterType="SysDept">
insert into sys_dept(
<if test="deptId != null and deptId != 0">dept_id,</if>
<if test="parentId != null and parentId != 0">parent_id,</if>
原创
2020-08-28 10:15:15 ·
6297 阅读 ·
0 评论