|
|
|
@ -22,6 +22,8 @@
|
|
|
|
<result property="delFlag" column="del_flag"/>
|
|
|
|
<result property="delFlag" column="del_flag"/>
|
|
|
|
<result property="factoryCode" column="factory_code"/>
|
|
|
|
<result property="factoryCode" column="factory_code"/>
|
|
|
|
<result property="nickName" column="nick_name" />
|
|
|
|
<result property="nickName" column="nick_name" />
|
|
|
|
|
|
|
|
<result property="unitPrice" column="unit_price"/>
|
|
|
|
|
|
|
|
<result property="allPrice" column="allPrice"/>
|
|
|
|
</resultMap>
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
|
|
<sql id="selectEquSparepartsInOutVo">
|
|
|
|
<sql id="selectEquSparepartsInOutVo">
|
|
|
|
@ -30,26 +32,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
<select id="selectEquSparepartsInOutList" parameterType="EquSparepartsInOut" resultMap="EquSparepartsInOutResult">
|
|
|
|
<select id="selectEquSparepartsInOutList" parameterType="EquSparepartsInOut" resultMap="EquSparepartsInOutResult">
|
|
|
|
SELECT
|
|
|
|
SELECT
|
|
|
|
id,
|
|
|
|
esio.id,
|
|
|
|
in_out_type,
|
|
|
|
esio.in_out_type,
|
|
|
|
order_no,
|
|
|
|
esio.order_no,
|
|
|
|
spare_code,
|
|
|
|
esio.spare_code,
|
|
|
|
spare_name,
|
|
|
|
esio.spare_name,
|
|
|
|
amount,
|
|
|
|
esio.amount,
|
|
|
|
attr1,
|
|
|
|
esio.attr1,
|
|
|
|
attr2,
|
|
|
|
esio.attr2,
|
|
|
|
attr3,
|
|
|
|
esio.attr3,
|
|
|
|
esio.create_by,
|
|
|
|
esio.create_by,
|
|
|
|
esio.create_time,
|
|
|
|
esio.create_time,
|
|
|
|
esio.update_by,
|
|
|
|
esio.update_by,
|
|
|
|
esio.update_time,
|
|
|
|
esio.update_time,
|
|
|
|
esio.del_flag,
|
|
|
|
esio.del_flag,
|
|
|
|
factory_code,
|
|
|
|
esio.factory_code,
|
|
|
|
storage_id,
|
|
|
|
esio.storage_id,
|
|
|
|
su.nick_name
|
|
|
|
su.nick_name,
|
|
|
|
FROM
|
|
|
|
esl.unit_price,
|
|
|
|
equ_spareparts_in_out esio
|
|
|
|
(esl.unit_price * esio.amount) allPrice
|
|
|
|
|
|
|
|
FROM equ_spareparts_in_out esio
|
|
|
|
LEFT JOIN lanju_op_cloud.dbo.sys_user su ON esio.create_by = su.user_name
|
|
|
|
LEFT JOIN lanju_op_cloud.dbo.sys_user su ON esio.create_by = su.user_name
|
|
|
|
|
|
|
|
LEFT JOIN equ_spareparts_ledger esl ON esio.spare_code = esl.material_code AND esl.del_flag = 0
|
|
|
|
<where>
|
|
|
|
<where>
|
|
|
|
<if test="inOutType != null and inOutType != ''">and in_out_type = #{inOutType}</if>
|
|
|
|
<if test="inOutType != null and inOutType != ''">and in_out_type = #{inOutType}</if>
|
|
|
|
<if test="orderNo != null and orderNo != ''">and order_no = #{orderNo}</if>
|
|
|
|
<if test="orderNo != null and orderNo != ''">and order_no = #{orderNo}</if>
|
|
|
|
|