Commit 5a5e9191 authored by niminmin's avatar niminmin

发票打印,坏账计提调整

parent 83d6fe57
...@@ -5,323 +5,170 @@ ...@@ -5,323 +5,170 @@
<bm:query-sql><![CDATA[ <bm:query-sql><![CDATA[
SELECT * SELECT *
FROM (SELECT * FROM (select cc.company_id,
FROM (select t1.spv_company_id, cc.project_id,
NULL journal_header_id, cc.contract_id,
NULL journal_line_id, cc.contract_number,
t1.company_id, cc.contract_name,
t1.project_id, cc.inception_of_lease,
t1.contract_id, cc.contract_status,
t1.contract_number, (SELECT sc.code_value_name
t1.contract_name, FROM sys_code_values_v sc
t1.inception_of_lease, WHERE sc.code = 'CON500_CONTRACT_STATUS'
t1.contract_status, AND sc.code_value = cc.contract_status) contract_status_desc,
t1.contract_status_desc, --t2.account_name,
t1.billing_method, cc.billing_method,
t1.billing_method_desc, (SELECT b.description
t1.inv_object_taxpayer_type, FROM hls_billing_method b
t1.inv_object_taxpayer_type_desc, WHERE b.billing_method = cc.billing_method) billing_method_desc,
decode(t2.cf_item, t2.bill_object_bp_id billing_object_id,
'250', hbm.bp_code billing_object_code,
t1.inv_billing_object_id, hbm.bp_name billing_object_name,
t1.billing_object_id) billing_object_id, hbm.taxpayer_type object_taxpayer_type,
decode(t2.cf_item, (SELECT v.code_value_name
'250', FROM sys_code_values_v v
t1.inv_billing_object_code, WHERE v.code = 'HLS211_TAXPAYER_TYPE'
t1.billing_object_code) billing_object_code, AND v.code_value = hbm.taxpayer_type) object_taxpayer_type_desc,
decode(t2.cf_item, hbm.tax_registry_num object_tax_registry_num,
'250', hbm.bp_class bill_object_bp_class,
t1.inv_billing_object_name, (SELECT v.code_value_name
t1.billing_object_name) billing_object_name, FROM sys_code_values_v v
decode(t2.cf_item, WHERE v.code = 'HLS211_BP_CLASS'
'250', AND v.code_value = hbm.bp_class) bill_object_bp_class_desc,
t1.inv_object_taxpayer_type, hbm.REF_V07 description,
t1.object_taxpayer_type) object_taxpayer_type, nvl(hbm.invoice_title, hbm.bp_name) invoice_title,
decode(t2.cf_item, (hbm.invoice_bp_address || '' || hbm.invoice_bp_phone_num) invoice_bp_address_phone_num,
'250', (hbm.invoice_bp_bank || '' || hbm.invoice_bp_bank_account) invoice_bp_bank_account,
t1.inv_object_taxpayer_type_desc, hbm.tax_registry_num tax_registry_num,
t1.object_taxpayer_type_desc) object_taxpayer_type_desc, cc.document_type,
-- t1.object_taxpayer_type_desc, t2.cashflow_id,
decode(t2.cf_item, t2.cf_item,
'250', (Select i.description
t1.inv_object_tax_registry_num, From hls_cashflow_item i
t1.object_tax_registry_num) object_tax_registry_num, Where i.cf_item = t2.cf_item) As cf_item_desc,
decode(t2.cf_item, t2.times,
'250', to_char(t2.last_received_date, 'yyyy-mm-dd') last_received_date,
t1.inv_bill_object_bp_class, to_char(t2.due_date, 'yyyy-mm-dd') due_date,
t1.bill_object_bp_class) bill_object_bp_class, t2.due_amount,
decode(t2.cf_item, t2.principal principal,
'250', t2.interest interest,
t1.inv_bill_object_bp_class_desc, t2.received_amount,
t1.bill_object_bp_class_desc) bill_object_bp_class_desc, t2.received_principal,
t1.tax_type_vat, t2.received_interest,
t1.description, t2.billing_amount,
decode(t2.cf_item, t2.billing_principal,
'250', t2.billing_interest,
t1.inv_invoice_title, t2.vat_due_amount,
t1.invoice_title) invoice_title, t2.vat_principal,
decode(t2.cf_item, t2.vat_interest,
'250', t2.net_due_amount,
t1.inv_bp_address_phone_num, t2.net_principal,
t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num, t2.net_interest,
decode(t2.cf_item, t2.exchange_rate,
'250', t2.exchange_rate_type,
t1.inv_invoice_bp_bank_account, t2.exchange_rate_quotation,
t1.invoice_bp_bank_account) invoice_bp_bank_account, t2.overdue_status,
decode(t2.cf_item, t2.overdue_max_days,
'250', cc.bp_id_agent_level1,
t1.inv_tax_registry_num, (Select m.bp_name
t1.tax_registry_num) tax_registry_num, From hls_bp_master m
t1.document_type, Where m.bp_id = cc.bp_id_agent_level1) bp_id_agent_level1_n,
t1.bp_name, cc.termination_date,
decode(t2.cf_item, cc.lease_channel,
'250', t2.cf_direction,
t1.inv_invoice_type_desc, t2.billing_status,
t1.invoice_type_desc) invoice_type_desc, t2.cf_status,
t2.cashflow_id, cc.business_type,
t2.cf_item, (SELECT bt.description
(Select i.description FROM hls_business_type bt
From hls_cashflow_item i WHERE bt.business_type = cc.business_type) business_type_desc,
Where i.cf_item = t2.cf_item) As cf_item_desc, t2.write_off_flag,
t2.times, case nvl(t2.write_off_flag, 'NOT')
t2.last_received_date, when 'NOT' then
t2.due_date, '未核销'
t2.due_amount, when 'PARTIAL' then
to_char((SELECT wm_concat(distinct '部分核销'
c.bp_bank_account_name) when 'FULL' then
FROM csh_transaction c '全部核销'
WHERE c.transaction_id IN end as write_off_flag_desc,
(SELECT coo.csh_transaction_id t2.ccr_document_type,
FROM csh_write_off coo (select t.description
WHERE coo.cashflow_id = t2.cashflow_id))) account_name, FROM hls_document_type t
decode(t1.lease_channel, '01', null, t2.principal) principal, where t.document_type = t2.ccr_document_type) ccr_document_type_desc
decode(t1.lease_channel, '01', null, t2.interest) interest, from con_contract cc, hls_bp_master hbm, CUS_ACR_INVOICE_V t2
t2.received_amount, where cc.contract_id = t2.contract_id
decode(t1.lease_channel, and hbm.bp_wfl_status = 'APPROVED'
'01', and hbm.invoice_wfl_status = 'APPROVED'
null, and hbm.bp_id = t2.bill_object_bp_id
t2.received_principal) received_principal, and nvl(t2.billing_status, 'NOT') != 'FULL'
decode(t1.lease_channel, --合同状态为结束中(不论是否做过提前结清或解约回购)、提前结清中、提前结清完成、正常结清的合同
'01', and (cc.contract_status in
null, ('TERMINATING', 'ETING', 'ETING', 'TERMINATE')
t2.received_interest) received_interest, --合同状态为起租做过承租人变更的合同
t2.billing_amount, or
t2.billing_principal, (cc.contract_status = 'INCEPT' and t2.document_type = 'LEASE_CHAG' and
t2.billing_interest, trunc(t2.due_date) < trunc(cc.CCR_LEASE_DATE))
t2.vat_due_amount, --合同状态为解约回购中、解约回购完成的合同
t2.vat_principal, or (cc.contract_status in ('REPUR', 'REPURING') and
t2.vat_interest, trunc(t2.due_date) < trunc(cc.REPURCHASE_DATE))
t2.net_due_amount, --合同状态为起租→开票对象:非深圳美鹏HCS小规模纳税人(自然人)→暂不开票→按季度展示未开票现金流
t2.net_principal, or
t2.net_interest, (cc.contract_status = 'INCEPT' and
t2.exchange_rate, trunc(t2.due_date) >= trunc(nvl(cc.CCR_LEASE_DATE, t2.due_date)) and
t2.exchange_rate_type, t2.inv_billing_object_code <> 'D00000009' and hbm.bp_class = 'NP' and
t2.exchange_rate_quotation, hbm.taxpayer_type = 'SMALL_SCALE_TAXPAYER' and
t2.overdue_status, hbm.invoice_method = 'NO_BILLING' and
t2.overdue_max_days, ((to_number(to_char(sysdate, 'MM')) in (3, 6, 9, 12) and
t1.bp_id_agent_level1, trunc(t2.due_date) <= sysdate
t1.bp_id_agent_level1_n,
t1.termination_date,
t1.lease_channel,
t2.cf_direction,
t2.billing_status,
t2.cf_status,
t1.business_type,
t1.business_type_desc,
t2.write_off_flag,
case t2.write_off_flag when 'NOT' then
'未核销'
when 'PARTIAL' then '部分核销'
when 'FULL' then '全部核销'
end as write_off_flag_desc
from cus_acr_invoice_contract_v t1,
con_contract_cashflow t2
where t1.contract_id = t2.contract_id
and t1.bp_wfl_status = 'APPROVED'
and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
((t1.bill_object_bp_class = 'NP' and
t1.inv_billing_object_code <> 'D00000009' AND
(((to_number(to_char(sysdate, 'MM')) in
(3, 6, 9, 12) and trunc(t2.due_date) <= sysdate
and ((to_number(to_char(t2.due_date, 'MM')) in and ((to_number(to_char(t2.due_date, 'MM')) in (3, 6, 9, 12)) or
(3, 6, 9, 12)) or (to_number(to_char(t2.due_date, 'MM')) in (1, 4, 7, 10) and
(to_number(to_char(t2.due_date, 'MM')) in nextduedate(t2.due_date, 2, 1) <= sysdate) or
(1, 4, 7, 10) and (to_number(to_char(t2.due_date, 'MM')) in (2, 5, 8, 11) and
nextduedate(t2.due_date, 2, 1) <= sysdate) or nextduedate(t2.due_date, 1, 1) <= sysdate))
(to_number(to_char(t2.due_date, 'MM')) in
(2, 5, 8, 11) and
nextduedate(t2.due_date, 1, 1) <= sysdate))
) or ( ) or (to_number(to_char(sysdate, 'MM')) in (1, 2) and
trunc(t2.due_date) <= (trunc(sysdate, 'yyyy') - 1)) or
(to_number(to_char(sysdate, 'MM')) in (4, 5) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') || '-03', 'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (7, 8) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') || '-06', 'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (10, 11) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') || '-09', 'yyyy-mm')))))
--合同状态为起租、解约回购中、解约回购完成→开票对象:一般纳税人(法人)→按期开票→核销完展现现金流
or
(((cc.contract_status = 'INCEPT' and
trunc(t2.due_date) >= trunc(nvl(cc.CCR_LEASE_DATE, t2.due_date))) or
(cc.contract_status in ('REPUR', 'REPURING') and
trunc(t2.due_date) >=
trunc(nvl(cc.REPURCHASE_DATE, t2.due_date)))) and
hbm.taxpayer_type = 'GENERAL_TAXPAYER' and hbm.bp_class = 'ORG' and
hbm.invoice_method = 'BILLING' and
nvl(t2.write_off_flag, 'NOT') = 'FULL')
--合同状态为起租→开票对象:小规模纳税人(法人/自然人)→按期开票→到应收日即展示,不论是否核销
or
(cc.contract_status = 'INCEPT' and
trunc(t2.due_date) >= trunc(nvl(cc.CCR_LEASE_DATE, t2.due_date)) and
hbm.taxpayer_type = 'SMALL_SCALE_TAXPAYER' and
hbm.invoice_method = 'BILLING' and
trunc(t2.due_date) <= trunc(sysdate)))
--合同状态为起租→开票对象:一般纳税人(法人),小规模纳税人(法人)和深圳美鹏HCS小规模纳税人(自然人)→暂不开票→暂不展示
and not exists
(select 1
from dual
where hbm.invoice_method = 'NO_BILLING'
and cc.contract_status = 'INCEPT'
and (hbm.bp_class = 'ORG' or
(hbm.taxpayer_type = 'SMALL_SCALE_TAXPAYER' and
hbm.bp_class = 'NP' and
t2.inv_billing_object_code = 'D00000009')))
ORDER BY cc.contract_id, t2.due_date
to_number(to_char(sysdate, 'MM')) in (1, 2) and
trunc(t2.due_date) <=
(trunc(sysdate, 'yyyy') - 1)) or
(
to_number(to_char(sysdate, 'MM')) in (4, 5) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-03',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (7, 8) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-06',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (10, 11) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-09',
'yyyy-mm'))) and t1.contract_status not in ('TERMINATE', 'ET','TERMINATING','ETING'))or
t1.contract_status in ('TERMINATE', 'ET','TERMINATING','ETING'))) or
((t1.bill_object_bp_class = 'ORG' or
(t1.inv_billing_object_code = 'D00000009' and
t1.bill_object_bp_class = 'NP')) AND
t1.contract_status in ('TERMINATE', 'ET', 'REPUR','TERMINATING','ETING','REPURING')))))
and ((decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) =
'SMALL_SCALE_TAXPAYER' and
to_char(t2.due_date, 'yyyy-mm') <=
to_char(SYSDATE, 'yyyy-mm')) or
(t2.write_off_flag = 'FULL' and
t1.contract_status not in ('REPURING', 'REPUR')) or
(nvl(t2.write_off_flag, 'NOT') = 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item <> 1) or
(nvl(t2.write_off_flag, 'NOT') <> 'NOT' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1))
AND cf_item <> 9
AND ((t2.cf_status = 'RELEASE' and
t1.contract_status not in ('REPURING', 'REPUR') and
t2.cf_direction = 'INFLOW') or
(t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item in (1, 2, 250) and
t2.cf_status = 'RELEASE') or
(t2.cf_status in ('BLOCK') and
nvl(t2.write_off_flag, 'NOT') = 'PARTIAL' and
nvl(t2.billing_status, 'NOT') != 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1 and t2.cf_direction = 'NONCASH' and
nvl(t2.billing_amount, 0) <> t2.received_amount))
and t2.cashflow_id not in (20265, 34267, 24445)
and nvl(t2.billing_status, 'NOT') != 'FULL'
--and t2.cf_direction='INFLOW'
and ((decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) <>
'SMALL_SCALE_TAXPAYER' and received_amount > 0) OR
(decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) =
'SMALL_SCALE_TAXPAYER'))
ORDER BY t1.contract_id, t2.due_date)
UNION ALL
select t1.spv_company_id,
t2.journal_header_id,
t2.journal_line_id,
t1.company_id,
t1.project_id,
t1.contract_id,
t1.contract_number,
t1.contract_name,
t1.inception_of_lease,
t1.contract_status,
t1.contract_status_desc,
t1.billing_method,
t1.billing_method_desc,
t1.inv_object_taxpayer_type,
t1.inv_object_taxpayer_type_desc,
(t1.billing_object_id) billing_object_id,
(t1.billing_object_code) billing_object_code,
(t1.billing_object_name) billing_object_name,
(t1.object_taxpayer_type) object_taxpayer_type,
(t1.object_taxpayer_type_desc) object_taxpayer_type_desc,
-- t1.object_taxpayer_type_desc,
(t1.object_tax_registry_num) object_tax_registry_num,
(t1.bill_object_bp_class) bill_object_bp_class,
(t1.bill_object_bp_class_desc) bill_object_bp_class_desc,
t1.tax_type_vat,
t1.description,
(t1.invoice_title) invoice_title,
(t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num,
(t1.invoice_bp_bank_account) invoice_bp_bank_account,
(t1.tax_registry_num) tax_registry_num,
t1.document_type,
t1.bp_name,
(t1.invoice_type_desc) invoice_type_desc,
NULL cashflow_id,
9 cf_item,
(SELECT t.description
FROM hls_cashflow_item t
WHERE t.cf_item = 9) cf_item_desc,
null times,
t2.transaction_date last_received_date,
NULL due_date,
NULL due_amount,
(SELECT c.bp_bank_account_name
FROM csh_transaction c
WHERE c.transaction_id = t2.csh_transaction_id) account_name,
--NULL account_name,
NULL principal,
NULL interest,
t2.amount_dr received_amount,
NULL received_principal,
NULL received_interest,
nvl((SELECT SUM(l.total_amount)
FROM acr_invoice_ln l
WHERE l.ref_n04 = t2.journal_line_id),
0) billing_amount,
NULL billing_principal,
NULL billing_interest,
NULL vat_due_amount,
NULL vat_principal,
NULL vat_interest,
NULL net_due_amount,
NULL net_principal,
NULL net_interest,
NULL exchange_rate,
NULL exchange_rate_type,
NULL exchange_rate_quotation,
NULL overdue_status,
NULL overdue_max_days,
t1.bp_id_agent_level1,
t1.bp_id_agent_level1_n,
t1.termination_date,
t1.lease_channel,
NULL cf_direction,
NULL billing_status,
NULL cf_status,
t1.business_type,
t1.business_type_desc,
'FULL' as write_off_flag,
'全部核销' as write_off_flag_desc
from cus_acr_invoice_contract_v t1, acr_invoice_penalty_v t2
where t2.contract_id = t1.contract_id
and t1.bp_wfl_status = 'APPROVED'
and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
t1.contract_status in ('TERMINATE', 'ET', 'REPUR')))
AND NOT EXISTS (SELECT 1
FROM acr_invoice_ln l, acr_invoice_hd h
WHERE l.invoice_hd_id = h.invoice_hd_id
and h.contract_id = t2.contract_id
and l.cf_item = 9
and l.ref_n04 = t2.journal_line_id
and l.ref_n03 = t2.journal_header_id
group by t2.journal_line_id
having sum(l.total_amount) = t2.amount_dr)
) vv ) vv
...@@ -330,127 +177,129 @@ ...@@ -330,127 +177,129 @@
]]></bm:query-sql> ]]></bm:query-sql>
</bm:operation> </bm:operation>
</bm:operations> </bm:operations>
<bm:fields> <!-- <bm:fields>-->
<bm:field name="spv_company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="SPV_COMPANY_ID"/> <!--&lt;!&ndash; <bm:field name="spv_company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="SPV_COMPANY_ID"/>&ndash;&gt;-->
<bm:field name="journal_header_id" databaseType="NUMBER" datatype="java.lang.Long"/> <!-- <bm:field name="journal_header_id" databaseType="NUMBER" datatype="java.lang.Long"/>-->
<bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long"/> <!-- <bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long"/>-->
<bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/> <!-- <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/>-->
<bm:field name="project_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROJECT_ID"/> <!-- <bm:field name="project_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROJECT_ID"/>-->
<!-- <bm:field name="project_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NUMBER"/>--> <!-- &lt;!&ndash; <bm:field name="project_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NUMBER"/>&ndash;&gt;-->
<!-- <bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/>--> <!-- &lt;!&ndash; <bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/>&ndash;&gt;-->
<bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" required="true"/> <!-- <bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" required="true"/>-->
<bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER"/> <!-- <bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER"/>-->
<bm:field name="contract_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NAME"/> <!-- <bm:field name="contract_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NAME"/>-->
<bm:field name="inception_of_lease" databaseType="DATE" datatype="java.util.Date" physicalName="INCEPTION_OF_LEASE"/> <!-- <bm:field name="inception_of_lease" databaseType="DATE" datatype="java.util.Date" physicalName="INCEPTION_OF_LEASE"/>-->
<bm:field name="contract_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS" required="true"/> <!-- <bm:field name="contract_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS" required="true"/>-->
<bm:field name="contract_status_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS_DESC"/> <!-- <bm:field name="contract_status_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS_DESC"/>-->
<bm:field name="account_name" databaseType="VARCHAR2" datatype="java.lang.String"/> <!--&lt;!&ndash; <bm:field name="account_name" databaseType="VARCHAR2" datatype="java.lang.String"/>&ndash;&gt;-->
<bm:field name="billing_method" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD"/> <!-- <bm:field name="billing_method" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD"/>-->
<bm:field name="billing_method_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD_DESC"/> <!-- <bm:field name="billing_method_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD_DESC"/>-->
<bm:field name="inv_object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type"/> <!--&lt;!&ndash; <bm:field name="inv_object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type"/>&ndash;&gt;-->
<bm:field name="inv_object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type_desc"/> <!--&lt;!&ndash; <bm:field name="inv_object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type_desc"/>&ndash;&gt;-->
<bm:field name="billing_object_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BILLING_OBJECT_ID"/> <!-- <bm:field name="billing_object_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BILLING_OBJECT_ID"/>-->
<bm:field name="billing_object_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_CODE"/> <!-- <bm:field name="billing_object_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_CODE"/>-->
<bm:field name="billing_object_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_NAME"/> <!-- <bm:field name="billing_object_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_NAME"/>-->
<bm:field name="object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE"/> <!-- <bm:field name="object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE"/>-->
<bm:field name="object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE_DESC"/> <!-- <bm:field name="object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE_DESC"/>-->
<bm:field name="object_tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAX_REGISTRY_NUM"/> <!-- <bm:field name="object_tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAX_REGISTRY_NUM"/>-->
<bm:field name="bill_object_bp_class" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS"/> <!-- <bm:field name="bill_object_bp_class" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS"/>-->
<bm:field name="bill_object_bp_class_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS_DESC"/> <!-- <bm:field name="bill_object_bp_class_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS_DESC"/>-->
<bm:field name="tax_type_vat" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_TYPE_VAT"/> <!--&lt;!&ndash; <bm:field name="tax_type_vat" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_TYPE_VAT"/>&ndash;&gt;-->
<bm:field name="description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DESCRIPTION"/> <!-- <bm:field name="description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DESCRIPTION"/>-->
<bm:field name="invoice_title" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TITLE"/> <!-- <bm:field name="invoice_title" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TITLE"/>-->
<bm:field name="invoice_bp_address_phone_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_ADDRESS_PHONE_NUM"/> <!-- <bm:field name="invoice_bp_address_phone_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_ADDRESS_PHONE_NUM"/>-->
<bm:field name="invoice_bp_bank_account" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_BANK_ACCOUNT"/> <!-- <bm:field name="invoice_bp_bank_account" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_BANK_ACCOUNT"/>-->
<bm:field name="tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_REGISTRY_NUM"/> <!-- <bm:field name="tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_REGISTRY_NUM"/>-->
<!-- <bm:field name="prj_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRJ_SEARCH_TERM_1"/>--> <!-- &lt;!&ndash; <bm:field name="prj_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRJ_SEARCH_TERM_1"/>&ndash;&gt;-->
<!-- <bm:field name="prj_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRJ_SEARCH_TERM_2"/>--> <!-- &lt;!&ndash; <bm:field name="prj_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRJ_SEARCH_TERM_2"/>&ndash;&gt;-->
<!-- <bm:field name="con_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CON_SEARCH_TERM_1"/>--> <!-- &lt;!&ndash; <bm:field name="con_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CON_SEARCH_TERM_1"/>&ndash;&gt;-->
<!-- <bm:field name="con_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CON_SEARCH_TERM_2"/>--> <!-- &lt;!&ndash; <bm:field name="con_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CON_SEARCH_TERM_2"/>&ndash;&gt;-->
<bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" required="true"/> <!-- <bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" required="true"/>-->
<bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_NAME"/> <!--&lt;!&ndash; <bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_NAME"/>&ndash;&gt;-->
<bm:field name="invoice_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TYPE_DESC"/> <!--&lt;!&ndash; <bm:field name="invoice_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TYPE_DESC"/>&ndash;&gt;-->
<bm:field name="cashflow_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CASHFLOW_ID"/> <!-- <bm:field name="cashflow_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CASHFLOW_ID"/>-->
<bm:field name="cf_item" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CF_ITEM" required="true"/> <!-- <bm:field name="cf_item" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CF_ITEM" required="true"/>-->
<bm:field name="cf_item_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CF_ITEM_DESC"/> <!-- <bm:field name="cf_item_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CF_ITEM_DESC"/>-->
<bm:field name="times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="TIMES"/> <!-- <bm:field name="times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="TIMES"/>-->
<bm:field name="last_received_date" databaseType="DATE" datatype="java.util.Date" physicalName="LAST_RECEIVED_DATE"/> <!-- <bm:field name="last_received_date" databaseType="DATE" datatype="java.util.Date" physicalName="LAST_RECEIVED_DATE"/>-->
<bm:field name="due_date" databaseType="DATE" datatype="java.util.Date" physicalName="DUE_DATE"/> <!-- <bm:field name="due_date" databaseType="DATE" datatype="java.util.Date" physicalName="DUE_DATE"/>-->
<bm:field name="due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DUE_AMOUNT"/> <!-- <bm:field name="due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DUE_AMOUNT"/>-->
<bm:field name="principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PRINCIPAL"/> <!-- <bm:field name="principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PRINCIPAL"/>-->
<bm:field name="interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST"/> <!-- <bm:field name="interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST"/>-->
<bm:field name="received_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_AMOUNT"/> <!-- <bm:field name="received_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_AMOUNT"/>-->
<bm:field name="received_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_PRINCIPAL"/> <!-- <bm:field name="received_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_PRINCIPAL"/>-->
<bm:field name="received_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_INTEREST"/> <!-- <bm:field name="received_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_INTEREST"/>-->
<bm:field name="billing_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_AMOUNT"/> <!-- <bm:field name="billing_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_AMOUNT"/>-->
<bm:field name="billing_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_PRINCIPAL"/> <!-- <bm:field name="billing_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_PRINCIPAL"/>-->
<bm:field name="billing_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_INTEREST"/> <!-- <bm:field name="billing_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_INTEREST"/>-->
<bm:field name="vat_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_DUE_AMOUNT"/> <!-- <bm:field name="vat_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_DUE_AMOUNT"/>-->
<bm:field name="vat_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_PRINCIPAL"/> <!-- <bm:field name="vat_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_PRINCIPAL"/>-->
<bm:field name="vat_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_INTEREST"/> <!-- <bm:field name="vat_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_INTEREST"/>-->
<bm:field name="net_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_DUE_AMOUNT"/> <!-- <bm:field name="net_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_DUE_AMOUNT"/>-->
<bm:field name="net_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_PRINCIPAL"/> <!-- <bm:field name="net_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_PRINCIPAL"/>-->
<bm:field name="net_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INTEREST"/> <!-- <bm:field name="net_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INTEREST"/>-->
<!-- <bm:field name="currency" databaseType="CHAR" datatype="java.lang.String" physicalName="CURRENCY"/>--> <!-- &lt;!&ndash; <bm:field name="currency" databaseType="CHAR" datatype="java.lang.String" physicalName="CURRENCY"/>&ndash;&gt;-->
<!-- <bm:field name="currency_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CURRENCY_DESC"/>--> <!-- &lt;!&ndash; <bm:field name="currency_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CURRENCY_DESC"/>&ndash;&gt;-->
<bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE"/> <!-- <bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE"/>-->
<bm:field name="exchange_rate_type" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE"/> <!-- <bm:field name="exchange_rate_type" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE"/>-->
<!-- <bm:field name="exchange_rate_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE_DESC"/>--> <!-- &lt;!&ndash; <bm:field name="exchange_rate_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE_DESC"/>&ndash;&gt;-->
<bm:field name="exchange_rate_quotation" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION"/> <!-- <bm:field name="exchange_rate_quotation" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION"/>-->
<!-- <bm:field name="exchange_rate_quotation_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION_DESC"/>--> <!-- &lt;!&ndash; <bm:field name="exchange_rate_quotation_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION_DESC"/>&ndash;&gt;-->
<bm:field name="overdue_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OVERDUE_STATUS"/> <!-- <bm:field name="overdue_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OVERDUE_STATUS"/>-->
<bm:field name="overdue_max_days" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MAX_DAYS"/> <!-- <bm:field name="overdue_max_days" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MAX_DAYS"/>-->
<bm:field name="bp_id_agent_level1"/> <!-- <bm:field name="bp_id_agent_level1"/>-->
<bm:field name="bp_id_agent_level1_n"/> <!-- <bm:field name="bp_id_agent_level1_n"/>-->
<bm:field name="termination_date"/> <!-- <bm:field name="termination_date"/>-->
<bm:field name="lease_channel"/> <!-- <bm:field name="lease_channel"/>-->
<bm:field name="business_type_desc"/> <!-- <bm:field name="business_type_desc"/>-->
<bm:field name="business_type"/> <!-- <bm:field name="business_type"/>-->
<bm:field name="write_off_flag"/> <!-- <bm:field name="write_off_flag"/>-->
<bm:field name="write_off_flag_desc"/> <!-- <bm:field name="write_off_flag_desc"/>-->
</bm:fields> <!-- </bm:fields>-->
<bm:query-fields> <bm:query-fields>
<bm:query-field name="billing_object_code" queryExpression="vv.billing_object_code = ${@billing_object_code}"/> <bm:query-field name="billing_object_code" queryExpression="vv.billing_object_code = ${@billing_object_code}"/>
<!-- <bm:query-field name="billing_object_name" queryExpression="vv.billing_object_name = ${@billing_object_name}"/>--> <!-- <bm:query-field name="billing_object_name" queryExpression="vv.billing_object_name = ${@billing_object_name}"/>-->
<bm:query-field name="cf_item" queryExpression="vv.cf_item = ${@cf_item}"/> <bm:query-field name="cf_item" queryExpression="vv.cf_item = ${@cf_item}"/>
<bm:query-field name="due_date_from" queryExpression="vv.due_date &gt;= to_date(${@due_date_from},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="due_date_from" queryExpression="to_date(vv.due_date,&apos;yyyy-mm-dd&apos;) &gt;= to_date(${@due_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="due_date_to" queryExpression="vv.due_date &lt;= to_date(${@due_date_to},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="due_date_to" queryExpression="to_date(vv.due_date,&apos;yyyy-mm-dd&apos;) &lt;= to_date(${@due_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="overdue_max_days_from" queryExpression="vv.overdue_max_days &gt;= ${@overdue_max_days_from}"/> <!-- <bm:query-field name="overdue_max_days_from" queryExpression="vv.overdue_max_days &gt;= ${@overdue_max_days_from}"/>-->
<bm:query-field name="overdue_max_days_to" queryExpression="vv.overdue_max_days &lt;= ${@overdue_max_days_to}"/> <!-- <bm:query-field name="overdue_max_days_to" queryExpression="vv.overdue_max_days &lt;= ${@overdue_max_days_to}"/>-->
<bm:query-field field="overdue_status" queryExpression="vv.overdue_status=${@overdue_status} and vv.write_off_flag != &apos;FULL&apos;"/> <!-- <bm:query-field name="overdue_status" queryExpression="vv.overdue_status=${@overdue_status} and vv.write_off_flag != &apos;FULL&apos;"/>-->
<bm:query-field field="bill_object_bp_class" queryOperator="="/> <bm:query-field name="bill_object_bp_class" queryExpression="vv.bill_object_bp_class = ${@bill_object_bp_class}"/>
<bm:query-field name="invoice_type_desc" queryExpression="vv.invoice_type_desc like ${@invoice_type_desc}"/> <!-- <bm:query-field name="invoice_type_desc" queryExpression="vv.invoice_type_desc like ${@invoice_type_desc}"/>-->
<bm:query-field name="invoice_title" queryExpression="vv.invoice_title like ${@invoice_title}"/> <!-- <bm:query-field name="invoice_title" queryExpression="vv.invoice_title like ${@invoice_title}"/>-->
<bm:query-field name="project_number_from" queryExpression="vv.project_number &gt;=${@project_number_from}"/> <!-- <bm:query-field name="project_number_from" queryExpression="vv.project_number &gt;=${@project_number_from}"/>-->
<bm:query-field name="project_number_to" queryExpression="vv.project_number &lt;=${@project_number_to}"/> <!-- <bm:query-field name="project_number_to" queryExpression="vv.project_number &lt;=${@project_number_to}"/>-->
<bm:query-field name="contract_number" queryExpression="vv.contract_number like ${@contract_number}"/> <bm:query-field name="contract_number" queryExpression="vv.contract_number like ${@contract_number}"/>
<bm:query-field name="bp_code_tenant_from" queryExpression="vv.billing_object_code &gt;=${@bp_code_tenant_from}"/> <!-- <bm:query-field name="bp_code_tenant_from" queryExpression="vv.billing_object_code &gt;=${@bp_code_tenant_from}"/>-->
<bm:query-field name="bp_code_tenant_to" queryExpression="vv.billing_object_code &lt;=${@bp_code_tenant_to}"/> <!-- <bm:query-field name="bp_code_tenant_to" queryExpression="vv.billing_object_code &lt;=${@bp_code_tenant_to}"/>-->
<bm:query-field name="lease_start_date_from" queryExpression="vv.inception_of_lease &gt;= to_date(${@lease_start_date_from},&apos;yyyy-mm-dd&apos;)"/> <!-- <bm:query-field name="lease_start_date_from" queryExpression="vv.inception_of_lease &gt;= to_date(${@lease_start_date_from},&apos;yyyy-mm-dd&apos;)"/>-->
<bm:query-field name="last_received_date_from" queryExpression="vv.last_received_date &gt;= to_date(${@last_received_date_from},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="last_received_date_from" queryExpression="to_date(vv.last_received_date,&apos;yyyy-mm-dd&apos;) &gt;= to_date(${@last_received_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="lease_start_date_to" queryExpression="vv.inception_of_lease &lt;= to_date(${@lease_start_date_to},&apos;yyyy-mm-dd&apos;)"/> <!-- <bm:query-field name="lease_start_date_to" queryExpression="vv.inception_of_lease &lt;= to_date(${@lease_start_date_to},&apos;yyyy-mm-dd&apos;)"/>-->
<bm:query-field name="last_received_date_to" queryExpression="vv.last_received_date &lt;= to_date(${@last_received_date_to},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="last_received_date_to" queryExpression="to_date(vv.last_received_date,&apos;yyyy-mm-dd&apos;) &lt;= to_date(${@last_received_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/> <!-- <bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/>-->
<bm:query-field name="billing_method" queryExpression="vv.billing_method=${@billing_method}"/> <!-- <bm:query-field name="billing_method" queryExpression="vv.billing_method=${@billing_method}"/>-->
<bm:query-field name="prj_search_term_1" queryExpression="vv.prj_search_term_1=${@prj_search_term_1}"/> <!-- <bm:query-field name="prj_search_term_1" queryExpression="vv.prj_search_term_1=${@prj_search_term_1}"/>-->
<bm:query-field name="prj_search_term_2" queryExpression="vv.prj_search_term_2=${@prj_search_term_2}"/> <!-- <bm:query-field name="prj_search_term_2" queryExpression="vv.prj_search_term_2=${@prj_search_term_2}"/>-->
<bm:query-field name="con_search_term_1" queryExpression="vv.con_search_term_1=${@con_search_term_1}"/> <!-- <bm:query-field name="con_search_term_1" queryExpression="vv.con_search_term_1=${@con_search_term_1}"/>-->
<bm:query-field name="con_search_term_2" queryExpression="vv.con_search_term_2=${@con_search_term_2}"/> <!-- <bm:query-field name="con_search_term_2" queryExpression="vv.con_search_term_2=${@con_search_term_2}"/>-->
<bm:query-field name="bp_name" queryExpression="t1.bp_name like &apos;%&apos;||${@bp_name}||&apos;%&apos; "/> <!-- <bm:query-field name="bp_name" queryExpression="t1.bp_name like &apos;%&apos;||${@bp_name}||&apos;%&apos; "/>-->
<bm:query-field name="project_name" queryExpression="vv.project_name like &apos;%&apos;||${@project_name}||&apos;%&apos; "/> <!-- <bm:query-field name="project_name" queryExpression="vv.project_name like &apos;%&apos;||${@project_name}||&apos;%&apos; "/>-->
<bm:query-field name="contract_name" queryExpression="vv.contract_name like &apos;%&apos;||${@contract_name}||&apos;%&apos; "/> <!-- <bm:query-field name="contract_name" queryExpression="vv.contract_name like &apos;%&apos;||${@contract_name}||&apos;%&apos; "/>-->
<bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/> <!-- <bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/>-->
<bm:query-field name="business_type" queryExpression="vv.business_type=${@business_type}"/> <bm:query-field name="business_type" queryExpression="vv.business_type=${@business_type}"/>
<bm:query-field name="write_off_flag" queryExpression="vv.write_off_flag=${@write_off_flag}"/> <bm:query-field name="write_off_flag" queryExpression="vv.write_off_flag=${@write_off_flag}"/>
<bm:query-field name="contract_status" queryExpression="vv.contract_status = ${@contract_status}"/> <bm:query-field name="contract_status" queryExpression="vv.contract_status = ${@contract_status}"/>
<bm:query-field name="bp_id_agent_level1_n" queryExpression="vv.bp_id_agent_level1 = ${@bp_id_agent_level1}"/> <bm:query-field name="bp_id_agent_level1" queryExpression="vv.bp_id_agent_level1 = ${@bp_id_agent_level1}"/>
<!-- <bm:query-field name="bp_id_agent_level1_n" queryExpression="vv.bp_id_agent_level1_n like &apos;%&apos;||${@bp_id_agent_level1_n}||&apos;%&apos;"/>--> <!-- <bm:query-field name="bp_id_agent_level1_n" queryExpression="vv.bp_id_agent_level1_n like &apos;%&apos;||${@bp_id_agent_level1_n}||&apos;%&apos;"/>-->
<bm:query-field name="termination_date_from" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &gt;= to_date(${@termination_date_from},&apos;yyyy-mm-dd&apos;)"/> <!-- <bm:query-field name="termination_date_from" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &gt;= to_date(${@termination_date_from},&apos;yyyy-mm-dd&apos;)"/>-->
<bm:query-field name="termination_date_to" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &lt;= to_date(${@termination_date_to},&apos;yyyy-mm-dd&apos;)"/> <!-- <bm:query-field name="termination_date_to" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &lt;= to_date(${@termination_date_to},&apos;yyyy-mm-dd&apos;)"/>-->
<bm:query-field name="lease_channel" queryExpression="t1.lease_channel=${@lease_channel}"/> <!-- <bm:query-field name="lease_channel" queryExpression="t1.lease_channel=${@lease_channel}"/>-->
<bm:query-field name="project_number" queryExpression="t1.project_number like &apos;%&apos;|| ${@project_number}||&apos;%&apos;"/> <!-- <bm:query-field name="project_number" queryExpression="t1.project_number like &apos;%&apos;|| ${@project_number}||&apos;%&apos;"/>-->
<bm:query-field name="inv_object_taxpayer_type" queryExpression="vv.inv_object_taxpayer_type =${@inv_object_taxpayer_type}"/> <!-- <bm:query-field name="inv_object_taxpayer_type" queryExpression="vv.inv_object_taxpayer_type =${@inv_object_taxpayer_type}"/>-->
<bm:query-field name="object_taxpayer_type" queryExpression="vv.object_taxpayer_type =${@object_taxpayer_type}"/> <bm:query-field name="object_taxpayer_type" queryExpression="vv.object_taxpayer_type =${@object_taxpayer_type}"/>
<bm:query-field name="ccr_document_type" queryExpression="vv.ccr_document_type =${@ccr_document_type}"/>
</bm:query-fields> </bm:query-fields>
<bm:data-filters> <bm:data-filters>
<bm:data-filter enforceOperations="query" expression="vv.contract_status not in ('CANCEL')"/> <bm:data-filter enforceOperations="query" expression="vv.contract_status not in ('CANCEL')"/>
......
<?xml version="1.0" encoding="UTF-8"?>
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT *
FROM (SELECT *
FROM (select t1.spv_company_id,
NULL journal_header_id,
NULL journal_line_id,
t1.company_id,
t1.project_id,
t1.contract_id,
t1.contract_number,
t1.contract_name,
t1.inception_of_lease,
t1.contract_status,
t1.contract_status_desc,
t1.billing_method,
t1.billing_method_desc,
t1.inv_object_taxpayer_type,
t1.inv_object_taxpayer_type_desc,
decode(t2.cf_item,
'250',
t1.inv_billing_object_id,
t1.billing_object_id) billing_object_id,
decode(t2.cf_item,
'250',
t1.inv_billing_object_code,
t1.billing_object_code) billing_object_code,
decode(t2.cf_item,
'250',
t1.inv_billing_object_name,
t1.billing_object_name) billing_object_name,
decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) object_taxpayer_type,
decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type_desc,
t1.object_taxpayer_type_desc) object_taxpayer_type_desc,
-- t1.object_taxpayer_type_desc,
decode(t2.cf_item,
'250',
t1.inv_object_tax_registry_num,
t1.object_tax_registry_num) object_tax_registry_num,
decode(t2.cf_item,
'250',
t1.inv_bill_object_bp_class,
t1.bill_object_bp_class) bill_object_bp_class,
decode(t2.cf_item,
'250',
t1.inv_bill_object_bp_class_desc,
t1.bill_object_bp_class_desc) bill_object_bp_class_desc,
t1.tax_type_vat,
t1.description,
decode(t2.cf_item,
'250',
t1.inv_invoice_title,
t1.invoice_title) invoice_title,
decode(t2.cf_item,
'250',
t1.inv_bp_address_phone_num,
t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num,
decode(t2.cf_item,
'250',
t1.inv_invoice_bp_bank_account,
t1.invoice_bp_bank_account) invoice_bp_bank_account,
decode(t2.cf_item,
'250',
t1.inv_tax_registry_num,
t1.tax_registry_num) tax_registry_num,
t1.document_type,
t1.bp_name,
decode(t2.cf_item,
'250',
t1.inv_invoice_type_desc,
t1.invoice_type_desc) invoice_type_desc,
t2.cashflow_id,
t2.cf_item,
(Select i.description
From hls_cashflow_item i
Where i.cf_item = t2.cf_item) As cf_item_desc,
t2.times,
t2.last_received_date,
t2.due_date,
t2.due_amount,
to_char((SELECT wm_concat(distinct
c.bp_bank_account_name)
FROM csh_transaction c
WHERE c.transaction_id IN
(SELECT coo.csh_transaction_id
FROM csh_write_off coo
WHERE coo.cashflow_id = t2.cashflow_id))) account_name,
decode(t1.lease_channel, '01', null, t2.principal) principal,
decode(t1.lease_channel, '01', null, t2.interest) interest,
t2.received_amount,
decode(t1.lease_channel,
'01',
null,
t2.received_principal) received_principal,
decode(t1.lease_channel,
'01',
null,
t2.received_interest) received_interest,
t2.billing_amount,
t2.billing_principal,
t2.billing_interest,
t2.vat_due_amount,
t2.vat_principal,
t2.vat_interest,
t2.net_due_amount,
t2.net_principal,
t2.net_interest,
t2.exchange_rate,
t2.exchange_rate_type,
t2.exchange_rate_quotation,
t2.overdue_status,
t2.overdue_max_days,
t1.bp_id_agent_level1,
t1.bp_id_agent_level1_n,
t1.termination_date,
t1.lease_channel,
t2.cf_direction,
t2.billing_status,
t2.cf_status,
t1.business_type,
t1.business_type_desc,
t2.write_off_flag,
case t2.write_off_flag when 'NOT' then
'未核销'
when 'PARTIAL' then '部分核销'
when 'FULL' then '全部核销'
end as write_off_flag_desc
from cus_acr_invoice_contract_v t1,
con_contract_cashflow t2
where t1.contract_id = t2.contract_id
and t1.bp_wfl_status = 'APPROVED'
and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
((t1.bill_object_bp_class = 'NP' and
t1.inv_billing_object_code <> 'D00000009' AND
(((to_number(to_char(sysdate, 'MM')) in
(3, 6, 9, 12) and trunc(t2.due_date) <= sysdate
and ((to_number(to_char(t2.due_date, 'MM')) in
(3, 6, 9, 12)) or
(to_number(to_char(t2.due_date, 'MM')) in
(1, 4, 7, 10) and
nextduedate(t2.due_date, 2, 1) <= sysdate) or
(to_number(to_char(t2.due_date, 'MM')) in
(2, 5, 8, 11) and
nextduedate(t2.due_date, 1, 1) <= sysdate))
) or (
to_number(to_char(sysdate, 'MM')) in (1, 2) and
trunc(t2.due_date) <=
(trunc(sysdate, 'yyyy') - 1)) or
(
to_number(to_char(sysdate, 'MM')) in (4, 5) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-03',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (7, 8) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-06',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (10, 11) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-09',
'yyyy-mm'))) and t1.contract_status not in ('TERMINATE', 'ET','TERMINATING','ETING'))or
t1.contract_status in ('TERMINATE', 'ET','TERMINATING','ETING'))) or
((t1.bill_object_bp_class = 'ORG' or
(t1.inv_billing_object_code = 'D00000009' and
t1.bill_object_bp_class = 'NP')) AND
t1.contract_status in ('TERMINATE', 'ET', 'REPUR','TERMINATING','ETING','REPURING')))))
and ((decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) =
'SMALL_SCALE_TAXPAYER' and
to_char(t2.due_date, 'yyyy-mm') <=
to_char(SYSDATE, 'yyyy-mm')) or
(t2.write_off_flag = 'FULL' and
t1.contract_status not in ('REPURING', 'REPUR')) or
(nvl(t2.write_off_flag, 'NOT') = 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item <> 1) or
(nvl(t2.write_off_flag, 'NOT') <> 'NOT' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1))
AND cf_item <> 9
AND ((t2.cf_status = 'RELEASE' and
t1.contract_status not in ('REPURING', 'REPUR') and
t2.cf_direction = 'INFLOW') or
(t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item in (1, 2, 250) and
t2.cf_status = 'RELEASE') or
(t2.cf_status in ('BLOCK') and
nvl(t2.write_off_flag, 'NOT') = 'PARTIAL' and
nvl(t2.billing_status, 'NOT') != 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1 and t2.cf_direction = 'NONCASH' and
nvl(t2.billing_amount, 0) <> t2.received_amount))
and t2.cashflow_id not in (20265, 34267, 24445)
and nvl(t2.billing_status, 'NOT') != 'FULL'
--and t2.cf_direction='INFLOW'
and ((decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) <>
'SMALL_SCALE_TAXPAYER' and received_amount > 0) OR
(decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) =
'SMALL_SCALE_TAXPAYER'))
ORDER BY t1.contract_id, t2.due_date)
UNION ALL
select t1.spv_company_id,
t2.journal_header_id,
t2.journal_line_id,
t1.company_id,
t1.project_id,
t1.contract_id,
t1.contract_number,
t1.contract_name,
t1.inception_of_lease,
t1.contract_status,
t1.contract_status_desc,
t1.billing_method,
t1.billing_method_desc,
t1.inv_object_taxpayer_type,
t1.inv_object_taxpayer_type_desc,
(t1.billing_object_id) billing_object_id,
(t1.billing_object_code) billing_object_code,
(t1.billing_object_name) billing_object_name,
(t1.object_taxpayer_type) object_taxpayer_type,
(t1.object_taxpayer_type_desc) object_taxpayer_type_desc,
-- t1.object_taxpayer_type_desc,
(t1.object_tax_registry_num) object_tax_registry_num,
(t1.bill_object_bp_class) bill_object_bp_class,
(t1.bill_object_bp_class_desc) bill_object_bp_class_desc,
t1.tax_type_vat,
t1.description,
(t1.invoice_title) invoice_title,
(t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num,
(t1.invoice_bp_bank_account) invoice_bp_bank_account,
(t1.tax_registry_num) tax_registry_num,
t1.document_type,
t1.bp_name,
(t1.invoice_type_desc) invoice_type_desc,
NULL cashflow_id,
9 cf_item,
(SELECT t.description
FROM hls_cashflow_item t
WHERE t.cf_item = 9) cf_item_desc,
null times,
t2.transaction_date last_received_date,
NULL due_date,
NULL due_amount,
(SELECT c.bp_bank_account_name
FROM csh_transaction c
WHERE c.transaction_id = t2.csh_transaction_id) account_name,
--NULL account_name,
NULL principal,
NULL interest,
t2.amount_dr received_amount,
NULL received_principal,
NULL received_interest,
nvl((SELECT SUM(l.total_amount)
FROM acr_invoice_ln l
WHERE l.ref_n04 = t2.journal_line_id),
0) billing_amount,
NULL billing_principal,
NULL billing_interest,
NULL vat_due_amount,
NULL vat_principal,
NULL vat_interest,
NULL net_due_amount,
NULL net_principal,
NULL net_interest,
NULL exchange_rate,
NULL exchange_rate_type,
NULL exchange_rate_quotation,
NULL overdue_status,
NULL overdue_max_days,
t1.bp_id_agent_level1,
t1.bp_id_agent_level1_n,
t1.termination_date,
t1.lease_channel,
NULL cf_direction,
NULL billing_status,
NULL cf_status,
t1.business_type,
t1.business_type_desc,
'FULL' as write_off_flag,
'全部核销' as write_off_flag_desc
from cus_acr_invoice_contract_v t1, acr_invoice_penalty_v t2
where t2.contract_id = t1.contract_id
and t1.bp_wfl_status = 'APPROVED'
and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
t1.contract_status in ('TERMINATE', 'ET', 'REPUR')))
AND NOT EXISTS (SELECT 1
FROM acr_invoice_ln l, acr_invoice_hd h
WHERE l.invoice_hd_id = h.invoice_hd_id
and h.contract_id = t2.contract_id
and l.cf_item = 9
and l.ref_n04 = t2.journal_line_id
and l.ref_n03 = t2.journal_header_id
group by t2.journal_line_id
having sum(l.total_amount) = t2.amount_dr)
) vv
#WHERE_CLAUSE#
]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:fields>
<bm:field name="spv_company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="SPV_COMPANY_ID"/>
<bm:field name="journal_header_id" databaseType="NUMBER" datatype="java.lang.Long"/>
<bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long"/>
<bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/>
<bm:field name="project_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROJECT_ID"/>
<!-- <bm:field name="project_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NUMBER"/>-->
<!-- <bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/>-->
<bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" required="true"/>
<bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER"/>
<bm:field name="contract_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NAME"/>
<bm:field name="inception_of_lease" databaseType="DATE" datatype="java.util.Date" physicalName="INCEPTION_OF_LEASE"/>
<bm:field name="contract_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS" required="true"/>
<bm:field name="contract_status_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_STATUS_DESC"/>
<bm:field name="account_name" databaseType="VARCHAR2" datatype="java.lang.String"/>
<bm:field name="billing_method" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD"/>
<bm:field name="billing_method_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_METHOD_DESC"/>
<bm:field name="inv_object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type"/>
<bm:field name="inv_object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="inv_object_taxpayer_type_desc"/>
<bm:field name="billing_object_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="BILLING_OBJECT_ID"/>
<bm:field name="billing_object_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_CODE"/>
<bm:field name="billing_object_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILLING_OBJECT_NAME"/>
<bm:field name="object_taxpayer_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE"/>
<bm:field name="object_taxpayer_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAXPAYER_TYPE_DESC"/>
<bm:field name="object_tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OBJECT_TAX_REGISTRY_NUM"/>
<bm:field name="bill_object_bp_class" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS"/>
<bm:field name="bill_object_bp_class_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BILL_OBJECT_BP_CLASS_DESC"/>
<bm:field name="tax_type_vat" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_TYPE_VAT"/>
<bm:field name="description" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DESCRIPTION"/>
<bm:field name="invoice_title" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TITLE"/>
<bm:field name="invoice_bp_address_phone_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_ADDRESS_PHONE_NUM"/>
<bm:field name="invoice_bp_bank_account" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_BANK_ACCOUNT"/>
<bm:field name="tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_REGISTRY_NUM"/>
<!-- <bm:field name="prj_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRJ_SEARCH_TERM_1"/>-->
<!-- <bm:field name="prj_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRJ_SEARCH_TERM_2"/>-->
<!-- <bm:field name="con_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CON_SEARCH_TERM_1"/>-->
<!-- <bm:field name="con_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CON_SEARCH_TERM_2"/>-->
<bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" required="true"/>
<bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_NAME"/>
<bm:field name="invoice_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TYPE_DESC"/>
<bm:field name="cashflow_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CASHFLOW_ID"/>
<bm:field name="cf_item" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CF_ITEM" required="true"/>
<bm:field name="cf_item_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CF_ITEM_DESC"/>
<bm:field name="times" databaseType="NUMBER" datatype="java.lang.Long" physicalName="TIMES"/>
<bm:field name="last_received_date" databaseType="DATE" datatype="java.util.Date" physicalName="LAST_RECEIVED_DATE"/>
<bm:field name="due_date" databaseType="DATE" datatype="java.util.Date" physicalName="DUE_DATE"/>
<bm:field name="due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="DUE_AMOUNT"/>
<bm:field name="principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="PRINCIPAL"/>
<bm:field name="interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="INTEREST"/>
<bm:field name="received_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_AMOUNT"/>
<bm:field name="received_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_PRINCIPAL"/>
<bm:field name="received_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="RECEIVED_INTEREST"/>
<bm:field name="billing_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_AMOUNT"/>
<bm:field name="billing_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_PRINCIPAL"/>
<bm:field name="billing_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="BILLING_INTEREST"/>
<bm:field name="vat_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_DUE_AMOUNT"/>
<bm:field name="vat_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_PRINCIPAL"/>
<bm:field name="vat_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="VAT_INTEREST"/>
<bm:field name="net_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_DUE_AMOUNT"/>
<bm:field name="net_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_PRINCIPAL"/>
<bm:field name="net_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INTEREST"/>
<!-- <bm:field name="currency" databaseType="CHAR" datatype="java.lang.String" physicalName="CURRENCY"/>-->
<!-- <bm:field name="currency_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CURRENCY_DESC"/>-->
<bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE"/>
<bm:field name="exchange_rate_type" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE"/>
<!-- <bm:field name="exchange_rate_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE_DESC"/>-->
<bm:field name="exchange_rate_quotation" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION"/>
<!-- <bm:field name="exchange_rate_quotation_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION_DESC"/>-->
<bm:field name="overdue_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OVERDUE_STATUS"/>
<bm:field name="overdue_max_days" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MAX_DAYS"/>
<bm:field name="bp_id_agent_level1"/>
<bm:field name="bp_id_agent_level1_n"/>
<bm:field name="termination_date"/>
<bm:field name="lease_channel"/>
<bm:field name="business_type_desc"/>
<bm:field name="business_type"/>
<bm:field name="write_off_flag"/>
<bm:field name="write_off_flag_desc"/>
</bm:fields>
<bm:query-fields>
<bm:query-field name="billing_object_code" queryExpression="vv.billing_object_code = ${@billing_object_code}"/>
<!-- <bm:query-field name="billing_object_name" queryExpression="vv.billing_object_name = ${@billing_object_name}"/>-->
<bm:query-field name="cf_item" queryExpression="vv.cf_item = ${@cf_item}"/>
<bm:query-field name="due_date_from" queryExpression="vv.due_date &gt;= to_date(${@due_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="due_date_to" queryExpression="vv.due_date &lt;= to_date(${@due_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="overdue_max_days_from" queryExpression="vv.overdue_max_days &gt;= ${@overdue_max_days_from}"/>
<bm:query-field name="overdue_max_days_to" queryExpression="vv.overdue_max_days &lt;= ${@overdue_max_days_to}"/>
<bm:query-field field="overdue_status" queryExpression="vv.overdue_status=${@overdue_status} and vv.write_off_flag != &apos;FULL&apos;"/>
<bm:query-field field="bill_object_bp_class" queryOperator="="/>
<bm:query-field name="invoice_type_desc" queryExpression="vv.invoice_type_desc like ${@invoice_type_desc}"/>
<bm:query-field name="invoice_title" queryExpression="vv.invoice_title like ${@invoice_title}"/>
<bm:query-field name="project_number_from" queryExpression="vv.project_number &gt;=${@project_number_from}"/>
<bm:query-field name="project_number_to" queryExpression="vv.project_number &lt;=${@project_number_to}"/>
<bm:query-field name="contract_number" queryExpression="vv.contract_number like ${@contract_number}"/>
<bm:query-field name="bp_code_tenant_from" queryExpression="vv.billing_object_code &gt;=${@bp_code_tenant_from}"/>
<bm:query-field name="bp_code_tenant_to" queryExpression="vv.billing_object_code &lt;=${@bp_code_tenant_to}"/>
<bm:query-field name="lease_start_date_from" queryExpression="vv.inception_of_lease &gt;= to_date(${@lease_start_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="last_received_date_from" queryExpression="vv.last_received_date &gt;= to_date(${@last_received_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="lease_start_date_to" queryExpression="vv.inception_of_lease &lt;= to_date(${@lease_start_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="last_received_date_to" queryExpression="vv.last_received_date &lt;= to_date(${@last_received_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/>
<bm:query-field name="billing_method" queryExpression="vv.billing_method=${@billing_method}"/>
<bm:query-field name="prj_search_term_1" queryExpression="vv.prj_search_term_1=${@prj_search_term_1}"/>
<bm:query-field name="prj_search_term_2" queryExpression="vv.prj_search_term_2=${@prj_search_term_2}"/>
<bm:query-field name="con_search_term_1" queryExpression="vv.con_search_term_1=${@con_search_term_1}"/>
<bm:query-field name="con_search_term_2" queryExpression="vv.con_search_term_2=${@con_search_term_2}"/>
<bm:query-field name="bp_name" queryExpression="t1.bp_name like &apos;%&apos;||${@bp_name}||&apos;%&apos; "/>
<bm:query-field name="project_name" queryExpression="vv.project_name like &apos;%&apos;||${@project_name}||&apos;%&apos; "/>
<bm:query-field name="contract_name" queryExpression="vv.contract_name like &apos;%&apos;||${@contract_name}||&apos;%&apos; "/>
<bm:query-field name="document_type" queryExpression="vv.document_type=${@document_type}"/>
<bm:query-field name="business_type" queryExpression="vv.business_type=${@business_type}"/>
<bm:query-field name="write_off_flag" queryExpression="vv.write_off_flag=${@write_off_flag}"/>
<bm:query-field name="contract_status" queryExpression="vv.contract_status = ${@contract_status}"/>
<bm:query-field name="bp_id_agent_level1_n" queryExpression="vv.bp_id_agent_level1 = ${@bp_id_agent_level1}"/>
<!-- <bm:query-field name="bp_id_agent_level1_n" queryExpression="vv.bp_id_agent_level1_n like &apos;%&apos;||${@bp_id_agent_level1_n}||&apos;%&apos;"/>-->
<bm:query-field name="termination_date_from" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &gt;= to_date(${@termination_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="termination_date_to" queryExpression="to_date(t1.termination_date,&apos;yyyy-mm-dd&apos;) &lt;= to_date(${@termination_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="lease_channel" queryExpression="t1.lease_channel=${@lease_channel}"/>
<bm:query-field name="project_number" queryExpression="t1.project_number like &apos;%&apos;|| ${@project_number}||&apos;%&apos;"/>
<bm:query-field name="inv_object_taxpayer_type" queryExpression="vv.inv_object_taxpayer_type =${@inv_object_taxpayer_type}"/>
<bm:query-field name="object_taxpayer_type" queryExpression="vv.object_taxpayer_type =${@object_taxpayer_type}"/>
</bm:query-fields>
<bm:data-filters>
<bm:data-filter enforceOperations="query" expression="vv.contract_status not in ('CANCEL')"/>
<!--<bm:data-filter enforceOperations="query" expression="t1.contract_id = vv.contract_id"/>-->
<!-- <bm:data-filter name="contract_status" enforceOperations="query" expression="vv.contract_status in(&apos;NEW&apos;,&apos;INCEPT&apos;,&apos;ETING&apos;,&apos;REPURING&apos;,&apos;CLOSED&apos;)"/>-->
</bm:data-filters>
</bm:model>
...@@ -108,7 +108,7 @@ SELECT h.period_year, ...@@ -108,7 +108,7 @@ SELECT h.period_year,
WHERE h.journal_header_id = l.journal_header_id WHERE h.journal_header_id = l.journal_header_id
and h.sbo_num is not null and h.sbo_num is not null
and ga.account_id=l.account_id and ga.account_id=l.account_id
and ga.account_code='2221001020' and ga.account_code in('2221001020','2221001023')
and h.reversed_flag='N' and h.reversed_flag='N'
AND ((h.je_transaction_code IN AND ((h.je_transaction_code IN
('HL_SALES_TAX_ACT_NEW', 'HL_CSH_CONSOLIDATION_DALAY') ('HL_SALES_TAX_ACT_NEW', 'HL_CSH_CONSOLIDATION_DALAY')
......
...@@ -108,7 +108,7 @@ SELECT h.period_year, ...@@ -108,7 +108,7 @@ SELECT h.period_year,
WHERE h.journal_header_id = l.journal_header_id WHERE h.journal_header_id = l.journal_header_id
and h.sbo_num is not null and h.sbo_num is not null
and ga.account_id=l.account_id and ga.account_id=l.account_id
and ga.account_code='2221001020' and ga.account_code in('2221001020','2221001023')
and h.reversed_flag='N' and h.reversed_flag='N'
AND ((h.je_transaction_code IN AND ((h.je_transaction_code IN
('HL_SALES_TAX_ACT_NEW', 'HL_CSH_CONSOLIDATION_DALAY') ('HL_SALES_TAX_ACT_NEW', 'HL_CSH_CONSOLIDATION_DALAY')
......
var jacob_config = { var jacob_config = {
jacobUrl : "http://10.40.128.182:8080/core/jacob/", jacobUrl : "http://10.203.0.125:8082/hlcm_leasing/jacob/",
jacobserviceUrl : "http://10.40.128.186:8091/jacob/jacob/", jacobserviceUrl : "http://10.203.0.125:8083/jacob/jacob/",
target_path : "C://hls_file/ds_hls/excel/" target_path : "D:\\"
}; };
\ No newline at end of file
...@@ -271,16 +271,26 @@ ...@@ -271,16 +271,26 @@
<a:record code_value="FULL" code_value_name="全部核销"/> <a:record code_value="FULL" code_value_name="全部核销"/>
</a:datas> </a:datas>
</a:dataSet> </a:dataSet>
<a:dataSet id="ccr_document_type_ds">
<a:datas>
<a:record code_value="LEASE_CHAG" code_value_name="承租人变更"/>
<a:record code_value="CUT_CHAG" code_value_name="租金计划变更"/>
<a:record code_value="ACC_CHAG" code_value_name="回款账户变更"/>
<a:record code_value="ET_CHAG" code_value_name="提前结清"/>
<a:record code_value="REPUR" code_value_name="解约回购"/>
</a:datas>
</a:dataSet>
<a:dataSet id="allConditionDs" autoCreate="true"> <a:dataSet id="allConditionDs" autoCreate="true">
<a:fields> <a:fields>
<a:field name="business_type"/> <a:field name="business_type"/>
<a:field name="bill_object_bp_class"/> <a:field name="bill_object_bp_class"/>
<a:field name="business_type_desc" displayField="code_value_name" options="business_type_desc_ds" <a:field name="business_type_desc" displayField="code_value_name" options="business_type_desc_ds"
returnField="business_type" valueField="code_value"/> returnField="business_type" valueField="code_value"/>
<a:field name="ccr_document_type"/>
<a:field name="write_off_flag_desc" displayField="code_value_name" options="write_off_flag_ds" <a:field name="write_off_flag_desc" displayField="code_value_name" options="write_off_flag_ds"
returnField="write_off_flag" valueField="code_value"/> returnField="write_off_flag" valueField="code_value"/>
<a:field name="ccr_document_type_desc" displayField="code_value_name" options="ccr_document_type_ds"
returnField="ccr_document_type" valueField="code_value"/>
<a:field name="object_taxpayer_type_desc" displayField="code_value_name" options="taxpayer_type_ds" <a:field name="object_taxpayer_type_desc" displayField="code_value_name" options="taxpayer_type_ds"
returnField="object_taxpayer_type" valueField="code_value"/> returnField="object_taxpayer_type" valueField="code_value"/>
<a:field name="bill_object_bp_class_desc" displayField="code_value_name" options="acr510_bp_class" <a:field name="bill_object_bp_class_desc" displayField="code_value_name" options="acr510_bp_class"
...@@ -404,8 +414,8 @@ ...@@ -404,8 +414,8 @@
<a:event name="update" handler="queryUpdateFunction"/> <a:event name="update" handler="queryUpdateFunction"/>
</a:events> </a:events>
</a:dataSet> </a:dataSet>
<a:dataSet id="ar510n_cashflow_ds" autoPageSize="true" model="acr.ACR510.acr_invoice_cf_v_new" <a:dataSet id="ar510n_cashflow_ds" autoQuery="true" autoPageSize="true" model="acr.ACR510.acr_invoice_cf_v_new"
queryDataSet="allConditionDs" selectable="true"> queryDataSet="allConditionDs" selectable="true" queryUrl="${/request/@context_path}/autocrud/acr.ACR510.acr_invoice_cf_v_new/query">
<a:fields> <a:fields>
<a:field name="invoice_title" required="true"/> <a:field name="invoice_title" required="true"/>
<a:field name="object_tax_registry_num" validator="validate_contractDs" prompt="纳税人识别号"/> <a:field name="object_tax_registry_num" validator="validate_contractDs" prompt="纳税人识别号"/>
...@@ -436,10 +446,10 @@ ...@@ -436,10 +446,10 @@
<a:screenTitle/> <a:screenTitle/>
<a:gridButton click="contractDs_grid_query" text="HLS.QUERY"/> <a:gridButton click="contractDs_grid_query" text="HLS.QUERY"/>
<a:gridButton click="allConditionDs_reset" text="重置条件"/> <a:gridButton click="allConditionDs_reset" text="重置条件"/>
<a:gridButton click="contractDs_grid_clear" text="ACR510.BUTTON.CLEAR_CONTRACT"/> <!-- <a:gridButton click="contractDs_grid_clear" text="ACR510.BUTTON.CLEAR_CONTRACT"/>-->
<a:gridButton click="invoiceHd_confirm" text="ACR510.BUTTON.COMFIRM"/> <a:gridButton click="invoiceHd_confirm" text="ACR510.BUTTON.COMFIRM"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form id="condition_queryForm" marginWidth="55"> <a:form id="condition_queryForm" marginWidth="10">
<a:hBox> <a:hBox>
<a:lov name="billing_object_name" bindTarget="allConditionDs" prompt="开票对象"/> <a:lov name="billing_object_name" bindTarget="allConditionDs" prompt="开票对象"/>
...@@ -466,6 +476,7 @@ ...@@ -466,6 +476,7 @@
</a:hBox> </a:hBox>
<a:hBox> <a:hBox>
<a:comboBox name="write_off_flag_desc" bindTarget="allConditionDs" prompt="核销标识"/> <a:comboBox name="write_off_flag_desc" bindTarget="allConditionDs" prompt="核销标识"/>
<a:comboBox name="ccr_document_type_desc" bindTarget="allConditionDs" prompt="变更类型"/>
</a:hBox> </a:hBox>
<!-- <a:formBody column="4" labelWidth="400"> <!-- <a:formBody column="4" labelWidth="400">
<a:lov name="contract_number_from" bindTarget="allConditionDs" prompt="HLS.CONTRACT_NUMBER_FROM"/> <a:lov name="contract_number_from" bindTarget="allConditionDs" prompt="HLS.CONTRACT_NUMBER_FROM"/>
...@@ -491,7 +502,7 @@ ...@@ -491,7 +502,7 @@
<a:datePicker name="termination_date_to" bindTarget="allConditionDs" prompt="结清日期到"/>&ndash;&gt; <a:datePicker name="termination_date_to" bindTarget="allConditionDs" prompt="结清日期到"/>&ndash;&gt;
</a:formBody>--> </a:formBody>-->
</a:form> </a:form>
<a:tabPanel id="acr510n_detail_tabpanel_id" marginHeight="140" marginWidth="50"> <a:tabPanel id="acr510n_detail_tabpanel_id" marginHeight="160" marginWidth="10">
<a:tabs> <a:tabs>
<a:tab prompt="开票信息" width="150"> <a:tab prompt="开票信息" width="150">
<a:grid id="cashflowDs_grid" bindTarget="ar510n_cashflow_ds" marginHeight="170" marginWidth="70" <a:grid id="cashflowDs_grid" bindTarget="ar510n_cashflow_ds" marginHeight="170" marginWidth="70"
...@@ -499,17 +510,17 @@ ...@@ -499,17 +510,17 @@
<a:columns> <a:columns>
<!--<a:column name="invoice_type_desc" prompt="发票类型"/>--> <!--<a:column name="invoice_type_desc" prompt="发票类型"/>-->
<!--<a:column name="object_taxpayer_type_desc" prompt="纳税人类型"/>--> <!--<a:column name="object_taxpayer_type_desc" prompt="纳税人类型"/>-->
<a:column name="contract_number" lock="true" prompt="合同编号" width="150"/> <a:column name="contract_number" lock="true" prompt="合同编号" width="100"/>
<a:column name="billing_object_name" prompt="发票抬头"/> <a:column name="billing_object_name" prompt="发票抬头"/>
<a:column name="bp_id_agent_level1_n" prompt="代理店"/> <a:column name="bp_id_agent_level1_n" prompt="代理店" width="170"/>
<a:column name="business_type_desc" prompt="业务类型"/> <a:column name="business_type_desc" prompt="业务类型" align="center" width="70"/>
<a:column name="times" align="right" lock="true" prompt="期数" width="40"/> <a:column name="times" align="right" lock="true" prompt="期数" width="40"/>
<a:column name="cf_item_desc" lock="true" prompt="应收项目"/> <a:column name="cf_item_desc" lock="true" prompt="应收项目" align="center"/>
<a:column name="due_date" prompt="应收日" renderer="Leaf.formatDate"/> <a:column name="due_date" prompt="应收日" align="center"/>
<a:column name="due_amount" align="right" prompt="应收金额" renderer="Leaf.formatMoney"/> <a:column name="due_amount" align="right" prompt="应收金额" renderer="Leaf.formatMoney"/>
<a:column name="principal" align="right" prompt="本金" renderer="Leaf.formatMoney"/> <a:column name="principal" align="right" prompt="本金" renderer="Leaf.formatMoney"/>
<a:column name="interest" align="right" prompt="利息" renderer="Leaf.formatMoney"/> <a:column name="interest" align="right" prompt="利息" renderer="Leaf.formatMoney"/>
<a:column name="account_name" prompt="收款户名"/> <!-- <a:column name="account_name" prompt="收款户名"/>-->
<a:column name="received_amount" align="right" prompt="已收金额" <a:column name="received_amount" align="right" prompt="已收金额"
renderer="Leaf.formatMoney"/> renderer="Leaf.formatMoney"/>
<a:column name="received_principal" align="right" prompt="已收本金" <a:column name="received_principal" align="right" prompt="已收本金"
...@@ -522,7 +533,7 @@ ...@@ -522,7 +533,7 @@
renderer="Leaf.formatMoney"/> renderer="Leaf.formatMoney"/>
<!-- <a:column name="billing_principal" align="right" prompt="已开票本金" renderer="Leaf.formatMoney"/> <!-- <a:column name="billing_principal" align="right" prompt="已开票本金" renderer="Leaf.formatMoney"/>
<a:column name="billing_interest" align="right" prompt="已开票利息" renderer="Leaf.formatMoney"/>--> <a:column name="billing_interest" align="right" prompt="已开票利息" renderer="Leaf.formatMoney"/>-->
<a:column name="last_received_date" prompt="最后收款日" renderer="Leaf.formatDate"/> <a:column name="last_received_date" align="center" prompt="最后收款日" renderer="Leaf.formatDate"/>
<!-- <!--
<a:column name="termination_date" prompt="正常结清日" renderer="Leaf.formatDate"/> <a:column name="termination_date" prompt="正常结清日" renderer="Leaf.formatDate"/>
--> -->
...@@ -541,22 +552,24 @@ ...@@ -541,22 +552,24 @@
<a:columns> <a:columns>
<!--<a:column name="invoice_type_desc" prompt="发票类型"/>--> <!--<a:column name="invoice_type_desc" prompt="发票类型"/>-->
<!--<a:column name="object_taxpayer_type_desc" prompt="纳税人类型"/>--> <!--<a:column name="object_taxpayer_type_desc" prompt="纳税人类型"/>-->
<a:column name="contract_number" prompt="合同编号" width="150"/> <a:column name="contract_number" prompt="合同编号" align="center" width="100"/>
<a:column name="contract_status_desc" prompt="合同状态" width="80"/> <a:column name="contract_status_desc" prompt="合同状态" align="center" width="80"/>
<a:column name="billing_method_desc" prompt="开票规则" width="80"/> <a:column name="billing_method_desc" prompt="开票规则" width="155"/>
<a:column name="billing_object_name" autoAdjust="false" <a:column name="billing_object_name" autoAdjust="false"
editor="contractDs_grid_editor_lov" prompt="开票对象名称" editor="contractDs_grid_editor_lov" prompt="开票对象名称"
renderer="render_contractDs_grid" showTitle="true" width="200"/> renderer="render_contractDs_grid" showTitle="true" width="200"/>
<a:column name="invoice_title" autoAdjust="false" prompt="发票抬头" showTitle="true" <a:column name="invoice_title" autoAdjust="false" prompt="发票抬头" showTitle="true"
width="200"/> width="200"/>
<a:column name="object_tax_registry_num" prompt="纳税人识别号" width="150"/> <a:column name="object_tax_registry_num" prompt="纳税人识别号" width="150"/>
<a:column name="object_taxpayer_type_desc" prompt="纳税人类型" width="150"/> <a:column name="object_taxpayer_type_desc" prompt="纳税人类型" align="center" width="150"/>
<a:column name="invoice_bp_address_phone_num" autoAdjust="false" prompt="开票地址电话" <a:column name="invoice_bp_address_phone_num" autoAdjust="false" prompt="开票地址电话"
showTitle="true" width="200"/> showTitle="true" width="200"/>
<a:column name="invoice_bp_bank_account" autoAdjust="false" prompt="开户行及账号" <a:column name="invoice_bp_bank_account" autoAdjust="false" prompt="开户行及账号"
showTitle="true" width="150"/> showTitle="true" width="150"/>
<a:column name="description" autoAdjust="false" prompt="备注" showTitle="true" <a:column name="description" autoAdjust="false" prompt="备注" showTitle="true"
width="200"/> width="200"/>
<a:column name="ccr_document_type_desc" prompt="变更操作" align="center" showTitle="true"
width="100"/>
</a:columns> </a:columns>
<a:editors> <a:editors>
<a:lov id="contractDs_grid_editor_lov"/> <a:lov id="contractDs_grid_editor_lov"/>
......
...@@ -10,6 +10,8 @@ ...@@ -10,6 +10,8 @@
<a:link id="acr_invoice_reverse_apply_detail_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail.lview"/> <a:link id="acr_invoice_reverse_apply_detail_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail.lview"/>
<a:link id="acr_invoice_reverse_apply_detail_readonly_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail_wfl.lview"/> <a:link id="acr_invoice_reverse_apply_detail_readonly_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail_wfl.lview"/>
<a:link id="acr620_invoice_reverse_apply_status_change" model="acr.ACR610.acr_invoice_apply_query" modelaction="delete"/> <a:link id="acr620_invoice_reverse_apply_status_change" model="acr.ACR610.acr_invoice_apply_query" modelaction="delete"/>
<a:link id="acr620_invoice_finish_print_link_id"
url="${/request/@context_path}/modules/csh/CSH501/csh_payment_req_history_pdf_print.lsc"/>
<script><![CDATA[ <script><![CDATA[
function lock_current_window() { function lock_current_window() {
...@@ -100,8 +102,19 @@ ...@@ -100,8 +102,19 @@
}else{ }else{
document.getElementById("acr620_invoice_reverse_cancel_id").style.display = ""; document.getElementById("acr620_invoice_reverse_cancel_id").style.display = "";
} }
if (record.get('reverse_method') == 'REDPUNCH'||record.get('reverse_method') == 'INVALID') {
document.getElementById("acr620_invoice_print_id").style.display = "";
} else {
document.getElementById("acr620_invoice_print_id").style.display = "none";
}
} }
function acr620_invoice_print() {
var record = $('acr620_invoice_reverse_result_ds').getSelected()[0];
var document_id = record.get('invoice_apply_id');
var url_l = $('acr620_invoice_finish_print_link_id').getUrl() + '?document_id=' + document_id + '&document_table=ACR_INVOICE_REVERSE&batch_flag=Y&source_type=COMMON';
var OpenWindow = window.open(href = url_l, target = "_blank");
}
]]></script> ]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/> <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
...@@ -139,6 +152,7 @@ ...@@ -139,6 +152,7 @@
<a:screenTitle/> <a:screenTitle/>
<a:toolbarButton click="acr620_invoice_reverse_reset" text="HLS.RESET"/> <a:toolbarButton click="acr620_invoice_reverse_reset" text="HLS.RESET"/>
<a:toolbarButton click="acr620_invoice_reverse_query" text="HLS.QUERY"/> <a:toolbarButton click="acr620_invoice_reverse_query" text="HLS.QUERY"/>
<a:toolbarButton id="acr620_invoice_print_id" click="acr620_invoice_print" text="HLS.PRINT"/>
<a:toolbarButton id="acr620_invoice_reverse_cancel_id" click="acr620_invoice_reverse_cancel" text="取消申请"/> <a:toolbarButton id="acr620_invoice_reverse_cancel_id" click="acr620_invoice_reverse_cancel" text="取消申请"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="200" padding="0" title="查询条件"> <a:form marginWidth="200" padding="0" title="查询条件">
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
function wordToPdf(word_file_path,pdf_file_path) { function wordToPdf(word_file_path,pdf_file_path) {
// word转pdf // word转pdf
var pdf_file_path_new = pdf_file_path + '.pdf'; var pdf_file_path_new = pdf_file_path + '.pdf';
var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.18-x64.dll"); var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.19-x64.dll");
wordToPdf.word2pdf(word_file_path, pdf_file_path_new); wordToPdf.word2pdf(word_file_path, pdf_file_path_new);
//删除word文件 //删除word文件
// deleteFile(word_file_path); // deleteFile(word_file_path);
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
function wordToPdf(word_file_path,pdf_file_path) { function wordToPdf(word_file_path,pdf_file_path) {
// word转pdf // word转pdf
var pdf_file_path_new = pdf_file_path + '.pdf'; var pdf_file_path_new = pdf_file_path + '.pdf';
var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.18-x64.dll"); var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.19-x64.dll");
wordToPdf.word2pdf(word_file_path, pdf_file_path_new); wordToPdf.word2pdf(word_file_path, pdf_file_path_new);
//删除word文件 //删除word文件
// deleteFile(word_file_path); // deleteFile(word_file_path);
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
function wordToPdf(word_file_path,pdf_file_path) { function wordToPdf(word_file_path,pdf_file_path) {
// word转pdf // word转pdf
var pdf_file_path_new = pdf_file_path + '.pdf'; var pdf_file_path_new = pdf_file_path + '.pdf';
var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.18-x64.dll"); var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.19-x64.dll");
wordToPdf.word2pdf(word_file_path, pdf_file_path_new); wordToPdf.word2pdf(word_file_path, pdf_file_path_new);
//删除word文件 //删除word文件
// deleteFile(word_file_path); // deleteFile(word_file_path);
......
...@@ -155,11 +155,45 @@ ...@@ -155,11 +155,45 @@
}, },
scope: this scope: this
}); });
}if (name == 'pay_method') {
if ( value== 'WIRE_TRANSFER') {
record.set('bank_account_id', null);
record.set('bank_account_id_n', null);
record.getField('bank_account_id').setReadOnly(true);
record.getField('bank_account_id_n').setReadOnly(true);
record.getField('bank_account_id').setRequired(false);
record.getField('bank_account_id_n').setRequired(false);
record.set('bank_account_name', null);
record.set('bank_branch_num', null);
record.set('bank_branch_name', null);
record.set('withhold_way', null);
} else if (value== 'AGRI_THREE'){
record.getField('bank_account_id').setReadOnly(false);
record.getField('bank_account_id_n').setReadOnly(false);
record.getField('bank_account_id').setRequired(true);
record.getField('bank_account_id_n').setRequired(true);
record.set('withhold_way', 'ABC');
}
else if (value == 'AGRI_TWO'){
record.getField('bank_account_id').setReadOnly(false);
record.getField('bank_account_id_n').setReadOnly(false);
record.getField('bank_account_id').setRequired(true);
record.getField('bank_account_id_n').setRequired(true);
record.set('withhold_way', 'ABC_2');
}
else if (value == 'CCB_THREE'){
record.getField('bank_account_id').setReadOnly(false);
record.getField('bank_account_id_n').setReadOnly(false);
record.getField('bank_account_id').setRequired(true);
record.getField('bank_account_id_n').setRequired(true);
record.set('withhold_way', null);
}
} }
} }
// 回款賬戶變更 // 回款賬戶變更
if ('${/parameter/@layout_code}' == 'CON_ACCOUNT_CHANGE_MODIFY') { if ('${/parameter/@layout_code}' == 'CON_ACCOUNT_CHANGE_MODIFY') {
debugger;
if (name == 'pay_method') { if (name == 'pay_method') {
if ( value== 'WIRE_TRANSFER') { if ( value== 'WIRE_TRANSFER') {
record.set('bank_account_id', null); record.set('bank_account_id', null);
......
...@@ -20,7 +20,6 @@ ...@@ -20,7 +20,6 @@
var download_arr = []; var download_arr = [];
Leaf.onReady(function() { Leaf.onReady(function() {
debugger;
if("${/model/role_info/record/@role_code}"!="0018"&&"${/model/role_info/record/@role_code}"!="0019") { if("${/model/role_info/record/@role_code}"!="0018"&&"${/model/role_info/record/@role_code}"!="0019") {
document.getElementById("CON736_F_QUERY_NULL_BP_ID_AGENT_LEVEL1_prompt").style.display = ""; document.getElementById("CON736_F_QUERY_NULL_BP_ID_AGENT_LEVEL1_prompt").style.display = "";
document.getElementById("CON736_F_QUERY_NULL_BP_ID_AGENT_LEVEL1").style.display = ""; document.getElementById("CON736_F_QUERY_NULL_BP_ID_AGENT_LEVEL1").style.display = "";
......
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
</a:form> </a:form>
<a:tabPanel marginHeight="100" marginWidth="50"> <a:tabPanel marginHeight="100" marginWidth="50">
<a:tabs> <a:tabs>
<a:tab prompt="分期回购合同计提对象金额" width="190"> <a:tab prompt="解约回购合同计提对象金额" width="190">
<a:grid id="con_bad_debts_confirmed_result_id" bindTarget="con_bad_debts_confirmed_result_ds" <a:grid id="con_bad_debts_confirmed_result_id" bindTarget="con_bad_debts_confirmed_result_ds"
marginHeight="150" marginWidth="238" navBar="true"> marginHeight="150" marginWidth="238" navBar="true">
<a:columns> <a:columns>
...@@ -113,7 +113,7 @@ ...@@ -113,7 +113,7 @@
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:tab> </a:tab>
<a:tab prompt="分期回购坏账计提合计" width="180"> <a:tab prompt="解约回购坏账计提合计" width="180">
<a:grid id="con_bad_debts_confirmed_sum_id" bindTarget="con_bad_debts_confirmed_sum_ds" <a:grid id="con_bad_debts_confirmed_sum_id" bindTarget="con_bad_debts_confirmed_sum_ds"
marginHeight="150" marginWidth="238" navBar="true"> marginHeight="150" marginWidth="238" navBar="true">
<a:columns> <a:columns>
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
function wordToPdf(word_file_path,pdf_file_path) { function wordToPdf(word_file_path,pdf_file_path) {
// word转pdf // word转pdf
var pdf_file_path_new = pdf_file_path + '.pdf'; var pdf_file_path_new = pdf_file_path + '.pdf';
var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.18-x64.dll"); var wordToPdf = new WordToPdf($instance('uncertain.ocm.IObjectRegistry'), "jacob-1.19-x64.dll");
wordToPdf.word2pdf(word_file_path, pdf_file_path_new); wordToPdf.word2pdf(word_file_path, pdf_file_path_new);
//删除word文件 //删除word文件
// deleteFile(word_file_path); // deleteFile(word_file_path);
......
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