| | |
| | | <result property="validFlag" column="valid_flag" typeHandler="com.nanometer.smartlab.entity.handler.ValidFlagHandler"></result> |
| | | <result property="createTime" column="create_time"></result> |
| | | <result property="updateTime" column="update_time"></result> |
| | | <result property="project" column="project"></result> |
| | | </resultMap> |
| | | |
| | | <sql id="queryWhereSql"> |
| | |
| | | </if> |
| | | <if test="department != null and department != ''"> |
| | | and su.department = #{department} |
| | | </if> |
| | | <if test="project != null and project != ''"> |
| | | and su.project like concat("%",#{project},"%") |
| | | </if> |
| | | </sql> |
| | | |
| | |
| | | CONCAT(location1,'-',location2) |
| | | END |
| | | location, |
| | | bm2.meta_value department |
| | | bm2.meta_value department, |
| | | sl.project |
| | | from sys_laboratory as sl |
| | | LEFT JOIN base_meta bm1 on bm1.id = sl.type |
| | | left JOIN base_meta bm2 on bm2.id = sl.department |
| | |
| | | </if> |
| | | <if test="type != null and type != ''"> |
| | | and sl.type = #{type}; |
| | | </if> |
| | | <if test="project != null and project != ''"> |
| | | and sl.project like concat("%",#{project},"%") |
| | | </if> |
| | | </select> |
| | | |
| | |
| | | WHERE |
| | | sl.project LIKE CONCAT('%',#{project},'%') |
| | | </select> |
| | | <select id="getSysLaboratoryByName" resultMap="SysLaboratory"> |
| | | select * |
| | | from sys_laboratory |
| | | where name = #{0} |
| | | and valid_flag = 1 |
| | | </select> |
| | | <select id="getPersonInCharge" resultType="java.util.Map"> |
| | | select su.phone |
| | | from sys_user as su |
| | | left join base_role as br on su.role_id = br.id |
| | | where su.project like concat("%",#{project},"%") |
| | | and su.valid_flag = 1 |
| | | and br.`name` = '实验负责人' |
| | | |
| | | </select> |
| | | <update id="updateLabExport" parameterType="com.nanometer.smartlab.entity.SysLaboratory"> |
| | | update sys_laboratory set |
| | | type=#{type}, |