| | |
| | | and a.input_unit_id = #{terms.inputUnitId} |
| | | </if> |
| | | <if test="terms.inputUnitName != null and terms.inputUnitName !=''"> |
| | | and a.input_unit_name = #{terms.inputUnitName} |
| | | and a.input_unit_name like CONCAT('%', #{terms.inputUnitName}, '%') |
| | | </if> |
| | | <if test="terms.visitTimeStart != null and terms.visitTimeStart !='' and terms.visitTimeEnd != null and terms.visitTimeEnd !=''"> |
| | | and (DATE_FORMAT(a.visit_time,'%Y-%m-%d %H:%i:%s') <![CDATA[ >= ]]> #{terms.visitTimeStart} |
| | |
| | | and a.case_ref = #{terms.caseRef} |
| | | </if> |
| | | <if test="terms.plaintiffs != null and terms.plaintiffs !=''"> |
| | | and a.plaintiffs = #{terms.plaintiffs} |
| | | and a.plaintiffs like CONCAT('%', #{terms.plaintiffs}, '%') |
| | | </if> |
| | | <if test="terms.defendants != null and terms.defendants !=''"> |
| | | and a.defendants = #{terms.defendants} |
| | | and a.defendants like CONCAT('%', #{terms.defendants}, '%') |
| | | </if> |
| | | <if test="terms.peopleNumStart != null and terms.peopleNumStart !=''"> |
| | | and a.people_num <![CDATA[ >= ]]> #{terms.peopleNumStart} |
| | |
| | | </if> |
| | | <if test="terms.assistUnitId != null and terms.assistUnitId !=''"> |
| | | and b.assist_unit_id = #{terms.assistUnitId} |
| | | </if> |
| | | <if test="terms.mediateUnitName != null and terms.mediateUnitName !=''"> |
| | | and b.mediate_unit_name like CONCAT('%', #{terms.mediateUnitName}, '%') |
| | | </if> |
| | | <if test="terms.assistUnitName != null and terms.assistUnitName !=''"> |
| | | and b.assist_unit_name like CONCAT('%', #{terms.assistUnitName}, '%') |
| | | </if> |
| | | <if test="terms.mediResult != null and terms.mediResult !=''"> |
| | | and b.medi_result = #{terms.mediResult} |
| | | </if> |
| | | </where> |
| | | </if> |
| | |
| | | <sql id="where-register-part"> |
| | | <if test="terms != null"> |
| | | <where> |
| | | <if test="terms.inputUnitName != null and terms.inputUnitName !=''"> |
| | | and t1.input_unit_mame = #{inputUnitName} |
| | | <if test="terms.inputUnitId != null and terms.inputUnitId !=''"> |
| | | and t1.input_unit_id = #{terms.inputUnitId} |
| | | </if> |
| | | <if test="terms.createStart != null and terms.createStart !='' and terms.createEnd != null and terms.createEnd !=''"> |
| | | and (DATE_FORMAT(t1.create_time,'%Y-%m-%d') <![CDATA[ >= ]]> #{terms.createStart} |
| | |
| | | and t1.canal_name = #{terms.canalName} |
| | | </if> |
| | | <if test="terms.plaintiffs != null and terms.plaintiffs !=''"> |
| | | and t1.plaintiffs = #{terms.plaintiffs} |
| | | and t1.plaintiffs like CONCAT('%', #{terms.plaintiffs}, '%') |
| | | </if> |
| | | <if test="terms.defendants != null and terms.defendants !=''"> |
| | | and t1.defendants = #{terms.defendants} |
| | | and t1.defendants like CONCAT('%', #{terms.defendants}, '%') |
| | | </if> |
| | | <if test="terms.statusName != null and terms.statusName !=''"> |
| | | and t1.status_name = #{terms.statusName} |
| | |
| | | <if test="terms.mediResultName != null and terms.mediResultName !=''"> |
| | | and t2.medi_result_name = #{terms.mediResultName} |
| | | </if> |
| | | <if test="terms.mediResult != null and terms.mediResult !=''"> |
| | | and t2.medi_result = #{terms.mediResult} |
| | | </if> |
| | | </where> |
| | | </if> |
| | | </sql> |