96
|
1
|
|
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
3 <html xmlns="http://www.w3.org/1999/xhtml"
|
|
4 xmlns:h="http://java.sun.com/jsf/html"
|
|
5 xmlns:f="http://java.sun.com/jsf/core"
|
|
6 xmlns:ui="http://java.sun.com/jsf/facelets"
|
|
7 xmlns:a4j="http://richfaces.org/a4j"
|
|
8 xmlns:rich="http://richfaces.org/rich">
|
|
9
|
|
10 <body>
|
|
11 <ui:composition template="/templates/privateTemplate.xhtml">
|
|
12
|
|
13 <ui:define name="privateContent">
|
|
14
|
|
15 <div id="pageTitle">
|
|
16 <h:outputText value="Merge Import List" />
|
|
17 </div>
|
|
18
|
|
19 <h:panelGrid rendered="#{Session.user != null}"
|
|
20 styleClass="mainPanel" columns="1">
|
|
21
|
|
22
|
|
23
|
|
24 <h:panelGrid columns="2" styleClass="createPanel"
|
|
25 columnClasses="createPanelFirstColumn" id="loadListPanel">
|
|
26
|
|
27 <h:outputText value="Import File" />
|
|
28
|
|
29 <h:panelGrid columns="3">
|
|
30 <h:outputText value="#{Session.importMerge.importFilename}" />
|
|
31
|
|
32 <a4j:commandButton value="Load"
|
|
33 actionListener="#{Session.importMerge.loadImportFile}"
|
|
34 render="loadListPanel,loadingPanel" />
|
|
35
|
|
36 <h:outputText
|
|
37 value="#{Session.importMerge.importFileMsg}"
|
|
38 rendered="#{!empty Session.importMerge.importFileMsg}"
|
|
39 styleClass="textBack"/>
|
|
40 </h:panelGrid>
|
|
41 </h:panelGrid>
|
|
42
|
|
43 <h:panelGrid columns="2" styleClass="createPanel"
|
|
44 columnClasses="createPanelFirstColumn" id="loadingPanel"
|
|
45 rendered="#{Session.importMerge.importNodeListLength > 0}">
|
|
46
|
|
47 <h:outputText value="Import Nodes" />
|
|
48
|
|
49 <h:panelGrid columns="3">
|
|
50
|
|
51 <h:outputText value="Node #{Session.importMerge.importNodeIdx + 1} / #{Session.importMerge.importNodeListLength}"
|
|
52 styleClass="textBack"/>
|
|
53 <a4j:commandButton value="Skip"
|
|
54 actionListener="#{Session.importMerge.skipCurrentNode}"
|
|
55 render="loadingPanel,mergingPanel" />
|
|
56 <h:column>
|
|
57 <h:outputText
|
|
58 value="#{Session.importMerge.importNodeAsText}"
|
|
59 rendered="#{Session.importMerge.importNode != null}"
|
|
60 styleClass="textBack"/>
|
|
61 </h:column>
|
|
62
|
|
63 <h:outputText/>
|
|
64 <a4j:commandButton value="Load"
|
|
65 actionListener="#{Session.importMerge.loadFirstEntity}"
|
|
66 render="loadingPanel,mergingPanel" />
|
|
67 <h:outputText
|
|
68 value="#{Session.importMerge.importNodeMsg}"
|
|
69 rendered="#{! empty Session.importMerge.importNodeMsg}"
|
|
70 styleClass="textBack"/>
|
|
71 </h:panelGrid>
|
|
72
|
|
73 </h:panelGrid>
|
|
74
|
|
75 <h:panelGrid columns="1" id="mergingPanel">
|
|
76
|
|
77 <h:outputText value="Merge Mapping"
|
|
78 rendered="#{Session.importMerge.entitiesLoaded}"
|
|
79 styleClass="titlePanel"/>
|
|
80
|
|
81 <h:panelGrid columns="2" styleClass="createPanel"
|
|
82 columnClasses="createPanelFirstColumn,createPanelColumn02,createPanelColumn02"
|
|
83 rendered="#{Session.importMerge.entitiesLoaded}">
|
|
84
|
|
85
|
|
86 <h:outputText value="Attributes" />
|
|
87 <rich:dataTable var="attName"
|
|
88 value="#{Session.importMerge.attLabels}"
|
|
89 rendered="#{!empty Session.importMerge.attLabels}">
|
|
90 <h:column>
|
|
91 <f:facet name="header">
|
|
92 <h:outputText value="Attribute Name" />
|
|
93 </f:facet>
|
|
94 <h:outputText value="#{attName}" />
|
|
95 </h:column>
|
|
96 <h:column>
|
|
97 <f:facet name="header">
|
|
98 <h:outputText value="Value Old Entity" />
|
|
99 </f:facet>
|
|
100 <h:outputText
|
|
101 value="#{Session.importMerge.firstAttMap[attName]}" />
|
|
102 </h:column>
|
|
103 <h:column>
|
|
104 <f:facet name="header">
|
|
105 <h:outputText value="Value New Entity" />
|
|
106 </f:facet>
|
|
107 <h:outputText
|
|
108 value="#{Session.importMerge.secondAttMap[attName]}" />
|
|
109 </h:column>
|
|
110 <h:column style="width:300px;">
|
|
111 <f:facet name="header">
|
|
112 <h:outputText value="Select Value" />
|
|
113 </f:facet>
|
|
114 <h:selectOneRadio
|
|
115 value="#{Session.importMerge.selectedAtts[attName]}">
|
|
116 <f:selectItems value="#{Session.importMerge.attSelectItems}" />
|
|
117 </h:selectOneRadio>
|
|
118 </h:column>
|
|
119 </rich:dataTable>
|
|
120
|
|
121 </h:panelGrid>
|
|
122
|
|
123 <h:panelGrid columns="3" styleClass="createPanel"
|
|
124 columnClasses="createPanelFirstColumn,createPanelColumn02,createPanelColumn02"
|
|
125 rendered="#{Session.importMerge.entitiesLoaded}">
|
|
126
|
|
127
|
|
128 <h:outputText value="Source Relations" />
|
|
129
|
|
130 <h:panelGrid columns="1">
|
|
131 <rich:dataTable var="srcRelation"
|
|
132 rendered="#{!empty Session.importMerge.firstEntity.sourceRelations}"
|
|
133 value="#{Session.importMerge.firstEntity.sourceRelations}">
|
|
134
|
|
135 <h:column>
|
|
136 <f:facet name="header">
|
|
137 <h:outputText value="Relation Name" />
|
|
138 </f:facet>
|
|
139 <h:outputText value="#{srcRelation.ownValue}" />
|
|
140 </h:column>
|
|
141 <h:column>
|
|
142 <f:facet name="header">
|
|
143 <h:outputText value="linked to this" />
|
|
144 </f:facet>
|
|
145 <h:outputText
|
|
146 value="#{srcRelation.target.ownValue} [#{srcRelation.target.objectClass}-#{srcRelation.targetId}]" />
|
|
147 </h:column>
|
|
148
|
|
149 <h:column>
|
|
150 <h:selectOneRadio
|
|
151 value="#{Session.importMerge.selectedFirstSrcRelations[srcRelation.id]}">
|
|
152 <f:selectItems value="#{Session.importMerge.relSelectItems}" />
|
|
153 </h:selectOneRadio>
|
|
154 </h:column>
|
|
155
|
|
156 </rich:dataTable>
|
|
157
|
|
158 <h:outputText
|
|
159 value="The old entity does not have source relations"
|
|
160 rendered="#{empty Session.importMerge.firstEntity.sourceRelations}" />
|
|
161 </h:panelGrid>
|
|
162
|
|
163 <h:panelGrid columns="1">
|
|
164
|
|
165 <rich:dataTable var="srcRelation"
|
|
166 rendered="#{!empty Session.importMerge.secondEntity.sourceRelations}"
|
|
167 value="#{Session.importMerge.secondEntity.sourceRelations}">
|
|
168 <h:column>
|
|
169 <f:facet name="header">
|
|
170 <h:outputText value="Relation Name" />
|
|
171 </f:facet>
|
|
172 <h:outputText value="#{srcRelation.ownValue}" />
|
|
173 </h:column>
|
|
174 <h:column>
|
|
175 <f:facet name="header">
|
|
176 <h:outputText value="linked to this" />
|
|
177 </f:facet>
|
|
178 <h:outputText
|
|
179 value="#{srcRelation.target.ownValue} [#{srcRelation.target.objectClass}-#{srcRelation.targetId}]" />
|
|
180 </h:column>
|
|
181 <h:column>
|
|
182 <h:selectOneRadio
|
|
183 value="#{Session.importMerge.selectedSecondSrcRelations[srcRelation.id]}">
|
|
184 <f:selectItems value="#{Session.importMerge.relSelectItems}" />
|
|
185 </h:selectOneRadio>
|
|
186 </h:column>
|
|
187 </rich:dataTable>
|
|
188
|
|
189 <h:outputText
|
|
190 value="The new entity does not have source relations"
|
|
191 rendered="#{empty Session.importMerge.secondEntity.sourceRelations}" />
|
|
192
|
|
193 </h:panelGrid>
|
|
194
|
|
195
|
|
196 <h:outputText value="Target Relations" />
|
|
197
|
|
198 <h:panelGrid columns="1">
|
|
199 <rich:dataTable var="tarRelation"
|
|
200 rendered="#{!empty Session.importMerge.firstEntity.targetRelations}"
|
|
201 value="#{Session.importMerge.firstEntity.targetRelations}"
|
|
202 style="width:60%;">
|
|
203
|
|
204 <h:column>
|
|
205 <f:facet name="header">
|
|
206 <h:outputText value="linked from this" />
|
|
207 </f:facet>
|
|
208 <h:outputText
|
|
209 value="#{tarRelation.source.ownValue} [#{tarRelation.source.objectClass}-#{tarRelation.sourceId}]" />
|
|
210 </h:column>
|
|
211
|
|
212 <h:column>
|
|
213 <f:facet name="header">
|
|
214 <h:outputText value="Relation Name" />
|
|
215 </f:facet>
|
|
216 <h:outputText value="#{tarRelation.ownValue}" />
|
|
217 </h:column>
|
|
218
|
|
219 <h:column>
|
|
220 <h:selectOneRadio
|
|
221 value="#{Session.importMerge.selectedFirstTarRelations[tarRelation.id]}">
|
|
222 <f:selectItems value="#{Session.importMerge.relSelectItems}" />
|
|
223 </h:selectOneRadio>
|
|
224 </h:column>
|
|
225 </rich:dataTable>
|
|
226 <h:outputText
|
|
227 value="The old entity does not have target relations."
|
|
228 rendered="#{empty Session.importMerge.firstEntity.targetRelations}" />
|
|
229 </h:panelGrid>
|
|
230
|
|
231 <h:panelGrid columns="1">
|
|
232
|
|
233 <rich:dataTable var="tarRelation"
|
|
234 rendered="#{!empty Session.importMerge.secondEntity.targetRelations}"
|
|
235 value="#{Session.importMerge.secondEntity.targetRelations}"
|
|
236 style="width:60%;">
|
|
237
|
|
238 <h:column>
|
|
239 <f:facet name="header">
|
|
240 <h:outputText value="linked from this" />
|
|
241 </f:facet>
|
|
242 <h:outputText
|
|
243 value="#{tarRelation.source.ownValue} [#{tarRelation.source.objectClass}-#{tarRelation.sourceId}]" />
|
|
244 </h:column>
|
|
245
|
|
246 <h:column>
|
|
247 <f:facet name="header">
|
|
248 <h:outputText value="Relation Name" />
|
|
249 </f:facet>
|
|
250 <h:outputText value="#{tarRelation.ownValue}" />
|
|
251 </h:column>
|
|
252
|
|
253 <h:column>
|
|
254 <h:selectOneRadio
|
|
255 value="#{Session.importMerge.selectedSecondTarRelations[tarRelation.id]}">
|
|
256 <f:selectItems value="#{Session.importMerge.relSelectItems}" />
|
|
257 </h:selectOneRadio>
|
|
258 </h:column>
|
|
259
|
|
260 </rich:dataTable>
|
|
261
|
|
262 <h:outputText
|
|
263 value="The new entity does not have target relations"
|
|
264 rendered="#{empty Session.importMerge.secondEntity.targetRelations}" />
|
|
265
|
|
266 </h:panelGrid>
|
|
267 </h:panelGrid>
|
|
268
|
|
269 <h:panelGrid columns="2" styleClass="controlPanel"
|
|
270 rendered="#{Session.importMerge.entitiesLoaded}">
|
|
271
|
|
272 <a4j:commandButton value="Preview"
|
|
273 actionListener="#{Session.importMerge.preview}"
|
|
274 rendered="#{Session.importMerge.entitiesLoaded}"
|
|
275 render="mergingPanel" />
|
|
276
|
|
277 <a4j:commandButton value="Execute Merge"
|
|
278 actionListener="#{Session.importMerge.listenerExecuteMerge }"
|
|
279 rendered="#{Session.importMerge.entitiesLoaded}"
|
|
280 onclick="#{ApplicationBean1.JSConfirmationMerge}"
|
|
281 render="mergingPanel" />
|
|
282
|
|
283 </h:panelGrid>
|
|
284
|
|
285
|
|
286 <h:outputText value="Entity Preview"
|
|
287 rendered="#{!empty Session.importMerge.entResult}"
|
|
288 styleClass="titlePanel"/>
|
|
289 <h:panelGrid columns="2" styleClass="createPanel"
|
|
290 columnClasses="createPanelFirstColumn"
|
|
291 rendered="#{!empty Session.importMerge.entResult}">
|
|
292
|
|
293
|
|
294 <h:outputText value="Attributes" />
|
|
295 <rich:dataTable
|
|
296 value="#{Session.importMerge.entResult.attributes}"
|
|
297 var="attribute" border="1">
|
|
298 <h:column>
|
|
299 <f:facet name="header">
|
|
300 <h:outputText value="Name" />
|
|
301 </f:facet>
|
|
302 <h:outputText value="#{attribute.objectClass}" />
|
|
303 </h:column>
|
|
304 <h:column>
|
|
305 <f:facet name="header">
|
|
306 <h:outputText value="Value" />
|
|
307 </f:facet>
|
|
308 <h:outputText value="#{attribute.ownValue}" />
|
|
309 </h:column>
|
|
310 </rich:dataTable>
|
|
311
|
|
312
|
|
313 <h:outputText value="Source Relations" />
|
|
314 <rich:dataTable
|
|
315 value="#{Session.importMerge.entResult.sourceRelations}"
|
|
316 var="srcRelation" border="1">
|
|
317
|
|
318 <h:column>
|
|
319 <f:facet name="header">
|
|
320 <h:outputText value="linked from this" />
|
|
321 </f:facet>
|
|
322 <h:outputText value="#{'x'}" />
|
|
323 </h:column>
|
|
324
|
|
325 <h:column>
|
|
326 <f:facet name="header">
|
|
327 <h:outputText value="Relation Name" />
|
|
328 </f:facet>
|
|
329 <h:outputText value="#{srcRelation.ownValue}" />
|
|
330 </h:column>
|
|
331 <h:column>
|
|
332 <f:facet name="header">
|
|
333 <h:outputText value="linked to this" />
|
|
334 </f:facet>
|
|
335 <h:outputText
|
|
336 value="#{srcRelation.target.ownValue} [#{srcRelation.target.objectClass}]" />
|
|
337 </h:column>
|
|
338 </rich:dataTable>
|
|
339
|
|
340 <h:outputText value="Target Relations" />
|
|
341 <rich:dataTable
|
|
342 value="#{Session.importMerge.entResult.targetRelations}"
|
|
343 var="tarRelation" border="1">
|
|
344 <h:column>
|
|
345 <f:facet name="header">
|
|
346 <h:outputText value="linked from this" />
|
|
347 </f:facet>
|
|
348 <h:outputText
|
|
349 value="#{tarRelation.source.ownValue} [#{tarRelation.source.objectClass}]" />
|
|
350 </h:column>
|
|
351 <h:column>
|
|
352 <f:facet name="header">
|
|
353 <h:outputText value="Relation Name" />
|
|
354 </f:facet>
|
|
355 <h:outputText value="#{tarRelation.ownValue}" />
|
|
356 </h:column>
|
|
357 <h:column>
|
|
358 <f:facet name="header">
|
|
359 <h:outputText value="linked to this" />
|
|
360 </f:facet>
|
|
361 <h:outputText value="#{'x'}" />
|
|
362 </h:column>
|
|
363 </rich:dataTable>
|
|
364
|
|
365
|
|
366 </h:panelGrid>
|
|
367
|
|
368
|
|
369
|
|
370 </h:panelGrid>
|
|
371
|
|
372
|
|
373
|
|
374 </h:panelGrid>
|
|
375 </ui:define>
|
|
376 </ui:composition>
|
|
377 </body>
|
|
378 </html> |