Commit 6b186f74 authored by 18083's avatar 18083

经租收付款及报表调整

parent 16f488ab
......@@ -188,6 +188,7 @@
AND f.write_off_flag <> 'FULL'
AND f.cf_status IN ('RELEASE', 'BLOCK')
AND f.cf_direction = 'OUTFLOW'
and t.business_type<>'LEASEOPERAT'
AND NOT EXISTS (
SELECT 1
FROM csh_payment_req_ln l,csh_payment_req_hd hd
......
......@@ -101,6 +101,7 @@
<bm:field name="paid_byother_flag" />
<bm:field name="guarantor_name_duty_desc" expression="(select v.code_value_name from sys_code_values_v v where v.code = 'YES_NO' and v.code_value = t1.guarantor_name_duty)" forInsert="false" forUpdate="false" prompt="担保人履行担保义务" />
<bm:field name="guarantor_name_duty" />
<bm:field name="operat_flag" />
</bm:fields>
......
......@@ -108,17 +108,64 @@
<bm:field name="acc_confirmed_by"/>
<bm:field name="acc_confirmed_by_desc" expression="(select description from sys_user where user_id=t1.acc_confirmed_by)" forInsert="false" forUpdate="false"/>
<bm:field name="receipt_type_n" expression="(select v.code_value_name from sys_code_values_v v where v.code = 'RECEIPT_TYPE' and v.code_value =t1.receipt_type)" forInsert="false" forUpdate="false"/>
<bm:field name="deposit_trans_type"/>
<bm:field name="deposit_trans_type_desc" expression="(select v.code_value_name from sys_code_values_v v where v.code = 'DEPOSIT_TRANS_TYPE' and v.code_value =t1.deposit_trans_type)" forInsert="false" forUpdate="false"/>
<bm:field name="bp_id_telnet_n" expression="(select hb.bp_name from hls_bp_master hb,con_contract ct where ct.contract_id=t1.ref_contract_id and hb.bp_id=ct.bp_id_tenant)" forInsert="false" forUpdate="false"/>
<bm:field name="deposit_trans_type" expression="decode(t1.ref_contract_id,
null,
decode(t1.collection_classes,
'OPERAT_DEPOSIT',
'vender_deposit',
t1.deposit_trans_type),
t1.deposit_trans_type)" forInsert="false" forUpdate="false" />
<bm:field name="deposit_trans_type_desc" expression="decode(t1.ref_contract_id,
null,
decode(t1.collection_classes,
'OPERAT_DEPOSIT',
(select v.code_value_name value_name
from sys_code_values_v v
where v.code = 'DEPOSIT_TRANS_TYPE'
and v.code_value = 'vender_deposit'),
(select v.code_value_name
from sys_code_values_v v
where v.code = 'DEPOSIT_TRANS_TYPE'
and v.code_value = t1.deposit_trans_type)),
(select v.code_value_name
from sys_code_values_v v
where v.code = 'DEPOSIT_TRANS_TYPE'
and v.code_value = t1.deposit_trans_type))" forInsert="false" forUpdate="false"/>
<bm:field name="bp_id_telnet_n" expression="(select hb.bp_name from hls_bp_master hb,con_contract ct where ct.contract_id=t1.ref_contract_id and hb.bp_id=ct.bp_id_tenant)" forInsert="false" forUpdate="false"/>
<bm:field name="bp_name_n" expression="(select hb.bp_name from hls_bp_master hb,con_contract ct where ct.contract_id=t1.ref_contract_id and hb.bp_id=ct.bp_id_agent_level1)" forInsert="false" forUpdate="false"/>
<bm:field name="source_type"/>
<bm:field name="approve_status" expression=" nvl(( hlcm_cux_deposit_pkg.get_transaction_status_new(p_transaction_id=>t1.transaction_id,p_user_id=>1) ),'正常')" forInsert="false" forUpdate="false"/>
<bm:field name="vender_contract_number" expression="(select cc.search_term_1 vender_contract_number from con_contract cc where cc.contract_id = t1.ref_contract_id)"/>
<bm:field name="vender_project_number" expression="(select p.project_number vender_project_number from prj_project_lease_item pi, prj_project p, con_contract_lease_item ci where pi.source_project_id = p.project_id and pi.project_lease_item_id = ci.project_lease_item_id and ci.contract_id=t1.ref_contract_id)"/>
<bm:field name="business_type" expression="(select cc.business_type from con_contract cc where cc.contract_id = t1.ref_contract_id)"/>
<bm:field name="business_type_desc" expression="(select hb.description from con_contract cc,hls_business_type_v hb where cc.business_type= hb.business_type and hb.enabled_flag = 'Y' and cc.contract_id = t1.ref_contract_id)"/>
</bm:fields>
<bm:field name="business_type" expression=" decode(t1.ref_contract_id,
null,
decode(t1.collection_classes,
'OPERAT_DEPOSIT',
'LEASEOPERAT',
(select cc.business_type
from con_contract cc
where cc.contract_id = t1.ref_contract_id)),
(select cc.business_type
from con_contract cc
where cc.contract_id = t1.ref_contract_id))"/>
<bm:field name="business_type_desc" expression="decode(t1.ref_contract_id,
null,
decode(t1.collection_classes,
'OPERAT_DEPOSIT',
(select ht.description
from hls_business_type ht
where ht.business_type = 'LEASEOPERAT'),
(select hb.description
from con_contract cc, hls_business_type_v hb
where cc.business_type = hb.business_type
and hb.enabled_flag = 'Y'
and cc.contract_id = t1.ref_contract_id)),
(select hb.description
from con_contract cc, hls_business_type_v hb
where cc.business_type = hb.business_type
and hb.enabled_flag = 'Y'
and cc.contract_id = t1.ref_contract_id))"/>
</bm:fields>
<bm:features>
<f:standard-who/>
</bm:features>
......@@ -210,5 +257,5 @@
<bm:query-field name="vender_contract_number" queryExpression="(SELECT cc.search_term_1 FROM con_contract cc WHERE cc.contract_id = t1.ref_contract_id) like &apos;%&apos;||${@vender_contract_number}||&apos;%&apos;"/>
<bm:query-field name="vender_project_number" queryExpression="(select p.project_number from prj_project_lease_item pi, prj_project p, con_contract_lease_item ci where pi.source_project_id = p.project_id and pi.project_lease_item_id = ci.project_lease_item_id and ci.contract_id=t1.ref_contract_id) like &apos;%&apos;||${@vender_project_number}||&apos;%&apos;"/>
<bm:query-field name="business_type" queryExpression="(SELECT cc.business_type FROM con_contract cc WHERE cc.contract_id = t1.ref_contract_id) like &apos;%&apos;||${@business_type}||&apos;%&apos;"/>
</bm:query-fields>
</bm:query-fields>
</bm:model>
......@@ -28,7 +28,9 @@
(SELECT ccli.modelcd
FROM con_contract_lease_item ccli
WHERE ccli.contract_id =
ct.contract_id) modelcd,
ct.contract_id
AND ccli.equipment_type ='MAIN') modelcd,
--机型
(SELECT nvl(i.machine_number,i.machine_number_70)
FROM con_contract_lease_item i
......@@ -785,6 +787,7 @@
FROM con_contract ct
WHERE ct.contract_status NOT IN ('CANCEL')
AND ct.data_class = 'NORMAL'
and ct.document_type not in('PUR_ORDER')
ORDER BY ct.bp_id_agent_level1
]]></bm:query-sql>
</bm:operation>
......
......@@ -137,7 +137,8 @@
queryExpression="t1.plan_order_date &lt;= ${@plan_order_date_to}"/>
<bm:query-field name="lease_item_amount"
queryExpression="t1.due_amount&gt;=${@lease_item_amount}"/>
<bm:query-field name="vender_con_number" queryExpression="t1.vender_con_number=${@vender_con_number}"/>
<bm:query-field name="bp_id_agent_n" queryExpression="t1.vender_name_n=${@bp_id_agent_n}"/>
<bm:query-field name="vender_name_n" queryExpression="t1.vender_name_n=${@vender_name_n}"/>
<bm:query-field name="invoice_status_n"
queryExpression="t1.invoice_status_n like &apos;%&apos;||${@invoice_status_n}||&apos;%&apos;"/>
<bm:query-field name="contract_number" queryExpression="t1.contract_number=${@contract_number}"/>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment