2004 |
16 Feb 06 |
nicklas |
1 |
<%-- $Id$ |
2004 |
16 Feb 06 |
nicklas |
2 |
------------------------------------------------------------------ |
5425 |
23 Sep 10 |
nicklas |
Copyright (C) 2006 Jari Häkkinen, Nicklas Nordborg, Martin Svensson |
3675 |
16 Aug 07 |
jari |
Copyright (C) 2007 Johan Enell, Martin Svensson |
2004 |
16 Feb 06 |
nicklas |
5 |
|
2304 |
22 May 06 |
jari |
6 |
This file is part of BASE - BioArray Software Environment. |
2304 |
22 May 06 |
jari |
7 |
Available at http://base.thep.lu.se/ |
2004 |
16 Feb 06 |
nicklas |
8 |
|
2004 |
16 Feb 06 |
nicklas |
9 |
BASE is free software; you can redistribute it and/or |
2004 |
16 Feb 06 |
nicklas |
10 |
modify it under the terms of the GNU General Public License |
4476 |
05 Sep 08 |
jari |
11 |
as published by the Free Software Foundation; either version 3 |
2004 |
16 Feb 06 |
nicklas |
12 |
of the License, or (at your option) any later version. |
2004 |
16 Feb 06 |
nicklas |
13 |
|
2004 |
16 Feb 06 |
nicklas |
14 |
BASE is distributed in the hope that it will be useful, |
2004 |
16 Feb 06 |
nicklas |
15 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
2004 |
16 Feb 06 |
nicklas |
16 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
2004 |
16 Feb 06 |
nicklas |
17 |
GNU General Public License for more details. |
2004 |
16 Feb 06 |
nicklas |
18 |
|
2004 |
16 Feb 06 |
nicklas |
19 |
You should have received a copy of the GNU General Public License |
4510 |
11 Sep 08 |
jari |
20 |
along with BASE. If not, see <http://www.gnu.org/licenses/>. |
2004 |
16 Feb 06 |
nicklas |
21 |
------------------------------------------------------------------ |
2004 |
16 Feb 06 |
nicklas |
22 |
|
2004 |
16 Feb 06 |
nicklas |
23 |
@author Nicklas |
2004 |
16 Feb 06 |
nicklas |
24 |
@version 2.0 |
2004 |
16 Feb 06 |
nicklas |
25 |
--%> |
5426 |
24 Sep 10 |
nicklas |
26 |
<%@ page pageEncoding="UTF-8" session="false" |
2004 |
16 Feb 06 |
nicklas |
27 |
import="net.sf.basedb.core.SessionControl" |
2004 |
16 Feb 06 |
nicklas |
28 |
import="net.sf.basedb.core.DbControl" |
2004 |
16 Feb 06 |
nicklas |
29 |
import="net.sf.basedb.core.Item" |
2004 |
16 Feb 06 |
nicklas |
30 |
import="net.sf.basedb.core.Client" |
2004 |
16 Feb 06 |
nicklas |
31 |
import="net.sf.basedb.core.ItemQuery" |
2004 |
16 Feb 06 |
nicklas |
32 |
import="net.sf.basedb.core.Include" |
2004 |
16 Feb 06 |
nicklas |
33 |
import="net.sf.basedb.core.ItemResultIterator" |
2004 |
16 Feb 06 |
nicklas |
34 |
import="net.sf.basedb.core.ItemResultList" |
2004 |
16 Feb 06 |
nicklas |
35 |
import="net.sf.basedb.core.ItemContext" |
3552 |
06 Jul 07 |
martin |
36 |
import="net.sf.basedb.core.Nameable" |
2004 |
16 Feb 06 |
nicklas |
37 |
import="net.sf.basedb.core.Permission" |
2004 |
16 Feb 06 |
nicklas |
38 |
import="net.sf.basedb.core.PluginDefinition" |
2004 |
16 Feb 06 |
nicklas |
39 |
import="net.sf.basedb.core.query.Orders" |
2004 |
16 Feb 06 |
nicklas |
40 |
import="net.sf.basedb.core.query.Hql" |
2004 |
16 Feb 06 |
nicklas |
41 |
import="net.sf.basedb.core.plugin.GuiContext" |
2004 |
16 Feb 06 |
nicklas |
42 |
import="net.sf.basedb.core.plugin.Plugin" |
2004 |
16 Feb 06 |
nicklas |
43 |
import="net.sf.basedb.util.Enumeration" |
3552 |
06 Jul 07 |
martin |
44 |
import="net.sf.basedb.util.ShareableUtil" |
2004 |
16 Feb 06 |
nicklas |
45 |
import="net.sf.basedb.clients.web.Base" |
2401 |
21 Jun 06 |
martin |
46 |
import="net.sf.basedb.clients.web.PermissionUtil" |
2004 |
16 Feb 06 |
nicklas |
47 |
import="net.sf.basedb.clients.web.ModeInfo" |
2004 |
16 Feb 06 |
nicklas |
48 |
import="net.sf.basedb.clients.web.util.HTML" |
2753 |
20 Oct 06 |
nicklas |
49 |
import="net.sf.basedb.util.Values" |
4698 |
10 Dec 08 |
nicklas |
50 |
import="net.sf.basedb.util.formatter.Formatter" |
4698 |
10 Dec 08 |
nicklas |
51 |
import="net.sf.basedb.clients.web.formatter.FormatterFactory" |
4886 |
03 Apr 09 |
nicklas |
52 |
import="net.sf.basedb.clients.web.extensions.ExtensionsControl" |
4886 |
03 Apr 09 |
nicklas |
53 |
import="net.sf.basedb.clients.web.extensions.JspContext" |
4886 |
03 Apr 09 |
nicklas |
54 |
import="net.sf.basedb.clients.web.extensions.renderer.PrefixSuffixRenderer" |
7604 |
25 Feb 19 |
nicklas |
55 |
import="net.sf.basedb.clients.web.extensions.toolbar.ButtonAction" |
4886 |
03 Apr 09 |
nicklas |
56 |
import="net.sf.basedb.clients.web.extensions.toolbar.ToolbarUtil" |
7604 |
25 Feb 19 |
nicklas |
57 |
import="net.sf.basedb.clients.web.extensions.list.ListColumnAction" |
6045 |
03 Apr 12 |
nicklas |
58 |
import="net.sf.basedb.clients.web.extensions.list.ListColumnUtil" |
4886 |
03 Apr 09 |
nicklas |
59 |
import="net.sf.basedb.util.extensions.ExtensionsInvoker" |
4698 |
10 Dec 08 |
nicklas |
60 |
import="java.util.Date" |
3552 |
06 Jul 07 |
martin |
61 |
import="java.util.Iterator" |
2004 |
16 Feb 06 |
nicklas |
62 |
import="java.util.List" |
2004 |
16 Feb 06 |
nicklas |
63 |
import="java.util.Map" |
2004 |
16 Feb 06 |
nicklas |
64 |
%> |
2004 |
16 Feb 06 |
nicklas |
65 |
<%@ taglib prefix="base" uri="/WEB-INF/base.tld" %> |
2004 |
16 Feb 06 |
nicklas |
66 |
<%@ taglib prefix="tbl" uri="/WEB-INF/table.tld" %> |
4886 |
03 Apr 09 |
nicklas |
67 |
<%@ taglib prefix="ext" uri="/WEB-INF/extensions.tld" %> |
2004 |
16 Feb 06 |
nicklas |
68 |
<%! |
2004 |
16 Feb 06 |
nicklas |
69 |
private static final Item itemType = Item.CLIENT; |
2004 |
16 Feb 06 |
nicklas |
70 |
private static final GuiContext guiContext = new GuiContext(itemType, GuiContext.Type.LIST); |
2004 |
16 Feb 06 |
nicklas |
71 |
%> |
2004 |
16 Feb 06 |
nicklas |
72 |
<% |
2004 |
16 Feb 06 |
nicklas |
73 |
final SessionControl sc = Base.getExistingSessionControl(pageContext, Permission.DENIED, itemType); |
2004 |
16 Feb 06 |
nicklas |
74 |
final String ID = sc.getId(); |
2004 |
16 Feb 06 |
nicklas |
75 |
final boolean createPermission = sc.hasPermission(Permission.CREATE, itemType); |
2004 |
16 Feb 06 |
nicklas |
76 |
final ItemContext cc = Base.getAndSetCurrentContext(sc, itemType, null, null); |
2004 |
16 Feb 06 |
nicklas |
77 |
|
2004 |
16 Feb 06 |
nicklas |
78 |
final ModeInfo mode = ModeInfo.get(request.getParameter("mode")); |
2004 |
16 Feb 06 |
nicklas |
79 |
final String callback = request.getParameter("callback"); |
2004 |
16 Feb 06 |
nicklas |
80 |
final String title = mode.generateTitle("client application", "client applications"); |
7954 |
12 May 21 |
nicklas |
81 |
final DbControl dc = sc.newDbControl(":List "+itemType); |
2004 |
16 Feb 06 |
nicklas |
82 |
ItemResultIterator<Client> clients = null; |
2004 |
16 Feb 06 |
nicklas |
83 |
try |
2004 |
16 Feb 06 |
nicklas |
84 |
{ |
4698 |
10 Dec 08 |
nicklas |
85 |
Formatter<Date> dateFormatter = FormatterFactory.getDateFormatter(sc); |
2004 |
16 Feb 06 |
nicklas |
86 |
|
2004 |
16 Feb 06 |
nicklas |
87 |
Map<Plugin.MainType, Integer> pluginCount = PluginDefinition.countPlugins(dc, guiContext); |
7914 |
23 Feb 21 |
nicklas |
88 |
JspContext jspContext = ExtensionsControl.createContext(dc, pageContext, guiContext, null); |
2004 |
16 Feb 06 |
nicklas |
89 |
try |
2004 |
16 Feb 06 |
nicklas |
90 |
{ |
7914 |
23 Feb 21 |
nicklas |
91 |
final ItemQuery<Client> query = Base.getConfiguredQuery(dc, cc, jspContext, true, Client.getQuery(), mode); |
2004 |
16 Feb 06 |
nicklas |
92 |
clients = query.iterate(dc); |
2004 |
16 Feb 06 |
nicklas |
93 |
} |
2004 |
16 Feb 06 |
nicklas |
94 |
catch (Throwable t) |
2004 |
16 Feb 06 |
nicklas |
95 |
{ |
2004 |
16 Feb 06 |
nicklas |
96 |
cc.setMessage(t.getMessage()); |
2004 |
16 Feb 06 |
nicklas |
97 |
} |
2004 |
16 Feb 06 |
nicklas |
98 |
int numListed = 0; |
7604 |
25 Feb 19 |
nicklas |
99 |
ExtensionsInvoker<ButtonAction> invoker = ToolbarUtil.useExtensions(jspContext); |
7604 |
25 Feb 19 |
nicklas |
100 |
ExtensionsInvoker<ListColumnAction<Client,?>> columnsInvoker = ListColumnUtil.useExtensions(jspContext); |
2004 |
16 Feb 06 |
nicklas |
101 |
%> |
6289 |
05 Jun 13 |
nicklas |
102 |
<base:page title="<%=title==null ? "Client applications" : title%>" type="<%=mode.getPageType()%>" id="list-page"> |
6289 |
05 Jun 13 |
nicklas |
103 |
<base:head scripts="table.js,~clients.js" styles="table.css,toolbar.css"> |
4886 |
03 Apr 09 |
nicklas |
104 |
<ext:scripts context="<%=jspContext%>" /> |
4886 |
03 Apr 09 |
nicklas |
105 |
<ext:stylesheets context="<%=jspContext%>" /> |
2004 |
16 Feb 06 |
nicklas |
106 |
</base:head> |
2004 |
16 Feb 06 |
nicklas |
107 |
|
2004 |
16 Feb 06 |
nicklas |
108 |
<base:body> |
5954 |
13 Feb 12 |
nicklas |
109 |
<h1><%=title==null ? "Client applications" : title%></h1> |
5954 |
13 Feb 12 |
nicklas |
110 |
<div class="content"> |
2004 |
16 Feb 06 |
nicklas |
111 |
<tbl:table |
2004 |
16 Feb 06 |
nicklas |
112 |
id="clients" |
2004 |
16 Feb 06 |
nicklas |
113 |
columns="<%=cc.getSetting("columns")%>" |
2004 |
16 Feb 06 |
nicklas |
114 |
sortby="<%=cc.getSortProperty()%>" |
2004 |
16 Feb 06 |
nicklas |
115 |
direction="<%=cc.getSortDirection()%>" |
2004 |
16 Feb 06 |
nicklas |
116 |
action="index.jsp" |
2004 |
16 Feb 06 |
nicklas |
117 |
sc="<%=sc%>" |
2004 |
16 Feb 06 |
nicklas |
118 |
item="<%=itemType%>" |
6705 |
02 Feb 15 |
nicklas |
119 |
filterrows="<%=cc.getFilterRows()%>" |
5954 |
13 Feb 12 |
nicklas |
120 |
subclass="fulltable" |
7982 |
14 Jun 21 |
nicklas |
121 |
stickyheaders="<%=cc.getSetting("columns.sticky", "name")%>" |
2004 |
16 Feb 06 |
nicklas |
122 |
> |
2004 |
16 Feb 06 |
nicklas |
123 |
<tbl:hidden |
2004 |
16 Feb 06 |
nicklas |
124 |
name="mode" |
2004 |
16 Feb 06 |
nicklas |
125 |
value="<%=mode.getName()%>" |
2004 |
16 Feb 06 |
nicklas |
126 |
/> |
2004 |
16 Feb 06 |
nicklas |
127 |
<tbl:hidden |
2004 |
16 Feb 06 |
nicklas |
128 |
name="callback" |
2004 |
16 Feb 06 |
nicklas |
129 |
value="<%=callback%>" |
2004 |
16 Feb 06 |
nicklas |
130 |
skip="<%=callback == null%>" |
2004 |
16 Feb 06 |
nicklas |
131 |
/> |
2004 |
16 Feb 06 |
nicklas |
132 |
<tbl:columndef |
2004 |
16 Feb 06 |
nicklas |
133 |
id="name" |
2004 |
16 Feb 06 |
nicklas |
134 |
property="name" |
2004 |
16 Feb 06 |
nicklas |
135 |
datatype="string" |
2004 |
16 Feb 06 |
nicklas |
136 |
title="Name" |
2004 |
16 Feb 06 |
nicklas |
137 |
sortable="true" |
2004 |
16 Feb 06 |
nicklas |
138 |
filterable="true" |
2004 |
16 Feb 06 |
nicklas |
139 |
exportable="true" |
2004 |
16 Feb 06 |
nicklas |
140 |
show="always" |
2004 |
16 Feb 06 |
nicklas |
141 |
/> |
2004 |
16 Feb 06 |
nicklas |
142 |
<tbl:columndef |
4332 |
12 Jun 08 |
martin |
143 |
id="id" |
4387 |
11 Aug 08 |
nicklas |
144 |
clazz="uniquecol" |
4332 |
12 Jun 08 |
martin |
145 |
property="id" |
4332 |
12 Jun 08 |
martin |
146 |
datatype="int" |
4332 |
12 Jun 08 |
martin |
147 |
title="ID" |
4332 |
12 Jun 08 |
martin |
148 |
sortable="true" |
4332 |
12 Jun 08 |
martin |
149 |
filterable="true" |
4332 |
12 Jun 08 |
martin |
150 |
exportable="true" |
4332 |
12 Jun 08 |
martin |
151 |
/> |
4332 |
12 Jun 08 |
martin |
152 |
<tbl:columndef |
4698 |
10 Dec 08 |
nicklas |
153 |
id="entryDate" |
4698 |
10 Dec 08 |
nicklas |
154 |
property="entryDate" |
4698 |
10 Dec 08 |
nicklas |
155 |
datatype="date" |
4698 |
10 Dec 08 |
nicklas |
156 |
title="Registered" |
4698 |
10 Dec 08 |
nicklas |
157 |
sortable="true" |
4698 |
10 Dec 08 |
nicklas |
158 |
filterable="true" |
4698 |
10 Dec 08 |
nicklas |
159 |
exportable="true" |
4698 |
10 Dec 08 |
nicklas |
160 |
formatter="<%=dateFormatter%>" |
4698 |
10 Dec 08 |
nicklas |
161 |
/> |
4698 |
10 Dec 08 |
nicklas |
162 |
<tbl:columndef |
2004 |
16 Feb 06 |
nicklas |
163 |
id="externalId" |
4387 |
11 Aug 08 |
nicklas |
164 |
clazz="uniquecol" |
2004 |
16 Feb 06 |
nicklas |
165 |
property="externalId" |
2004 |
16 Feb 06 |
nicklas |
166 |
datatype="string" |
2004 |
16 Feb 06 |
nicklas |
167 |
title="External ID" |
2004 |
16 Feb 06 |
nicklas |
168 |
sortable="true" |
2004 |
16 Feb 06 |
nicklas |
169 |
filterable="true" |
2004 |
16 Feb 06 |
nicklas |
170 |
exportable="true" |
2004 |
16 Feb 06 |
nicklas |
171 |
/> |
2004 |
16 Feb 06 |
nicklas |
172 |
<tbl:columndef |
7403 |
04 Oct 17 |
nicklas |
173 |
id="supportsDeviceVerification" |
7403 |
04 Oct 17 |
nicklas |
174 |
property="supportsDeviceVerification" |
7403 |
04 Oct 17 |
nicklas |
175 |
datatype="boolean" |
7412 |
11 Oct 17 |
nicklas |
176 |
title="2-factor login" |
7403 |
04 Oct 17 |
nicklas |
177 |
sortable="true" |
7403 |
04 Oct 17 |
nicklas |
178 |
filterable="true" |
7403 |
04 Oct 17 |
nicklas |
179 |
exportable="true" |
7403 |
04 Oct 17 |
nicklas |
180 |
/> |
7403 |
04 Oct 17 |
nicklas |
181 |
<tbl:columndef |
2004 |
16 Feb 06 |
nicklas |
182 |
id="owner" |
2004 |
16 Feb 06 |
nicklas |
183 |
property="owner.name" |
2004 |
16 Feb 06 |
nicklas |
184 |
datatype="string" |
2004 |
16 Feb 06 |
nicklas |
185 |
title="Owner" |
2004 |
16 Feb 06 |
nicklas |
186 |
sortable="true" |
2004 |
16 Feb 06 |
nicklas |
187 |
filterable="true" |
2004 |
16 Feb 06 |
nicklas |
188 |
exportable="true" |
2004 |
16 Feb 06 |
nicklas |
189 |
/> |
2004 |
16 Feb 06 |
nicklas |
190 |
<tbl:columndef |
2004 |
16 Feb 06 |
nicklas |
191 |
id="description" |
2004 |
16 Feb 06 |
nicklas |
192 |
property="description" |
2004 |
16 Feb 06 |
nicklas |
193 |
datatype="string" |
2004 |
16 Feb 06 |
nicklas |
194 |
title="Description" |
2004 |
16 Feb 06 |
nicklas |
195 |
sortable="true" |
2004 |
16 Feb 06 |
nicklas |
196 |
filterable="true" |
2004 |
16 Feb 06 |
nicklas |
197 |
exportable="true" |
2004 |
16 Feb 06 |
nicklas |
198 |
/> |
2401 |
21 Jun 06 |
martin |
199 |
<tbl:columndef |
2401 |
21 Jun 06 |
martin |
200 |
id="permission" |
2401 |
21 Jun 06 |
martin |
201 |
title="Permission" |
2401 |
21 Jun 06 |
martin |
202 |
/> |
5165 |
28 Oct 09 |
nicklas |
203 |
<tbl:columndef |
5165 |
28 Oct 09 |
nicklas |
204 |
id="sharedTo" |
5165 |
28 Oct 09 |
nicklas |
205 |
title="Shared to" |
5165 |
28 Oct 09 |
nicklas |
206 |
filterable="true" |
5165 |
28 Oct 09 |
nicklas |
207 |
filterproperty="!sharedTo.name" |
5165 |
28 Oct 09 |
nicklas |
208 |
datatype="string" |
3552 |
06 Jul 07 |
martin |
209 |
/> |
6045 |
03 Apr 12 |
nicklas |
210 |
<tbl:columndef |
6045 |
03 Apr 12 |
nicklas |
211 |
id="xt-columns" |
6045 |
03 Apr 12 |
nicklas |
212 |
extensions="<%=columnsInvoker%>" |
6045 |
03 Apr 12 |
nicklas |
213 |
jspcontext="<%=jspContext%>" |
6045 |
03 Apr 12 |
nicklas |
214 |
/> |
6604 |
18 Nov 14 |
nicklas |
215 |
<div class="panelgroup bg-filled-50 bottomborder"> |
5954 |
13 Feb 12 |
nicklas |
216 |
<tbl:toolbar |
5954 |
13 Feb 12 |
nicklas |
217 |
subclass="bottomborder" |
5954 |
13 Feb 12 |
nicklas |
218 |
visible="<%=mode.hasToolbar()%>" |
5954 |
13 Feb 12 |
nicklas |
219 |
> |
5954 |
13 Feb 12 |
nicklas |
220 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
221 |
id="btnNewItem" |
5954 |
13 Feb 12 |
nicklas |
222 |
disabled="<%=!createPermission%>" |
5954 |
13 Feb 12 |
nicklas |
223 |
image="new.png" |
5954 |
13 Feb 12 |
nicklas |
224 |
title="New…" |
5954 |
13 Feb 12 |
nicklas |
225 |
tooltip="<%=createPermission ? "Create new client application" : "You do not have permission to create client applications"%>" |
5954 |
13 Feb 12 |
nicklas |
226 |
/> |
5954 |
13 Feb 12 |
nicklas |
227 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
228 |
id="btnDeleteItems" |
5954 |
13 Feb 12 |
nicklas |
229 |
image="delete.png" |
5954 |
13 Feb 12 |
nicklas |
230 |
title="Delete" |
5954 |
13 Feb 12 |
nicklas |
231 |
tooltip="Delete the selected items" |
5954 |
13 Feb 12 |
nicklas |
232 |
/> |
5954 |
13 Feb 12 |
nicklas |
233 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
234 |
id="btnRestoreItems" |
5954 |
13 Feb 12 |
nicklas |
235 |
image="restore.png" |
5954 |
13 Feb 12 |
nicklas |
236 |
title="Restore" |
5954 |
13 Feb 12 |
nicklas |
237 |
tooltip="Restore the selected (deleted) items" |
5954 |
13 Feb 12 |
nicklas |
238 |
/> |
5954 |
13 Feb 12 |
nicklas |
239 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
240 |
id="btnShareItems" |
5954 |
13 Feb 12 |
nicklas |
241 |
image="share.png" |
5954 |
13 Feb 12 |
nicklas |
242 |
title="Share…" |
5954 |
13 Feb 12 |
nicklas |
243 |
tooltip="Share the selected items" |
5954 |
13 Feb 12 |
nicklas |
244 |
/> |
5954 |
13 Feb 12 |
nicklas |
245 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
246 |
id="btnSetOwner" |
5954 |
13 Feb 12 |
nicklas |
247 |
image="take_ownership.png" |
5954 |
13 Feb 12 |
nicklas |
248 |
title="Set owner…" |
5954 |
13 Feb 12 |
nicklas |
249 |
tooltip="Change owner of the selected items" |
5954 |
13 Feb 12 |
nicklas |
250 |
/> |
5954 |
13 Feb 12 |
nicklas |
251 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
252 |
id="btnColumns" |
5954 |
13 Feb 12 |
nicklas |
253 |
image="columns.png" |
5954 |
13 Feb 12 |
nicklas |
254 |
title="Columns…" |
5954 |
13 Feb 12 |
nicklas |
255 |
tooltip="Show, hide and re-order columns" |
5954 |
13 Feb 12 |
nicklas |
256 |
/> |
5954 |
13 Feb 12 |
nicklas |
257 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
258 |
id="btnImport" |
6289 |
05 Jun 13 |
nicklas |
259 |
data-plugin-type="IMPORT" |
5954 |
13 Feb 12 |
nicklas |
260 |
image="import.png" |
5954 |
13 Feb 12 |
nicklas |
261 |
title="Import…" |
5954 |
13 Feb 12 |
nicklas |
262 |
tooltip="Import data" |
5954 |
13 Feb 12 |
nicklas |
263 |
visible="<%=pluginCount.containsKey(Plugin.MainType.IMPORT)%>" |
5954 |
13 Feb 12 |
nicklas |
264 |
/> |
5954 |
13 Feb 12 |
nicklas |
265 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
266 |
id="btnExport" |
6289 |
05 Jun 13 |
nicklas |
267 |
data-plugin-type="EXPORT" |
5954 |
13 Feb 12 |
nicklas |
268 |
image="export.png" |
5954 |
13 Feb 12 |
nicklas |
269 |
title="Export…" |
5954 |
13 Feb 12 |
nicklas |
270 |
tooltip="Export data" |
5954 |
13 Feb 12 |
nicklas |
271 |
visible="<%=pluginCount.containsKey(Plugin.MainType.EXPORT)%>" |
5954 |
13 Feb 12 |
nicklas |
272 |
/> |
5954 |
13 Feb 12 |
nicklas |
273 |
<tbl:button |
6289 |
05 Jun 13 |
nicklas |
274 |
id="btnRunPlugin" |
6289 |
05 Jun 13 |
nicklas |
275 |
data-plugin-type="OTHER" |
5954 |
13 Feb 12 |
nicklas |
276 |
image="runplugin.png" |
5954 |
13 Feb 12 |
nicklas |
277 |
title="Run plugin…" |
5954 |
13 Feb 12 |
nicklas |
278 |
tooltip="Run a plugin" |
5954 |
13 Feb 12 |
nicklas |
279 |
visible="<%=pluginCount.containsKey(Plugin.MainType.OTHER)%>" |
5954 |
13 Feb 12 |
nicklas |
280 |
/> |
5954 |
13 Feb 12 |
nicklas |
281 |
<ext:render extensions="<%=invoker%>" context="<%=jspContext%>" |
7604 |
25 Feb 19 |
nicklas |
282 |
wrapper="<%=new PrefixSuffixRenderer<ButtonAction>(jspContext, "<td>", "</td>") %>"/> |
5954 |
13 Feb 12 |
nicklas |
283 |
</tbl:toolbar> |
5954 |
13 Feb 12 |
nicklas |
284 |
<tbl:panel> |
6182 |
23 Oct 12 |
nicklas |
285 |
<tbl:presetselector /> |
5954 |
13 Feb 12 |
nicklas |
286 |
<tbl:navigator |
5954 |
13 Feb 12 |
nicklas |
287 |
page="<%=cc.getPage()%>" |
5954 |
13 Feb 12 |
nicklas |
288 |
rowsperpage="<%=cc.getRowsPerPage()%>" |
5954 |
13 Feb 12 |
nicklas |
289 |
totalrows="<%=clients == null ? 0 : clients.getTotalCount()%>" |
5954 |
13 Feb 12 |
nicklas |
290 |
visible="<%=mode.hasNavigator()%>" |
5954 |
13 Feb 12 |
nicklas |
291 |
/> |
5954 |
13 Feb 12 |
nicklas |
292 |
</tbl:panel> |
5954 |
13 Feb 12 |
nicklas |
293 |
</div> |
2004 |
16 Feb 06 |
nicklas |
294 |
<tbl:data> |
5948 |
08 Feb 12 |
nicklas |
295 |
<tbl:headers> |
5948 |
08 Feb 12 |
nicklas |
296 |
<tbl:headerrow> |
7943 |
04 May 21 |
nicklas |
297 |
<tbl:header clazz="row-index bg-filled-100" /> |
5948 |
08 Feb 12 |
nicklas |
298 |
<tbl:columnheaders /> |
5948 |
08 Feb 12 |
nicklas |
299 |
</tbl:headerrow> |
6705 |
02 Feb 15 |
nicklas |
300 |
<% |
6705 |
02 Feb 15 |
nicklas |
301 |
int numFilters = cc.getNumPropertyFilters(); |
6705 |
02 Feb 15 |
nicklas |
302 |
int numRows = cc.getFilterRows(); |
6705 |
02 Feb 15 |
nicklas |
303 |
for (int filterNo = 0; filterNo < numRows; filterNo++) |
6705 |
02 Feb 15 |
nicklas |
304 |
{ |
6705 |
02 Feb 15 |
nicklas |
305 |
boolean lastRow = filterNo == numRows-1; |
6705 |
02 Feb 15 |
nicklas |
306 |
%> |
6705 |
02 Feb 15 |
nicklas |
307 |
<tbl:headerrow> |
7943 |
04 May 21 |
nicklas |
308 |
<tbl:header subclass="row-index bg-filled-100"> |
7943 |
04 May 21 |
nicklas |
309 |
<div class="index-<%=mode.getName()%>"> |
7943 |
04 May 21 |
nicklas |
310 |
<div class="index"></div> |
7943 |
04 May 21 |
nicklas |
311 |
<div class="check"> |
7943 |
04 May 21 |
nicklas |
312 |
<base:icon |
7943 |
04 May 21 |
nicklas |
313 |
subclass="link table-check" |
7943 |
04 May 21 |
nicklas |
314 |
image="check_uncheck.png" |
7943 |
04 May 21 |
nicklas |
315 |
tooltip="Toggle all (use CTRL, ALT or SHIFT to check/uncheck)" |
7943 |
04 May 21 |
nicklas |
316 |
visible="<%=lastRow && mode.hasCheck()%>" |
7943 |
04 May 21 |
nicklas |
317 |
/> |
7943 |
04 May 21 |
nicklas |
318 |
</div> |
7943 |
04 May 21 |
nicklas |
319 |
<div class="icons"> |
7943 |
04 May 21 |
nicklas |
320 |
<base:icon |
7943 |
04 May 21 |
nicklas |
321 |
subclass="link table-filter-row-action" |
7943 |
04 May 21 |
nicklas |
322 |
image="add.png" |
7943 |
04 May 21 |
nicklas |
323 |
tooltip="Add extra filter row" |
7943 |
04 May 21 |
nicklas |
324 |
visible="<%=lastRow%>" |
7943 |
04 May 21 |
nicklas |
325 |
/><base:icon |
7943 |
04 May 21 |
nicklas |
326 |
subclass="link table-filter-row-action" |
7943 |
04 May 21 |
nicklas |
327 |
image="remove.png" |
7943 |
04 May 21 |
nicklas |
328 |
tooltip="Remove this filter row" |
7943 |
04 May 21 |
nicklas |
329 |
visible="<%=numRows > 1 || numFilters > 0 %>" |
7943 |
04 May 21 |
nicklas |
330 |
data-remove-row="<%=filterNo%>" |
7943 |
04 May 21 |
nicklas |
331 |
/> |
7943 |
04 May 21 |
nicklas |
332 |
</div> |
7943 |
04 May 21 |
nicklas |
333 |
</div> |
6705 |
02 Feb 15 |
nicklas |
334 |
</tbl:header> |
6705 |
02 Feb 15 |
nicklas |
335 |
<tbl:propertyfilter row="<%=filterNo%>" /> |
6705 |
02 Feb 15 |
nicklas |
336 |
</tbl:headerrow> |
6705 |
02 Feb 15 |
nicklas |
337 |
<% |
6705 |
02 Feb 15 |
nicklas |
338 |
} |
6705 |
02 Feb 15 |
nicklas |
339 |
%> |
7913 |
22 Feb 21 |
nicklas |
340 |
<tbl:columnsubtitles /> |
5948 |
08 Feb 12 |
nicklas |
341 |
</tbl:headers> |
5948 |
08 Feb 12 |
nicklas |
342 |
<tbl:rows> |
2004 |
16 Feb 06 |
nicklas |
343 |
<% |
5954 |
13 Feb 12 |
nicklas |
344 |
if (cc.getMessage() != null) |
5954 |
13 Feb 12 |
nicklas |
345 |
{ |
5954 |
13 Feb 12 |
nicklas |
346 |
%> |
6604 |
18 Nov 14 |
nicklas |
347 |
<tbl:panel subclass="bg-filled-50"> |
5954 |
13 Feb 12 |
nicklas |
348 |
<div class="messagecontainer error"><%=cc.getMessage()%></div> |
5954 |
13 Feb 12 |
nicklas |
349 |
</tbl:panel> |
5954 |
13 Feb 12 |
nicklas |
350 |
<% |
5954 |
13 Feb 12 |
nicklas |
351 |
cc.setMessage(null); |
5954 |
13 Feb 12 |
nicklas |
352 |
} |
2004 |
16 Feb 06 |
nicklas |
353 |
int index = cc.getPage()*cc.getRowsPerPage(); |
2004 |
16 Feb 06 |
nicklas |
354 |
int selectedItemId = cc.getId(); |
2004 |
16 Feb 06 |
nicklas |
355 |
if (clients != null) |
2500 |
09 Aug 06 |
martin |
356 |
{ |
2004 |
16 Feb 06 |
nicklas |
357 |
while (clients.hasNext()) |
2004 |
16 Feb 06 |
nicklas |
358 |
{ |
2004 |
16 Feb 06 |
nicklas |
359 |
Client item = clients.next(); |
2004 |
16 Feb 06 |
nicklas |
360 |
int itemId = item.getId(); |
6221 |
10 Jan 13 |
nicklas |
361 |
|
6221 |
10 Jan 13 |
nicklas |
362 |
|
4003 |
26 Nov 07 |
nicklas |
363 |
boolean deletePermission = item.hasPermission(Permission.DELETE); |
2437 |
28 Jun 06 |
nicklas |
364 |
boolean sharePermission = item.hasPermission(Permission.SET_PERMISSION); |
2500 |
09 Aug 06 |
martin |
365 |
boolean writePermission = item.hasPermission(Permission.WRITE); |
2004 |
16 Feb 06 |
nicklas |
366 |
String name = HTML.encodeTags(item.getName()); |
2500 |
09 Aug 06 |
martin |
367 |
String tooltip = mode.isSelectionMode() ? |
2500 |
09 Aug 06 |
martin |
368 |
"Select this item" : "View this item" + (writePermission ? " (use CTRL, ALT or SHIFT to edit)" : ""); |
2004 |
16 Feb 06 |
nicklas |
369 |
index++; |
2004 |
16 Feb 06 |
nicklas |
370 |
numListed++; |
2004 |
16 Feb 06 |
nicklas |
371 |
%> |
2004 |
16 Feb 06 |
nicklas |
372 |
<tbl:row> |
7943 |
04 May 21 |
nicklas |
373 |
<tbl:header clazz="row-index bg-filled-100"> |
7943 |
04 May 21 |
nicklas |
374 |
<div class="index-<%=mode.getName()%>"> |
7943 |
04 May 21 |
nicklas |
375 |
<div class="index <%=index>999?"index-smaller":""%>"><%=index%></div> |
7943 |
04 May 21 |
nicklas |
376 |
<div class="check"> |
7943 |
04 May 21 |
nicklas |
377 |
<base:input |
7943 |
04 May 21 |
nicklas |
378 |
type="checkbox" |
7943 |
04 May 21 |
nicklas |
379 |
name="<%=itemId%>" |
7943 |
04 May 21 |
nicklas |
380 |
value="<%=itemId%>" |
7943 |
04 May 21 |
nicklas |
381 |
title="<%=name%>" |
7943 |
04 May 21 |
nicklas |
382 |
checked="<%=cc.getSelected().contains(itemId)%>" |
7943 |
04 May 21 |
nicklas |
383 |
visible="<%=mode.hasCheck()%>" |
7943 |
04 May 21 |
nicklas |
384 |
/> |
7943 |
04 May 21 |
nicklas |
385 |
<base:input |
7943 |
04 May 21 |
nicklas |
386 |
type="radio" |
7943 |
04 May 21 |
nicklas |
387 |
name="item_id" |
7943 |
04 May 21 |
nicklas |
388 |
value="<%=itemId%>" |
7943 |
04 May 21 |
nicklas |
389 |
title="<%=name%>" |
7943 |
04 May 21 |
nicklas |
390 |
checked="<%=selectedItemId == itemId%>" |
7943 |
04 May 21 |
nicklas |
391 |
visible="<%=mode.hasRadio()%>" |
7943 |
04 May 21 |
nicklas |
392 |
/> |
7943 |
04 May 21 |
nicklas |
393 |
</div> |
7943 |
04 May 21 |
nicklas |
394 |
<div class="icons"> |
7943 |
04 May 21 |
nicklas |
395 |
<base:icon |
7943 |
04 May 21 |
nicklas |
396 |
image="deleted.png" |
7943 |
04 May 21 |
nicklas |
397 |
id="<%="delete."+itemId %>" |
7943 |
04 May 21 |
nicklas |
398 |
subclass="<%=deletePermission ? "table-delete-item" : "disabled" %>" |
7943 |
04 May 21 |
nicklas |
399 |
data-item-id="<%=itemId%>" |
7943 |
04 May 21 |
nicklas |
400 |
tooltip="This item has been scheduled for deletion" |
7943 |
04 May 21 |
nicklas |
401 |
visible="<%=item.isRemoved()%>" |
7943 |
04 May 21 |
nicklas |
402 |
/><base:icon |
7943 |
04 May 21 |
nicklas |
403 |
image="shared.png" |
7943 |
04 May 21 |
nicklas |
404 |
id="<%="share."+itemId %>" |
7943 |
04 May 21 |
nicklas |
405 |
subclass="<%=sharePermission ? "table-share-item" : "disabled" %>" |
7943 |
04 May 21 |
nicklas |
406 |
data-item-id="<%=itemId%>" |
7943 |
04 May 21 |
nicklas |
407 |
tooltip="This item is shared to other users, groups and/or projects" |
7943 |
04 May 21 |
nicklas |
408 |
visible="<%=item.isShared()%>" |
7943 |
04 May 21 |
nicklas |
409 |
/> |
7943 |
04 May 21 |
nicklas |
410 |
</div> |
7943 |
04 May 21 |
nicklas |
411 |
</div> |
7943 |
04 May 21 |
nicklas |
412 |
</tbl:header> |
6289 |
05 Jun 13 |
nicklas |
413 |
<tbl:cell column="name"><div |
6289 |
05 Jun 13 |
nicklas |
414 |
class="link table-item" |
6289 |
05 Jun 13 |
nicklas |
415 |
data-item-id="<%=itemId%>" |
6289 |
05 Jun 13 |
nicklas |
416 |
data-no-edit="<%=writePermission ? 0 : 1 %>" |
6289 |
05 Jun 13 |
nicklas |
417 |
tabindex="0" |
2438 |
28 Jun 06 |
nicklas |
418 |
title="<%=tooltip%>"><%=name%></div></tbl:cell> |
4332 |
12 Jun 08 |
martin |
419 |
<tbl:cell column="id"><%=item.getId()%></tbl:cell> |
4698 |
10 Dec 08 |
nicklas |
420 |
<tbl:cell column="entryDate" value="<%=item.getEntryDate()%>" /> |
2004 |
16 Feb 06 |
nicklas |
421 |
<tbl:cell column="externalId"><%=Values.getString(item.getExternalId())%></tbl:cell> |
7403 |
04 Oct 17 |
nicklas |
422 |
<tbl:cell column="supportsDeviceVerification"><%=item.getSupportsDeviceVerification() ? "yes" : "no"%></tbl:cell> |
2354 |
07 Jun 06 |
martin |
423 |
<tbl:cell column="owner" |
2354 |
07 Jun 06 |
martin |
424 |
><base:propertyvalue |
2354 |
07 Jun 06 |
martin |
425 |
item="<%=item%>" |
2354 |
07 Jun 06 |
martin |
426 |
property="owner" |
2354 |
07 Jun 06 |
martin |
427 |
enableEditLink="<%=mode.hasEditLink()%>" |
2354 |
07 Jun 06 |
martin |
428 |
enablePropertyLink="<%=mode.hasPropertyLink()%>" |
2354 |
07 Jun 06 |
martin |
429 |
/></tbl:cell> |
2004 |
16 Feb 06 |
nicklas |
430 |
<tbl:cell column="description"><%=HTML.encodeTags(item.getDescription())%></tbl:cell> |
2401 |
21 Jun 06 |
martin |
431 |
<tbl:cell column="permission"><%=PermissionUtil.getShortPermissions(item)%></tbl:cell> |
3552 |
06 Jul 07 |
martin |
432 |
<tbl:cell column="sharedTo"> |
3552 |
06 Jul 07 |
martin |
433 |
<% |
3552 |
06 Jul 07 |
martin |
434 |
Iterator<Nameable> sharees = ShareableUtil.getSharedTo(dc, item).iterator(); |
3552 |
06 Jul 07 |
martin |
435 |
while(sharees.hasNext()) |
3552 |
06 Jul 07 |
martin |
436 |
{ |
3552 |
06 Jul 07 |
martin |
437 |
Nameable n = sharees.next(); |
3552 |
06 Jul 07 |
martin |
438 |
if (mode.hasPropertyLink()) |
3552 |
06 Jul 07 |
martin |
439 |
{ |
3552 |
06 Jul 07 |
martin |
440 |
out.write(Base.getLinkedName(ID, n, false, mode.hasEditLink())); |
3552 |
06 Jul 07 |
martin |
441 |
} |
3552 |
06 Jul 07 |
martin |
442 |
else |
3552 |
06 Jul 07 |
martin |
443 |
{ |
3552 |
06 Jul 07 |
martin |
444 |
out.write(HTML.encodeTags(n.getName())); |
3552 |
06 Jul 07 |
martin |
445 |
} |
3552 |
06 Jul 07 |
martin |
446 |
out.write(sharees.hasNext() ? ", " : ""); |
3552 |
06 Jul 07 |
martin |
447 |
} |
3552 |
06 Jul 07 |
martin |
448 |
%> |
3552 |
06 Jul 07 |
martin |
449 |
</tbl:cell> |
6045 |
03 Apr 12 |
nicklas |
450 |
<tbl:xt-cells dc="<%=dc%>" item="<%=item%>"> |
6045 |
03 Apr 12 |
nicklas |
451 |
<tbl:cell column="xt-columns" /> |
6045 |
03 Apr 12 |
nicklas |
452 |
</tbl:xt-cells> |
2004 |
16 Feb 06 |
nicklas |
453 |
</tbl:row> |
2004 |
16 Feb 06 |
nicklas |
454 |
<% |
2004 |
16 Feb 06 |
nicklas |
455 |
} |
2004 |
16 Feb 06 |
nicklas |
456 |
} |
5954 |
13 Feb 12 |
nicklas |
457 |
if (numListed == 0) |
5954 |
13 Feb 12 |
nicklas |
458 |
{ |
5954 |
13 Feb 12 |
nicklas |
459 |
%> |
6604 |
18 Nov 14 |
nicklas |
460 |
<tbl:panel subclass="bg-filled-50"> |
5954 |
13 Feb 12 |
nicklas |
461 |
<div class="messagecontainer note"> |
5954 |
13 Feb 12 |
nicklas |
462 |
<%=clients == null || clients.getTotalCount() == 0 ? "No client applications were found" : "No client applications on this page. Please select another page!" %> |
5954 |
13 Feb 12 |
nicklas |
463 |
</div> |
5954 |
13 Feb 12 |
nicklas |
464 |
</tbl:panel> |
5954 |
13 Feb 12 |
nicklas |
465 |
<% |
5954 |
13 Feb 12 |
nicklas |
466 |
} |
2004 |
16 Feb 06 |
nicklas |
467 |
%> |
5954 |
13 Feb 12 |
nicklas |
468 |
</tbl:rows> |
2004 |
16 Feb 06 |
nicklas |
469 |
</tbl:data> |
2004 |
16 Feb 06 |
nicklas |
470 |
</tbl:table> |
5954 |
13 Feb 12 |
nicklas |
471 |
</div> |
5954 |
13 Feb 12 |
nicklas |
472 |
|
5951 |
09 Feb 12 |
nicklas |
473 |
<base:buttongroup subclass="dialogbuttons"> |
6289 |
05 Jun 13 |
nicklas |
474 |
<base:button id="btnOk" title="Ok" visible="<%=mode.hasOkButton()%>" /> |
6289 |
05 Jun 13 |
nicklas |
475 |
<base:button id="close" title="Cancel" visible="<%=mode.hasCancelButton()%>" /> |
6289 |
05 Jun 13 |
nicklas |
476 |
<base:button id="close" title="Close" visible="<%=mode.hasCloseButton()%>" /> |
2004 |
16 Feb 06 |
nicklas |
477 |
</base:buttongroup> |
5951 |
09 Feb 12 |
nicklas |
478 |
|
2004 |
16 Feb 06 |
nicklas |
479 |
</base:body> |
2004 |
16 Feb 06 |
nicklas |
480 |
</base:page> |
2004 |
16 Feb 06 |
nicklas |
481 |
<% |
2004 |
16 Feb 06 |
nicklas |
482 |
} |
2004 |
16 Feb 06 |
nicklas |
483 |
finally |
2004 |
16 Feb 06 |
nicklas |
484 |
{ |
2004 |
16 Feb 06 |
nicklas |
485 |
if (clients != null) clients.close(); |
2004 |
16 Feb 06 |
nicklas |
486 |
if (dc != null) dc.close(); |
2004 |
16 Feb 06 |
nicklas |
487 |
} |
3675 |
16 Aug 07 |
jari |
488 |
%> |