Mercurial > hg > ismi-richfaces
annotate src/main/webapp/browse/entityDetails.xhtml @ 148:b40a84944716
add public/private editing to Entity Details.
author | Robert Casties <casties@mpiwg-berlin.mpg.de> |
---|---|
date | Tue, 11 Jul 2017 17:44:50 +0200 |
parents | 1389c83028ef |
children | 2522985f44af |
rev | line source |
---|---|
7 | 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
2 <html xmlns="http://www.w3.org/1999/xhtml" | |
3 xmlns:h="http://java.sun.com/jsf/html" | |
4 xmlns:f="http://java.sun.com/jsf/core" | |
5 xmlns:ui="http://java.sun.com/jsf/facelets" | |
6 xmlns:a4j="http://richfaces.org/a4j" | |
7 xmlns:rich="http://richfaces.org/rich"> | |
8 | |
9 <body> | |
10 <ui:composition template="/templates/publicTemplate.xhtml"> | |
11 | |
12 <ui:define name="publicContent"> | |
13 | |
14 <h:outputStylesheet name="/css/ismi-db/repository.css" /> | |
15 | |
16 <div id="pageTitle"> | |
17 <h:outputText value="Entity Details" /> | |
18 </div> | |
19 | |
20 <h:panelGrid columns="1" | |
21 style="margin-left: auto; margin-right: auto; text-align: center; width: 700px"> | |
22 | |
23 <hr/> | |
24 | |
25 <h:panelGrid columns="3" styleClass="controlPanel"> | |
26 <h:outputLabel value="ID" /> | |
27 <h:inputText value="#{Session.entDetailsForm.currentEntityId}" /> | |
28 <a4j:commandButton value="Submit" | |
29 actionListener="#{Session.entDetailsForm.listenerShowEntity}" | |
30 render="entityDetailsPanel" /> | |
31 </h:panelGrid> | |
32 | |
33 <hr/> | |
34 | |
35 <h:panelGrid columns="1" | |
36 rendered="#{Session.entDetailsForm.entity.id != null}" | |
37 style="width: 100%;"> | |
38 | |
39 <h:panelGrid columns="1" style="text-align:left;color: #3B4186;"> | |
40 <h:outputText | |
41 value="#{Session.entDetailsForm.entity.objectClass}: #{Session.entDetailsForm.entity.ownValue}" /> | |
42 | |
43 <h:outputText | |
44 value="[ID=#{Session.entDetailsForm.entity.id}, Version=#{Session.entDetailsForm.entity.version}, #{Session.entDetailsForm.entity.privacity}]" | |
45 style="font-size: 9pt;"/> | |
46 <h:panelGroup | |
47 style="display: block;margin-left: auto;margin-right: auto;"> | |
48 <h:commandButton value="Edit" title="Edit this entity" | |
49 image="#{ApplicationBean1.imgEdit32}" | |
50 rendered="#{Session.canEdit}" | |
51 action="#{Session.entDetailsForm.actionEdit}" | |
52 style="margin-right: 20px;" /> | |
53 <h:commandButton value="Get previous versions" | |
54 title="Get previous versions" rendered="#{Session.canEdit}" | |
55 image="#{ApplicationBean1.imgVersions32}" | |
56 actionListener="#{Session.entDetailsForm.listenerGetPreviousVersions}" | |
57 style="margin-right: 20px;" /> | |
58 <h:commandButton value="Remove" title="Remove this entity" | |
59 rendered="#{Session.canDelete}" | |
60 image="#{ApplicationBean1.imgRemove32}" | |
61 onclick="if(!confirm('Do you really want to remove this entity?')){ return; };" | |
62 action="#{Session.entDetailsForm.listenerDeleteEntity}" | |
63 style="margin-right: 20px;" /> | |
64 </h:panelGroup> | |
65 <h:outputText | |
66 value="Modified by: #{Session.entDetailsForm.entity.user} - Last modification: #{Session.entDetailsForm.entity.timeStamp}" | |
67 style="font-size: 9pt;"/> | |
68 </h:panelGrid> | |
69 | |
70 <hr/> | |
71 | |
72 <h:panelGrid id="entityDetailsPanel" columns="1" | |
73 styleClass="entityDetailsPanel" columnClasses="createPanelFirstColumn"> | |
74 | |
148
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
75 <h:outputText value="Publication state: #{Session.entDetailsForm.entity.privacity}" styleClass="titlePanel"/> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
76 |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
77 <h:panelGroup |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
78 rendered="#{Session.canEdit}" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
79 style="display:block; margin-left:auto; margin-right:auto;"> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
80 |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
81 <a4j:commandButton value="Make entity public" title="Change publication state of this entity" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
82 rendered="#{!Session.entDetailsForm.entity.isPublic}" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
83 style="margin-right:10px;" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
84 onclick="if(!confirm('Do you really want to make this entity public?')){ return; };" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
85 action="#{Session.entDetailsForm.actionChangeEntityPrivacity}"/> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
86 <a4j:commandButton value="Make entity private" title="Change publication state of this entity" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
87 rendered="#{Session.entDetailsForm.entity.isPublic}" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
88 style="margin-right:10px;" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
89 onclick="if(!confirm('Do you really want to make this entity private?')){ return; };" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
90 action="#{Session.entDetailsForm.actionChangeEntityPrivacity}"/> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
91 |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
92 <a4j:commandButton value="Make related entities public" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
93 title="Change publication state of directly related entities" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
94 rendered="#{Session.entDetailsForm.entity.isPublic}" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
95 style="margin-right:10px;" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
96 onclick="if(!confirm('Do you really want to make all related entities public?')){ return; };" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
97 action="#{Session.entDetailsForm.actionChangeRelatedEntitiesPrivacity}"/> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
98 <a4j:commandButton value="Make related entities private" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
99 title="Change publication state of directly related entities" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
100 rendered="#{!Session.entDetailsForm.entity.isPublic}" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
101 style="margin-right:10px;" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
102 onclick="if(!confirm('Do you really want to make all related entities private?')){ return; };" |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
103 action="#{Session.entDetailsForm.actionChangeRelatedEntitiesPrivacity}"/> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
104 |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
105 </h:panelGroup> |
b40a84944716
add public/private editing to Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
147
diff
changeset
|
106 |
7 | 107 <h:outputText value="Attributes" styleClass="titlePanel"/> |
108 | |
109 <rich:dataTable id="entity" | |
110 value="#{Session.entDetailsForm.attributeList}" var="attribute" | |
111 rendered="#{!empty Session.entDetailsForm.attributeList}" | |
112 styleClass="mainPanel" | |
113 columnClasses="mainPanelcolumn01,mainPanelcolumn02"> | |
114 | |
115 <h:column rendered="#{ApplicationBean1.confService.debugModus}"> | |
116 <f:facet name="header"> | |
117 <h:outputText value="Debug" /> | |
118 </f:facet> | |
119 <h:outputText value="#{attribute.id} - #{attribute.rowId}" /> | |
120 </h:column> | |
121 <h:column> | |
122 <f:facet name="header"> | |
123 <h:outputText value="Name" /> | |
124 </f:facet> | |
125 <h:outputText value="#{attribute.name}" /> | |
126 </h:column> | |
127 <h:column> | |
128 <f:facet name="header"> | |
129 <h:outputText value="Value" /> | |
130 </f:facet> | |
131 <h:outputText value="#{attribute.value}" /> | |
132 </h:column> | |
133 </rich:dataTable> | |
134 | |
135 <h:outputText value="Source Relations" styleClass="titlePanel"/> | |
136 | |
137 <rich:dataTable var="srcName" | |
138 value="#{Session.entDetailsForm.sourceRelationNames}" | |
139 styleClass="mainPanel" | |
140 columnClasses="mainPanelcolumn01"> | |
141 <h:column | |
142 rendered="#{Session.entDetailsForm.sourceRelationCount[srcName] != '0'}"> | |
143 | |
144 <h:outputText | |
145 value="#{srcName} [#{Session.entDetailsForm.sourceRelationCount[srcName]}]" /> | |
146 <h:commandLink value="show" | |
147 actionListener="#{Session.entDetailsForm.listenerShowSourceRelations}" | |
148 rendered="#{empty Session.entDetailsForm.sourceRelations[srcName]}" | |
149 styleClass="showLink"/> | |
150 | |
151 <rich:dataTable var="srcRelation" | |
152 value="#{Session.entDetailsForm.sourceRelations[srcName]}" | |
153 rendered="#{!empty Session.entDetailsForm.sourceRelations[srcName]}" | |
154 styleClass="internalPanel" | |
155 columnClasses="internalPanelColumn,internalPanelColumn,internalPanelColumnLeft"> | |
156 | |
157 <h:column> | |
158 <f:facet name="header"> | |
159 <h:outputText value="linked from this" /> | |
160 </f:facet> | |
161 <h:outputText value="#{'x'}" /> | |
162 </h:column> | |
163 | |
164 <h:column> | |
165 <f:facet name="header"> | |
166 <h:outputText value="Relation Name" /> | |
167 </f:facet> | |
168 <h:outputText value="#{srcRelation.ownValue}" /> | |
169 </h:column> | |
170 <h:column> | |
171 <f:facet name="header"> | |
172 <h:outputText value="linked to this" /> | |
173 </f:facet> | |
174 <h:panelGrid styleClass="attLink"> | |
175 <h:outputLink | |
176 value="#{ApplicationBean1.root}/browse/entityDetails.xhtml?eid=#{srcRelation.target.id}"> | |
177 <h:outputText | |
147
1389c83028ef
show public information in Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
7
diff
changeset
|
178 value="[#{srcRelation.target.objectClass}] #{srcRelation.target.ownValue} [#{srcRelation.target.id}, #{srcRelation.target.privacity}]" /> |
7 | 179 </h:outputLink> |
180 </h:panelGrid> | |
181 | |
182 </h:column> | |
183 <h:column rendered="#{ApplicationBean1.confService.debugModus}"> | |
184 <h:panelGrid columns="1"> | |
185 <h:outputLabel value="user=#{srcRelation.user}" /> | |
186 <h:outputLabel value="id=#{srcRelation.id}" /> | |
187 <h:outputLabel value="rowId=#{srcRelation.rowId}" /> | |
188 </h:panelGrid> | |
189 </h:column> | |
190 </rich:dataTable> | |
191 | |
192 </h:column> | |
193 </rich:dataTable> | |
194 | |
195 <h:outputText value="Target Relations" styleClass="titlePanel"/> | |
196 | |
197 <rich:dataTable var="tarName" | |
198 value="#{Session.entDetailsForm.targetRelationNames}" | |
199 styleClass="mainPanel" | |
200 columnClasses="mainPanelcolumn01"> | |
201 <h:column | |
202 rendered="#{Session.entDetailsForm.targetRelationCount[tarName] != '0'}"> | |
203 | |
204 <h:outputText | |
205 value="#{tarName} [#{Session.entDetailsForm.targetRelationCount[tarName]}]" /> | |
206 <h:commandLink value="show" | |
207 actionListener="#{Session.entDetailsForm.listenerShowTargetRelations}" | |
208 rendered="#{empty Session.entDetailsForm.targetRelations[tarName]}" | |
209 styleClass="showLink"/> | |
210 | |
211 <rich:dataTable var="tarRelation" | |
212 value="#{Session.entDetailsForm.targetRelations[tarName]}" | |
213 rendered="#{!empty Session.entDetailsForm.targetRelations[tarName]}" | |
214 styleClass="internalPanel" | |
215 columnClasses="internalPanelColumnLeft,internalPanelColumn,internalPanelColumn"> | |
216 <h:column> | |
217 <f:facet name="header"> | |
218 <h:outputText value="linked from this" /> | |
219 </f:facet> | |
220 <h:panelGrid styleClass="attLink"> | |
221 <h:outputLink | |
222 value="#{ApplicationBean1.root}/browse/entityDetails.xhtml?eid=#{tarRelation.source.id}"> | |
223 <h:outputText | |
147
1389c83028ef
show public information in Entity Details.
Robert Casties <casties@mpiwg-berlin.mpg.de>
parents:
7
diff
changeset
|
224 value="[#{tarRelation.source.objectClass}] #{tarRelation.source.ownValue} [#{tarRelation.source.id}, #{tarRelation.source.privacity}]" /> |
7 | 225 </h:outputLink> |
226 </h:panelGrid> | |
227 | |
228 </h:column> | |
229 <h:column> | |
230 <f:facet name="header"> | |
231 <h:outputText value="Relation Name" /> | |
232 </f:facet> | |
233 <h:outputText value="#{tarRelation.ownValue}" /> | |
234 </h:column> | |
235 <h:column> | |
236 <f:facet name="header"> | |
237 <h:outputText value="linked to this" /> | |
238 </f:facet> | |
239 <h:outputText value="#{'x'}" /> | |
240 </h:column> | |
241 | |
242 <h:column rendered="#{ApplicationBean1.confService.debugModus}"> | |
243 <h:panelGrid columns="1"> | |
244 <h:outputLabel value="user=#{tarRelation.user}" /> | |
245 <h:outputLabel value="id=#{tarRelation.id}" /> | |
246 <h:outputLabel value="rowId=#{tarRelation.rowId}" /> | |
247 </h:panelGrid> | |
248 </h:column> | |
249 </rich:dataTable> | |
250 </h:column> | |
251 </rich:dataTable> | |
252 | |
253 </h:panelGrid> | |
254 </h:panelGrid> | |
255 </h:panelGrid> | |
256 </ui:define> | |
257 </ui:composition> | |
258 </body> | |
259 </html> |