|
|
@ -23,6 +23,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<result property="materialTypeName" column="material_type_name" /> |
|
|
|
<result property="processMethod" column="process_method" /> |
|
|
|
<result property="unit" column="unit" /> |
|
|
|
<result property="materialModel" column="material_model"/> |
|
|
|
<result property="brand" column="brand" /> |
|
|
|
<result property="describe" column="describe" /> |
|
|
|
<result property="warehouseDept" column="warehouse_dept" /> |
|
|
@ -48,14 +49,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
select id, del_flag, create_by, create_time, update_by, update_time, remark, |
|
|
|
bomNo, material_no, material_name, audit_status, use_status,cancel_remark, |
|
|
|
hava_product_tem,product_item,itemName, material_type, process_method, |
|
|
|
unit, brand, `describe`, warehouse_dept,business_members,instance_id,instance_type,submit_instance_id, |
|
|
|
unit, material_model, brand, `describe`, warehouse_dept,business_members,instance_id,instance_type,submit_instance_id, |
|
|
|
cancel_instance_id,restore_instance_id,apply_title,apply_user,apply_time from erp_material |
|
|
|
</sql> |
|
|
|
|
|
|
|
<select id="selectErpMaterialList" parameterType="ErpMaterialVo" resultMap="ErpMaterialResult"> |
|
|
|
select erp.id, erp.del_flag, erp.create_by, erp.create_time, erp.update_by, erp.update_time, erp.remark,erp.bomNo, erp.material_no |
|
|
|
, erp.material_name, erp.audit_status, erp.use_status, erp.hava_product_tem, erp.product_item,erp.`itemName`, erp.material_type, erp.process_method |
|
|
|
, erp.unit, erp.brand, erp.`describe`, erp.warehouse_dept,erp.business_members |
|
|
|
, erp.unit, erp.material_model, erp.brand, erp.`describe`, erp.warehouse_dept,erp.business_members |
|
|
|
,erp.instance_id,erp.instance_type,process_type_dict.dict_label as instance_type_name, |
|
|
|
erp.submit_instance_id,erp.cancel_instance_id,erp.restore_instance_id,erp.apply_title,erp.apply_user,erp.apply_time, |
|
|
|
ss.supplier_name,cate.parent_id |
|
|
@ -122,7 +123,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<select id="selectErpMaterialById" parameterType="Long" resultMap="ErpMaterialResult"> |
|
|
|
select erp.id, erp.del_flag, erp.create_by, erp.create_time, erp.update_by, erp.update_time, erp.remark,erp.bomNo, erp.material_no |
|
|
|
, erp.material_name, erp.audit_status, erp.use_status, erp.hava_product_tem,erp.product_item,erp.itemName, erp.material_type |
|
|
|
, erp.process_method, erp.unit, erp.brand, erp.describe, erp.warehouse_dept,erp.supplier_id,erp.business_members,erp.cancel_remark |
|
|
|
, erp.process_method, erp.unit, erp.material_model, erp.brand, erp.describe, erp.warehouse_dept,erp.supplier_id,erp.business_members,erp.cancel_remark |
|
|
|
,erp.instance_id,erp.instance_type,erp.submit_instance_id,erp.cancel_instance_id,erp.restore_instance_id,erp.apply_title,erp.apply_user,erp.apply_time |
|
|
|
,att.id as photo_attach_id |
|
|
|
from erp_material erp |
|
|
@ -137,7 +138,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<select id="selectErpMaterialByMaterialNo" resultMap="ErpMaterialResult"> |
|
|
|
select erp.id, erp.del_flag, erp.create_by, erp.create_time, erp.update_by, erp.update_time, erp.remark,erp.bomNo, erp.material_no |
|
|
|
, erp.material_name, erp.audit_status, erp.use_status, erp.hava_product_tem,erp.product_item,erp.itemName, erp.material_type |
|
|
|
, erp.process_method, erp.unit, erp.brand, erp.describe, erp.warehouse_dept,erp.supplier_id,erp.business_members |
|
|
|
, erp.process_method, erp.unit, erp.material_model, erp.brand, erp.describe, erp.warehouse_dept,erp.supplier_id,erp.business_members |
|
|
|
,erp.instance_id,erp.instance_type,erp.submit_instance_id,erp.cancel_instance_id,erp.restore_instance_id,erp.apply_title,erp.apply_user,erp.apply_time |
|
|
|
,att.id as photo_attach_id |
|
|
|
from erp_material erp |
|
|
@ -162,7 +163,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
select em.id, em.del_flag, em.create_by, em.create_time, em.update_by, em.update_time, em.remark, |
|
|
|
em.bomNo, em.material_no, em.material_name, em.audit_status,em.use_status, |
|
|
|
em.hava_product_tem,em.product_item,em.itemName, em.material_type, em.process_method, |
|
|
|
em.unit, em.brand, em.`describe`, em.warehouse_dept,em.business_members, |
|
|
|
em.unit, em.material_model, em.brand, em.`describe`, em.warehouse_dept,em.business_members, |
|
|
|
eb.id as bom_id from erp_material em |
|
|
|
left join erp_bom eb on em.material_no = eb.material_no |
|
|
|
<where> |
|
|
@ -175,7 +176,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<select id="selectCateErpMaterialList" resultMap="ErpMaterialResult"> |
|
|
|
select erp.id, erp.del_flag, erp.create_by, erp.remark,erp.bomNo, erp.material_no, |
|
|
|
erp.material_name, erp.audit_status, erp.use_status, erp.hava_product_tem, |
|
|
|
erp.material_type, erp.process_method, erp.unit, erp.brand, erp.`describe`, |
|
|
|
erp.material_type, erp.process_method, erp.unit,erp.material_model, erp.brand, erp.`describe`, |
|
|
|
erp.warehouse_dept,erp.business_members,cate.parent_id,cate.name as material_type_name |
|
|
|
from erp_material erp |
|
|
|
left join ( |
|
|
@ -213,6 +214,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="materialType != null">material_type,</if> |
|
|
|
<if test="processMethod != null">process_method,</if> |
|
|
|
<if test="unit != null">unit,</if> |
|
|
|
<if test="materialModel != null">material_model,</if> |
|
|
|
<if test="brand != null">brand,</if> |
|
|
|
<if test="describe != null">`describe`,</if> |
|
|
|
<if test="warehouseDept != null">warehouse_dept,</if> |
|
|
@ -247,6 +249,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="materialType != null">#{materialType},</if> |
|
|
|
<if test="processMethod != null">#{processMethod},</if> |
|
|
|
<if test="unit != null">#{unit},</if> |
|
|
|
<if test="materialModel != null">#{materialModel},</if> |
|
|
|
<if test="brand != null">#{brand},</if> |
|
|
|
<if test="describe != null">#{describe},</if> |
|
|
|
<if test="warehouseDept != null">#{warehouseDept},</if> |
|
|
@ -289,6 +292,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<if test="materialType != null">material_type = #{materialType},</if> |
|
|
|
<if test="processMethod != null">process_method = #{processMethod},</if> |
|
|
|
<if test="unit != null">unit = #{unit},</if> |
|
|
|
<if test="materialModel != null">material_model = #{materialModel},</if> |
|
|
|
<if test="brand != null">brand = #{brand},</if> |
|
|
|
<if test="describe != null">`describe` = #{describe},</if> |
|
|
|
<if test="warehouseDept != null">warehouse_dept = #{warehouseDept},</if> |
|
|
@ -345,7 +349,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
<select id="searchMaterialsByPrefix" parameterType="String" resultMap="ErpMaterialResult"> |
|
|
|
select erp.id, erp.del_flag, erp.create_by, erp.remark,erp.bomNo, erp.material_no, |
|
|
|
erp.material_name, erp.audit_status, erp.use_status, erp.hava_product_tem, |
|
|
|
erp.material_type, erp.process_method, erp.unit, erp.brand, erp.`describe`, |
|
|
|
erp.material_type, erp.process_method, erp.unit, erp.material_model, erp.brand, erp.`describe`, |
|
|
|
erp.warehouse_dept,erp.business_members,cate.parent_id,cate.name as material_type_name |
|
|
|
from erp_material erp |
|
|
|
left join ( |
|
|
|