123456789101112131415161718192021222324 |
- <?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.imed.costaccount.mapper.ResponsibilityDepartmentMapper">
- <!-- 可根据自己的需求,是否要使用 -->
- <resultMap type="com.imed.costaccount.model.ResponsibilityDepartment" id="responsibilityDepartmentMap">
- <result property="id" column="id" jdbcType="INTEGER"/>
- <result property="responsibilityId" column="responsibility_id" jdbcType="INTEGER"/>
- <result property="departmentId" column="department_id" jdbcType="INTEGER"/>
- <result property="hospId" column="hosp_id" jdbcType="INTEGER"/>
- <result property="createTime" column="create_time" jdbcType="BIGINT"/>
- <result property="deleteTime" column="delete_time" jdbcType="BIGINT"/>
- </resultMap>
- <select id="getDepartByCenterId" resultType="com.imed.costaccount.model.vo.DepartVO">
- select sd.id as departmentId,concat(sd.department_name,sd.department_code) as departmentName
- from cost_responsibility_department crd left join sys_department sd on sd.id = crd.department_id
- where crd.responsibility_id = #{responsibilityId} and crd.delete_time = 0 and sd.delete_time = 0
- </select>
- </mapper>
|