Commit 80864119 by 朱淼

fix bug

parent 91f220a8
......@@ -13,7 +13,9 @@ import lombok.Data;
*/
@Data
@ApiModel("PlatBedPanoramaVO参数")
public class PlatBedPanoramaVO extends BaseIdDTO {
public class PlatBedPanoramaVO{
private String id;
@ApiModelProperty("空间全路径id")
private String spacePath;
......
......@@ -3,8 +3,23 @@
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.makeit.mapper.platform.space.PlatBedMapper">
<resultMap id="BaseResultMap" type="com.makeit.entity.platform.space.PlatBed">
<id property="id" column="id" jdbcType="VARCHAR"/>
<result property="tenantId" column="tenant_id" jdbcType="VARCHAR"/>
<result property="name" column="name" jdbcType="VARCHAR"/>
<result property="roomId" column="room_id" jdbcType="VARCHAR"/>
<result property="spaceId" column="space_id" jdbcType="VARCHAR"/>
<result property="status" column="status" jdbcType="VARCHAR"/>
<result property="sort" column="sort" jdbcType="VARCHAR"/>
<result property="createDate" column="create_date" jdbcType="TIMESTAMP"/>
<result property="updateDate" column="update_date" jdbcType="TIMESTAMP"/>
<result property="update_by" column="update_by" jdbcType="VARCHAR"/>
<result property="sort" column="sort" jdbcType="VARCHAR"/>
<result property="delFlag" column="del_flag" jdbcType="CHAR"/>
</resultMap>
<select id="selectBySpaceIdAndStatus" resultType="com.makeit.vo.platform.space.PlatBedPanoramaVO">
SELECT pb.id,pb.`status`,pb.name bedName ,pm.`name` roomName,pm.space_path,pe.name as elderName,pe.id as elderId,pm.id as roomId
SELECT pb.id,pb.`status`,pb.name as bedName ,pm.`name` as roomName,pm.space_path as spacePath,pe.name as elderName,pe.id as elderId,pm.id as roomId
FROM `plat_bed` pb
LEFT JOIN plat_room pm on pb.room_id = pm.id
LEFT JOIN plat_elder pe on pe.bed_id = pb.id
......@@ -20,7 +35,7 @@
</select>
<select id="selectByRoomIdAndStatus" resultType="com.makeit.vo.platform.space.PlatBedPanoramaVO">
SELECT pb.id,pb.`status`,pb.name bedName ,pm.`name` roomName,pm.space_path,pe.name as elderName,pe.id as elderId,pm.id as roomId
SELECT pb.id,pb.`status`,pb.name as bedName ,pm.`name` as roomName,pm.space_path as spacePath,pe.name as elderName,pe.id as elderId,pm.id as roomId
FROM `plat_bed` pb
LEFT JOIN plat_room pm on pb.room_id = pm.id
LEFT JOIN plat_elder pe on pe.bed_id = pb.id and pe.del_flag = 0
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment