|
@@ -95,10 +95,37 @@
|
|
and aircraft_type = #{aircraftType}
|
|
and aircraft_type = #{aircraftType}
|
|
</select>
|
|
</select>
|
|
|
|
|
|
- <select id="findByMultiple" parameterType="String" resultMap="faultMap">
|
|
|
|
- select * from t_fault where (book_name like #{name} and major_type = #{major})
|
|
|
|
- or (fault_name like #{name} and major_type = #{major})
|
|
|
|
|
|
|
|
|
|
+ <select id="findByMultiple" parameterType="com.zglc.fm.entity.FaultFind" resultMap="faultMap">
|
|
|
|
+ select *
|
|
|
|
+ from t_fault where 1=1
|
|
|
|
+ <if test="major !=null">
|
|
|
|
+ and major_type = #{major}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="aircraftType !=null">
|
|
|
|
+ and aircraft_type = #{aircraftType}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="book_name !=null">
|
|
|
|
+ and book_name like #{book_name}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fault_name !=null">
|
|
|
|
+ and fault_name like #{fault_name}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="author !=null">
|
|
|
|
+ and author like #{author}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="department !=null">
|
|
|
|
+ and department like #{department}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="description !=null">
|
|
|
|
+ and description like #{description}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="beginTime != null">
|
|
|
|
+ and fault_time <![CDATA[>=]]> #{beginTime}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="finishTime !=null">
|
|
|
|
+ and fault_time <![CDATA[<=]]> #{finishTime}
|
|
|
|
+ </if>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="findByFaultTime" parameterType="com.zglc.fm.entity.FaultFind" resultMap="faultMap">
|
|
<select id="findByFaultTime" parameterType="com.zglc.fm.entity.FaultFind" resultMap="faultMap">
|