Commit a2ccdde1 authored by 高泉铭's avatar 高泉铭

[refactor] 反冲功能校验改造

parent 4417c30b
...@@ -51,6 +51,7 @@ ...@@ -51,6 +51,7 @@
hls_ebank_batch_pkg.create_ebank_batch( hls_ebank_batch_pkg.create_ebank_batch(
p_bank_account_id =>${@bank_account_id}, p_bank_account_id =>${@bank_account_id},
p_merger_rules =>${@merger_rules}, p_merger_rules =>${@merger_rules},
p_pay_method =>${@payment_method},
p_payment_amount_from =>${@payment_amount_from}, p_payment_amount_from =>${@payment_amount_from},
p_payment_amount_to =>${@payment_amount_to}, p_payment_amount_to =>${@payment_amount_to},
p_due_date =>to_date(${@due_date},'yyyy-mm-dd'), p_due_date =>to_date(${@due_date},'yyyy-mm-dd'),
......
...@@ -76,6 +76,7 @@ ...@@ -76,6 +76,7 @@
<bm:field name="auto_filt_prinicipal_interest" expression="&apos;Y&apos;" forInsert="false" forUpdate="false" prompt="CSH513.AUTO_FILT_PRINICIPAL_INTEREST"/> <bm:field name="auto_filt_prinicipal_interest" expression="&apos;Y&apos;" forInsert="false" forUpdate="false" prompt="CSH513.AUTO_FILT_PRINICIPAL_INTEREST"/>
<bm:field name="returned_flag_desc" forInsert="false" forUpdate="false" prompt="CSH511.CSH_TRANSACTION.RETURNED_FLAG"/> <bm:field name="returned_flag_desc" forInsert="false" forUpdate="false" prompt="CSH511.CSH_TRANSACTION.RETURNED_FLAG"/>
<bm:field name="receipt_type"/> <bm:field name="receipt_type"/>
<bm:field name="paid_byother_flag"/>
<bm:field name="receipt_type_des" expression="(select v.code_value_name from sys_code_values_v v where v.code=&apos;RECEIPT_TYPE&apos; and v.code_value=t1.receipt_type)"/> <bm:field name="receipt_type_des" expression="(select v.code_value_name from sys_code_values_v v where v.code=&apos;RECEIPT_TYPE&apos; and v.code_value=t1.receipt_type)"/>
<bm:field name="ref_n01"/> <bm:field name="ref_n01"/>
</bm:fields> </bm:fields>
......
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
para: { para: {
bank_account_id: record.get('bank_account_id'), bank_account_id: record.get('bank_account_id'),
merger_rules: record.get('merger_rules'), merger_rules: record.get('merger_rules'),
pay_method: record.get('pay_method'),
payment_amount_from: record.get('payment_amount_from'), payment_amount_from: record.get('payment_amount_from'),
payment_amount_to: record.get('payment_amount_to'), payment_amount_to: record.get('payment_amount_to'),
due_date: record.get('due_date') due_date: record.get('due_date')
...@@ -76,6 +77,13 @@ ...@@ -76,6 +77,13 @@
} }
]]></script> ]]></script>
<a:dataSets> <a:dataSets>
<a:dataSet id="pay_methods_ds">
<a:datas>
<a:record code_value="AGRI_THREE" code_value_name="农行扣款(三方)"/>
<a:record code_value="CCB_THREE" code_value_name="建行扣款(三方)"/>
<a:record code_value="AGRI_TWO" code_value_name="农行扣款(两方)"/>
</a:datas>
</a:dataSet>
<a:dataSet id="hls_ccb_form_create_ds" autoCreate="true"> <a:dataSet id="hls_ccb_form_create_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="bank_account_num" autoComplete="true" lovGridHeight="350" lovHeight="550" <a:field name="bank_account_num" autoComplete="true" lovGridHeight="350" lovHeight="550"
...@@ -89,13 +97,14 @@ ...@@ -89,13 +97,14 @@
<a:map from="currency_code" to="currency"/> <a:map from="currency_code" to="currency"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="pay_method_desc" required="true" prompt="支付方式" displayField="code_value_name" options="pay_methods_ds" returnField="pay_method" valueField="code_value"/>
<a:field name="pay_method"/>
<a:field name="bank_account_name" readOnly="true"/> <a:field name="bank_account_name" readOnly="true"/>
<a:field name="bank_name" readOnly="true"/> <a:field name="bank_name" readOnly="true"/>
<a:field name="currency" readOnly="true"/> <a:field name="currency" readOnly="true"/>
<a:field name="due_date" datatype="date" defaultValue="${/model/create_date_path/record/@now_date}" required="true" prompt="应收日期"/> <a:field name="due_date" datatype="date" defaultValue="${/model/create_date_path/record/@now_date}" required="true" prompt="应收日期"/>
<!--<a:field name="merger_rules" defaultValue="NONE"/>--> <a:field name="merger_rules" defaultValue="NONE"/>
<a:field name="merger_rules" defaultValue="CONTRACT"/> <!-- <a:field name="merger_rules" defaultValue="CONTRACT"/>-->
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
...@@ -112,18 +121,19 @@ ...@@ -112,18 +121,19 @@
<a:gridButton click="return_batch" text="返回"/> <a:gridButton click="return_batch" text="返回"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:fieldSet title="本方账户" column="2"> <a:fieldSet title="本方账户" column="3">
<a:lov name="bank_account_num" bindTarget="hls_ccb_form_create_ds" prompt="银行账户"/> <a:lov name="bank_account_num" bindTarget="hls_ccb_form_create_ds" prompt="银行账户"/>
<a:textField name="bank_account_name" bindTarget="hls_ccb_form_create_ds" prompt="账户名"/> <a:textField name="bank_account_name" bindTarget="hls_ccb_form_create_ds" prompt="账户名"/>
<a:textField name="bank_name" bindTarget="hls_ccb_form_create_ds" prompt="银行"/> <a:textField name="bank_name" bindTarget="hls_ccb_form_create_ds" prompt="银行"/>
<a:comboBox name="pay_method_desc" bindTarget="hls_ccb_form_create_ds" prompt="支付方式"/>
<a:textField name="currency" bindTarget="hls_ccb_form_create_ds" prompt="币种"/> <a:textField name="currency" bindTarget="hls_ccb_form_create_ds" prompt="币种"/>
</a:fieldSet> </a:fieldSet>
<a:fieldSet title="合并规则" column="2"> <a:fieldSet title="合并规则" column="2">
<a:radio name="merger_rules" bindTarget="hls_ccb_form_create_ds" layout="horizontal" width="600"> <a:radio name="merger_rules" bindTarget="hls_ccb_form_create_ds" layout="horizontal" width="600">
<a:items> <a:items>
<!--<a:item label="不合并" value="NONE"/>-->
<a:item label="按合同" value="CONTRACT"/> <a:item label="按合同" value="CONTRACT"/>
<a:item label="按期数" value="TIMES"/> <a:item label="按期数" value="TIMES"/>
<a:item label="不合并" value="NONE"/>
</a:items> </a:items>
</a:radio> </a:radio>
</a:fieldSet> </a:fieldSet>
......
...@@ -11,14 +11,15 @@ ...@@ -11,14 +11,15 @@
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="sys_service_welcome_link" url="${/request/@context_path}/welcome.lview"/> <a:link id="sys_service_welcome_link" url="${/request/@context_path}/welcome.lview"/>
<a:link id="csh_write_off_reverse_detail_link" url="${/request/@context_path}/modules/csh/CSH514/csh_transaction_receipt_write_off_reverse_detail.lview"/> <a:link id="csh_write_off_reverse_detail_link"
url="${/request/@context_path}/modules/csh/CSH514/csh_transaction_receipt_write_off_reverse_detail.lview"/>
<a:link id="create_je_link_id" model="csh.CSH514.csh_transaction_write_off_reverse" modelaction="execute"/> <a:link id="create_je_link_id" model="csh.CSH514.csh_transaction_write_off_reverse" modelaction="execute"/>
<script type="text/javascript"><![CDATA[ <script type="text/javascript"><![CDATA[
function dateValidator(record, name, value) { //日期校验方法 function dateValidator(record, name, value) { //日期校验方法
if (name == 'transaction_date_from' || name == 'transaction_date_to') { if (name == 'transaction_date_from' || name == 'transaction_date_to') {
var start_date = Leaf.formatDate(record.get('transaction_date_from')); var start_date = Leaf.formatDate(record.get('transaction_date_from'));
var end_date = Leaf.formatDate(record.get('transaction_date_to')); var end_date = Leaf.formatDate(record.get('transaction_date_to'));
if ( !! end_date) { //由于结束日期非必填,只有在结束日期填了才进行比较 if (!!end_date) { //由于结束日期非必填,只有在结束日期填了才进行比较
if (!compareDate(start_date, end_date)) { if (!compareDate(start_date, end_date)) {
return '${l:CSH510.CSH_RECEIPT_DATE_CHECK}'; //校验不通过返回字符串 return '${l:CSH510.CSH_RECEIPT_DATE_CHECK}'; //校验不通过返回字符串
} }
...@@ -44,9 +45,9 @@ ...@@ -44,9 +45,9 @@
} }
} }
if (dirty_flag == 'N') { if (dirty_flag == 'N') {
Leaf.showConfirm('${l:PROMPT}', '${l:CSH510.CSH_RECEIPT_QUERY_INFORMATION}', function() { Leaf.showConfirm('${l:PROMPT}', '${l:CSH510.CSH_RECEIPT_QUERY_INFORMATION}', function () {
return; return;
}, function() { }, function () {
$('csh_transaction_receipt_write_off_reverse_result_ds').query(); $('csh_transaction_receipt_write_off_reverse_result_ds').query();
}, null, null); }, null, null);
} else { } else {
...@@ -73,7 +74,7 @@ ...@@ -73,7 +74,7 @@
function seedetail_transaction_num(value, record, name) { function seedetail_transaction_num(value, record, name) {
if (record.get('transaction_id')) { if (record.get('transaction_id')) {
url = $('csh_write_off_reverse_detail_link').getUrl() + '?transaction_id=' + record.get('transaction_id') + '&transaction_type=' + record.get('transaction_type') + '&ref_n01=' + record.get('ref_n01'); url = $('csh_write_off_reverse_detail_link').getUrl() + '?transaction_id=' + record.get('transaction_id') + '&transaction_type=' + record.get('transaction_type') + '&ref_n01=' + record.get('ref_n01') + '&receipt_type=' + record.get('receipt_type') + '&bp_category=' + record.get('bp_category') + '&paid_byother_flag=' + record.get('paid_byother_flag');
return '<a href="javascript:openWindow(\'' + url + '\');">' + value + '</a>'; return '<a href="javascript:openWindow(\'' + url + '\');">' + value + '</a>';
} }
} }
...@@ -95,9 +96,9 @@ ...@@ -95,9 +96,9 @@
var pattern = ['_from', '_to']; var pattern = ['_from', '_to'];
var obj = {}; var obj = {};
for (var i = 0, for (var i = 0,
j = config.length;i < j;i++) { j = config.length; i < j; i++) {
for (var m = 0, for (var m = 0,
n = pattern.length;m < n;m++) { n = pattern.length; m < n; m++) {
obj[config[i] + pattern[m]] = config[i] + pattern[n - 1 - m]; obj[config[i] + pattern[m]] = config[i] + pattern[n - 1 - m];
} }
} }
...@@ -115,7 +116,7 @@ ...@@ -115,7 +116,7 @@
} }
} }
function csh514_create_je(){ function csh514_create_je() {
var ds = $('csh_transaction_receipt_write_off_reverse_result_ds'); var ds = $('csh_transaction_receipt_write_off_reverse_result_ds');
var record = ds.getCurrentRecord(); var record = ds.getCurrentRecord();
...@@ -126,7 +127,7 @@ ...@@ -126,7 +127,7 @@
para: { para: {
transaction_id: transaction_id transaction_id: transaction_id
}, },
success: function() { success: function () {
ds.query(); ds.query();
Leaf.SideBar.show({ Leaf.SideBar.show({
msg: '操作成功', msg: '操作成功',
...@@ -137,6 +138,7 @@ ...@@ -137,6 +138,7 @@
}); });
} }
]]></script> ]]></script>
<a:dataSets> <a:dataSets>
<a:dataSet id="currency_ds"> <a:dataSet id="currency_ds">
...@@ -144,7 +146,8 @@ ...@@ -144,7 +146,8 @@
</a:dataSet> </a:dataSet>
<a:dataSet id="csh_transaction_receipt_write_off_reverse_query_ds" autoCreate="true"> <a:dataSet id="csh_transaction_receipt_write_off_reverse_query_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="bp_type" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_type_v_for_lov" lovWidth="500" title="HLS_BP_TYPE.BP_TYPE"> <a:field name="bp_type" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_type_v_for_lov"
lovWidth="500" title="HLS_BP_TYPE.BP_TYPE">
<a:mapping> <a:mapping>
<a:map from="description" to="bp_type_desc"/> <a:map from="description" to="bp_type_desc"/>
<a:map from="bp_type" to="bp_type"/> <a:map from="bp_type" to="bp_type"/>
...@@ -156,7 +159,8 @@ ...@@ -156,7 +159,8 @@
<a:field name="bp_type_desc" readOnly="true"/> <a:field name="bp_type_desc" readOnly="true"/>
<a:field name="bp_category" readOnly="true"/> <a:field name="bp_category" readOnly="true"/>
<a:field name="bp_category_desc" readOnly="true"/> <a:field name="bp_category_desc" readOnly="true"/>
<a:field name="bp_code" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE"> <a:field name="bp_code" lovGridHeight="350" lovHeight="500"
lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE">
<a:mapping> <a:mapping>
<a:map from="bp_id" to="bp_id"/> <a:map from="bp_id" to="bp_id"/>
<a:map from="bp_name" to="bp_name"/> <a:map from="bp_name" to="bp_name"/>
...@@ -171,18 +175,26 @@ ...@@ -171,18 +175,26 @@
<a:field name="bank_slip_num_to"/> <a:field name="bank_slip_num_to"/>
<a:field name="transaction_date_from" validator="dateValidator"/> <a:field name="transaction_date_from" validator="dateValidator"/>
<a:field name="transaction_date_to" validator="dateValidator"/> <a:field name="transaction_date_to" validator="dateValidator"/>
<a:field name="bank_account_code_from" autoCompleteField="bank_account_num" lovGridHeight="350" lovHeight="550" lovLabelWidth="90" lovService="csh.CSH101.csh_bank_account_lov" lovWidth="580" title="CSH511.BANK_ACCOUNT_CODE"> <a:field name="bank_account_code_from" autoCompleteField="bank_account_num" lovGridHeight="350"
lovHeight="550" lovLabelWidth="90" lovService="csh.CSH101.csh_bank_account_lov"
lovWidth="580" title="CSH511.BANK_ACCOUNT_CODE">
<a:mapping> <a:mapping>
<a:map from="bank_account_code" to="bank_account_code_from"/> <a:map from="bank_account_code" to="bank_account_code_from"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="bank_account_from_id"/> <a:field name="bank_account_from_id"/>
<a:field name="bank_account_code_to" 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"> <a:field name="bank_account_code_to" 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">
<a:mapping> <a:mapping>
<a:map from="bank_account_code" to="bank_account_code_to"/> <a:map from="bank_account_code" to="bank_account_code_to"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="bank_account_name" 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"> <a:field name="bank_account_name" 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">
<a:mapping> <a:mapping>
<a:map from="bank_account_name" to="bank_account_name"/> <a:map from="bank_account_name" to="bank_account_name"/>
<a:map from="bank_account_num" to="bank_account_num"/> <a:map from="bank_account_num" to="bank_account_num"/>
...@@ -192,24 +204,29 @@ ...@@ -192,24 +204,29 @@
<a:field name="transaction_amount_from"/> <a:field name="transaction_amount_from"/>
<a:field name="transaction_amount_to"/> <a:field name="transaction_amount_to"/>
<a:field name="posted_flag" defaultValue="Y"/> <a:field name="posted_flag" defaultValue="Y"/>
<a:field name="currency_name_from_display" displayField="currency_name" options="currency_ds" returnField="currency_code_from" valueField="currency_code"/> <a:field name="currency_name_from_display" displayField="currency_name" options="currency_ds"
returnField="currency_code_from" valueField="currency_code"/>
<a:field name="currency_code_from"/> <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_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="currency_code_to"/>
<a:field name="receipt" checkedValue="RECEIPT" defaultValue="RECEIPT" uncheckedValue="N"/> <a:field name="receipt" checkedValue="RECEIPT" defaultValue="RECEIPT" uncheckedValue="N"/>
<a:field name="advance_receipt" checkedValue="ADVANCE_RECEIPT" defaultValue="ADVANCE_RECEIPT" uncheckedValue="N"/> <a:field name="advance_receipt" checkedValue="ADVANCE_RECEIPT" defaultValue="ADVANCE_RECEIPT"
uncheckedValue="N"/>
<a:field name="transaction_category" defaultValue="BUSINESS"/> <a:field name="transaction_category" defaultValue="BUSINESS"/>
<a:field name="not_write_off_flag" defaultValue="NOT"/> <a:field name="not_write_off_flag" defaultValue="NOT"/>
<a:field name="reversed_flag" defaultValue="N"/> <a:field name="reversed_flag" defaultValue="N"/>
<a:field name="reverse_write_off_amount_flag" defaultValue="Y"/> <a:field name="reverse_write_off_amount_flag" defaultValue="Y"/>
<a:field name="bp_code_from" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE"> <a:field name="bp_code_from" lovGridHeight="350" lovHeight="500"
lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE">
<a:mapping> <a:mapping>
<a:map from="bp_id" to="bp_id_from"/> <a:map from="bp_id" to="bp_id_from"/>
<a:map from="bp_name" to="bp_name_from"/> <a:map from="bp_name" to="bp_name_from"/>
<a:map from="bp_code" to="bp_code_from"/> <a:map from="bp_code" to="bp_code_from"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="bp_code_to" lovGridHeight="350" lovHeight="500" lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE"> <a:field name="bp_code_to" lovGridHeight="350" lovHeight="500"
lovService="basic.hls_bp_master_v_for_lov" lovWidth="500" title="HLS.BP_TITLE">
<a:mapping> <a:mapping>
<a:map from="bp_id" to="bp_id_to"/> <a:map from="bp_id" to="bp_id_to"/>
<a:map from="bp_name" to="bp_name_to"/> <a:map from="bp_name" to="bp_name_to"/>
...@@ -221,7 +238,9 @@ ...@@ -221,7 +238,9 @@
<a:event name="update" handler="csh514_receipt_write_off_update"/> <a:event name="update" handler="csh514_receipt_write_off_update"/>
</a:events> </a:events>
</a:dataSet> </a:dataSet>
<a:dataSet id="csh_transaction_receipt_write_off_reverse_result_ds" model="csh.CSH510.csh_transaction_query" queryDataSet="csh_transaction_receipt_write_off_reverse_query_ds" selectable="true" selectionModel="single"/> <a:dataSet id="csh_transaction_receipt_write_off_reverse_result_ds" model="csh.CSH510.csh_transaction_query"
queryDataSet="csh_transaction_receipt_write_off_reverse_query_ds" selectable="true"
selectionModel="single"/>
</a:dataSets> </a:dataSets>
<a:screenBody> <a:screenBody>
<a:screenTopToolbar> <a:screenTopToolbar>
...@@ -231,9 +250,10 @@ ...@@ -231,9 +250,10 @@
<!-- <a:gridButton click="csh514_receipt_quit" text="HLS.EXIT"/> --> <!-- <a:gridButton click="csh514_receipt_quit" text="HLS.EXIT"/> -->
<a:gridButton click="csh514_receipt_query" text="HLS.QUERY"/> <a:gridButton click="csh514_receipt_query" text="HLS.QUERY"/>
<a:gridButton click="csh514_receipt_reset" text="HLS.RESET"/> <a:gridButton click="csh514_receipt_reset" text="HLS.RESET"/>
<a:gridButton click="csh514_create_je" text="补生成凭证"/> <!-- <a:gridButton click="csh514_create_je" text="补生成凭证"/>-->
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" column="4" labelWidth="120" marginWidth="35" title="CSH514.RECEIPT_WRITE_OFF_REVERSE"> <a:form bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" column="4" labelWidth="120"
marginWidth="35" title="CSH514.RECEIPT_WRITE_OFF_REVERSE">
<!-- <a:lov name="bp_type" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_TYPE"/> <!-- <a:lov name="bp_type" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_TYPE"/>
<a:textField name="bp_type_desc" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_TYPE_NAME"/> <a:textField name="bp_type_desc" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_TYPE_NAME"/>
<a:textField name="bp_category" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_CATEGORY"/> <a:textField name="bp_category" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH513.CSH_BP_CATEGORY"/>
...@@ -260,25 +280,40 @@ ...@@ -260,25 +280,40 @@
<!--<a:textField name="bp_name_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.BP_NAME_TO" readOnly="true"/>--> <!--<a:textField name="bp_name_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.BP_NAME_TO" readOnly="true"/>-->
<!--<a:textField name="transaction_num_from" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.RECEIPT_TRANSACTION_NUMBER_FROM"/>--> <!--<a:textField name="transaction_num_from" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.RECEIPT_TRANSACTION_NUMBER_FROM"/>-->
<!--<a:textField name="transaction_num_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.RECEIPT_TRANSACTION_NUMBER_TO"/>--> <!--<a:textField name="transaction_num_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.RECEIPT_TRANSACTION_NUMBER_TO"/>-->
<a:datePicker name="transaction_date_from" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH510.CSH_TRANSACTION.TRANSACTION_DATE_FROM"/> <a:datePicker name="transaction_date_from"
<a:datePicker name="transaction_date_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH510.CSH_TRANSACTION.TRANSACTION_DATE_TO"/> bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
<a:numberField name="transaction_amount_from" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="收款金额从"/> prompt="CSH510.CSH_TRANSACTION.TRANSACTION_DATE_FROM"/>
<a:numberField name="transaction_amount_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="收款金额到"/> <a:datePicker name="transaction_date_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="CSH510.CSH_TRANSACTION.TRANSACTION_DATE_TO"/>
<a:numberField name="transaction_amount_from"
bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="收款金额从"/>
<a:numberField name="transaction_amount_to"
bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="收款金额到"/>
<!--<a:comboBox name="currency_name_from_display" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.CURRENCY_FROM"/>--> <!--<a:comboBox name="currency_name_from_display" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.CURRENCY_FROM"/>-->
<!--<a:comboBox name="currency_name_to_display" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.CURRENCY_TO"/>--> <!--<a:comboBox name="currency_name_to_display" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.CURRENCY_TO"/>-->
<a:textField name="bp_bank_account_name" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="对方账户名称"/> <a:textField name="bp_bank_account_name" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
<a:textField name="bp_bank_account_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="对方账号"/> prompt="对方账户名称"/>
<a:lov name="bank_account_name" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="我方账户名称"/> <a:textField name="bp_bank_account_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="对方账号"/>
<a:lov name="bank_account_name" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="我方账户名称"/>
<!-- <a:textField name="bank_account_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="我方账号" readOnly="true"/>--> <!-- <a:textField name="bank_account_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="我方账号" readOnly="true"/>-->
<a:textField name="transaction_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="现金事务编号"/> <a:textField name="transaction_num" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="现金事务编号"/>
<!--<a:lov name="bank_account_code_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH510.CSH_TRANSACTION.BANK_ACCOUNT_CODE_TO"/>--> <!--<a:lov name="bank_account_code_to" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="CSH510.CSH_TRANSACTION.BANK_ACCOUNT_CODE_TO"/>-->
<a:checkBox name="receipt" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.RECEIPT"/> <a:checkBox name="receipt" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
<a:checkBox name="advance_receipt" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="HLS.ADVANCE_RECEIPT"/> prompt="HLS.RECEIPT"/>
<a:textField name="contract_number_r" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="合同编号"/> <a:checkBox name="advance_receipt" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
<a:textField name="bp_name_r" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds" prompt="客户名称"/> prompt="HLS.ADVANCE_RECEIPT"/>
<a:textField name="contract_number_r" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="合同编号"/>
<a:textField name="bp_name_r" bindTarget="csh_transaction_receipt_write_off_reverse_query_ds"
prompt="客户名称"/>
</a:form> </a:form>
<a:grid id="csh_transaction_receipt_write_off_grid_ds" bindTarget="csh_transaction_receipt_write_off_reverse_result_ds" marginHeight="260" marginWidth="35" navBar="true"> <a:grid id="csh_transaction_receipt_write_off_grid_ds"
bindTarget="csh_transaction_receipt_write_off_reverse_result_ds" marginHeight="260" marginWidth="35"
navBar="true">
<!-- <a:columns> <!-- <a:columns>
<a:column name="transaction_num" align="center" prompt="CSH511.CSH_TRANSACTION.TRANSACTION_NUM" renderer="seedetail_transaction_num" width="120"/> <a:column name="transaction_num" align="center" prompt="CSH511.CSH_TRANSACTION.TRANSACTION_NUM" renderer="seedetail_transaction_num" width="120"/>
<a:column name="transaction_date" align="center" renderer="Leaf.formatDate" width="120"/> <a:column name="transaction_date" align="center" renderer="Leaf.formatDate" width="120"/>
...@@ -290,11 +325,12 @@ ...@@ -290,11 +325,12 @@
<a:column name="bp_name" align="center" width="120"/> <a:column name="bp_name" align="center" width="120"/>
<a:column name="transaction_type_desc" align="center" width="120"/> <a:column name="transaction_type_desc" align="center" width="120"/>
</a:columns> --> </a:columns> -->
<a:toolBar> <!-- <a:toolBar>-->
<a:button type="excel"/> <!-- <a:button type="excel"/>-->
</a:toolBar> <!-- </a:toolBar>-->
<a:columns> <a:columns>
<a:column name="transaction_num" align="center" renderer="seedetail_transaction_num" prompt="现金事务编号" width="120"/> <a:column name="transaction_num" align="center" renderer="seedetail_transaction_num" prompt="现金事务编号"
width="120"/>
<a:column name="transaction_date" align="center" renderer="Leaf.formatDate" width="120"/> <a:column name="transaction_date" align="center" renderer="Leaf.formatDate" width="120"/>
<!--<a:column name="bp_code" align="center" width="120"/>--> <!--<a:column name="bp_code" align="center" width="120"/>-->
<!--<a:column name="bp_name" align="center" width="120"/>--> <!--<a:column name="bp_name" align="center" width="120"/>-->
...@@ -306,6 +342,7 @@ ...@@ -306,6 +342,7 @@
<a:column name="bank_account_num" width="120"/> <a:column name="bank_account_num" width="120"/>
<a:column name="bank_account_name" width="120"/> <a:column name="bank_account_name" width="120"/>
<a:column name="transaction_type_desc" align="center" prompt="事务类型" width="120"/> <a:column name="transaction_type_desc" align="center" prompt="事务类型" width="120"/>
<a:column name="receipt_type_des" align="center" prompt="收款类型" width="120"/>
</a:columns> </a:columns>
<a:editors> <a:editors>
<a:checkBox id="receipt_write_off_checkbox_id"/> <a:checkBox id="receipt_write_off_checkbox_id"/>
......
...@@ -11,8 +11,10 @@ ...@@ -11,8 +11,10 @@
<a:model-query fetchAll="true" model="csh.CSH510.csh_transaction_query" rootPath="csh_value"/> <a:model-query fetchAll="true" model="csh.CSH510.csh_transaction_query" rootPath="csh_value"/>
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="csh_transaction_write_off_reverse_link_id" url="${/request/@context_path}/modules/csh/CSH514/csh_transaction_write_off_reverse_new.lsc"/> <a:link id="csh_transaction_write_off_reverse_link_id"
<a:link id="csh514_write_off_reverse_link_id" model="csh.CSH514.csh_transaction_write_off_reverse" modelaction="batch_update"/> url="${/request/@context_path}/modules/csh/CSH514/csh_transaction_write_off_reverse_new.lsc"/>
<a:link id="csh514_write_off_reverse_link_id" model="csh.CSH514.csh_transaction_write_off_reverse"
modelaction="batch_update"/>
<a:link id="get_period_name_id" model="csh.CSH511.csh_transaction_get_period_name" modelaction="query"/> <a:link id="get_period_name_id" model="csh.CSH511.csh_transaction_get_period_name" modelaction="query"/>
<script type="text/javascript"><![CDATA[ <script type="text/javascript"><![CDATA[
...@@ -23,12 +25,13 @@ ...@@ -23,12 +25,13 @@
if ($('csh_transaction_receipt_write_off_reverse_detail_head_ds').validate()) { if ($('csh_transaction_receipt_write_off_reverse_detail_head_ds').validate()) {
var head_record = $('csh_transaction_receipt_write_off_reverse_detail_head_ds').getAt(0); var head_record = $('csh_transaction_receipt_write_off_reverse_detail_head_ds').getAt(0);
var records = $('csh_transaction_receipt_write_off_reverse_detail_result_ds').getSelected(); var records = $('csh_transaction_receipt_write_off_reverse_detail_result_ds').getSelected();
var all = $('csh_transaction_receipt_write_off_reverse_detail_result_ds').getAll();
//var records = $('csh_transaction_receipt_write_off_reverse_detail_result_ds').getAll(); //var records = $('csh_transaction_receipt_write_off_reverse_detail_result_ds').getAll();
if (!records.length) { if (!records.length) {
Leaf.showMessage('${l:PROMPT}', '${l:CSH514.SELECT_REVERSE_RECORD}'); Leaf.showMessage('${l:PROMPT}', '${l:CSH514.SELECT_REVERSE_RECORD}');
return; return;
} }
if (records[0].get('history_flag') ==='Y') { if (records[0].get('history_flag') === 'Y') {
Leaf.showConfirm('${l:PROMPT}', '该事务是历史事务,请检查是否进行了补生成凭证', function () { Leaf.showConfirm('${l:PROMPT}', '该事务是历史事务,请检查是否进行了补生成凭证', function () {
var saveData = []; var saveData = [];
for (var i = 0; i < records.length; i++) { for (var i = 0; i < records.length; i++) {
...@@ -72,10 +75,27 @@ ...@@ -72,10 +75,27 @@
Leaf.Masker.unmask(win_body); Leaf.Masker.unmask(win_body);
return; return;
}, null, null); }, null, null);
},null) }, null)
}else{ } else {
var saveData = []; var saveData = [];
var receipt_type = '${/parameter/@receipt_tpye}';
var paid_byother_flag = '${/parameter/paid_byother_flag}';
var bp_category = '${/parameter/bp_category}';
alert(receipt_type);
alert(paid_byother_flag);
alert(bp_category);
if (receipt_type == 'WITHHOLD') { //划扣
if (all.length != records.length) {
Leaf.showInfoMessage("提示", "该现金事务不支付部分反冲");
return;
}
} else {
if (paid_byother_flag == 'F' && bp_category == 'TENANT') {
Leaf.showInfoMessage("提示", "该现金事务不支付部分反冲");
return;
}
}
for (var i = 0; i < records.length; i++) { for (var i = 0; i < records.length; i++) {
records[i].set('reversed_date', head_record.get('reversed_date')); records[i].set('reversed_date', head_record.get('reversed_date'));
records[i].set('description', head_record.get('description')); records[i].set('description', head_record.get('description'));
...@@ -177,9 +197,12 @@ ...@@ -177,9 +197,12 @@
<a:dataSets> <a:dataSets>
<a:dataSet id="csh_transaction_receipt_write_off_reverse_detail_head_ds" autoCreate="true"> <a:dataSet id="csh_transaction_receipt_write_off_reverse_detail_head_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="reversed_date" defaultValue="${/model/default_value/record/@now_time}" required="true"/> <a:field name="reversed_date" defaultValue="${/model/default_value/record/@now_time}"
<a:field name="reversed_period_name" defaultValue="${/model/default_value/record/@now_period_name}" readOnly="true" required="true"/> required="true"/>
<a:field name="transaction_date" defaultValue="${/model/csh_value/record/@transaction_date}" readOnly="true"/> <a:field name="reversed_period_name" defaultValue="${/model/default_value/record/@now_period_name}"
readOnly="true" required="true"/>
<a:field name="transaction_date" defaultValue="${/model/csh_value/record/@transaction_date}"
readOnly="true"/>
<a:field name="description" defaultValue="${l:HLS.REVERSE}"/> <a:field name="description" defaultValue="${l:HLS.REVERSE}"/>
</a:fields> </a:fields>
<a:events> <a:events>
...@@ -187,8 +210,10 @@ ...@@ -187,8 +210,10 @@
<a:event name="add" handler="on_write_off_reverse_detail_add"/> <a:event name="add" handler="on_write_off_reverse_detail_add"/>
</a:events> </a:events>
</a:dataSet> </a:dataSet>
<a:dataSet id="csh_transaction_receipt_write_off_reverse_detail_result_ds" autoQuery="true" fetchAll="true" model="csh.CSH514.csh_write_off" pageSize="15" <a:dataSet id="csh_transaction_receipt_write_off_reverse_detail_result_ds" autoQuery="true" fetchAll="true"
queryUrl="${/request/@context_path}/autocrud/csh.CSH514.csh_write_off/query?csh_transaction_id=${/parameter/@transaction_id}&amp;reversed_flag=N&amp;reverse_detail_flag=Y" selectable="true"> model="csh.CSH514.csh_write_off" pageSize="15"
queryUrl="${/request/@context_path}/autocrud/csh.CSH514.csh_write_off/query?csh_transaction_id=${/parameter/@transaction_id}&amp;reversed_flag=N&amp;reverse_detail_flag=Y"
selectable="true">
<a:fields> <a:fields>
<a:field name="due_date" datatype="java.util.Date"/> <a:field name="due_date" datatype="java.util.Date"/>
</a:fields> </a:fields>
...@@ -200,12 +225,19 @@ ...@@ -200,12 +225,19 @@
<a:gridButton click="csh514_write_off_reverse" text="HLS.REVERSE"/> <a:gridButton click="csh514_write_off_reverse" text="HLS.REVERSE"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form column="4" title="CSH514.CSH_WRITE_OFF_DETAIL"> <a:form column="4" title="CSH514.CSH_WRITE_OFF_DETAIL">
<a:datePicker name="reversed_date" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds" prompt="HLS.REVERSE_DATE"/> <a:datePicker name="reversed_date" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds"
<a:textField name="reversed_period_name" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds" prompt="HLS.REVERSE_PERIOD"/> prompt="HLS.REVERSE_DATE"/>
<a:datePicker name="transaction_date" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds" prompt="收款日期"/> <a:textField name="reversed_period_name"
<a:textField name="description" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds" prompt="HLS.NOTE" width="300"/> bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds"
prompt="HLS.REVERSE_PERIOD"/>
<a:datePicker name="transaction_date"
bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds" prompt="收款日期"/>
<a:textField name="description" bindTarget="csh_transaction_receipt_write_off_reverse_detail_head_ds"
prompt="HLS.NOTE" width="300"/>
</a:form> </a:form>
<a:grid id="csh_transaction_receipt_write_off_reverse_detail_grid_ds" bindTarget="csh_transaction_receipt_write_off_reverse_detail_result_ds" marginHeight="170" marginWidth="50" navBar="true"> <a:grid id="csh_transaction_receipt_write_off_reverse_detail_grid_ds"
bindTarget="csh_transaction_receipt_write_off_reverse_detail_result_ds" marginHeight="170"
marginWidth="50" navBar="true">
<a:columns> <a:columns>
<a:column name="write_off_type_name"/> <a:column name="write_off_type_name"/>
<a:column name="write_off_date" renderer="Leaf.formatDate"/> <a:column name="write_off_date" renderer="Leaf.formatDate"/>
......
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