|
|
@@ -0,0 +1,280 @@
|
|
|
+<?xml version="1.0" encoding="UTF-8" ?>
|
|
|
+<!DOCTYPE mapper
|
|
|
+ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
+ "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
+<mapper namespace="assetImportOwnerRoomV1ServiceDaoImpl">
|
|
|
+
|
|
|
+
|
|
|
+ <!-- 保存资产导入日志信息 add by wuxw 2018-07-03 -->
|
|
|
+ <insert id="saveAssetImportOwnerRoomInfo" parameterType="Map">
|
|
|
+ insert into asset_import_owner_room(
|
|
|
+ room_state,id_card,owner_type_cd,detail_id,unit_num,section,remark,floor_num,layer,room_num,owner_name,log_id,tel,state,community_id,room_rent,layer_count,sex,room_sub_type,room_area,built_up_area,left,import_user_id,age
|
|
|
+ ) values (
|
|
|
+ #{roomState},#{idCard},#{ownerTypeCd},#{detailId},#{unitNum},#{section},#{remark},#{floorNum},#{layer},#{roomNum},#{ownerName},#{logId},#{tel},#{state},#{communityId},#{roomRent},#{layerCount},#{sex},#{roomSubType},#{roomArea},#{builtUpArea},#{left},#{importUserId},#{age}
|
|
|
+ )
|
|
|
+ </insert>
|
|
|
+
|
|
|
+
|
|
|
+ <!-- 查询资产导入日志信息 add by wuxw 2018-07-03 -->
|
|
|
+ <select id="getAssetImportOwnerRoomInfo" parameterType="Map" resultType="Map">
|
|
|
+ select t.room_state,t.room_state roomState,t.id_card,t.id_card idCard,t.owner_type_cd,t.owner_type_cd
|
|
|
+ ownerTypeCd,t.detail_id,t.detail_id detailId,t.unit_num,t.unit_num
|
|
|
+ unitNum,t.section,t.remark,t.floor_num,t.floor_num floorNum,t.layer,t.room_num,t.room_num
|
|
|
+ roomNum,t.owner_name,t.owner_name ownerName,t.log_id,t.log_id logId,t.tel,t.state,t.community_id,t.community_id
|
|
|
+ communityId,t.room_rent,t.room_rent roomRent,t.layer_count,t.layer_count
|
|
|
+ layerCount,t.sex,t.room_sub_type,t.room_sub_type roomSubType,t.room_area,t.room_area
|
|
|
+ roomArea,t.status_cd,t.status_cd statusCd,t.built_up_area,t.built_up_area
|
|
|
+ builtUpArea,t.left,t.import_user_id,t.import_user_id importUserId,t.age
|
|
|
+ from asset_import_owner_room t
|
|
|
+ where 1 =1
|
|
|
+ <if test="roomState !=null and roomState != ''">
|
|
|
+ and t.room_state= #{roomState}
|
|
|
+ </if>
|
|
|
+ <if test="idCard !=null and idCard != ''">
|
|
|
+ and t.id_card= #{idCard}
|
|
|
+ </if>
|
|
|
+ <if test="ownerTypeCd !=null and ownerTypeCd != ''">
|
|
|
+ and t.owner_type_cd= #{ownerTypeCd}
|
|
|
+ </if>
|
|
|
+ <if test="detailId !=null and detailId != ''">
|
|
|
+ and t.detail_id= #{detailId}
|
|
|
+ </if>
|
|
|
+ <if test="unitNum !=null and unitNum != ''">
|
|
|
+ and t.unit_num= #{unitNum}
|
|
|
+ </if>
|
|
|
+ <if test="section !=null and section != ''">
|
|
|
+ and t.section= #{section}
|
|
|
+ </if>
|
|
|
+ <if test="remark !=null and remark != ''">
|
|
|
+ and t.remark= #{remark}
|
|
|
+ </if>
|
|
|
+ <if test="floorNum !=null and floorNum != ''">
|
|
|
+ and t.floor_num= #{floorNum}
|
|
|
+ </if>
|
|
|
+ <if test="layer !=null and layer != ''">
|
|
|
+ and t.layer= #{layer}
|
|
|
+ </if>
|
|
|
+ <if test="roomNum !=null and roomNum != ''">
|
|
|
+ and t.room_num= #{roomNum}
|
|
|
+ </if>
|
|
|
+ <if test="ownerName !=null and ownerName != ''">
|
|
|
+ and t.owner_name= #{ownerName}
|
|
|
+ </if>
|
|
|
+ <if test="logId !=null and logId != ''">
|
|
|
+ and t.log_id= #{logId}
|
|
|
+ </if>
|
|
|
+ <if test="tel !=null and tel != ''">
|
|
|
+ and t.tel= #{tel}
|
|
|
+ </if>
|
|
|
+ <if test="state !=null and state != ''">
|
|
|
+ and t.state= #{state}
|
|
|
+ </if>
|
|
|
+ <if test="communityId !=null and communityId != ''">
|
|
|
+ and t.community_id= #{communityId}
|
|
|
+ </if>
|
|
|
+ <if test="roomRent !=null and roomRent != ''">
|
|
|
+ and t.room_rent= #{roomRent}
|
|
|
+ </if>
|
|
|
+ <if test="layerCount !=null and layerCount != ''">
|
|
|
+ and t.layer_count= #{layerCount}
|
|
|
+ </if>
|
|
|
+ <if test="sex !=null and sex != ''">
|
|
|
+ and t.sex= #{sex}
|
|
|
+ </if>
|
|
|
+ <if test="roomSubType !=null and roomSubType != ''">
|
|
|
+ and t.room_sub_type= #{roomSubType}
|
|
|
+ </if>
|
|
|
+ <if test="roomArea !=null and roomArea != ''">
|
|
|
+ and t.room_area= #{roomArea}
|
|
|
+ </if>
|
|
|
+ <if test="statusCd !=null and statusCd != ''">
|
|
|
+ and t.status_cd= #{statusCd}
|
|
|
+ </if>
|
|
|
+ <if test="builtUpArea !=null and builtUpArea != ''">
|
|
|
+ and t.built_up_area= #{builtUpArea}
|
|
|
+ </if>
|
|
|
+ <if test="left !=null and left != ''">
|
|
|
+ and t.left= #{left}
|
|
|
+ </if>
|
|
|
+ <if test="importUserId !=null and importUserId != ''">
|
|
|
+ and t.import_user_id= #{importUserId}
|
|
|
+ </if>
|
|
|
+ <if test="age !=null and age != ''">
|
|
|
+ and t.age= #{age}
|
|
|
+ </if>
|
|
|
+ order by t.create_time desc
|
|
|
+ <if test="page != -1 and page != null ">
|
|
|
+ limit #{page}, #{row}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ </select>
|
|
|
+
|
|
|
+
|
|
|
+ <!-- 修改资产导入日志信息 add by wuxw 2018-07-03 -->
|
|
|
+ <update id="updateAssetImportOwnerRoomInfo" parameterType="Map">
|
|
|
+ update asset_import_owner_room t set t.status_cd = #{statusCd}
|
|
|
+ <if test="newBId != null and newBId != ''">
|
|
|
+ ,t.b_id = #{newBId}
|
|
|
+ </if>
|
|
|
+ <if test="roomState !=null and roomState != ''">
|
|
|
+ , t.room_state= #{roomState}
|
|
|
+ </if>
|
|
|
+ <if test="idCard !=null and idCard != ''">
|
|
|
+ , t.id_card= #{idCard}
|
|
|
+ </if>
|
|
|
+ <if test="ownerTypeCd !=null and ownerTypeCd != ''">
|
|
|
+ , t.owner_type_cd= #{ownerTypeCd}
|
|
|
+ </if>
|
|
|
+ <if test="unitNum !=null and unitNum != ''">
|
|
|
+ , t.unit_num= #{unitNum}
|
|
|
+ </if>
|
|
|
+ <if test="section !=null and section != ''">
|
|
|
+ , t.section= #{section}
|
|
|
+ </if>
|
|
|
+ <if test="remark !=null and remark != ''">
|
|
|
+ , t.remark= #{remark}
|
|
|
+ </if>
|
|
|
+ <if test="floorNum !=null and floorNum != ''">
|
|
|
+ , t.floor_num= #{floorNum}
|
|
|
+ </if>
|
|
|
+ <if test="layer !=null and layer != ''">
|
|
|
+ , t.layer= #{layer}
|
|
|
+ </if>
|
|
|
+ <if test="roomNum !=null and roomNum != ''">
|
|
|
+ , t.room_num= #{roomNum}
|
|
|
+ </if>
|
|
|
+ <if test="ownerName !=null and ownerName != ''">
|
|
|
+ , t.owner_name= #{ownerName}
|
|
|
+ </if>
|
|
|
+ <if test="logId !=null and logId != ''">
|
|
|
+ , t.log_id= #{logId}
|
|
|
+ </if>
|
|
|
+ <if test="tel !=null and tel != ''">
|
|
|
+ , t.tel= #{tel}
|
|
|
+ </if>
|
|
|
+ <if test="state !=null and state != ''">
|
|
|
+ , t.state= #{state}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="roomRent !=null and roomRent != ''">
|
|
|
+ , t.room_rent= #{roomRent}
|
|
|
+ </if>
|
|
|
+ <if test="layerCount !=null and layerCount != ''">
|
|
|
+ , t.layer_count= #{layerCount}
|
|
|
+ </if>
|
|
|
+ <if test="sex !=null and sex != ''">
|
|
|
+ , t.sex= #{sex}
|
|
|
+ </if>
|
|
|
+ <if test="roomSubType !=null and roomSubType != ''">
|
|
|
+ , t.room_sub_type= #{roomSubType}
|
|
|
+ </if>
|
|
|
+ <if test="roomArea !=null and roomArea != ''">
|
|
|
+ , t.room_area= #{roomArea}
|
|
|
+ </if>
|
|
|
+ <if test="builtUpArea !=null and builtUpArea != ''">
|
|
|
+ , t.built_up_area= #{builtUpArea}
|
|
|
+ </if>
|
|
|
+ <if test="left !=null and left != ''">
|
|
|
+ , t.left= #{left}
|
|
|
+ </if>
|
|
|
+ <if test="importUserId !=null and importUserId != ''">
|
|
|
+ , t.import_user_id= #{importUserId}
|
|
|
+ </if>
|
|
|
+ <if test="age !=null and age != ''">
|
|
|
+ , t.age= #{age}
|
|
|
+ </if>
|
|
|
+ where 1=1
|
|
|
+ <if test="detailId !=null and detailId != ''">
|
|
|
+ and t.detail_id= #{detailId}
|
|
|
+ </if>
|
|
|
+ <if test="communityId !=null and communityId != ''">
|
|
|
+ and t.community_id= #{communityId}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <!-- 查询资产导入日志数量 add by wuxw 2018-07-03 -->
|
|
|
+ <select id="queryAssetImportOwnerRoomsCount" parameterType="Map" resultType="Map">
|
|
|
+ select count(1) count
|
|
|
+ from asset_import_owner_room t
|
|
|
+ where 1 =1
|
|
|
+ <if test="roomState !=null and roomState != ''">
|
|
|
+ and t.room_state= #{roomState}
|
|
|
+ </if>
|
|
|
+ <if test="idCard !=null and idCard != ''">
|
|
|
+ and t.id_card= #{idCard}
|
|
|
+ </if>
|
|
|
+ <if test="ownerTypeCd !=null and ownerTypeCd != ''">
|
|
|
+ and t.owner_type_cd= #{ownerTypeCd}
|
|
|
+ </if>
|
|
|
+ <if test="detailId !=null and detailId != ''">
|
|
|
+ and t.detail_id= #{detailId}
|
|
|
+ </if>
|
|
|
+ <if test="unitNum !=null and unitNum != ''">
|
|
|
+ and t.unit_num= #{unitNum}
|
|
|
+ </if>
|
|
|
+ <if test="section !=null and section != ''">
|
|
|
+ and t.section= #{section}
|
|
|
+ </if>
|
|
|
+ <if test="remark !=null and remark != ''">
|
|
|
+ and t.remark= #{remark}
|
|
|
+ </if>
|
|
|
+ <if test="floorNum !=null and floorNum != ''">
|
|
|
+ and t.floor_num= #{floorNum}
|
|
|
+ </if>
|
|
|
+ <if test="layer !=null and layer != ''">
|
|
|
+ and t.layer= #{layer}
|
|
|
+ </if>
|
|
|
+ <if test="roomNum !=null and roomNum != ''">
|
|
|
+ and t.room_num= #{roomNum}
|
|
|
+ </if>
|
|
|
+ <if test="ownerName !=null and ownerName != ''">
|
|
|
+ and t.owner_name= #{ownerName}
|
|
|
+ </if>
|
|
|
+ <if test="logId !=null and logId != ''">
|
|
|
+ and t.log_id= #{logId}
|
|
|
+ </if>
|
|
|
+ <if test="tel !=null and tel != ''">
|
|
|
+ and t.tel= #{tel}
|
|
|
+ </if>
|
|
|
+ <if test="state !=null and state != ''">
|
|
|
+ and t.state= #{state}
|
|
|
+ </if>
|
|
|
+ <if test="communityId !=null and communityId != ''">
|
|
|
+ and t.community_id= #{communityId}
|
|
|
+ </if>
|
|
|
+ <if test="roomRent !=null and roomRent != ''">
|
|
|
+ and t.room_rent= #{roomRent}
|
|
|
+ </if>
|
|
|
+ <if test="layerCount !=null and layerCount != ''">
|
|
|
+ and t.layer_count= #{layerCount}
|
|
|
+ </if>
|
|
|
+ <if test="sex !=null and sex != ''">
|
|
|
+ and t.sex= #{sex}
|
|
|
+ </if>
|
|
|
+ <if test="roomSubType !=null and roomSubType != ''">
|
|
|
+ and t.room_sub_type= #{roomSubType}
|
|
|
+ </if>
|
|
|
+ <if test="roomArea !=null and roomArea != ''">
|
|
|
+ and t.room_area= #{roomArea}
|
|
|
+ </if>
|
|
|
+ <if test="statusCd !=null and statusCd != ''">
|
|
|
+ and t.status_cd= #{statusCd}
|
|
|
+ </if>
|
|
|
+ <if test="builtUpArea !=null and builtUpArea != ''">
|
|
|
+ and t.built_up_area= #{builtUpArea}
|
|
|
+ </if>
|
|
|
+ <if test="left !=null and left != ''">
|
|
|
+ and t.left= #{left}
|
|
|
+ </if>
|
|
|
+ <if test="importUserId !=null and importUserId != ''">
|
|
|
+ and t.import_user_id= #{importUserId}
|
|
|
+ </if>
|
|
|
+ <if test="age !=null and age != ''">
|
|
|
+ and t.age= #{age}
|
|
|
+ </if>
|
|
|
+
|
|
|
+
|
|
|
+ </select>
|
|
|
+
|
|
|
+</mapper>
|