ソースを参照

-员工上岗证查询

jiangbiao 2 年 前
コミット
c13fe15647

+ 10 - 4
master/src/main/resources/mybatis/training/TByxWorklicenseMapper.xml

@@ -56,11 +56,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="post != null  and post != ''"> and post = #{post}</if>
             <if test="idtype != null  and idtype != ''"> and idtype = #{idtype}</if>
             <if test="containerIdnum != null  and containerIdnum != ''"> and container_idnum = #{containerIdnum}</if>
-            <if test="boiler != null  and boiler != ''"> and boiler = #{boiler}</if>
-            <if test="container != null  and container != ''"> and container = #{container}</if>
-            <if test="pipe != null  and pipe != ''"> and pipe = #{pipe}</if>
-            <if test="alkylation != null  and alkylation != ''"> and alkylation = #{alkylation}</if>
             <if test="aromatic != null  and aromatic != ''"> and aromatic = #{aromatic}</if>
+            <if test="boiler != null  and boiler != '' and boiler == 'true'"> and boiler=1</if>
+            <if test="container != null  and container != '' and container == 'true'"> and container=1</if>
+            <if test="pipe != null  and pipe != '' and pipe == 'true'"> and pipe=1</if>
+            <if test="alkylation != null  and alkylation != '' and alkylation == 'true'"> and alkylation=1</if>
+            <if test="notHave == 'true'"> and boiler = 0 and container = 0 and pipe = 0 and alkylation = 0</if>
+            <if test="expiring == 'true'">and (boiler_lifespan <![CDATA[<=]]> #{expiringDate} or
+                container_lifespan <![CDATA[<=]]> #{expiringDate} or
+                pipe_lifespan <![CDATA[<=]]> #{expiringDate} or
+                alkylation_lifespan <![CDATA[<=]]> #{expiringDate})
+                </if>
             <if test="recertificatedate != null "> and recertificatedate = #{recertificatedate}</if>
             <if test="validity != null "> and validity = #{validity}</if>
             <if test="createrCode != null  and createrCode != ''"> and creater_code = #{createrCode}</if>