<?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="digital.laboratory.platform.imr.mapper.StorageCupboardMapper">

  <resultMap id="storageCupboardMap" type="digital.laboratory.platform.imr.entity.StorageCupboard">
    <id property="id" column="id"/>
    <result property="name" column="name"/>
    <result property="cupboardNo" column="cupboard_no"/>
    <result property="specifications" column="specifications"/>
    <result property="storageType" column="storage_type"/>
    <result property="status" column="status"/>
    <result property="roomId" column="room_id"/>
    <result property="cupboardPhoto" column="cupboard_photo"/>
    <result property="createBy" column="create_by"/>
    <result property="createTime" column="create_time"/>
    <result property="updateBy" column="update_By"/>
    <result property="updateTime" column="update_time"/>
    <result property="sort" column="sort"/>
    <result property="fileName" column="file_name"/>
  </resultMap>

  <!--getStorageCupboardList-->

 <sql id="cupboardMap">
    select cupboard.*
    from dlp_identification_material_repository.storage_cupboard cupboard
  </sql>
  <!--getStorageRoomList 柜子列表 &ndash;&gt;-->
  <select id="getStorageCupboardList" resultMap="storageCupboardMap">
    <include refid="cupboardMap"/>
      ${ew.customSqlSegment}
  </select >

    <select id="getStorageCupboardPage" resultMap="storageCupboardMap">
        <include refid="cupboardMap"/>
        ${ew.customSqlSegment}
    </select >
</mapper>
