ibsAccountSummary.jsp

Zahir Abd Latif, November 03, 2021 20:00

Download (14.5 KB)

 
1
<%@ taglib uri="/WEB-INF/tld/struts-html.tld" prefix="html" %>
2
<%@ taglib uri="/WEB-INF/tld/struts-html-el.tld" prefix="htmlEL" %>
3
<%@ taglib uri="/WEB-INF/tld/struts-bean.tld" prefix="bean" %>
4
<%@ taglib uri="/WEB-INF/tld/c.tld" prefix="c" %>
5

    
6
<%@ page import="org.apache.commons.beanutils.DynaBean" %>
7
<%@ page import="java.util.List" %>
8
<%@ page import="java.util.Iterator" %>
9

    
10
<%
11
	List errorBeansList = (List) session.getAttribute("errorBeansList");
12
	if (null!=errorBeansList&&!errorBeansList.isEmpty())
13
	{
14
		if (errorBeansList.size() == 0)
15
		{
16
%>
17
			<c:set var="isErrorThrown" value="false"></c:set>
18
<%
19
		}
20
		else 
21
		{
22
%>
23
			<c:set var="isErrorThrown" value="true"></c:set>
24
<%
25
		}
26
	}
27
%>
28
<h1><c:out value="${navigationDTO.map.nodeName}"/></h1>
29

    
30
<c:set var="formBean" value="${fbAccountSummary}" scope="request"/>
31
<c:set var="viewBean" value="${formBean.map.viewBean}" scope="request"/>
32
<c:set var="serviceInfo" value="${viewBean.map.serviceInfoBean}" />
33

    
34
<c:choose>
35
	<c:when test="${isErrorThrown eq 'true'}">
36
		<table id="errorTable">
37
			<tr>
38
				<td><span id="serverSideError" class="error"><jsp:include flush="true" page="/jsp/errorHandler.jsp"></jsp:include></span></td>
39
			</tr>
40
		</table>
41
		<br/>
42
	</c:when>
43
	<c:otherwise>
44
		<c:set var="pagination" value="${viewBean.map.pagination}" />
45
		
46
		<c:if test="${not empty viewBean}">		
47
			<c:choose>
48
				<c:when test="${empty viewBean.map.summaryCAList and empty viewBean.map.summarySAList and empty viewBean.map.summaryCCList and empty viewBean.map.summaryTDList and empty viewBean.map.summaryLAList}">
49
					<bean:message key="common.error.display.no.valid.account"/>
50
					<table id="errorTable">
51
						<tr>
52
							<td>
53
								<span id="serverSideError" class="error"><jsp:include flush="true" page="/jsp/errorHandler.jsp"></jsp:include></span>
54
							</td>
55
						</tr>
56
					</table>
57
				</c:when>
58
				<c:otherwise>
59
					<c:choose>
60
						<c:when test="${serviceInfo.status eq 1}"><div><bean:write name="serviceInfo" property="offlineMessage" filter="false"/></div></c:when>
61
					<c:otherwise>
62
					
63
					<c:if test="${(not empty viewBean.map.serviceInfo) && (not empty serviceInfo.mainNote1)}">
64
						<div id="notes">
65
					       <h5><bean:message key="general.note" /></h5>
66
					       <p><bean:write name="serviceInfo" property="mainNote1" filter="false"/></p>
67
					    </div>
68
					</c:if>
69
				
70
					<c:if test="${pagination.totalPageNumber gt 1}">
71
						<jsp:include flush="true" page="/jsp/ib102_enquiry/summary/ibsAccountSummaryPagination.jsp"></jsp:include>
72
					</c:if>
73

    
74
					<div>
75
						<c:if test="${viewBean.map.caSize gt 0}">
76
							<table class="tabsummary" width="100%" cellspacing="0" cellpadding="10" border="0">
77
								<thead>
78
									<tr>
79
										<th class="header" width="50%"><bean:message key="ib102.summary.label.current.account" /></th>
80
										<th class="headerRight" width="50%" align="left"><bean:message key="general.label.available.balance" /></th>
81
										<th class="header">&nbsp;</th>
82
									</tr>
83
								</thead>
84
								<tbody>
85
									<c:forEach var="account" items="${viewBean.map.summaryCAList}" varStatus="index">
86
										<c:if test="${index.count mod 2 eq 0}">
87
											<bean:define id="trClass1" value="even" />
88
										</c:if>
89
										<c:if test="${index.count mod 2 ne 0}">
90
											<bean:define id="trClass1" value="alt" />
91
										</c:if>
92
										<tr class="<bean:write name="trClass1"/>">
93
											<c:choose>
94
												<c:when test="${not empty account.accountStatus}">
95
													<td class="title">
96
														<c:url var="acctInfo" value="/ib102/ibAccountInfo.do">
97
															<c:param name="acctIndex" value="${account.index}"></c:param>
98
															<c:param name="acctType" value="${account.accountType}"></c:param>
99
															<c:forEach var="item" items="${navigationDTO.map.URLParams}">
100
																<c:param name="${item.key}" value="${item.value}"></c:param>
101
															</c:forEach>
102
														</c:url> 
103
														
104
														<a href="<c:out value="${acctInfo}"/>" onclick="overlay();">
105
															<u><bean:write name="account" property="productName" /></u>
106
														</a><br/>
107
														<bean:write name="account" property="accountNumber" />
108
														<bean:write name="account" property="accountNickname" />
109
													</td>
110
													<td class="balance" width="30%"><bean:write name="account" property="currentBalance" /></td>
111
												</c:when>
112
												<c:otherwise>
113
													<td class="title">
114
														<bean:write name="account" property="productName" /><br/>
115
														<bean:write name="account" property="accountNumber" />
116
														<bean:write name="account" property="accountNickname" />
117
													</td>
118
													<td class="balance"><bean:write name="account" property="currentBalance" /></td>
119
												</c:otherwise>
120
											</c:choose>
121
										</tr>
122
									</c:forEach>
123
								</tbody>
124
							</table>
125
							<br/>
126
						</c:if>
127
						
128
						<c:if test="${viewBean.map.saSize gt 0}">
129
							<table class="tabsummary" width="100%" cellspacing="0" cellpadding="10" border="0">
130
								<thead>
131
									<tr>
132
										<th class="header" width="50%"><bean:message key="ib102.summary.label.savings.account" /></th>
133
										<th class="headerRight" width="50%" align="left"><bean:message key="general.label.available.balance" /></th>
134
										<th class="header">&nbsp;</th>
135
									</tr>
136
								</thead>
137
								<tbody>
138
									<c:forEach var="account" items="${viewBean.map.summarySAList}" varStatus="index">
139
										<c:if test="${index.count mod 2 eq 0}">
140
											<bean:define id="trClass1" value="even" />
141
										</c:if>
142
										<c:if test="${index.count mod 2 ne 0}">
143
											<bean:define id="trClass1" value="alt" />
144
										</c:if>
145
										<tr class="<bean:write name="trClass1"/>">
146
											<c:choose>
147
												<c:when test="${not empty account.accountStatus}">
148
													<td class="title">
149
														<c:url var="acctInfo" value="/ib102/ibAccountInfo.do">
150
															<c:param name="acctIndex" value="${account.index}"></c:param>
151
															<c:param name="acctType" value="${account.accountType}"></c:param>
152
															<c:forEach var="item" items="${navigationDTO.map.URLParams}">
153
																<c:param name="${item.key}" value="${item.value}"></c:param>
154
															</c:forEach>
155
														</c:url> 
156
														
157
														<a href="<c:out value="${acctInfo}"/>" onclick="overlay();">
158
															<u><bean:write name="account" property="productName" /></u>
159
														</a><br/>
160
														<bean:write name="account" property="accountNumber" />
161
														<bean:write name="account" property="accountNickname" />
162
													</td>
163
													<td class="balance" width="30%"><bean:write name="account" property="currentBalance" /></td>
164
												</c:when>
165
												<c:otherwise>
166
													<td class="title">
167
														<bean:write name="account" property="productName" /><br/>
168
														<bean:write name="account" property="accountNumber" />
169
														<bean:write name="account" property="accountNickname" />
170
													</td>
171
													<td class="balance"><bean:write name="account" property="currentBalance" /></td>
172
												</c:otherwise>
173
											</c:choose>
174
										</tr>
175
									</c:forEach>
176
								</tbody>
177
							</table>
178
							<br/>
179
						</c:if>
180
						
181
						<c:if test="${viewBean.map.ccSize gt 0}">
182
							<table class="tabsummary" width="100%" cellspacing="0" cellpadding="10" border="0">
183
								<thead>
184
									<tr>
185
										<th class="header" width="50%"><bean:message key="ib102.summary.label.credit.card" /></th>
186
										<th class="headerRight" width="50%" align="left"><bean:message key="general.label.last.amount.due" /></th>
187
										<th class="header">&nbsp;</th>
188
									</tr>
189
								</thead>
190
								<tbody>
191
									<c:forEach var="account" items="${viewBean.map.summaryCCList}" varStatus="index">
192
										<c:if test="${index.count mod 2 eq 0}">
193
											<bean:define id="trClass1" value="even" />
194
										</c:if>
195
										<c:if test="${index.count mod 2 ne 0}">
196
											<bean:define id="trClass1" value="alt" />
197
										</c:if>
198
										<tr class="<bean:write name="trClass1"/>">
199
											<c:choose>
200
												<c:when test="${not empty account.accountStatus}">
201
													<td class="title">
202
														<c:url var="acctInfo" value="/ib102/ibAccountInfo.do">
203
															<c:param name="acctIndex" value="${account.index}"></c:param>
204
															<c:param name="acctType" value="${account.accountType}"></c:param>
205
															<c:forEach var="item" items="${navigationDTO.map.URLParams}">
206
																<c:param name="${item.key}" value="${item.value}"></c:param>
207
															</c:forEach>
208
														</c:url> 
209
														
210
														<a href="<c:out value="${acctInfo}"/>" onclick="overlay();">
211
															<u><bean:write name="account" property="productName" /></u>
212
														</a><br/>
213
														<bean:write name="account" property="accountNumber" />
214
														<bean:write name="account" property="accountNickname" />
215
													</td>
216
													<td class="balance" width="30%"><bean:write name="account" property="fullAmountDisplay" /></td>
217
												</c:when>
218
												<c:otherwise>
219
													<td class="title">
220
														<bean:write name="account" property="productName" /><br/>
221
														<bean:write name="account" property="accountNumber" />
222
														<bean:write name="account" property="accountNickname" />
223
													</td>
224
													<td class="balance"><bean:write name="account" property="currentBalance" /></td>
225
												</c:otherwise>
226
											</c:choose>
227
										</tr>
228
									</c:forEach>
229
								</tbody>
230
							</table>
231
							<br/>
232
						</c:if>
233
						
234
						<c:if test="${viewBean.map.tdSize gt 0}">
235
							<table class="tabsummary" width="100%" cellspacing="0" cellpadding="10" border="0">
236
								<thead>
237
									<tr>
238
										<th class="header" width="50%"><bean:message key="ib102.summary.label.time.deposit" /></th>
239
										<th class="headerRight" width="50%"><bean:message key="general.label.available.balance" /></th>
240
										<th class="header">&nbsp;</th>
241
									</tr>
242
								</thead>
243
								<tbody>
244
									<c:forEach var="account" items="${viewBean.map.summaryTDList}" varStatus="index">
245
										<c:if test="${index.count mod 2 eq 0}">
246
											<bean:define id="trClass1" value="even" />
247
										</c:if>
248
										<c:if test="${index.count mod 2 ne 0}">
249
											<bean:define id="trClass1" value="alt" />
250
										</c:if>
251
										<tr class="<bean:write name="trClass1"/>">
252
											<c:choose>
253
												<c:when test="${not empty account.accountStatus}">
254
													<td class="title">
255
														<c:url var="acctInfo" value="/ib102/ibAccountInfo.do">
256
															<c:param name="acctIndex" value="${account.index}"></c:param>
257
															<c:param name="acctType" value="${account.accountType}"></c:param>
258
															<c:forEach var="item" items="${navigationDTO.map.URLParams}">
259
																<c:param name="${item.key}" value="${item.value}"></c:param>
260
															</c:forEach>
261
														</c:url> 
262
															<a href="<c:out value="${acctInfo}"/>" onclick="overlay();">
263
															<u><bean:write name="account" property="productName" /></u>
264
														</a><br/>
265
														
266
														<bean:write name="account" property="accountNumber" />
267
														<bean:write name="account" property="accountNickname" />
268
													</td>
269
													<td class="balance" width="30%"><bean:write name="account" property="currentBalance" /></td>
270
												</c:when>
271
												<c:otherwise>
272
													<td class="title">
273
														<bean:write name="account" property="productName" /><br/>
274
														<bean:write name="account" property="accountNumber" />
275
														<bean:write name="account" property="accountNickname" />
276
													</td>
277
													<td class="balance"><bean:write name="account" property="currentBalance" /></td>
278
												</c:otherwise>
279
											</c:choose>
280
										</tr>
281
									</c:forEach>
282
										<tr>
283
										<td colspan="3"><h6><bean:message key="ib102.remarks.time.deposit" /></h6></td>
284
										</tr>
285
								</tbody>
286
							</table>
287
							<br/>
288
						</c:if>
289
						
290
						<c:if test="${viewBean.map.laSize gt 0}">
291
							<table class="tabsummary" width="100%" cellspacing="0" cellpadding="10" border="0">
292
								<thead>
293
									<tr>
294
										<th class="header" width="50%"><bean:message key="ib102.summary.label.loan.account" /></th>
295
										<th class="headerRight" width="50%"><bean:message key="account.detail.loan.outstanding" /></th>
296
										<th class="header">&nbsp;</th>
297
									</tr>
298
								</thead>
299
								<tbody>
300
									<c:forEach var="account" items="${viewBean.map.summaryLAList}" varStatus="index">
301
										<c:if test="${index.count mod 2 eq 0}">
302
											<bean:define id="trClass1" value="even" />
303
										</c:if>
304
										<c:if test="${index.count mod 2 ne 0}">
305
											<bean:define id="trClass1" value="alt" />
306
										</c:if>
307
										<tr class="<bean:write name="trClass1"/>">
308
											<td class="title">
309
												<c:url var="acctInfo" value="/ib102/ibAccountInfo.do">
310
													<c:param name="acctIndex" value="${account.index}"></c:param>
311
													<c:param name="acctType" value="${account.accountType}"></c:param>
312
													<c:forEach var="item" items="${navigationDTO.map.URLParams}">
313
														<c:param name="${item.key}" value="${item.value}"></c:param>
314
													</c:forEach>
315
												</c:url> 
316
												
317
												<a href="<c:out value="${acctInfo}"/>" onclick="overlay();">
318
													<u><bean:write name="account" property="productName" /></u>
319
												</a>
320
												<br/>
321
												<bean:write name="account" property="accountNumber" />
322
												<bean:write name="account" property="accountNickname" />
323
											</td>
324
											<td class="balance"><bean:write name="account" property="currentBalance" /></td>
325
										</tr>
326
									</c:forEach>
327
								</tbody>
328
							</table>
329
							<br/>
330
						</c:if>
331
					</div>
332
					</c:otherwise>
333
					</c:choose>
334
				
335
				</c:otherwise>
336
			</c:choose>
337

    
338
			
339
			<c:if test="${pagination.totalPageNumber gt 1}">
340
				<jsp:include flush="true" page="/jsp/ib102_enquiry/summary/ibsAccountSummaryPagination.jsp"></jsp:include>
341
			</c:if>
342
		</c:if>
343
	</c:otherwise>
344
</c:choose>