新增模糊查询
This commit is contained in:
parent
f95d8040ed
commit
816b933fb9
|
|
@ -62,7 +62,7 @@
|
|||
owner_unit as ownerUnit,owner_phone as ownerPhone,create_time as createTime, create_user as createUser,
|
||||
update_time as updateTime
|
||||
from tb_company_perf where del_flag =0
|
||||
<if test="proName != '' and proName != null">and pro_name = #{proName}</if>
|
||||
<if test="proName != '' and proName != null">and pro_name like concat('%', #{proName}, '%')</if>
|
||||
<if test="voltage != '' and voltage != null">and voltage = #{voltage}</if>
|
||||
<if test="startTime != null and endTime != null">
|
||||
and start_time BETWEEN STR_TO_DATE(#{startTime}, '%Y-%m-%d') AND STR_TO_DATE(#{endTime}, '%Y-%m-%d')
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@
|
|||
title,position,major,diploma, diploma_num as diplomaNum,level,is_normal as isNormal,
|
||||
create_time,create_user,update_time,update_user,age
|
||||
from tb_key_people where del_flag = 0
|
||||
<if test="userName != '' and userName != null">and user_name = #{userName}</if>
|
||||
<if test="userName != '' and userName != null">and user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="title != '' and title != null"> and title = #{title}</if>
|
||||
<if test="diploma != '' and diploma != null"> and diploma = #{diploma}</if>
|
||||
<if test="major != '' and major != null"> and major = #{major}</if>
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@
|
|||
title,major,diploma, diploma_num as diplomaNum,level,is_normal as isNormal,
|
||||
create_time,create_user,update_time,update_user
|
||||
from tb_other_people where del_flag = 0
|
||||
<if test="userName != '' and userName != null">and user_name = #{userName}</if>
|
||||
<if test="userName != '' and userName != null">and user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="title != '' and title != null"> and title = #{title}</if>
|
||||
<if test="diploma != '' and diploma != null"> and diploma = #{diploma}</if>
|
||||
<if test="major != '' and major != null"> and major = #{major}</if>
|
||||
|
|
|
|||
|
|
@ -51,8 +51,7 @@
|
|||
from tb_sub_people tsp
|
||||
left join tb_sub ts on tsp.sub_id = ts.id
|
||||
where tsp.del_flag = 0
|
||||
<if test="userName != '' and userName != null">and tsp.user_name = #{userName}</if>
|
||||
<if test="userName != '' and userName != null">and tsp.user_name = #{userName}</if>
|
||||
<if test="userName != '' and userName != null">and tsp.user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="title != '' and title != null">and tsp.title = #{title}</if>
|
||||
<if test="diploma != '' and diploma != null">and tsp.diploma = #{diploma}</if>
|
||||
<if test="subId != '' and subId != null">and tsp.sub_id = #{subId}</if>
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@
|
|||
select id as id,sub_id as subId,pro_name as proName,cons_unit as consUnit,start_time as startTime,
|
||||
end_time as endTime,ht_remark as htRemark,money as money,voltage as voltage
|
||||
from tb_sub_perf where del_flag=0
|
||||
<if test="proName != '' and proName != null">and pro_name = #{proName}</if>
|
||||
<if test="proName != '' and proName != null">and pro_name like concat('%', #{proName}, '%')</if>
|
||||
<if test="subId != '' and subId != null">and sub_id = #{subId}</if>
|
||||
<if test="voltage != '' and voltage != null">and voltage = #{voltage}</if>
|
||||
<if test="startTime != null and endTime != null">
|
||||
|
|
|
|||
Loading…
Reference in New Issue