Commit e1691d49 authored by stone's avatar stone

【fix】付款申请带出代理店账号

parent f20052bd
......@@ -46,15 +46,25 @@
v.search_term_1,
v.bp_bank_account_id_n,
v.bp_bank_account_id,
v.BP_BANK_ACCOUNT_NUM,
'' bank_full_name, --宏菱需要置为空 bank_key
v.irr,
v.application_type_n,
v.application_result_n,
v.price,
v.factory_price,
/*v.sap_bvtyp,
v.sap_bvtyp_n*/
--代理店账户
(SELECT hbbc.bank_account_name
FROM hls_bp_master_bank_account hbbc
WHERE hbbc.bp_id=v.bp_id_agent_level1) bp_bank_account_name,
--代理店账号
(SELECT hbbc.bank_account_num
FROM hls_bp_master_bank_account hbbc
WHERE hbbc.bp_id=v.bp_id_agent_level1) bp_bank_account_num,
--代理店账号
(SELECT hbbc.bank_account_num
FROM hls_bp_master_bank_account hbbc
WHERE hbbc.bp_id=v.bp_id_agent_level1) bp_bank_account_num_n,
(SELECT hb.sap_bvtyp
FROM hls_bp_master_bank_account hb
WHERE hb.bank_account_id = v.bp_bank_account_id) sap_bvtyp,
......@@ -158,34 +168,6 @@
ELSE
NULL
END) bp_bank_account_id_n,
(CASE
WHEN f.cf_item IN (5, 6, 993, 998) THEN
(SELECT t.bank_account_num
FROM hls_bp_master_bank_account_v t
WHERE t.bp_id =
NVL(${@payment_bp_id},
csh_payment_req_pkg.get_bp_id(t.contract_id))
AND t.enabled_flag = 'Y'
AND t.sap_bvtyp = DECODE(t.division,
'10',
'CNYA',
'00',
'CNYA',
'01',
'CNYB')
AND rownum = 1)
WHEN f.cf_item IN (992, 994, 995, 997) THEN
(SELECT t.bank_account_num
FROM hls_bp_master_bank_account_v t
WHERE t.bp_id =
NVL(${@payment_bp_id},
csh_payment_req_pkg.get_bp_id(t.contract_id))
AND t.enabled_flag = 'Y'
AND t.sap_bvtyp = 'CNYC'
AND rownum = 1)
ELSE
NULL
END) BP_BANK_ACCOUNT_NUM,
(SELECT t.bank_branch_name
FROM hls_bp_master_bank_account_v t
WHERE t.bp_id =
......
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