|
|
@ -35,28 +35,50 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
select factory_code, production_version, bom_code, optional_bom, optional_bom_text, pvvd, pved, bom_calculate_number, bom_calculate_unit, bom_base_number, bom_base_unit, component_unit, component_pro_flag, msi, sanka, attr1, attr2, attr3, create_by, create_time, update_by, update_time, remark, current_version from base_bom
|
|
|
|
select factory_code, production_version, bom_code, optional_bom, optional_bom_text, pvvd, pved, bom_calculate_number, bom_calculate_unit, bom_base_number, bom_base_unit, component_unit, component_pro_flag, msi, sanka, attr1, attr2, attr3, create_by, create_time, update_by, update_time, remark, current_version from base_bom
|
|
|
|
</sql>
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectBaseBomList" parameterType="BaseBom" resultMap="BaseBomResult">
|
|
|
|
<select id="selectBaseBomList" parameterType="BaseBom" resultType="com.op.wms.domain.BaseBom">
|
|
|
|
<include refid="selectBaseBomVo"/>
|
|
|
|
select
|
|
|
|
<where>
|
|
|
|
bb.factory_code as factoryCode,
|
|
|
|
|
|
|
|
bb.production_version as productionVersion,
|
|
|
|
|
|
|
|
bb.bom_code as bomCode,
|
|
|
|
|
|
|
|
bb.optional_bom as optionalBom,
|
|
|
|
|
|
|
|
bb.optional_bom_text as optionalBomText,
|
|
|
|
|
|
|
|
bb.pvvd as pvvd,
|
|
|
|
|
|
|
|
bb.pved as pved,
|
|
|
|
|
|
|
|
bb.bom_calculate_number as bomCalculateNumber,
|
|
|
|
|
|
|
|
bb.bom_calculate_unit as bomCalculateUnit,
|
|
|
|
|
|
|
|
bb.bom_base_number as bomBaseNumber,
|
|
|
|
|
|
|
|
bb.bom_base_unit as bomBaseUnit,
|
|
|
|
|
|
|
|
bb.component_unit as componentUnit,
|
|
|
|
|
|
|
|
bb.component_pro_flag as componentProFlag,
|
|
|
|
|
|
|
|
bb.msi as msi,
|
|
|
|
|
|
|
|
bb.sanka as sanka,
|
|
|
|
|
|
|
|
bb.attr1 as attr1,
|
|
|
|
|
|
|
|
bb.attr2 as attr2,
|
|
|
|
|
|
|
|
bb.attr3 as attr3,
|
|
|
|
|
|
|
|
bb.create_by as createBy,
|
|
|
|
|
|
|
|
bb.create_time as createTime,
|
|
|
|
|
|
|
|
bb.update_by as updateBy,
|
|
|
|
|
|
|
|
bb.update_time,
|
|
|
|
|
|
|
|
bb.remark as remark,
|
|
|
|
|
|
|
|
bb.current_version as currentVersion,
|
|
|
|
|
|
|
|
bbc.product_code as productCode,
|
|
|
|
|
|
|
|
b1.product_desc_zh as productDescZh,
|
|
|
|
|
|
|
|
bp.product_desc_zh as componentDescZh,
|
|
|
|
|
|
|
|
bbc.cumc as cumc,
|
|
|
|
|
|
|
|
bbc.component as component,
|
|
|
|
|
|
|
|
bbc.bom_hierarchy as bomHierarchy,
|
|
|
|
|
|
|
|
bbc.project_no as projectNo,
|
|
|
|
|
|
|
|
bbc.standard_dosage as standardDosage,
|
|
|
|
|
|
|
|
bbc.loss_rate as lossRate,
|
|
|
|
|
|
|
|
bbc.loss_amount as lossAmount,
|
|
|
|
|
|
|
|
bbc.cilosses as cilosses
|
|
|
|
|
|
|
|
from base_bom bb
|
|
|
|
|
|
|
|
left join base_bom_component bbc on bb.bom_code = bbc.bom_code
|
|
|
|
|
|
|
|
left join base_product b1 on right(b1.product_code,11) = bbc.product_code
|
|
|
|
|
|
|
|
left join base_product bp on right(bp.product_code,11) = bbc.component
|
|
|
|
|
|
|
|
<where>
|
|
|
|
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
|
|
|
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
|
|
|
<if test="productionVersion != null and productionVersion != ''"> and production_version = #{productionVersion}</if>
|
|
|
|
|
|
|
|
<if test="bomCode != null and bomCode != ''"> and bom_code = #{bomCode}</if>
|
|
|
|
<if test="bomCode != null and bomCode != ''"> and bom_code = #{bomCode}</if>
|
|
|
|
<if test="optionalBom != null and optionalBom != ''"> and optional_bom = #{optionalBom}</if>
|
|
|
|
|
|
|
|
<if test="optionalBomText != null and optionalBomText != ''"> and optional_bom_text = #{optionalBomText}</if>
|
|
|
|
|
|
|
|
<if test="pvvd != null "> and pvvd = #{pvvd}</if>
|
|
|
|
|
|
|
|
<if test="pved != null "> and pved = #{pved}</if>
|
|
|
|
|
|
|
|
<if test="bomCalculateNumber != null "> and bom_calculate_number = #{bomCalculateNumber}</if>
|
|
|
|
|
|
|
|
<if test="bomCalculateUnit != null and bomCalculateUnit != ''"> and bom_calculate_unit = #{bomCalculateUnit}</if>
|
|
|
|
|
|
|
|
<if test="bomBaseNumber != null "> and bom_base_number = #{bomBaseNumber}</if>
|
|
|
|
|
|
|
|
<if test="bomBaseUnit != null and bomBaseUnit != ''"> and bom_base_unit = #{bomBaseUnit}</if>
|
|
|
|
|
|
|
|
<if test="componentUnit != null and componentUnit != ''"> and component_unit = #{componentUnit}</if>
|
|
|
|
|
|
|
|
<if test="componentProFlag != null and componentProFlag != ''"> and component_pro_flag = #{componentProFlag}</if>
|
|
|
|
|
|
|
|
<if test="msi != null and msi != ''"> and msi = #{msi}</if>
|
|
|
|
|
|
|
|
<if test="sanka != null and sanka != ''"> and sanka = #{sanka}</if>
|
|
|
|
|
|
|
|
<if test="attr1 != null and attr1 != ''"> and attr1 = #{attr1}</if>
|
|
|
|
|
|
|
|
<if test="attr2 != null and attr2 != ''"> and attr2 = #{attr2}</if>
|
|
|
|
|
|
|
|
<if test="attr3 != null and attr3 != ''"> and attr3 = #{attr3}</if>
|
|
|
|
|
|
|
|
<if test="currentVersion != null and currentVersion != ''"> and current_version = #{currentVersion}</if>
|
|
|
|
|
|
|
|
</where>
|
|
|
|
</where>
|
|
|
|
</select>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|