mdc-parent/mdc-showdb-mysql/src/main/resources/mapper/UseDepartment.xml
@@ -7,4 +7,14 @@ <result column="name" jdbcType="VARCHAR" property="name" /> </resultMap> <select id="queryPage" resultType="com.qianwen.mdc.dto.usedepartment.UseDepartmentDTO"> SELECT id,name FROM use_department <where> <if test="dto.name != null and dto.name != ''"> <bind name="name" value="'%' + dto.name + '%'" /> and name like #{name} </if> </where> </select> </mapper>