1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: zhangxing5129
$Date: 2013-9-9 下午02:04:08
$Revision: 1.0
$Purpose: 已收租金
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application">
<a:view>
<a:link id="csh_transaction_repayment_detail_query_link" url="${/request/@context_path}/modules/cont/CON305/con_contract_payment_transaction_detaill.lview"/>
<a:link id="csh_transaction_receipt_detail_query_link" url="${/request/@context_path}/modules/cont/CON305/con_contract_reception_transaction_detail.lview"/>
<script type="text/javascript"><![CDATA[
function close() {
$('con_contract_payment_detail_win').close();
}
function con_contract_payment_detail_clear() {
$('con_contract_payment_detail_line_grid').clear();
}
function con_contract_payment_detail_query() {
$('con_contract_payment_detail_line_ds').query();
}
function write_off_due_amount_renderer(value, record, name) {
if (value > 0) {
var transaction_type = record.get('transaction_type');
var csh_transaction_id = record.get('csh_transaction_id');
if (transaction_type == 'RECEIPT') {
return '<a href="javascript:open_transaction_receipt_detail_win(' + csh_transaction_id + ')">' + Leaf.formatMoney(value) + '</a>';
} else if (transaction_type == 'PAYMENT') {
return '<a href="javascript:open_transaction_repayment_detail_win(' + csh_transaction_id + ')">' + Leaf.formatMoney(value) + '</a>';
}
}
}
function open_transaction_receipt_detail_win(csh_transaction_id) {
new Leaf.Window({
id: 'transaction_receipt_detail_win',
url: $('csh_transaction_receipt_detail_query_link').getUrl(),
title: '收款明细',
params: {
'winId': 'transaction_receipt_detail_win',
'transaction_id': csh_transaction_id
},
fullScreen: true
});
}
function open_transaction_repayment_detail_win(csh_transaction_id) {
new Leaf.Window({
id: 'transaction_receipt_detail_win',
url: $('csh_transaction_repayment_detail_query_link').getUrl(),
title: '付款明细',
params: {
'winId': 'transaction_receipt_detail_win',
'transaction_id': csh_transaction_id
},
fullScreen: true
});
}
]]></script>
<a:dataSets>
<a:dataSet id="con_contract_payment_detail_ds" autoQuery="true" model="cont.CON305N.con_contract_payment_detail_header" queryUrl="${/request/@context_path}/autocrud/cont.CON305.con_contract_payment_detail_header/query?contract_id=${/parameter/@contract_id}">
<a:fields>
<a:field name="bp_name" readOnly="true"/>
<a:field name="document_type_desc" readOnly="true"/>
<a:field name="contract_number" readOnly="true"/>
<a:field name="total_rental" readOnly="true"/>
<a:field name="total_received" readOnly="true"/>
<a:field name="total_balance" readOnly="true"/>
<a:field name="overdue_amount" readOnly="true"/>
</a:fields>
</a:dataSet>
<a:dataSet id="con_contract_payment_detail_line_ds" autoPageSize="true" autoQuery="true" model="cont.CON305.con_contract_payment_detail_line" queryUrl="${/request/@context_path}/autocrud/cont.CON305.con_contract_payment_detail_line/query?contract_id=${/parameter/@contract_id}" selectable="true"/>
</a:dataSets>
<a:screenBody>
<a:screenTopToolbar>
<a:gridButton click="close" text="HLS.CLOSE"/>
<a:gridButton click="con_contract_payment_detail_clear" text="HLS.CLEAR"/>
<a:gridButton click="con_contract_payment_detail_query" text="HLS.QUERY"/>
</a:screenTopToolbar>
<a:form column="4" labelWidth="100" title="HLS.QUERY_TITLE">
<a:textField name="bp_name" bindTarget="con_contract_payment_detail_ds" colspan="2" prompt="HLS.CUSTOMER_NAME" readOnly="true" width="408"/>
<a:textField name="contract_number" bindTarget="con_contract_payment_detail_ds" prompt="HLS.CONTRACT_NUMBER" readOnly="true" width="150"/>
<a:textField name="document_type_desc" bindTarget="con_contract_payment_detail_ds" prompt="HLS.CONTRACT_TYPE" readOnly="true" width="150"/>
<a:numberField name="total_rental" allowFormat="true" bindTarget="con_contract_payment_detail_ds" prompt="CON305.TOTAL_RENTAL" readOnly="true" width="150"/>
<a:numberField name="total_received" allowFormat="true" bindTarget="con_contract_payment_detail_ds" prompt="CON305.TOTAL_RENANT_RECEIVED" readOnly="true" width="150"/>
<a:numberField name="total_balance" allowFormat="true" bindTarget="con_contract_payment_detail_ds" prompt="CON305.UNRECEIVED_TOTAL_RENANT" readOnly="true" width="150"/>
<a:numberField name="overdue_amount" allowFormat="true" bindTarget="con_contract_payment_detail_ds" prompt="CON305.OVERDUE_AMOUNT" readOnly="true" width="150"/>
</a:form>
<a:grid id="con_contract_payment_detail_line_grid" bindTarget="con_contract_payment_detail_line_ds" marginHeight="240" marginWidth="30" navBar="true">
<a:columns>
<!-- <a:column name="bp_name" prompt="HLS.CUSTOMER_NAME" width="200"/> -->
<!-- <a:column name="contract_number" prompt="HLS.CONTRACT_NUMBER" width="125"/> -->
<a:column name="tran_bp_name" prompt="CON305.TRAN_BP_NAME" width="225"/>
<a:column name="times" prompt="CON305.TIMES" width="50"/>
<a:column name="cf_item_desc" prompt="CON305.CF_ITEM" width="100"/>
<a:column name="due_date" prompt="CON305.DUE_DATE" renderer="Leaf.formatDate" width="80"/>
<a:column name="acc_due_amount_rental" align="right" prompt="CON305.ACC_AMOUNT" renderer="Leaf.formatMoney"/>
<a:column name="acc_due_amount_principal" align="right" prompt="CON305.ACC_PRINCIPAL" renderer="Leaf.formatMoney"/>
<a:column name="acc_due_amount_interest" align="right" prompt="CON305.ACC_INTEREST" renderer="Leaf.formatMoney"/>
<a:column name="transaction_date" prompt="CON305.LAST_RECEIVED_DATE" renderer="Leaf.formatDate" width="80"/>
<a:column name="write_off_due_amount" align="right" prompt="CON305.WRITE_OFF_DUE_AMOUNT_F" renderer="write_off_due_amount_renderer"/>
<a:column name="write_off_principal" align="right" prompt="CON305.WRITE_OFF_PRINCIPAL" renderer="Leaf.formatMoney"/>
<a:column name="write_off_interest" align="right" prompt="CON305.WRITE_OFF_INTEREST" renderer="Leaf.formatMoney"/>
</a:columns>
</a:grid>
</a:screenBody>
</a:view>
</a:screen>