You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
2.3 KiB
XML

<?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="org.dromara.mes.mapper.ProdBaseRouteProcessMapper">
<resultMap type="ProdBaseRouteProcess" id="ProdBaseRouteProcessResult">
<result property="routeProcessId" column="route_process_id" />
<result property="routeId" column="route_id" />
<result property="processId" column="process_id" />
<result property="processOrder" column="process_order" />
<result property="remark" column="remark" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="createDept" column="create_dept" />
<!-- <result property="processName" column="process_name" />
<result property="processType" column="process_type" />
<result property="productionTime" column="production_time" />
<result property="finalProcessFlag" column="final_process_flag" />-->
</resultMap>
<select id="selectProdBaseRouteProcessJoinList" parameterType="ProdBaseRouteProcess" resultMap="ProdBaseRouteProcessResult">
/* select mbrp.route_process_id, mbrp.route_id, mbrp.process_id, mbrp.process_order,
mbpi.process_name,mbpi.process_type,mbpi.production_time,mbpi.final_process_flag
from prod_base_route_process mbrp
left join prod_base_process_info mbpi on mbrp.process_id=mbpi.process_id*/
select mbrp.route_process_id, mbrp.route_id, mbrp.process_id, mbrp.process_order,
mbpi.process_name,mbpi.process_type,mbpi.production_time
from prod_base_route_process mbrp
left join prod_base_process_info mbpi on mbrp.process_id=mbpi.process_id
<where>
<if test="routeId != null "> and mbrp.route_id = #{routeId}</if>
<if test="processId != null "> and mbrp.process_id = #{processId}</if>
<if test="processOrder != null "> and mbrp.process_order = #{processOrder}</if>
<if test="remark != null and remark != ''"> and rmbrp.remark = #{remark}</if>
</where>
</select>
</mapper>