Commit 42e86897 authored by xiaochao's avatar xiaochao

Merge branch 'feature/收款维护调整' into develop

parents a33c3bd9 40775acf
......@@ -23,6 +23,7 @@
p_wanted_confirmed_flag =>${@wanted_confirmed_flag},
p_wanted_written_off_flag=>${@wanted_written_off_flag},
p_confirmed_by =>${@confirmed_by},
p_transaction_type =>${@transaction_type},
p_user_id =>${/session/@user_id}
);
end;
......
<?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 cc.extra_nam,
cc.bp_code,
cc.bp_name
FROM hls_bp_master cc
#WHERE_CLAUSE#]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:fields>
<bm:field name="bp_code" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="true" physicalName="bp_code" prompt="代理店编码"/>
<bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="false" forQuery="true" physicalName="bp_name" prompt="商业伙伴"/>
<bm:field name="extra_nam" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="true" physicalName="extra_nam" prompt="代理店简称"/>
</bm:fields>
<bm:query-fields>
<bm:query-field field="bp_name" queryOperator="like"/>
</bm:query-fields>
<bm:data-filters>
<bm:data-filter enforceOperations="query" expression="cc.enabled_flag=&apos;Y&apos;"/>
<bm:data-filter enforceOperations="query" expression="cc.bp_category=&apos;AGENT&apos;"/>
</bm:data-filters>
</bm:model>
<?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 cc.extra_nam,
cc.bp_code,
cc.bp_name
FROM hls_bp_master cc
#WHERE_CLAUSE#]]></bm:query-sql>
</bm:operation>
</bm:operations>
<bm:fields>
<bm:field name="bp_code" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="true" physicalName="bp_code" prompt="代理店编码"/>
<bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="true" physicalName="bp_name" prompt="代理店名称"/>
<bm:field name="extra_nam" databaseType="VARCHAR2" datatype="java.lang.String" forDisplay="true" forQuery="true" physicalName="extra_nam" prompt="代理店简称"/>
</bm:fields>
<bm:query-fields>
<bm:query-field field="extra_nam" queryOperator="like"/>
</bm:query-fields>
<bm:data-filters>
<bm:data-filter enforceOperations="query" expression="cc.enabled_flag=&apos;Y&apos;"/>
<bm:data-filter enforceOperations="query" expression="cc.bp_category=&apos;AGENT&apos;"/>
</bm:data-filters>
</bm:model>
......@@ -97,8 +97,11 @@
<bm:field name="debt_confirmed_by"/>
<bm:field name="debt_confirmed_by_desc" expression="(select description from sys_user where user_id=t1.debt_confirmed_by)" forInsert="false" forUpdate="false"/>
<bm:field name="acc_confirmed_by"/>
<bm:field name="paid_byother_flag"/>
<bm:field name="acc_confirmed_by_desc" expression="(select description from sys_user where user_id=t1.acc_confirmed_by)" forInsert="false" forUpdate="false"/>
<bm:field name="receipt_type_n" expression="(select v.code_value_name from sys_code_values_v v where v.code = 'RECEIPT_TYPE' and v.code_value =t1.receipt_type)" forInsert="false" forUpdate="false"/>
<bm:field name="guarantor_name_duty" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="GUARANTOR_NAME_DUTY" prompt="担保人履行担保义务" />
<bm:field name="extra_nam" expression="(select v.extra_nam from hls_bp_master v where v.enabled_flag = 'Y' and v.bp_category = 'AGENT' and v.bp_id = t1.bp_id)" forInsert="false" forUpdate="false"/>
</bm:fields>
<bm:features>
<f:standard-who/>
......@@ -159,5 +162,6 @@
<bm:query-field name="description" queryExpression="t1.description like &apos;%&apos;||${@description}||&apos;%&apos;"/>
<bm:query-field name="bank_account_num" queryExpression="(select a.bank_account_num from csh_bank_account a where a.bank_account_id=t1.bank_account_id) like &apos;%&apos;||upper(${@bank_account_num})||&apos;%&apos;"/>
<bm:query-field name="contract_number" queryExpression="(SELECT cc.contract_number FROM con_contract cc WHERE cc.contract_id = t1.ref_contract_id) like &apos;%&apos;||upper(${@contract_number})||&apos;%&apos;"/>
<bm:query-field name="extra_nam" queryExpression="(SELECT cc.extra_nam FROM hls_bp_master cc WHERE cc.enabled_flag = 'Y' and cc.bp_category = 'AGENT' and cc.bp_id = t1.bp_id ) like &apos;%&apos;||upper(${@extra_nam})||&apos;%&apos;"/>
</bm:query-fields>
</bm:model>
......@@ -52,13 +52,20 @@
t.bp_category,
t.transaction_amount,
t.collection_classes,
t.bp_id,
(select v.code_value_name from sys_code_values_v v where v.code='DS_COLLECTION_CLASSES'and v.code_value=t.collection_classes)collection_classes_desc,
t.bp_id ,
(select bp_name from hls_bp_master where bp_id = t.bp_id) bp_name,
t.paid_byother_flag,
decode(t.paid_byother_flag,'T','是','F','否')paid_byother_flag_desc,
t.csh_bank_account_id bank_account_id,
t.exists_flag,
t.temp_id
t.temp_id,
(select v.extra_nam from hls_bp_master v where v.enabled_flag = 'Y' and v.bp_category = 'AGENT' and v.bp_id = t.bp_id) extra_nam,
(case when t.paid_byother_flag = 'T' and (select v.extra_nam from hls_bp_master v where v.enabled_flag = 'Y' and v.bp_category = 'AGENT' and v.bp_id = t.bp_id) = '深圳美鹏' then
'是'
else
'否'
end) as guarantor_name_duty
FROM fnd_interface_headers hd,
fnd_interface_lines li,
csh_transaction_import_temp t
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: chenlingfeng
$Date: 2019-01-14 16:29:48
$Revision: 1.0
$Purpose:
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="update">
<bm:update-sql><![CDATA[
begin
update csh_transaction_import_temp ct
set ct.bp_id=${@bp_id},
ct.paid_byother_flag=${@paid_byother_flag},
ct.collection_classes=${@collection_classes}
where ct.temp_id=${@temp_id};
end;
]]></bm:update-sql>
</bm:operation>
</bm:operations>
</bm:model>
......@@ -74,7 +74,8 @@
p_zuonr=>${@bank_slip_num},
p_paid_byother_flag =>${@paid_byother_flag},
p_ref_v05 =>${@ref_v05},
p_status =>${@status}
p_status =>${@status},
p_guarantor_name_duty=>${@guarantor_name_duty}
);
end;
......@@ -145,7 +146,8 @@
p_purpose =>${@purpose},
p_gsber =>${@gsber},
p_sus_belnr =>${@sus_belnr},
p_bp_virtual_bank_account =>${@bp_virtual_bank_account});
p_bp_virtual_bank_account =>${@bp_virtual_bank_account},
p_guarantor_name_duty=>${@guarantor_name_duty});
end;
]]></bm:update-sql>
</bm:operation>
......
<?xml version="1.0" encoding="UTF-8"?>
<uncertain-engine defaultLogLevel="INFO">
<path-config logPath="D:\soft\logs" uiPackageBasePath="D:\soft\hlcm\lib\LeafUI\src"/>
<path-config logPath="E:\sanling\leaf-hlcm\logs" uiPackageBasePath="E:\sanling\leaf-hlcm\target\hlcm\lib\LeafUI\src"/>
</uncertain-engine>
......@@ -117,6 +117,15 @@
$('csh509_csh_trx_bank_business_confirm').enable();
return;
}
var paid_byother_flag = datas[i].get('paid_byother_flag');
var guarantor_name_duty = datas[i].get('guarantor_name_duty');
var transaction_type = datas[i].get('transaction_type');
if (paid_byother_flag != null && guarantor_name_duty != null){
if (paid_byother_flag == 'Y' && guarantor_name_duty != '是'){
transaction_type = 'ADVANCE_RECEIPT';
}
}
//
// if(confirmed_flag=='ACCAUDITING'){
// confirmed_by='00321';
......@@ -143,6 +152,7 @@
wanted_confirmed_flag: 'ACCAUDITED',
wanted_written_off_flag: 'NOT',
confirmed_by: confirmed_by,
transaction_type: transaction_type,
_status: 'update'
})
}
......@@ -654,6 +664,10 @@
<a:field name="transaction_num_to"/>
<a:field name="bank_slip_num_from"/>
<a:field name="bank_slip_num_to"/>
<a:field name="guarantor_name_duty"/>
<a:field name="paid_byother_flag"/>
<a:field name="transaction_date_from" validator="dateValidator"/>
<a:field name="transaction_date_to" validator="dateValidator"/>
<a:field name="bank_account_code" autoCompleteField="bank_account_num" lovGridHeight="350"
......@@ -863,6 +877,10 @@
<a:column name="bp_name" prompt="CSH510.CSH_TRANSACTION.BUSINESS_PARTNER" align="center"/>
<a:column name="bank_slip_num" prompt="CSH510.CSH_TRANSACTION.BANK_CASH_CODE" align="center"/>
<a:column name="description" prompt="CSH510.CSH_TRANSACTION.DESCRIPTION" align="center"/>
<a:column name="guarantor_name_duty" hidden="true" />
<a:column name="paid_byother_flag" hidden="true"/>
<a:column name="confirmed_flag_desc" prompt="单据审批状态"
align="center"/>
<!-- <a:column name="written_off_flag_desc" prompt="CSH510.CSH_TRANSACTION.WRITTEN_OFF_STATUS"-->
......
......@@ -669,7 +669,8 @@
<a:map from="bp_bank_account_num" to="bp_bank_account_num"/>
</a:mapping>
</a:field>
<a:field name="bp_bank_account_num" lovGridHeight="350" lovHeight="550" lovService="csh.CSH510.csh_transaction_for_lov" lovLabelWidth="90" lovWidth="580" title="对方账户信息">
<a:field name="bp_bank_account_num" lovGridHeight="350" lovHeight="550"
lovService="csh.CSH510.csh_transaction_for_lov" lovLabelWidth="90" lovWidth="580" title="对方账户信息">
<a:mapping>
<a:map from="bp_bank_account_name" to="bp_bank_account_name"/>
<a:map from="opposite_band_na" to="opposite_band_na"/>
......@@ -677,6 +678,14 @@
</a:mapping>
</a:field>
<a:field name="extra_nam" lovGridHeight="350" lovHeight="550"
lovService="csh.CSH510.csh_extra_nam_for_lov"
lovLabelWidth="90" lovWidth="580" title="代理店简称">
<a:mapping>
<a:map from="extra_nam" to="extra_nam"/>
</a:mapping>
</a:field>
</a:fields>
<a:events>
<a:event name="update" handler="csh510_receipt_maintain_update"/>
......@@ -728,6 +737,7 @@
<a:comboBox name="confirmed_flag_desc" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="单据审批状态"/>
<!-- <a:comboBox name="write_off_flag_desc" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="CSH510.CSH_TRANSACTION.WRITTEN_OFF_STATUS"/>-->
<a:comboBox name="collection_classes_n" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="CSH510.CSH_TRANSACTION.PURPOSE_OF_FUNDS"/>
<a:lov name="extra_nam" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="代理店简称"/>
</a:fieldSet>
......@@ -749,6 +759,8 @@
<a:column name="use_money_amount" prompt="CSH510.CSH_TRANSACTION.USEFUL_AMOUNT" align="right" renderer="Leaf.formatMoney"/>
<a:column name="collection_classes_desc" prompt="CSH510.CSH_TRANSACTION.PURPOSE_OF_FUNDS" align="center"/>
<a:column name="bp_name" prompt="CSH510.CSH_TRANSACTION.BUSINESS_PARTNER" align="center"/>
<a:column name="extra_nam" prompt="代理店简称" align="center"/>
<a:column name="guarantor_name_duty" prompt="担保人履行担保义务" align="center"/>
<a:column name="bank_slip_num" prompt="CSH510.CSH_TRANSACTION.BANK_CASH_CODE" align="center"/>
<a:column name="description" prompt="CSH510.CSH_TRANSACTION.DESCRIPTION" align="center"/>
<a:column name="confirmed_flag_desc" prompt="单据审批状态" align="center"/>
......
......@@ -22,7 +22,15 @@
<a:link id="save_import_csh_transaction_receipt_data_link_id" model="csh.CSH510N.csh_transaction_list_tmp"
modelaction="batch_update"/>
<a:link id="get_period_name_id" model="csh.CSH511.csh_transaction_get_period_name" modelaction="query"/>
<a:link id="update_import_csh_transaction_receipt_data_link_id"
model="csh.CSH510N.csh_transaction_list_tmp_update" modelaction="batch_update"/>
<script type="text/javascript"><![CDATA[
//导出
// window['${/parameter/@layout_code}_user_button1_layout_dynamic_click'] = function() {
// var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'fnd_interface_headers');
// var grid_id = ds_id.replace('ds', 'layout_grid_id');
// $(grid_id)._export();
// };
function backBtn() {
parent._input_window.close();
......@@ -100,12 +108,20 @@
});
} else {
Leaf.showMessage('${l:PROMPT}', '数据已导入不能重复导入!');
return;
}
}
function update_import_data(ds, record, name, value, oldvalue) {
if (name =='paid_byother_flag_desc'){
var paid_byother_flag_desc = record.get('paid_byother_flag_desc');
var extra_nam = record.get('extra_nam');
if (paid_byother_flag_desc == '是' && extra_nam == '深圳美鹏'){
record.set('guarantor_name_duty','是');
}else{
record.set('guarantor_name_duty','否');
}
}
}
function change_background_color(record) {
......@@ -115,14 +131,42 @@
}
function indexchange_data(ds, record) {
if(record.get('exists_flag') == 'Y'){
var field = record.getField('bp_name');
field.setLovService('basic.csh_transaction_bp_temp_for_lov');
field.setLovPara('temp_id', record.get('temp_id'));
if (record.get('exists_flag') == 'Y') {
var field = record.getField('bp_name');
field.setLovService('basic.csh_transaction_bp_temp_for_lov');
field.setLovPara('temp_id', record.get('temp_id'));
}
}
}
function export_btn() {
var ds = $('tre_withdraw_subscriber_import_ds');
var records = ds.getAll();
var saveData = [];
for (var i = 0; i < records.length; i++) {
saveData.push({
'bp_id': records[i].get('bp_id'),
'paid_byother_flag': records[i].get('paid_byother_flag'),
'collection_classes': records[i].get('collection_classes'),
'temp_id': records[i].get('temp_id'),
'_status': 'update'
});
}
Leaf.request({
url: $('update_import_csh_transaction_receipt_data_link_id').getUrl(),
para: saveData,
scope: this,
success: function () {
$('tre_withdraw_subscriber_import_grid_id')._export();
},
failure: function () {
Leaf.Masker.unmask(Ext.getBody());
},
error: function () {
Leaf.Masker.unmask(Ext.getBody());
}
});
}
]]></script>
<a:dataSets>
<a:dataSet id="collection_classes_ds" lookupCode="DS_COLLECTION_CLASSES">
......@@ -161,7 +205,7 @@
</a:fields>
<a:events>
<a:event name="update" handler="update_import_data"/>
<a:event name="indexchange" handler="indexchange_data" />
<a:event name="indexchange" handler="indexchange_data"/>
</a:events>
</a:dataSet>
</a:dataSets>
......@@ -170,8 +214,10 @@
<a:screenTopToolbar>
<a:gridButton click="backBtn" text="退出"/>
<a:gridButton click="import_btn" text="导入"/>
<a:gridButton click="export_btn" text="导出"/>
</a:screenTopToolbar>
<a:grid id="grid_ds_id" bindTarget="tre_withdraw_subscriber_import_ds" height="340" navBar="true"
<a:grid id="tre_withdraw_subscriber_import_grid_id" bindTarget="tre_withdraw_subscriber_import_ds"
height="340" navBar="false"
width="980" rowRenderer="change_background_color">
<a:columns>
<a:column name="error_message" editor="textArea_e" prompt="错误信息" width="180"/>
......@@ -183,14 +229,21 @@
<a:column name="attribute_8" prompt="对方账号" width="80"/>
<a:column name="attribute_9" prompt="对方账号户名" width="80"/>
<a:column name="attribute_10" prompt="对方银行名称" width="80"/>
<a:column name="bp_name" prompt="收款对象" editor="grid_lov" width="120"/>
<a:column name="paid_byother_flag_desc" prompt="是否代付" editor="grid_cb"/>
<a:column name="attribute_14" prompt="收款金额" renderer="Leaf.formatMoney" align="right"
width="80"/>
<a:column name="attribute_23" prompt="摘要" width="80"/>
<a:column name="collection_classes_desc" prompt="款项分类" editor="grid_cb"/>
<a:column name="attribute_24" prompt="附言" width="80"/>
<a:column name="extra_nam" prompt="代理店简称" width="80"/>
<a:column name="guarantor_name_duty" prompt="担保人履行担保义务" width="80"/>
</a:columns>
<a:editors>
<a:textArea id="textArea_e" height="50" width="240"/>
......@@ -201,7 +254,17 @@
</a:form>
</a:screenBody>
<script type="text/javascript"><![CDATA[
Leaf.onReady(init);
function init() {
]]></script>
if (document.getElementById("tre_withdraw_subscriber_import_grid_id_tb")) {
document.getElementById("tre_withdraw_subscriber_import_grid_id_tb").style.display = "none";
}
}
]]></script>
</a:view>
</a:screen>
......@@ -239,6 +239,17 @@
record.getField('paid_byother_flag_n').setReadOnly(false);
record.set('transaction_type', 'RECEIPT');
}
}else if(name == 'extra_nam'){
var extra_nam = record.get('extra_nam');
if (extra_nam != null && extra_nam == '深圳美鹏'){
record.getField('guarantor_name_duty').setReadOnly(false);
record.set('guarantor_name_duty','是');
record.getField('guarantor_name_duty').setRequired(true);
}else if (extra_nam != null && extra_nam != '深圳美鹏'){
record.getField('guarantor_name_duty').setReadOnly(true);
record.set('guarantor_name_duty','否');
record.getField('guarantor_name_duty').setRequired(false);
}
}
}
......@@ -263,6 +274,10 @@
// record.set('bank_account_code','0040101');
record.set('currency_code', 'CNY');
record.set('currency_name', '人民币');
record.getField('guarantor_name_duty').setReadOnly(true);
record.set('guarantor_name_duty','否');
}
function setfunctionamount(record) {
......@@ -365,6 +380,7 @@
]]></script>
<a:dataSets>
<a:dataSet id="yes_no_ds" lookupCode="YES_NO"/>
<a:dataSet id="PAID_BYOTHER_FLAG_DS" lookupCode="PAID_BYOTHER_FLAG"/>
<!-- <a:dataSet id="payment_method_ds">
<a:datas dataSource="/model/payment_method_path"/>
......@@ -408,6 +424,17 @@
<a:map from="bp_category_name" to="bp_category_display"/>
</a:mapping>
</a:field>
<!--代理店简称-->
<a:field name="extra_nam" required="true" lovGridHeight="350" lovHeight="500" lovLabelWidth="90"
lovService="csh.CSH510.csh_extra_nam_add_lov" lovWidth="550" title="代理店简称">
<a:mapping>
<a:map from="extra_nam" to="extra_nam"/>
</a:mapping>
</a:field>
<!--担保人履行担保义务-->
<a:field name="guarantor_name_duty" displayField="code_value_name" options="yes_no_ds" prompt="担保人履行担保义务" returnField="exist_flag" valueField="code_value"/>
<!-- <a:field name="bank_slip_num" lovGridHeight="350" lovHeight="600" lovService="csh.CSH510.csh_transaction_contract_query" lovWidth="1200" title="合同编号">
<a:mapping>
<a:map from="bp_id" to="bp_id"/>
......@@ -480,6 +507,8 @@
<a:map from="bp_id_agent_level1_n" to="bp_id_agent_level1_n"/>
</a:mapping>
</a:field>
<a:field name="bp_bank_account_num"/>
<a:field name="bp_bank_account_name" required="true"/>
<a:field name="collection_classes" />
......@@ -556,14 +585,24 @@
<a:comboBox name="collection_classes_desc" bindTarget="csh_transaction_receipt_head_ds"
prompt="款项用途"/>
</a:box>
<a:hBox style="width:800px">
<a:box column="2">
<a:hBox style="width:400px">
<a:textField width="350" name="description" bindTarget="csh_transaction_receipt_head_ds"/>
</a:hBox>
<!--#添加备注字段-->
<a:hBox style="width:800px">
</a:hBox>
<!--代理店简称-->
<a:lov name="extra_nam" bindTarget="csh_transaction_receipt_head_ds"
prompt="代理店简称"/>
</a:box>
<a:box column="2">
<!--#添加备注字段-->
<a:hBox style="width:400px">
<a:textField width="350" name="ref_v05" prompt="CSH511.CSH_TRANSACTION.STATEMENT"
bindTarget="csh_transaction_receipt_head_ds"/>
</a:hBox>
<!--担保人履行担保义务-->
<a:comboBox name="guarantor_name_duty" bindTarget="csh_transaction_receipt_head_ds"
prompt="担保人履行担保义务"/>
</a:box>
</a:fieldSet>
<!--删除下面的字段 currency_name,bank_account_name,banka,bank_branch_name,bank_account_num,bank_account_type_name,exchange_rate_type_display-->
<!-- <a:comboBox name="currency_name" bindTarget="csh_transaction_receipt_head_ds"/>
......
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