|
@@ -4,10 +4,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
<mapper namespace="com.ruoyi.ams.config.mapper.LocationPriorityHeaderMapper">
|
|
|
|
|
|
- <resultMap type="LocationPriorityHeader" id="LocationPriorityHeaderResult">
|
|
|
+ <resultMap type="locationPriorityHeaderVO" id="LocationPriorityHeaderResult">
|
|
|
<result property="id" column="id" />
|
|
|
<result property="flowName" column="flow_name" />
|
|
|
<result property="locationZone" column="location_zone" />
|
|
|
+ <result property="locationZoneName" column="location_zone_name" />
|
|
|
<result property="mixedFlag" column="mixed_flag" />
|
|
|
<result property="parallelFlag" column="parallel_flag" />
|
|
|
<result property="parallelCount" column="parallel_count" />
|
|
@@ -28,15 +29,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="sku" column="sku" />
|
|
|
</resultMap>
|
|
|
|
|
|
- <resultMap id="LocationPriorityHeaderLocationPriorityDetailsResult" type="LocationPriorityHeader" extends="LocationPriorityHeaderResult">
|
|
|
+ <resultMap id="LocationPriorityHeaderLocationPriorityDetailsResult" type="LocationPriorityHeaderVO" extends="LocationPriorityHeaderResult">
|
|
|
<collection property="locationPriorityDetailsList" notNullColumn="sub_id" javaType="java.util.List" resultMap="LocationPriorityDetailsResult" />
|
|
|
</resultMap>
|
|
|
|
|
|
- <resultMap type="LocationPriorityDetails" id="LocationPriorityDetailsResult">
|
|
|
+ <resultMap type="LocationPriorityDetailsVO" id="LocationPriorityDetailsResult">
|
|
|
<result property="id" column="sub_id" />
|
|
|
<result property="headerId" column="sub_header_id" />
|
|
|
<result property="lotattId" column="sub_lotatt_id" />
|
|
|
<result property="lotattValue" column="sub_lotatt_value" />
|
|
|
+ <result property="lotattName" column="sub_lotatt_name" />
|
|
|
+ <result property="inputType" column="sub_input_type" />
|
|
|
<result property="createBy" column="sub_create_by" />
|
|
|
<result property="createTime" column="sub_create_time" />
|
|
|
<result property="updateBy" column="sub_update_by" />
|
|
@@ -49,7 +52,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectLocationPriorityHeaderList" parameterType="LocationPriorityHeader" resultMap="LocationPriorityHeaderResult">
|
|
|
- <include refid="selectLocationPriorityHeaderVo"/>
|
|
|
+ <!-- <include refid="selectLocationPriorityHeaderVo"/> -->
|
|
|
+ select h.id, h.flow_name, h.location_zone, z.zone_name location_zone_name, h.mixed_flag, h.parallel_flag, h.parallel_count, h.outer_flag, h.period_flag, h.same_lotatt_flag, h.status, h.userdefine1, h.userdefine2, h.userdefine3, h.userdefine4, h.userdefine5, h.create_by, h.create_time, h.update_by, h.update_time, h.remark, h.sku
|
|
|
+ from location_priority_header h
|
|
|
+ left join base_location_zone z on h.location_zone = z.zone_id
|
|
|
<where>
|
|
|
<if test="flowName != null and flowName != ''"> and flow_name like concat('%', #{flowName}, '%')</if>
|
|
|
<if test="locationZone != null and locationZone != ''"> and location_zone = #{locationZone}</if>
|
|
@@ -60,9 +66,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
<select id="selectLocationPriorityHeaderById" parameterType="Long" resultMap="LocationPriorityHeaderLocationPriorityDetailsResult">
|
|
|
select a.id, a.flow_name, a.location_zone, a.mixed_flag, a.parallel_flag, a.parallel_count, a.outer_flag, a.period_flag, a.same_lotatt_flag, a.status, a.userdefine1, a.userdefine2, a.userdefine3, a.userdefine4, a.userdefine5, a.create_by, a.create_time, a.update_by, a.update_time, a.remark, a.sku,
|
|
|
- b.id as sub_id, b.header_id as sub_header_id, b.lotatt_id as sub_lotatt_id, b.lotatt_value as sub_lotatt_value, b.create_by as sub_create_by, b.create_time as sub_create_time, b.update_by as sub_update_by, b.update_time as sub_update_time, b.remark as sub_remark
|
|
|
+ b.id as sub_id, b.header_id as sub_header_id, b.lotatt_id as sub_lotatt_id,c.lotatt_name as sub_lotatt_name, b.lotatt_value as sub_lotatt_value, b.create_by as sub_create_by, b.create_time as sub_create_time, b.update_by as sub_update_by, b.update_time as sub_update_time, b.remark as sub_remark,
|
|
|
+ c.input_type as sub_input_type
|
|
|
from location_priority_header a
|
|
|
left join location_priority_details b on b.header_id = a.id
|
|
|
+ left join lotatt_config c on b.lotatt_id = c.lotatt_id
|
|
|
where a.id = #{id}
|
|
|
</select>
|
|
|
|