-
Notifications
You must be signed in to change notification settings - Fork 2
/
SitesTest-testShowSites.xml
197 lines (197 loc) · 6.79 KB
/
SitesTest-testShowSites.xml
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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<datasource xmlns="http://www.appng.org/schema/platform" id="sites">
<config>
<title id="sites">Sites</title>
<permissions>
<permission ref="site.list" mode="set"></permission>
</permissions>
<params>
<param name="name" />
<param name="domain" />
</params>
<meta-data bindClass="org.appng.api.model.Site">
<field name="name" type="text" binding="name">
<sort />
<label id="name">Name</label>
</field>
<field name="host" type="text" binding="host">
<sort />
<label id="host">Host</label>
</field>
<field name="domain" type="text" binding="domain">
<sort />
<label id="domain">Domain</label>
</field>
<field name="description" type="text" binding="description">
<label id="description">Description</label>
</field>
<field name="active" type="image" binding="active">
<sort />
<label id="active">Active</label>
<icon condition="${current.active}">led_green</icon>
<icon condition="${!current.active}">led_red</icon>
</field>
<field name="running" type="image" binding="running">
<label id="running">Running</label>
<icon condition="${current.running}">led_green</icon>
<icon condition="${!current.running}">led_red</icon>
</field>
<field name="startupTime" type="date" format="yyyy-MM-dd HH:mm:ss" binding="startupTime">
<label id="startupTime">Startup time</label>
</field>
<field name="actions" type="linkpanel" binding="actions">
<label id="actions">Actions</label>
</field>
</meta-data>
<linkpanel id="other" location="both">
<link id="other[1]" mode="intern" target="/sites/create">
<permissions>
<permission ref="site.create" mode="set"></permission>
</permissions>
<label id="site.create">Create site</label>
<icon>new</icon>
</link>
</linkpanel>
<linkpanel id="actions" location="inline">
<link id="actions[1]" mode="intern" target="/sites?form_action=start&siteid=${current.id}">
<condition expression="${current.active and current.state.name() eq 'STOPPED'}" />
<permissions>
<permission ref="site.reload" mode="set"></permission>
</permissions>
<label id="start">start</label>
<icon>activate</icon>
</link>
<link id="actions[2]" mode="intern" target="/sites?form_action=stop&siteid=${current.id}">
<condition expression="${current.active and current.running}" />
<permissions>
<permission ref="site.reload" mode="set"></permission>
</permissions>
<label id="stop">stop</label>
<icon>deactivate</icon>
</link>
<link id="actions[3]" mode="intern" target="/sites/update/${current.id}" default="true">
<permissions>
<permission ref="site.edit" mode="set"></permission>
</permissions>
<label id="edit">Edit</label>
<icon>edit</icon>
</link>
<link id="actions[4]" mode="intern" target="/sites?form_action=delete&siteid=${current.id}">
<permissions>
<permission ref="site.delete" mode="set"></permission>
</permissions>
<label id="delete">Delete</label>
<icon>delete</icon>
<confirmation id="site.delete.confirm" params="#{name}">Do you really want to delete the site "#{name}"?</confirmation>
</link>
<link id="actions[5]" mode="intern" target="/sites?form_action=reload&siteid=${current.id}"
show-disabled="true">
<condition expression="${current.active}" />
<permissions>
<permission ref="site.reload" mode="set"></permission>
</permissions>
<label id="reload">Reload</label>
<icon>reload</icon>
</link>
</linkpanel>
</config>
<data>
<selectionGroup>
<selection id="f_sn" type="text">
<title id="name">Name</title>
<option value="" name="f_sn" />
</selection>
<selection id="f_sd" type="text">
<title id="domain">Domain</title>
<option value="" name="f_sd" />
</selection>
</selectionGroup>
<resultset chunk="0" chunkname="sites" chunksize="10" nextchunk="0" previouschunk="0" firstchunk="0"
lastchunk="0" hits="2">
<result>
<field name="name" type="text">
<value>localhost</value>
</field>
<field name="host" type="text">
<value>localhost</value>
</field>
<field name="domain" type="text">
<value>localhost</value>
</field>
<field name="description" type="text">
<value></value>
</field>
<field name="active" type="image">
<value>true</value>
<icon type="class">led_green</icon>
</field>
<field name="running" type="image">
<value>false</value>
<icon type="class">led_red</icon>
</field>
<field name="startupTime" type="date">
<value></value>
</field>
<linkpanel id="actions" location="inline">
<link id="actions[3]" mode="intern" target="/sites/update/1" default="true">
<label id="edit">Edit</label>
<icon>edit</icon>
</link>
<link id="actions[4]" mode="intern" target="/sites?form_action=delete&siteid=1">
<label id="delete">Delete</label>
<icon>delete</icon>
<confirmation id="site.delete.confirm" params="#{name}">Do you really want to delete the site "localhost"?</confirmation>
</link>
<link id="actions[5]" mode="intern" target="/sites?form_action=reload&siteid=1">
<label id="reload">Reload</label>
<icon>reload</icon>
</link>
</linkpanel>
</result>
<result>
<field name="name" type="text">
<value>site2</value>
</field>
<field name="host" type="text">
<value>example.com</value>
</field>
<field name="domain" type="text">
<value>example.com</value>
</field>
<field name="description" type="text">
<value>a description</value>
</field>
<field name="active" type="image">
<value>true</value>
<icon type="class">led_green</icon>
</field>
<field name="running" type="image">
<value>false</value>
<icon type="class">led_red</icon>
</field>
<field name="startupTime" type="date">
<value></value>
</field>
<linkpanel id="actions" location="inline">
<link id="actions[1]" mode="intern" target="/sites?form_action=start&siteid=3">
<label id="start">start</label>
<icon>activate</icon>
</link>
<link id="actions[3]" mode="intern" target="/sites/update/3" default="true">
<label id="edit">Edit</label>
<icon>edit</icon>
</link>
<link id="actions[4]" mode="intern" target="/sites?form_action=delete&siteid=3">
<label id="delete">Delete</label>
<icon>delete</icon>
<confirmation id="site.delete.confirm" params="#{name}">Do you really want to delete the site "site2"?</confirmation>
</link>
<link id="actions[5]" mode="intern" target="/sites?form_action=reload&siteid=3">
<label id="reload">Reload</label>
<icon>reload</icon>
</link>
</linkpanel>
</result>
</resultset>
</data>
</datasource>