|
@@ -110,9 +110,9 @@
|
|
|
t4.settlement_date loan_date,
|
|
|
t6.c_supplier_info_id supplier_id,
|
|
|
t9.corporate_name supplier_name,
|
|
|
- t6.acceptance_status,
|
|
|
- t4.settlement_status,
|
|
|
- t1.invoice_status
|
|
|
+ t10.name acceptance_status,
|
|
|
+ t11.name settlement_status,
|
|
|
+ t12.name invoice_status
|
|
|
FROM
|
|
|
c_invoice_basic_info t1,
|
|
|
c_invoice_goods_info t2,
|
|
@@ -120,7 +120,10 @@
|
|
|
c_settlement_goods_info t5,
|
|
|
c_acceptance_basic_info t6,
|
|
|
c_acceptance_goods_info t7,
|
|
|
- c_enterprise t9
|
|
|
+ c_enterprise t9,
|
|
|
+ t_dictionary t10,
|
|
|
+ t_dictionary t11,
|
|
|
+ t_dictionary t12
|
|
|
WHERE
|
|
|
t1.id = t2.c_invoice_basic_info_id
|
|
|
AND t2.c_settlement_basic_info_id = t4.id
|
|
@@ -128,6 +131,9 @@
|
|
|
AND t5.c_acceptance_goods_info_id = t7.id
|
|
|
AND t6.id = t7.c_acceptance_basic_info_id
|
|
|
AND t9.id = t6.c_project_core_enterprise_id
|
|
|
+ AND t6.acceptance_status = t10.code
|
|
|
+ AND t4.settlement_status = t11.code
|
|
|
+ AND t1.invoice_status = t12.code
|
|
|
AND t9.id = #{enterpriseId}
|
|
|
AND t1.invoice_status = ( SELECT t3.id FROM t_dictionary t3 WHERE t3.CODE = 'invoice_pass' )
|
|
|
AND t6.is_settlement = 1
|