mirror of
http://192.168.1.205:9980/cf_devdept2/cf_imes_server.git
synced 2026-08-13 21:32:07 +08:00
1.新增用户模板授权分页列表接口,2.mock获取优化排单参数接口
This commit is contained in:
+45
@@ -0,0 +1,45 @@
|
||||
<?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.cf.imes.module.system.dal.mysql.machinetemplate.MachineTemplateMapper">
|
||||
|
||||
<resultMap id="map" type="com.cf.imes.module.system.controller.admin.machine.vo.AuthTemplateResp">
|
||||
<result property="nickname" column="nickname"/>
|
||||
<result property="organId" column="organ_id"/>
|
||||
<result property="userId" column="userId"/>
|
||||
<result property="organName" column="organName"/>
|
||||
<collection property="authTemplateList" javaType="java.util.List" ofType="com.cf.imes.module.system.controller.admin.machine.vo.AutoTemplateVO"
|
||||
select="selectAuthTemplateList" column="{userId=userId, templateName = templateName}" >
|
||||
</collection>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectAuthTemplatePage" resultMap="map" parameterType="com.cf.imes.module.system.controller.admin.machine.vo.AuthTemplatePage">
|
||||
select a.id AS userId, a.nickname, a.organ_id, f.name as organName,
|
||||
case when ('${vo.templateName}' != '') then '${vo.templateName}' else '' end as templateName
|
||||
from system_users a, user_machine b, system_organization f
|
||||
<where>
|
||||
a.id = b.user_id
|
||||
and a.organ_id = f.id
|
||||
and a.deleted = 0
|
||||
<if test="vo.organId != null">
|
||||
and a.organ_id = #{vo.organId}
|
||||
</if>
|
||||
<if test="vo.nickname != null and vo.nickname != '' ">
|
||||
and a.nickname like concat('%',#{vo.nickname},'%')
|
||||
</if>
|
||||
</where>
|
||||
group by a.id
|
||||
</select>
|
||||
|
||||
<select id="selectAuthTemplateList"
|
||||
resultType="com.cf.imes.module.system.controller.admin.machine.vo.AutoTemplateVO" parameterType="java.util.Map">
|
||||
select b.user_id, c.name AS templateName, c.id AS templateId
|
||||
from user_machine b
|
||||
inner join system_machine_template c on b.machine_id = c.id
|
||||
<where>
|
||||
c.deleted = 0
|
||||
<if test="templateName != null and templateName != ''">
|
||||
and c.name like concat('%',#{templateName},'%')
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user