预约管理
This commit is contained in:
@@ -0,0 +1,81 @@
|
||||
<?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.openhis.appointmentmanage.mapper.ClinicRoomMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="ClinicRoomResult" type="com.openhis.appointmentmanage.domain.ClinicRoom">
|
||||
<id property="id" column="id" />
|
||||
<result property="orgName" column="org_name" />
|
||||
<result property="roomName" column="room_name" />
|
||||
<result property="department" column="department" />
|
||||
<result property="building" column="building" />
|
||||
<result property="floor" column="floor" />
|
||||
<result property="roomNo" column="room_no" />
|
||||
<result property="isDisabled" column="is_disabled" />
|
||||
<result property="remarks" column="remarks" />
|
||||
<result property="voided" column="void" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
id, org_name, room_name, department, building, floor, room_no, is_disabled, remarks, void, create_by, create_time, update_by, update_time
|
||||
</sql>
|
||||
|
||||
<!-- 分页查询 -->
|
||||
<select id="selectClinicRoomPage" parameterType="com.openhis.appointmentmanage.domain.ClinicRoom" resultMap="ClinicRoomResult">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from clinic_room
|
||||
where 1 = 1
|
||||
<if test="orgName != null and orgName != ''">
|
||||
and org_name like concat('%', #{orgName}, '%')
|
||||
</if>
|
||||
<if test="roomName != null and roomName != ''">
|
||||
and room_name like concat('%', #{roomName}, '%')
|
||||
</if>
|
||||
order by create_time desc
|
||||
</select>
|
||||
|
||||
<!-- 查询详情 -->
|
||||
<select id="selectClinicRoomById" parameterType="Long" resultMap="ClinicRoomResult">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from clinic_room
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<!-- 新增 -->
|
||||
<insert id="insertClinicRoom" parameterType="com.openhis.appointmentmanage.domain.ClinicRoom" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into clinic_room
|
||||
(org_name, room_name, department, building, floor, room_no, is_disabled, remarks, void, create_by, create_time, update_by, update_time)
|
||||
values
|
||||
(#{orgName}, #{roomName}, #{department}, #{building}, #{floor}, #{roomNo}, #{isDisabled}, #{remarks}, #{voided}, #{createBy}, #{createTime}, #{updateBy}, #{updateTime})
|
||||
</insert>
|
||||
|
||||
<!-- 更新 -->
|
||||
<update id="updateClinicRoom" parameterType="com.openhis.appointmentmanage.domain.ClinicRoom">
|
||||
update clinic_room
|
||||
set
|
||||
org_name = #{orgName},
|
||||
room_name = #{roomName},
|
||||
department = #{department},
|
||||
building = #{building},
|
||||
floor = #{floor},
|
||||
room_no = #{roomNo},
|
||||
is_disabled = #{isDisabled},
|
||||
remarks = #{remarks},
|
||||
void = #{voided},
|
||||
update_by = #{updateBy},
|
||||
update_time = #{updateTime}
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<!-- 删除 -->
|
||||
<delete id="deleteClinicRoomById" parameterType="Long">
|
||||
delete from clinic_room where id = #{id}
|
||||
</delete>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user