@@ -402,7 +402,7 @@
and purchasedetail.companyid= #{companyid}
</select>
<select id="checkCustomer" parameterType="long" resultType="integer">
- select count(1) from sale left join customer on sa_custid=cu_id where cu_statuscode='CLOSE' and cu_statuscode='CLOSE'
+ select count(1) from sale left join customer on sa_custid=cu_id where cu_statuscode='CLOSE' and sa_id=#{id}
<!-- 销售订单转采购单-->