Commit 1f64c16b authored by liyuan.chen's avatar liyuan.chen

买断机修改,债权月报修改,同意导入修改

parent 3f2098df
......@@ -23,7 +23,11 @@
AND cwo.cf_item IN (1, 200, 250)
AND nvl(cwo.reversed_flag, 'N') = 'N'
AND trunc(ct.transaction_date) <=
trunc(to_date(${@last_month_date}, 'yyyy-mm-dd'))),
trunc(to_date(${@last_month_date}, 'yyyy-mm-dd'))
and exists(select 1
from con_contract_cashflow cc
where cc.CASHFLOW_ID = cwo.CASHFLOW_ID
and cc.CF_STATUS = 'RELEASE')),
0)
ELSE
0
......@@ -219,7 +223,12 @@
AND cwo.csh_transaction_id = ct.transaction_id
AND nvl(cwo.reversed_flag, 'N') = 'N'
AND trunc(ct.transaction_date) <=
TRUNC(last_day(to_date(${@start_calc_date}, 'yyyy-mm-dd')))),
TRUNC(last_day(to_date(${@start_calc_date}, 'yyyy-mm-dd')))
and exists(select 1
from con_contract_cashflow cc
where cc.CASHFLOW_ID = cwo.CASHFLOW_ID
and cc.CF_STATUS = 'RELEASE')
),
0) rest_unpayment_amount,
--保证金后
contract_item_query_pkg.calc_rest_rent_by_dudt(p_contract_id => t.contract_id,
......@@ -369,7 +378,14 @@
where v.CODE = 'CON500_CONTRACT_STATUS'
and v.CODE_VALUE = t.CONTRACT_STATUS
and v.CODE_ENABLED_FLAG = 'Y'
and v.CODE_VALUE_ENABLED_FLAG = 'Y') contract_status_n
and v.CODE_VALUE_ENABLED_FLAG = 'Y') contract_status_n,
t.is_buyout,
(Select v1.code_value_name
From sys_code_values_v v1
Where v1.code = 'YES_OR_NO'
And v1.code_enabled_flag = 'Y'
And v1.code_value_enabled_flag = 'Y'
and v1.CODE_VALUE = t.is_buyout) is_buyout_n
FROM con_contract t, hls_bp_master h
WHERE t.data_class = 'NORMAL'
AND t.bp_id_agent_level1 = h.bp_id
......
......@@ -3,14 +3,15 @@
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT t.contract_id,
SELECT
t.contract_id,
t.contract_number,
(SELECT h.extra_nam
FROM hls_bp_master h
WHERE h.bp_id=t.bp_id_agent_level1) extra_nam,
WHERE h.bp_id = t.bp_id_agent_level1) extra_nam,
(SELECT h.bp_name
FROM hls_bp_master h
WHERE h.bp_id=t.bp_id_tenant) tenant_name,
WHERE h.bp_id = t.bp_id_tenant) tenant_name,
--租赁开始日
t.lease_start_date,
--机型
......@@ -18,7 +19,7 @@
--机号
ccli.machine_number,
--回数
decode(ccc.cf_item,8,'留购价格',ccc.times) times,
decode(ccc.cf_item, 8, '留购价格', ccc.times) times,
--支付预定日
ccc.due_date,
--应收款金额
......@@ -59,7 +60,8 @@
AND nvl(cwo.reversed_flag, 'N') = 'N'
AND trunc(t.transaction_date) <=
trunc(to_date(${@last_month_date}, 'yyyy-mm-dd'))),
0)) > 0 THEN
0)) > 0
THEN
floor(to_date(${@last_month_date}, 'yyyy-mm-dd') - ccc.due_date)
ELSE
0
......@@ -69,8 +71,15 @@
from csh_transaction tt
where tt.transaction_type = 'DEPOSIT'
AND tt.deposit_trans_type = 'rent_deposit'
AND NVL(tt.reversed_flag,'N')='N'
and tt.ref_contract_id = T.contract_id),0) deposit_amount
AND NVL(tt.reversed_flag, 'N') = 'N'
and tt.ref_contract_id = T.contract_id), 0) deposit_amount,
t.is_buyout,
(Select v1.code_value_name
From sys_code_values_v v1
Where v1.code = 'YES_OR_NO'
And v1.code_enabled_flag = 'Y'
And v1.code_value_enabled_flag = 'Y'
and v1.CODE_VALUE = t.is_buyout) is_buyout_n
FROM con_contract_cashflow ccc,
con_contract t,
con_contract_lease_item ccli
......@@ -101,8 +110,8 @@
</bm:operations>
<bm:query-fields>
<!-- <bm:query-field name="period_name" queryExpression="t1.period_day=${@period_name}"/>-->
<!-- <bm:query-field name="journal_date_to" queryExpression="to_char(t.journal_date,&apos;yyyy-mm-dd&apos;) &lt;= ${@journal_date_to}"/>-->
<!-- <bm:query-field name="bp_id_agent_level1" queryExpression="t.bp_id_agent_level1=${@bp_id_agent_level1}"/>-->
<!-- <bm:query-field name="period_name" queryExpression="t1.period_day=${@period_name}"/>-->
<!-- <bm:query-field name="journal_date_to" queryExpression="to_char(t.journal_date,&apos;yyyy-mm-dd&apos;) &lt;= ${@journal_date_to}"/>-->
<!-- <bm:query-field name="bp_id_agent_level1" queryExpression="t.bp_id_agent_level1=${@bp_id_agent_level1}"/>-->
</bm:query-fields>
</bm:model>
......@@ -9,45 +9,62 @@
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT v.*,
SELECT
v.*,
--未收金额
(due_amount-received_amount) unreceived_amount
(due_amount - received_amount) unreceived_amount
FROM (SELECT
t.contract_number,
(SELECT bp_name FROM hls_bp_master h WHERE h.bp_id=t.bp_id_tenant) bp_tenant_name,
(SELECT H.extra_nam FROM hls_bp_master h WHERE h.bp_id=t.bp_id_agent_level1) agent_extra_name,
to_char(t.lease_start_date, 'yyyy-mm-dd') lease_start_date,
(SELECT bp_name
FROM hls_bp_master h
WHERE h.bp_id = t.bp_id_tenant) bp_tenant_name,
(SELECT H.extra_nam
FROM hls_bp_master h
WHERE h.bp_id =
t.bp_id_agent_level1) agent_extra_name,
to_char(t.lease_start_date,
'yyyy-mm-dd') lease_start_date,
ccli.machine_number,
ccli.modelcd,
( ccc.times||(SELECT ci.description FROM hls_cashflow_item ci WHERE ci.cf_item=ccc.cf_item) ) times,
ccc.times,
to_char(ccc.due_date, 'yyyy-mm-dd') due_date,
(NVL(t.int_rate_display, 0) * 100 || '%') int_rate_display, --利率
(NVL(t.int_rate_display, 0) * 100 ||
'%') int_rate_display,
--利率
--应收款金额
(ccc.due_amount - NVL((SELECT SUM(cwo.write_off_due_amount) FROM csh_transaction t,csh_write_off cwo
WHERE cwo.cashflow_id=ccc.cashflow_id
AND t.transaction_id=cwo.csh_transaction_id
AND NVL(cwo.reversed_flag,'N')='N'
AND TRUNC(T.transaction_date) <=TRUNC(to_date(${@before_end},'yyyy-mm-dd'))),0))due_amount,
(ccc.due_amount - NVL((SELECT SUM(cwo.write_off_due_amount)
FROM csh_transaction t, csh_write_off cwo
WHERE cwo.cashflow_id = ccc.cashflow_id
AND t.transaction_id = cwo.csh_transaction_id
AND NVL(cwo.reversed_flag, 'N') = 'N'
AND TRUNC(T.transaction_date) <=
TRUNC(to_date(${@before_end}, 'yyyy-mm-dd'))),
0)) due_amount,
--已收款金额
NVL((SELECT SUM(cwo.write_off_due_amount) FROM csh_transaction t,csh_write_off cwo
WHERE cwo.cashflow_id=ccc.cashflow_id
AND t.transaction_id=cwo.csh_transaction_id
AND NVL(cwo.reversed_flag,'N')='N'
AND TRUNC(T.transaction_date) >= TRUNC(to_date(${@cur_begin},'yyyy-mm-dd'))
AND TRUNC(T.transaction_date) <= TRUNC(to_date(${@cur_end},'yyyy-mm-dd'))
),0) received_amount,
NVL((SELECT SUM(cwo.write_off_due_amount)
FROM csh_transaction t, csh_write_off cwo
WHERE cwo.cashflow_id = ccc.cashflow_id
AND t.transaction_id = cwo.csh_transaction_id
AND NVL(cwo.reversed_flag, 'N') = 'N'
AND TRUNC(T.transaction_date) >= TRUNC(to_date(${@cur_begin}, 'yyyy-mm-dd'))
AND TRUNC(T.transaction_date) <= TRUNC(to_date(${@cur_end}, 'yyyy-mm-dd'))
),
0) received_amount,
--相减
--逾期日
(
CASE
WHEN (ccc.due_amount- NVL((SELECT SUM(cwo.write_off_due_amount) FROM csh_transaction t,csh_write_off cwo
WHERE cwo.cashflow_id=ccc.cashflow_id
AND t.transaction_id=cwo.csh_transaction_id
AND NVL(cwo.reversed_flag,'N')='N'
AND TRUNC(T.transaction_date) <= TRUNC(to_date(${@cur_end},'yyyy-mm-dd'))
),0)) >0 THEN
FLOOR(TO_date(${@cur_end},'yyyy-mm-dd')-ccc.due_date)
WHEN (ccc.due_amount - NVL((SELECT SUM(cwo.write_off_due_amount)
FROM csh_transaction t, csh_write_off cwo
WHERE cwo.cashflow_id = ccc.cashflow_id
AND t.transaction_id = cwo.csh_transaction_id
AND NVL(cwo.reversed_flag, 'N') = 'N'
AND TRUNC(T.transaction_date) <=
TRUNC(to_date(${@cur_end}, 'yyyy-mm-dd'))
), 0)) > 0
THEN
FLOOR(TO_date(${@cur_end}, 'yyyy-mm-dd') - ccc.due_date)
ELSE
0
END
......@@ -58,13 +75,20 @@
from csh_transaction tt
where tt.transaction_type = 'DEPOSIT'
AND tt.deposit_trans_type = 'rent_deposit'
AND NVL(tt.reversed_flag,'N')='N'
and tt.ref_contract_id = T.contract_id),0) deposit_amount
AND NVL(tt.reversed_flag, 'N') = 'N'
and tt.ref_contract_id = T.contract_id), 0) deposit_amount,
t.is_buyout,
(Select v1.code_value_name
From sys_code_values_v v1
Where v1.code = 'YES_OR_NO'
And v1.code_enabled_flag = 'Y'
And v1.code_value_enabled_flag = 'Y'
and v1.CODE_VALUE = t.is_buyout) is_buyout_n
from con_contract_cashflow ccc,con_contract t,con_contract_lease_item ccli
WHERE ccc.contract_id=t.contract_id
AND ccli.contract_id(+)=t.contract_id
AND ccc.cf_item IN (1, 8, 200, 250)
from con_contract_cashflow ccc, con_contract t, con_contract_lease_item ccli
WHERE ccc.contract_id = t.contract_id
AND ccli.contract_id (+) = t.contract_id
AND ccc.cf_item IN (1, 8, 200, 250)
AND ccc.cf_status = 'RELEASE'
AND t.data_class = 'NORMAL'
AND trunc(ccc.due_date) <=
......@@ -72,7 +96,7 @@ AND ccc.cf_item IN (1, 8, 200, 250)
AND ((trunc(t.lease_start_date) <=
trunc(to_date(${@cur_end}, 'yyyy-mm-dd')) AND
t.contract_status = 'INCEPT') OR
( trunc(t.et_date) >= trunc(to_date(${@cur_begin}, 'yyyy-mm-dd')) AND
(trunc(t.et_date) >= trunc(to_date(${@cur_begin}, 'yyyy-mm-dd')) AND
t.contract_status = 'TERMINATE'))
AND ccc.due_amount >
nvl((SELECT SUM(cwo.write_off_due_amount)
......@@ -84,8 +108,7 @@ AND ccc.cf_item IN (1, 8, 200, 250)
trunc(to_date(${@cur_begin}, 'yyyy-mm-dd'))),
0)
order by t.contract_id
) v
) v
]]></bm:query-sql>
</bm:operation>
<bm:operation name="update">
......@@ -115,11 +138,11 @@ AND ccc.cf_item IN (1, 8, 200, 250)
<bm:field name="unreceived_amount"/>
<bm:field name="overdue_days"/>
<bm:field name="deposit_amount"/>
<bm:field name="is_buyout_n"/>
</bm:fields>
<!-- <bm:query-fields>-->
<!-- <bm:query-field field="bp_id_tenant_n" queryExpression="t1.bp_id_tenant_n = ${@bp_id_tenant_n}"/>-->
<!-- <bm:query-field field="account_name" queryExpression="t1.account_name = ${@account_name}"/>-->
<!-- <bm:query-field field="account_id_n" queryExpression="t1.account_id_n = ${@account_id_n}"/>-->
<!-- </bm:query-fields>-->
<!-- <bm:query-fields>-->
<!-- <bm:query-field field="bp_id_tenant_n" queryExpression="t1.bp_id_tenant_n = ${@bp_id_tenant_n}"/>-->
<!-- <bm:query-field field="account_name" queryExpression="t1.account_name = ${@account_name}"/>-->
<!-- <bm:query-field field="account_id_n" queryExpression="t1.account_id_n = ${@account_id_n}"/>-->
<!-- </bm:query-fields>-->
</bm:model>
......@@ -13,27 +13,53 @@
(SELECT m.extra_nam
FROM hls_bp_master m
WHERE m.bp_id = ct.bp_id_agent_level1) agent_extra_name, --代理店简称
(SELECT m.bp_name FROM hls_bp_master m WHERE m.bp_id = ct.bp_id_tenant) AS bp_tenant_name, --承租人名称
ct.contract_number, --合同编号
to_char(ct.lease_start_date, 'yyyy-mm-dd') lease_start_date, --租赁期开始日
WHERE m.bp_id = ct.bp_id_agent_level1) agent_extra_name,
--代理店简称
(SELECT m.bp_name
FROM hls_bp_master m
WHERE m.bp_id =
ct.bp_id_tenant) AS bp_tenant_name,
--承租人名称
ct.contract_number,
--合同编号
to_char(ct.lease_start_date,
'yyyy-mm-dd') lease_start_date,
--租赁期开始日
(SELECT ccli.modelcd
FROM con_contract_lease_item ccli
WHERE ccli.contract_id = ct.contract_id) modelcd, --机型
WHERE ccli.contract_id =
ct.contract_id) modelcd,
--机型
(SELECT i.machine_number
FROM con_contract_lease_item i
WHERE i.contract_id = ct.contract_id
AND i.equipment_type = 'MAIN') machine_number, --机号
(NVL(ct.int_rate_display, 0) * 100 || '%') int_rate_display, --利率
ct.lease_times, --租赁期间
(NVL(ct.down_payment_ratio, 0) * 100 || '%') down_payment_ratio, --首付比例
ct.lease_item_amount as lease_item_amount, --设备款
NVL(ct.residual_value, 0) residual_amount, --留购金
AND i.equipment_type =
'MAIN') machine_number,
--机号
(NVL(ct.int_rate_display, 0) * 100 ||
'%') int_rate_display,
--利率
ct.lease_times,
--租赁期间
(NVL(ct.down_payment_ratio, 0) * 100 ||
'%') down_payment_ratio,
--首付比例
ct.lease_item_amount as lease_item_amount,
--设备款
NVL(ct.residual_value,
0) residual_amount,
--留购金
NVL(ct.total_rental, 0) + NVL(ct.down_payment, 0) +
NVL(ct.residual_value, 0) contract_amount, --合同金额
NVL(ct.down_payment, 0) down_payment, --首付款
(case when ct.contract_status='TERMINATE' then
0 else
NVL(ct.residual_value,
0) contract_amount,
--合同金额
NVL(ct.down_payment,
0) down_payment,
--首付款
(case when ct.contract_status = 'TERMINATE'
then
0
else
((select sum(ccw.due_amount)
from con_contract_cashflow ccw
where ccw.contract_id = ct.contract_id
......@@ -43,13 +69,16 @@
where cw.csh_transaction_id = cn.transaction_id
and cw.cf_item in (1, 200)
and cw.contract_id = ct.contract_id
and NVL(cw.reversed_flag,'N')='N'
and NVL(cw.reversed_flag, 'N') = 'N'
and trunc(cn.transaction_date) <=
trunc(to_date(${@cur_end},'yyyy-mm-dd'))),
trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),
0))
end )month_due_amount, --当月末应收款余额(合计)
(case when ct.contract_status='TERMINATE' then
0 else
end) month_due_amount,
--当月末应收款余额(合计)
(case when ct.contract_status = 'TERMINATE'
then
0
else
((select sum(ccw.principal)
from con_contract_cashflow ccw
where ccw.contract_id = ct.contract_id
......@@ -59,13 +88,16 @@
where cw.csh_transaction_id = cn.transaction_id
and cw.cf_item in (1, 200)
and cw.contract_id = ct.contract_id
and NVL(cw.reversed_flag,'N')='N'
and NVL(cw.reversed_flag, 'N') = 'N'
and trunc(cn.transaction_date) <=
trunc(to_date(${@cur_end},'yyyy-mm-dd'))),
trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),
0))
end) month_due_principal, --当月末本金余额(合计)
(case when ct.contract_status='TERMINATE' then
0 else
end) month_due_principal,
--当月末本金余额(合计)
(case when ct.contract_status = 'TERMINATE'
then
0
else
((select sum(ccw.interest)
from con_contract_cashflow ccw
where ccw.contract_id = ct.contract_id
......@@ -75,12 +107,15 @@
where cw.csh_transaction_id = cn.transaction_id
and cw.cf_item in (1, 200)
and cw.contract_id = ct.contract_id
and NVL(cw.reversed_flag,'N')='N'
and NVL(cw.reversed_flag, 'N') = 'N'
and trunc(cn.transaction_date) <=
trunc(to_date(${@cur_end},'yyyy-mm-dd'))),
0)) end ) month_interest, --当月末利息余额(合计)
(case when ct.contract_status='TERMINATE' then
0 else
trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),
0)) end) month_interest,
--当月末利息余额(合计)
(case when ct.contract_status = 'TERMINATE'
then
0
else
((select sum(ccw.due_amount)
from con_contract_cashflow ccw
where ccw.contract_id = ct.contract_id
......@@ -90,59 +125,81 @@
where cw.csh_transaction_id = cn.transaction_id
and cw.cf_item in (8)
and cw.contract_id = ct.contract_id
and NVL(cw.reversed_flag,'N')='N'
and NVL(cw.reversed_flag, 'N') = 'N'
and trunc(cn.transaction_date) <=
trunc(to_date(${@cur_end},'yyyy-mm-dd'))),
0)) end ) month_residual, --当月末留购金余额
(case when ct.contract_status='TERMINATE' then
0 else
trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),
0)) end) month_residual,
--当月末留购金余额
(case when ct.contract_status = 'TERMINATE'
then
0
else
con_contract_pkg.get_business_times(p_contract_id => ct.contract_id,
p_calc_date => to_date(${@cur_end},'yyyy-mm-dd'),
p_contract_inception_date => ct.contract_inception_date) end) business_due_times, --逾期期数
(case when ct.contract_status='TERMINATE' then
0 else
(nvl((select sum(ccw.due_amount)-sum(nvl((SELECT SUM(nvl(cwo.write_off_due_amount, 0))
p_calc_date => to_date(${@cur_end}, 'yyyy-mm-dd'),
p_contract_inception_date => ct.contract_inception_date) end) business_due_times,
--逾期期数
(case when ct.contract_status = 'TERMINATE'
then
0
else
(nvl((select sum(ccw.due_amount) - sum(nvl((SELECT SUM(nvl(cwo.write_off_due_amount, 0))
FROM csh_write_off cwo, csh_transaction cn
WHERE nvl(cwo.reversed_flag, 'N') = 'N'
AND cwo.contract_id = ccw.contract_id
AND cwo.times = ccw.times
and cwo.csh_transaction_id = cn.transaction_id
and
cwo.csh_transaction_id = cn.transaction_id
AND cwo.cf_item = ccw.cf_item
and trunc(cn.transaction_date) <=
trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),
trunc(to_date(${@cur_end},
'yyyy-mm-dd'))),
0))
from con_contract_cashflow ccw
where ccw.contract_id =ct.contract_id
where ccw.contract_id = ct.contract_id
and ccw.cf_item in (1, 200, 8)
and trunc(ccw.due_date) <= trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))),0)
-nvl((select sum((nvl(tt.transaction_amount, 0) - nvl(tt.write_off_amount, 0) -
and trunc(ccw.due_date) <= trunc(to_date(${@cur_end}, 'yyyy-mm-dd'))), 0)
- nvl((select sum((nvl(tt.transaction_amount, 0) - nvl(tt.write_off_amount, 0) -
nvl(tt.returned_amount, 0)))
from csh_transaction tt
where tt.transaction_type = 'DEPOSIT'
AND tt.deposit_trans_type = 'rent_deposit'
and tt.ref_contract_id = ct.contract_id),0)) end ) business_due_amount, --当月末逾期金额(合计)
and tt.ref_contract_id = ct.contract_id),
0)) end) business_due_amount,
--当月末逾期金额(合计)
(select sum((nvl(tt.transaction_amount, 0) - nvl(tt.write_off_amount, 0) -
nvl(tt.returned_amount, 0)))
from csh_transaction tt
where tt.transaction_type = 'DEPOSIT'
AND tt.deposit_trans_type = 'rent_deposit'
and tt.ref_contract_id = ct.contract_id) deposit_amount, --保证金金额
and tt.ref_contract_id =
ct.contract_id) deposit_amount,
--保证金金额
(SELECT v.code_value_name
FROM sys_code_values_v v
WHERE v.code = 'CON500_CONTRACT_STATUS'
AND v.code_value = ct.contract_status) AS contract_status_n, --合同金额
AND v.code_value =
ct.contract_status) AS contract_status_n,
--合同金额
(select to_char(due_date, 'yyyy-mm-dd')
from con_contract_cashflow
where contract_id = ct.contract_id
and cf_item = 8) residual_date ,-- 合同终了
to_char(ct.et_date, 'yyyy-mm-dd') terminate_date
and cf_item =
8) residual_date,
-- 合同终了
to_char(ct.et_date,
'yyyy-mm-dd') terminate_date,
ct.is_buyout,
(Select v.code_value_name
From sys_code_values_v v
Where v.code = 'YES_OR_NO'
And v.code_enabled_flag = 'Y'
And v.code_value_enabled_flag = 'Y'
and v.CODE_VALUE = ct.is_buyout) is_buyout_n
from con_contract ct
where ct.contract_status not in ('CANCEL')
and ct.data_class='NORMAL'
and ct.data_class = 'NORMAL'
order by ct.bp_id_agent_level1
]]></bm:query-sql>
</bm:operation>
<bm:operation name="update">
......@@ -204,7 +261,7 @@
<bm:field name="contract_status_n"/>
<bm:field name="residual_date"/>
<bm:field name="terminate_date"/>
<bm:field name="is_buyout_n"/>
</bm:fields>
<!-- <bm:query-fields>-->
......
......@@ -78,7 +78,7 @@
if (record.get('secondary_lease') == 'YES') {
document.getElementById('${/parameter/@layout_code}_F_BASIC_1_CON_CONTRACT_REPUR_CONTRACT_ID_prompt').style.display = 'block';
document.getElementById('${/parameter/@layout_code}_F_BASIC_1_CON_CONTRACT_REPUR_CONTRACT_ID').style.display = 'block';
} else if (record.get('secondary_lease') == 'NO') {
} else /*if (record.get('secondary_lease') == 'NO') */{
document.getElementById('${/parameter/@layout_code}_F_BASIC_1_CON_CONTRACT_REPUR_CONTRACT_ID_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_1_CON_CONTRACT_REPUR_CONTRACT_ID').style.display = 'none';
}
......
......@@ -29,6 +29,7 @@
<a:column name="bp_tenant_name" align="center" prompt="客户名称" width="120"/>
<a:column name="contract_number" align="center" prompt="合同编号" width="100"/>
<a:column name="lease_start_date" align="center" prompt="租赁期开始日" width="80"/>
<a:column name="is_buyout_n" align="center" prompt="是否买断机" width="100"/>
<a:column name="modelcd" align="center" prompt=" 机型" width="180"/>
<a:column name="machine_number" align="center" prompt="机器号码" width="80"/>
<a:column name="int_rate_display" align="center" prompt="利率" width="80"/>
......@@ -59,6 +60,7 @@
<a:column name="bp_tenant_name" align="center" prompt="客户名称" width="120"/>
<a:column name="contract_number" align="center" prompt="合同编号" width="100"/>
<a:column name="lease_start_date" align="center" prompt="租赁期开始日" width="80"/>
<a:column name="is_buyout_n" align="center" prompt="是否买断机" width="100"/>
<a:column name="modelcd" align="center" prompt=" 机型" width="180"/>
<a:column name="machine_number" align="center" prompt="机器号码" width="80"/>
<a:column name="int_rate_display" align="center" prompt="利率" width="80"/>
......
......@@ -4,7 +4,7 @@
<a:model-query fetchAll="true" model="sys.SYS999.fnd_transfer_table" rootPath="gerneral_cols"/>
</a:init-procedure>
<a:view>
<script type="text/javascript"><![CDATA[
<script><![CDATA[
/* window['${/parameter/@sheet_name}_indexchange_fun'] = function(ds,record){
var line_id = record.get('line_id');
$('general_error_mes_ds').setQueryParameter('line_id',line_id);
......
......@@ -8,8 +8,8 @@
</a:init-procedure>
<a:view>
<a:link id="import_detail_link" url="${/request/@context_path}/modules/sys/SYS999/general_import_detail.lview"/>
<script type="text/javascript"><![CDATA[
Leaf.post($('import_detail_link').getUrl()+'?header_id=${/parameter/@header_id}');
<script><![CDATA[
Leaf.post($('import_detail_link').getUrl()+'?header_id=${/parameter/@header_id}&_csrf=${/session/@_csrf.token}');
]]></script>
</a:view>
</a:screen>
......@@ -7,7 +7,7 @@
<a:view>
<a:link id="general_confirm" model="sys.SYS999.main" modelaction="execute"/>
<a:link id="general_import_upload_link" url="${/request/@context_path}/modules/sys/SYS999/general_upload.lview"/>
<script type="text/javascript"><![CDATA[
<script><![CDATA[
var general_ds_list = []; //用于存放所有被加载的ds_id
function load_all_ds_list() {//加载所有的已打开的tab_ds
......@@ -81,8 +81,25 @@
$(ds_id).submit();
}
}
function display_query(){
var err_flag= $('sy999_query_ds').getAt(0).get('err_flag');
for (var i = 0;i < general_ds_list.length;i++) {
var ds_id = general_ds_list[i].ds_id;
if (err_flag =='Y'){
$(ds_id).setQueryParameter('err_flag',err_flag);
}else{
$(ds_id).setQueryParameter('err_flag',null);
}
$(ds_id).query();
}
}
]]></script>
<a:dataSets>
<a:dataSet id="sy999_query_ds" autoCreate="true">
<a:fields>
<a:field name="err_flag" checkedValue="Y" uncheckedValue="N"/>
</a:fields>
</a:dataSet>
<a:dataSet id="general_error_mes_ds" model="sys.SYS999.fnd_interface_log"/>
</a:dataSets>
<a:screenBody>
......@@ -92,6 +109,13 @@
<a:gridButton click="general_save" text="保存"/>
<a:gridButton click="general_execute" text="确认数据"/>
</a:screenTopToolbar>
<a:hBox>
<a:checkBox name="err_flag" bindTarget="sy999_query_ds" prompt="只显示错误">
<a:events>
<a:event name="change" handler="display_query"/>
</a:events>
</a:checkBox>
</a:hBox>
<a:tabPanel id="general_detail_tabpanel_id" marginHeight="300" marginWidth="50">
<a:tabs>
<a:placeHolder id="dynamic_tab"/>
......
......@@ -3,7 +3,7 @@
<a:init-procedure/>
<a:view>
<a:link id="general_upload_excel_control_link" url="${/request/@context_path}/modules/sys/SYS999/general_excel_execute.lview"/>
<script type="text/javascript"><![CDATA[
<script><![CDATA[
function saveClick() {
if (document.getElementById('general_importFile').value) {
var fileName = document.getElementById('general_importFile').value;
......@@ -11,6 +11,8 @@
if (fileType != '.xls' && fileType != '.xlsx') {
alert('请选择正确的导入文件!');
} else {
var detail_mask = $('upload_window').wrap;
Leaf.Masker.mask(detail_mask, '${l:HLS.EXECUTING}');
document.getElementById('general_importForm').submit();
}
}
......@@ -34,7 +36,7 @@
<a:label name="label6" bindTarget="csh713_label_ds" style="margin-left:10px;" width="380"/>
</a:fieldSet>
<a:fieldSet style="margin-left:10px;margin-top:10px;" title="导入文件" width="400">
<form name="upload" id="general_importForm" action="general_excel_execute.lview" enctype="multipart/form-data" method="post">
<form name="upload" id="general_importForm" action="general_excel_execute.lview?_csrf=${/session/@_csrf.token}" enctype="multipart/form-data" method="post">
<input name="CONTENT" id="general_importFile" style="margin-bottom:4px;width:250px;height:22px;" type="file"/>
<input onclick="saveClick()" style="margin-left:10px;margin-top:10px;width:60px;" type="button" value="导入"/>
</form>
......
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