|
|
@ -56,12 +56,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
,b.id as bom_id |
|
|
|
from sys_sales_order_child a |
|
|
|
left join erp_bom b |
|
|
|
on a.materialCode = b.material_no and b.del_flag = '0' |
|
|
|
on a.materialCode = b.material_no |
|
|
|
</sql> |
|
|
|
<select id="selectSysSalesOrderChildList" parameterType="SysSalesOrderChild" resultMap="SysSalesOrderChildResult"> |
|
|
|
<include refid="selectSysSalesOrderChild"/> |
|
|
|
<where> |
|
|
|
a.del_flag = '0' |
|
|
|
<if test="quoteId != null and quoteId !='' "> and a.quoteId = #{quoteId}</if> |
|
|
|
<if test="materialId != null "> and a.materialId = #{materialId}</if> |
|
|
|
<if test="materialCode != null and materialCode != ''"> and a.materialCode like concat('%', #{materialCode}, '%')</if> |
|
|
@ -288,11 +287,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
</delete> |
|
|
|
<delete id="deleteSysSalesOrderChildByQuoteIds" parameterType="String"> |
|
|
|
delete from sys_sales_order_child where quoteId in |
|
|
|
<foreach item="id" collection="array" open="(" separator="," close=")"> |
|
|
|
#{id} |
|
|
|
<foreach item="salesOrderCode" collection="array" open="(" separator="," close=")"> |
|
|
|
#{salesOrderCode} |
|
|
|
</foreach> |
|
|
|
</delete> |
|
|
|
<update id="updateSysSalesOrderChildByQuoteId" parameterType="String"> |
|
|
|
update sys_sales_order_child set del_flag = '1' where quoteId = #{salesOrderCode} |
|
|
|
<update id="deleteSysSalesOrderChildByQuoteId" parameterType="String"> |
|
|
|
delete from sys_sales_order_child where quoteId = #{salesOrderCode} |
|
|
|
</update> |
|
|
|
</mapper> |