|
|
@@ -641,11 +641,11 @@
|
|
|
</select>
|
|
|
<select id="financeOrderInvoiceList" resultType="com.goafanti.order.bo.TOrderInvoiceBo">
|
|
|
select a.id,a.unit_name as unitName,a.order_no as orderNo,c.name,b.project_status as projectStatus,a.amount,
|
|
|
- ifnull(d.sumAmount,0) as sumAmount, date_format(a.create_time,'%Y-%m-%d %H:%i:%S')as createTime ,a.status,
|
|
|
+ ifnull(d.sumAmount,0) as sumAmount, date_format(a.create_time,'%Y-%m-%d %H:%i:%S')as createTime ,a.status,b.process_status processStatus,
|
|
|
b.settlement_amount as settlementAmount, (b.total_amount-b.settlement_amount) as notAmount from t_order_invoice a
|
|
|
left join t_order_new b on a.order_no=b.order_no left join admin c on b.salesman_id=c.id
|
|
|
left join (select order_no,sum(amount)as sumAmount from t_order_invoice where status =2 group by order_no) d
|
|
|
- on a.order_no=d.order_no where a.status in (1,2) and a.approval in (0,2)
|
|
|
+ on a.order_no=d.order_no where a.status in (1,2) and a.approval in (0,2)
|
|
|
<if test="type !=null">
|
|
|
and a.`type`= #{type,jdbcType=INTEGER}
|
|
|
</if>
|
|
|
@@ -716,7 +716,7 @@
|
|
|
</select>
|
|
|
|
|
|
<select id="approvalOrderInvoiceList" resultType="com.goafanti.order.bo.TOrderInvoiceBo">
|
|
|
- select a.id,a.unit_name as unitName,a.order_no as orderNo,c.name,b.project_status as projectStatus,a.amount,
|
|
|
+ select a.id,a.unit_name as unitName,a.order_no as orderNo,c.name,b.project_status as projectStatus,a.amount,b.process_status processStatus,
|
|
|
ifnull(d.sumAmount,0) as sumAmount, date_format(a.create_time,'%Y-%m-%d %H:%i:%S')as createTime ,a.status, a.approval,
|
|
|
b.settlement_amount as settlementAmount, (b.total_amount-b.settlement_amount) as notAmount from t_order_invoice a
|
|
|
left join t_order_new b on a.order_no=b.order_no left join admin c on b.salesman_id=c.id
|