@ -13,7 +13,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property= "planCode" column= "plan_code" />
<result property= "planDetailCode" column= "plan_detail_code" />
<result property= "stationId" column= "station_id" />
<result property= " productId" column= "product _id" />
<result property= " materialId" column= "material _id" />
<result property= "materialBatch" column= "material_batch" />
<result property= "palletInfoCode" column= "pallet_info_code" />
<result property= "outstockAmount" column= "outstock_amount" />
@ -55,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property= "materialBarcode" column= "sub_material_barcode" />
<result property= "materialId" column= "sub_material_id" />
<result property= "instockBatch" column= "sub_instock_batch" />
<result property= "materialProductionDate" column= "sub_material_production_ D ate" />
<result property= "materialProductionDate" column= "sub_material_production_ d ate" />
<result property= "planAmount" column= "sub_plan_amount" />
<result property= "outstockAmount" column= "sub_outstock_amount" />
<result property= "executeStatus" column= "sub_execute_status" />
@ -73,7 +73,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id= "selectWmsRawOutstockVo" >
select raw_outstock_id, task_code, warehouse_id, location_code, order_id, plan_code, plan_detail_code, station_id, product _id, material_batch, pallet_info_code, outstock_amount, real_outstock_amount, end_station_code, operation_type, task_type, apply_reason, audit_reason, audit_status, execute_status, apply_by, apply_date, audit_by, audit_date, update_by, update_date, begin_time, end_time, erp_status, erp_amount from wms_raw_outstock
select raw_outstock_id, task_code, warehouse_id, location_code, order_id, plan_code, plan_detail_code, station_id, material _id, material_batch, pallet_info_code, outstock_amount, real_outstock_amount, end_station_code, operation_type, task_type, apply_reason, audit_reason, audit_status, execute_status, apply_by, apply_date, audit_by, audit_date, update_by, update_date, begin_time, end_time, erp_status, erp_amount from wms_raw_outstock
</sql>
<select id= "selectWmsRawOutstockList" parameterType= "WmsRawOutstock" resultMap= "WmsRawOutstockResult" >
@ -86,7 +86,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test= "planCode != null " > and plan_code = #{planCode}</if>
<if test= "planDetailCode != null " > and plan_detail_code = #{planDetailCode}</if>
<if test= "stationId != null " > and station_id = #{stationId}</if>
<if test= " productId != null "> and product_id = #{product Id}</if>
<if test= " materialId != null "> and material_id = #{material Id}</if>
<if test= "operationType != null and operationType != ''" > and operation_type = #{operationType}</if>
<if test= "taskType != null and taskType != ''" > and task_type = #{taskType}</if>
<if test= "applyReason != null and applyReason != ''" > and apply_reason = #{applyReason}</if>
@ -119,7 +119,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test= "planCode != null" > plan_code,</if>
<if test= "planDetailCode != null" > plan_detail_code,</if>
<if test= "stationId != null" > station_id,</if>
<if test= " productId != null"> product _id,</if>
<if test= " materialId != null"> material _id,</if>
<if test= "materialBatch != null" > material_batch,</if>
<if test= "palletInfoCode != null" > pallet_info_code,</if>
<if test= "outstockAmount != null" > outstock_amount,</if>
@ -150,7 +150,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test= "planCode != null" > #{planCode},</if>
<if test= "planDetailCode != null" > #{planDetailCode},</if>
<if test= "stationId != null" > #{stationId},</if>
<if test= " productId != null"> #{product Id},</if>
<if test= " materialId != null"> #{material Id},</if>
<if test= "materialBatch != null" > #{materialBatch},</if>
<if test= "palletInfoCode != null" > #{palletInfoCode},</if>
<if test= "outstockAmount != null" > #{outstockAmount},</if>
@ -185,7 +185,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test= "planCode != null" > plan_code = #{planCode},</if>
<if test= "planDetailCode != null" > plan_detail_code = #{planDetailCode},</if>
<if test= "stationId != null" > station_id = #{stationId},</if>
<if test= " productId != null"> product_id = #{product Id},</if>
<if test= " materialId != null"> material_id = #{material Id},</if>
<if test= "materialBatch != null" > material_batch = #{materialBatch},</if>
<if test= "palletInfoCode != null" > pallet_info_code = #{palletInfoCode},</if>
<if test= "outstockAmount != null" > outstock_amount = #{outstockAmount},</if>
@ -234,7 +234,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</delete>
<insert id= "batchWmsRawOutstockDetail" >
insert into wms_raw_outstock_detail( raw_outstock_detail_id, raw_outstock_id, location_code, material_barcode, material_id, instock_batch, material_production_D ate, plan_amount, outstock_amount, execute_status, erp_status, outstock_person, outstock_time, outstock_way, machine_name, quality_status, create_by, create_date, update_by, update_date, stack_amount) values
insert into wms_raw_outstock_detail( raw_outstock_detail_id, raw_outstock_id, location_code, material_barcode, material_id, instock_batch, material_production_d ate, plan_amount, outstock_amount, execute_status, erp_status, outstock_person, outstock_time, outstock_way, machine_name, quality_status, create_by, create_date, update_by, update_date, stack_amount) values
<foreach item= "item" index= "index" collection= "list" separator= "," >
( #{item.rawOutstockDetailId}, #{item.rawOutstockId}, #{item.locationCode}, #{item.materialBarcode}, #{item.materialId}, #{item.instockBatch}, #{item.materialProductionDate}, #{item.planAmount}, #{item.outstockAmount}, #{item.executeStatus}, #{item.erpStatus}, #{item.outstockPerson}, #{item.outstockTime}, #{item.outstockWay}, #{item.machineName}, #{item.qualityStatus}, #{item.createBy}, #{item.createDate}, #{item.updateBy}, #{item.updateDate}, #{item.stackAmount})
</foreach>
@ -244,7 +244,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id= "selectWmsRawOutstockJoinList" parameterType= "WmsRawOutstock" resultMap= "WmsRawOutstockResult" >
select wro.raw_outstock_id, wro.task_code, wro.warehouse_id, wro.location_code, wro.order_id, wro.plan_code, wro.plan_detail_code, wro.station_id,wro.material_batch,
wro.product _id, wro.operation_type, wro.task_type, wro.apply_reason, wro.audit_reason, wro.audit_status, wro.execute_status, wro.apply_by, wro.apply_date,
wro.material _id, wro.operation_type, wro.task_type, wro.apply_reason, wro.audit_reason, wro.audit_status, wro.execute_status, wro.apply_by, wro.apply_date,
wro.audit_by, wro.audit_date, wro.update_by, wro.update_date, wro.begin_time, wro.end_time,wbw.warehouse_name
from wms_raw_outstock wro left join wms_base_warehouse wbw on wro.warehouse_id = wbw.warehouse_id
<where >
@ -282,7 +282,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
wro.apply_by,wro.apply_date,wro.apply_reason,wro.audit_by,wro.audit_date,wro.audit_reason,wro.plan_code,wro.plan_detail_code,wro.audit_status,wro.task_type,
wro.execute_status,wro.erp_status,wro.erp_amount,
mbmi.material_code,mbmi.material_name
from wms_raw_outstock wro left join mes_base_material_info mbmi on wro.product _id = mbmi.material_id
from wms_raw_outstock wro left join mes_base_material_info mbmi on wro.material _id = mbmi.material_id
<where >
<if test= "taskCode != null and taskCode != ''" > and wro.task_code = #{taskCode}</if>
<if test= "auditStatus != null and auditStatus != ''" > and wro.audit_status = #{auditStatus}</if>
@ -291,9 +291,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</select>
<insert id= "batchWmsRawOutstock" >
insert into wms_raw_outstock(raw_outstock_id, task_code,warehouse_id,location_code,order_id,plan_code,plan_detail_code,station_id,product _id,material_batch,pallet_info_code,outstock_amount,end_station_code,operation_type,task_type,audit_status,execute_status,apply_by,apply_date) values
insert into wms_raw_outstock(raw_outstock_id, task_code,warehouse_id,location_code,order_id,plan_code,plan_detail_code,station_id,material _id,material_batch,pallet_info_code,outstock_amount,end_station_code,operation_type,task_type,audit_status,execute_status,apply_by,apply_date) values
<foreach item= "item" index= "index" collection= "list" separator= "," >
( #{item.rawOutstockId}, #{item.taskCode}, #{item.warehouseId}, #{item.locationCode}, #{item.orderId}, #{item.planCode}, #{item.planDetailCode}, #{item.stationId}, #{item.product Id}, #{item.materialBatch}, #{item.palletInfoCode}, #{item.outstockAmount}, #{item.endStationCode}, #{item.operationType}, #{item.taskType}, #{item.auditStatus}, #{item.executeStatus}, #{item.applyBy}, #{item.applyDate})
( #{item.rawOutstockId}, #{item.taskCode}, #{item.warehouseId}, #{item.locationCode}, #{item.orderId}, #{item.planCode}, #{item.planDetailCode}, #{item.stationId}, #{item.material Id}, #{item.materialBatch}, #{item.palletInfoCode}, #{item.outstockAmount}, #{item.endStationCode}, #{item.operationType}, #{item.taskType}, #{item.auditStatus}, #{item.executeStatus}, #{item.applyBy}, #{item.applyDate})
</foreach>
</insert>
@ -316,7 +316,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
wro.apply_by,wro.apply_date,wro.apply_reason,wro.audit_by,wro.audit_date,wro.audit_reason,wro.plan_code,wro.plan_detail_code,wro.audit_status,wro.task_type,
wro.execute_status,wro.erp_status,wro.erp_amount,
mbmi.material_code,mbmi.material_name
from wms_raw_outstock wro left join mes_base_material_info mbmi on wro.product _id = mbmi.material_id
from wms_raw_outstock wro left join mes_base_material_info mbmi on wro.material _id = mbmi.material_id
where wro.raw_outstock_id = #{rawOutstockId}
</select>