<?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="com.panzhihua.service_community.dao.ComMngBuildingDAO">
|
|
<resultMap type="com.panzhihua.service_community.model.dos.ComMngBuildingDO" id="ComMngBuildingBaseResultMap">
|
<result property="id" column="id"/>
|
<result property="streetId" column="street_id"/>
|
<result property="actId" column="act_id"/>
|
<result property="villageId" column="village_id"/>
|
<result property="name" column="name"/>
|
<result property="buildFloorSum" column="build_floor_sum"/>
|
<result property="everyFloorSum" column="every_floor_sum"/>
|
<result property="buildUserSum" column="build_user_sum"/>
|
<result property="buildType" column="build_type"/>
|
<result property="buildStructure" column="build_structure"/>
|
<result property="useType" column="use_type"/>
|
<result property="buildDate" column="build_date"/>
|
<result property="unitTotal" column="unit_total"/>
|
<result property="elevatorTotal" column="elevator_total"/>
|
<result property="buildStatus" column="build_status"/>
|
<result property="path" column="path"/>
|
<result property="lng" column="lng"/>
|
<result property="lat" column="lat"/>
|
<result property="buildingResponsible" column="building_responsible"/>
|
<result property="buildingResponsibleCardNo" column="building_responsible_card_no"/>
|
<result property="buildingResponsiblePhone" column="building_responsible_phone"/>
|
<result property="buildingResponsibleType" column="building_responsible_type"/>
|
<result property="createAt" column="create_at"/>
|
<result property="updateAt" column="update_at"/>
|
<result property="remark" column="remark"/>
|
<result property="gridId" column="grid_id"/>
|
</resultMap>
|
|
<select id="find" resultType="String">
|
select concat(t1.group_at,t.name,'栋') from com_mng_building t left join com_mng_village t1 on t.village_id = t1.village_id where t.id in (#{id})
|
</select>
|
|
<resultMap id="selectMap" type="com.panzhihua.common.model.vos.community.VillageVO">
|
<result property="value" column="villageId"/>
|
<result property="label" column="villageName"/>
|
<collection property="children" ofType="com.panzhihua.common.model.vos.community.BuildingVO"
|
column="{village_id = village_id}"
|
javaType="java.util.ArrayList">
|
<result property="value" column="id"/>
|
<result property="label" column="name"/>
|
</collection>
|
</resultMap>
|
|
<select id="select" resultMap="selectMap">
|
select t.village_id as villageId,t.name as villageName,t1.id,t1.name from com_mng_village t left join com_mng_building t1 on t.village_id = t1.village_id where t.community_id=#{id} and t1.id is not null
|
</select>
|
|
</mapper>
|