Commit 1affd26a authored by gzj34291's avatar gzj34291

日立返还金银行回单上传功能

parent f8c23132
......@@ -116,7 +116,7 @@
</bm:primary-key>
<bm:data-filters>
<bm:data-filter name="query" expression="(t1.company_id=${/session/@company_id} and t1.posted_flag=&apos;Y&apos; and t1.reversed_flag=&apos;N&apos; and returned_flag not in ( &apos;RETURN&apos;) and t1.transaction_type in (&apos;RECEIPT&apos;,&apos;ADVANCE_RECEIPT&apos;) and (nvl(t1.returned_amount, 0)+nvl(t1.write_off_amount, 0)&lt;=t1.transaction_amount)) "/>
<!-- <bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;) and t1.write_off_flag in(&apos;NOT&apos;,&apos;PARTIAL&apos;))"/>-->
<!-- <bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;) and t1.write_off_flag in(&apos;NOT&apos;,&apos;PARTIAL&apos;))"/>-->
<bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;))"/>
</bm:data-filters>
<bm:query-fields>
......
......@@ -21,6 +21,7 @@
<a:link id="csh515_amount_return_link" url="${/request/@context_path}/modules/csh/CSH515/csh_amount_return.lview"/>
<a:link id="csh515_get_layout_link" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/>
<a:link id="csh_transaction_receipt_maintain_readonly_link" url="${/request/@context_path}/modules/csh/CSH510/csh_transaction_hand_receipt_update_readonly.lview"/>
<a:link id="prj500_cdd_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/>
<script type="text/javascript"><![CDATA[
function dateValidator(record, name, value) { //日期校验方法
if (name == 'transaction_date_from' || name == 'transaction_date_to') {
......@@ -51,12 +52,18 @@
dirty_flag = 'Y';
}
}
if (dirty_flag == 'N') {
Leaf.showConfirm('${l:PROMPT}', '${l:CSH510.CSH_RECEIPT_QUERY_INFORMATION}', function() {
return;
}, function() {
$('csh_transaction_receipt_return_maintain_ds').query();
}, null, null);
// Leaf.showConfirm('${l:PROMPT}', '${l:CSH510.CSH_RECEIPT_QUERY_INFORMATION}', function() {
// return false;
// }
// , function() {
// $('csh_transaction_receipt_return_maintain_ds').query();
// }, null, null);
Leaf.showConfirm('${l:PROMPT}', '${l:CSH510.CSH_RECEIPT_QUERY_INFORMATION}');
return false;
} else {
$('csh_transaction_receipt_return_maintain_ds').query();
}
......@@ -86,6 +93,47 @@
return '<a href="javascript:openWindow(\'' + url + '\');">' + value + '</a>';
}
}
function attachment_uploadFile(value, record, name) {
if (name == 'attachment') {
var role_code = '${/model/role_info/record/@role_code}';
if (role_code !== '0008'&&role_code !== '0014'&&role_code !== '0014-1'&&role_code !== '0017'&&role_code !== 'HAND') {
return null;
}
return '<a href="javascript:prj501n_upload_file(\'' + record.get('transaction_id') + '\');">' +'附件上传'+ '</a>';
} else if (name == 'attach_file_name') {
if (value != null) {
var link = '${/request/@context_path}/atm_download.lsc?attachment_id=';
var str = value.split(';;');
var url = '';
for (var i = 0; i < str.length; i++) {
//
var temp = str[i].split('--');
if (!Leaf.isEmpty(temp[0])) {
url = url + '<a href=' + link + temp[1] + '>' + temp[0] + '</a>' + ',';
}
}
return url;
}
}
}
function prj501n_upload_file(transaction_id) {
if (transaction_id) {
var url;
url = $('prj500_cdd_uploadFile_id').getUrl() + '?table_name=CON_CONTRACT_BANK&header_id=' + transaction_id;
}
var win = new Leaf.Window({
url: url,
title: '${l:HLS.SUPPORTING_DOCUMENT}',
id: 'prj500_cdd_uploadFile_screen_id',
width: 850,
height: 400
});
win.on('close', function () {
$('csh_transaction_receipt_return_maintain_ds').query();
});
}
function openWindow(url) {
new Leaf.Window({
......@@ -274,6 +322,7 @@
<a:dataSet id="returned_flag_ds" lookupCode="CSH510_RETURN_SELECT"/>
<a:dataSet id="reversed_flag_ds" lookupCode="CSH510_REVERSE_SELECT"/>
<a:dataSet id="ds_collection_classes_ds" lookupCode="DS_COLLECTION_CLASSES"/>
<a:dataSet id="attachment_return_ds" lookupCode="ATTACHMENT_RETURN"/>
<a:dataSet id="csh_transaction_receipt_maintain_query_ds" autoCreate="true">
<a:fields>
<a:field name="payment_method_display" displayField="description" options="payment_method_ds" returnField="payment_method_id" valueField="payment_method_id"/>
......@@ -389,18 +438,23 @@
<a:field name="currency_code_from"/>
<a:field name="currency_name_to_display" displayField="currency_name" options="currency_ds" returnField="currency_code_to" valueField="currency_code"/>
<a:field name="currency_code_to"/>
<a:field name="transaction_category" defaultValue="BUSINESS"/>
<!-- <a:field name="transaction_category" defaultValue="BUSINESS"/>-->
<a:field name="transaction_category" />
<a:field name="write_off_flag"/>
<a:field name="collection_classes"/>
<a:field name="collection_classes_desc" options="ds_collection_classes_ds"
prompt="款项用途"
displayField="code_value_name" returnField="collection_classes" valueField="code_value"/>
<a:field name="attachment_return"/>
<a:field name="attachment_return_desc" options="attachment_return_ds"
prompt="银行回单是否上传"
displayField="code_value_name" returnField="attachment_return" valueField="code_value"/>
</a:fields>
<a:events>
<a:event name="update" handler="csh510_receipt_maintain_update"/>
</a:events>
</a:dataSet>
<a:dataSet id="csh_transaction_receipt_return_maintain_ds" autoQuery="false" model="csh.CSH515.csh_transaction_receipt_return_query" queryDataSet="csh_transaction_receipt_maintain_query_ds" selectable="true" selectionModel="single">
<a:dataSet id="csh_transaction_receipt_return_maintain_ds" autoQuery="false" model="csh.CSH515.new_csh_transaction_receipt_return_query" queryDataSet="csh_transaction_receipt_maintain_query_ds" selectable="true" selectionModel="single">
<a:fields>
<a:field name="payment_method_display" displayField="description" options="payment_method_ds" returnField="payment_method_id" valueField="payment_method_id"/>
<a:field name="bank_account_code" autoComplete="true" autoCompleteField="bank_account_num" lovGridHeight="350" lovHeight="550" lovLabelWidth="90" lovService="csh.CSH101.csh_bank_account_lov" lovWidth="580" title="CSH511.BANK_ACCOUNT_CODE">
......@@ -464,6 +518,8 @@
<a:lov name="bp_name" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="CSH510.CSH_TRANSACTION.BUSINESS_PARTNER"/>
<a:textField name="contract_number" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="合同编号"/>
<a:comboBox name="collection_classes_desc" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="款项用途"/>
<a:comboBox name="attachment_return_desc" bindTarget="csh_transaction_receipt_maintain_query_ds" prompt="银行回单是否上传"/>
</a:fieldSet>
......@@ -484,6 +540,7 @@
<a:column name="bank_slip_num" prompt="银行流水号" align="center"/>
<a:column name="this_return_amount" prompt="退款中金额" align="right" renderer="Leaf.formatMoney"/>
<a:column name="returned_amount" renderer="Leaf.formatMoney" align="right"/>
<!-- <a:column name="posted_flag" prompt="HLS.POST"/> -->
<!-- <a:column name="bank_account_code" prompt="CSH511.BANK_ACCOUNT_CODE"/>
<a:column name="bank_account_name" prompt="CSH511.BANK_ACCOUNT_NAME"/>-->
......@@ -505,6 +562,9 @@
<a:column prompt="CSH510.CSH_TRANSACTION.ACCOUNT_BANK" name="opposite_band_na" align="center"/>
<a:column prompt="CSH510.CSH_TRANSACTION.ACCOUNT_NUM" name="bp_bank_account_num" align="center"/>
</a:column>
<a:column name="attachment" prompt="银行回单附件上传" renderer="attachment_uploadFile" width="120" align="center"/>
<a:column name="attach_file_name" prompt="银行回单文件" renderer="attachment_uploadFile" width="120" align="center"/>
</a:columns>
</a:grid>
</a:screenBody>
......
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