| | |
| | | <result property="containerId" column="container_id"></result> |
| | | </resultMap> |
| | | |
| | | <insert id="insertOpeLaboratoryReserve" parameterType="com.nanometer.smartlab.entity.OpeLaboratoryReserve"> |
| | | insert into ope_laboratory_reserve(id, reagent_id, article_number,reserve, valid_flag, update_time,user_id,house_id,container_id) |
| | | values (#{id},#{reagentId},#{articleNumber},#{reserve},#{validFlag},now(),#{userId},#{houseId},#{containerId}) |
| | | <insert id="insertOpeLaboratoryReserve" parameterType="com.nanometer.smartlab.entity.OpeLaboratoryReserve" useGeneratedKeys = "true" keyProperty = "id"> |
| | | insert into ope_laboratory_reserve( reagent_id, article_number,reserve, valid_flag, update_time,user_id,house_id,container_id) |
| | | values (#{reagentId},#{articleNumber},#{reserve},#{validFlag},now(),#{userId},#{houseId},#{containerId}) |
| | | </insert> |
| | | |
| | | <insert id="batchInsert"> |
| | | insert into ope_laboratory_reserve( reagent_id, article_number,reserve, valid_flag, user_id,house_id,container_id) |
| | | values |
| | | <foreach collection="list" item="item" separator=","> |
| | | (#{item.reagentId},#{item.articleNumber},#{item.reserve},#{item.validFlag},#{item.userId},#{item.houseId},#{item.containerId}) |
| | | </foreach> |
| | | </insert> |
| | | |
| | | <select id="selectByReId" resultMap="OpeLaboratoryReserve"> |
| | | select * from ope_laboratory_reserve where reagent_id=#{id} |
| | | </select> |