197b937c59baf2886008e30f8c312d300ab3ae50
[racktables] / inc / navigation.php
1 <?php
2 /*
3 *
4 * This file implements generic navigation for RackTables.
5 *
6 */
7
8 $page = array();
9 $tab = array();
10 $trigger = array();
11 $ophandler = array();
12 $tabhandler = array();
13 $delayauth = array();
14
15 $indexlayout = array
16 (
17 array ('rackspace', 'depot', 'ipv4space', 'ipv6space'),
18 array ('files', 'reports', 'ipv4slb', '8021q'),
19 array ('config', 'objectlog'),
20 );
21
22 $page['index']['title'] = 'Main page';
23 $page['index']['handler'] = 'renderIndex';
24
25 $page['rackspace']['title'] = 'Rackspace';
26 $page['rackspace']['parent'] = 'index';
27 $tab['rackspace']['default'] = 'Browse';
28 $tab['rackspace']['edit'] = 'Manage rows';
29 $tab['rackspace']['history'] = 'History';
30 $tabhandler['rackspace']['default'] = 'renderRackspace';
31 $tabhandler['rackspace']['edit'] = 'renderRackspaceRowEditor';
32 $tabhandler['rackspace']['history'] = 'renderRackspaceHistory';
33 $ophandler['rackspace']['edit']['updateRow'] = 'updateRow';
34 $ophandler['rackspace']['edit']['delete'] = 'deleteRow';
35 $ophandler['rackspace']['edit']['addRow'] = array
36 (
37 'table' => 'RackRow',
38 'action' => 'INSERT',
39 'arglist' => array
40 (
41 array ('url_argname' => 'name', 'assertion' => 'string')
42 ),
43 );
44
45 $page['depot']['parent'] = 'index';
46 $page['depot']['title'] = 'Objects';
47 $tab['depot']['default'] = 'Browse';
48 $tab['depot']['addmore'] = 'Add more';
49 $tabhandler['depot']['default'] = 'renderDepot';
50 $tabhandler['depot']['addmore'] = 'renderAddMultipleObjectsForm';
51 $ophandler['depot']['addmore']['addObjects'] = 'addMultipleObjects';
52 $ophandler['depot']['addmore']['addLotOfObjects'] = 'addLotOfObjects';
53 $ophandler['depot']['addmore']['deleteObject'] = 'deleteObject';
54
55 $page['row']['bypass'] = 'row_id';
56 $page['row']['bypass_type'] = 'uint';
57 $page['row']['parent'] = 'rackspace';
58 $tab['row']['default'] = 'View';
59 $tab['row']['newrack'] = 'Add new rack';
60 $tab['row']['tagroller'] = 'Tag roller';
61 $tabhandler['row']['default'] = 'renderRow';
62 $tabhandler['row']['newrack'] = 'renderNewRackForm';
63 $tabhandler['row']['tagroller'] = 'renderTagRollerForRow';
64 $ophandler['row']['tagroller']['rollTags'] = 'rollTags';
65 $ophandler['row']['newrack']['addRack'] = 'addRack';
66
67 $page['rack']['bypass'] = 'rack_id';
68 $page['rack']['bypass_type'] = 'uint';
69 $page['rack']['parent'] = 'row';
70 $tab['rack']['default'] = 'View';
71 $tab['rack']['edit'] = 'Properties';
72 $tab['rack']['design'] = 'Design';
73 $tab['rack']['problems'] = 'Problems';
74 $tab['rack']['tags'] = 'Tags';
75 $tab['rack']['files'] = 'Files';
76 $tabhandler['rack']['default'] = 'renderRackPage';
77 $tabhandler['rack']['edit'] = 'renderEditRackForm';
78 $tabhandler['rack']['design'] = 'renderRackDesign';
79 $tabhandler['rack']['problems'] = 'renderRackProblems';
80 $tabhandler['rack']['tags'] = 'renderEntityTags';
81 $tabhandler['rack']['files'] = 'renderFilesForEntity';
82 $trigger['rack']['tags'] = 'trigger_tags';
83 $ophandler['rack']['design']['updateRack'] = 'updateRackDesign';
84 $ophandler['rack']['problems']['updateRack'] = 'updateRackProblems';
85 $ophandler['rack']['edit']['updateRack'] = 'updateRack';
86 $ophandler['rack']['edit']['deleteRack'] = 'deleteRack';
87 $ophandler['rack']['tags']['saveTags'] = 'saveEntityTags';
88 $ophandler['rack']['files']['addFile'] = 'addFileToEntity';
89 $ophandler['rack']['files']['linkFile'] = 'linkFileToEntity';
90 $ophandler['rack']['files']['unlinkFile'] = 'unlinkFile';
91
92 $page['object']['bypass'] = 'object_id';
93 $page['object']['bypass_type'] = 'uint';
94 $page['object']['bypass_tabs'] = array ('hl_port_id');
95 $page['object']['parent'] = 'depot';
96 $tab['object']['default'] = 'View';
97 $tab['object']['edit'] = 'Properties';
98 $tab['object']['log'] = 'Log';
99 $tab['object']['rackspace'] = 'Rackspace';
100 $tab['object']['ports'] = 'Ports';
101 $tab['object']['ipv4'] = 'IPv4';
102 $tab['object']['ipv6'] = 'IPv6';
103 $tab['object']['nat4'] = 'NATv4';
104 $tab['object']['livevlans'] = 'Live VLANs';
105 $tab['object']['liveports'] = 'Live ports';
106 $tab['object']['livecdp'] = 'Live CDP';
107 $tab['object']['livelldp'] = 'Live LLDP';
108 $tab['object']['livehndp'] = 'Live HNDP';
109 $tab['object']['snmpportfinder'] = 'SNMP sync';
110 $tab['object']['editrspvs'] = 'RS pools';
111 $tab['object']['lvsconfig'] = 'keepalived.conf';
112 $tab['object']['autoports'] = 'AutoPorts';
113 $tab['object']['tags'] = 'Tags';
114 $tab['object']['files'] = 'Files';
115 $tab['object']['8021qorder'] = '802.1Q order';
116 $tab['object']['8021qports'] = '802.1Q ports';
117 $tab['object']['8021qsync'] = '802.1Q sync';
118 $tabhandler['object']['default'] = 'renderRackObject';
119 $tabhandler['object']['edit'] = 'renderEditObjectForm';
120 $tabhandler['object']['log'] = 'renderObjectLogEditor';
121 $tabhandler['object']['rackspace'] = 'renderRackSpaceForObject';
122 $tabhandler['object']['ports'] = 'renderPortsForObject';
123 $tabhandler['object']['ipv4'] = 'renderIPv4ForObject';
124 $tabhandler['object']['ipv6'] = 'renderIPv6ForObject';
125 $tabhandler['object']['nat4'] = 'renderNATv4ForObject';
126 $tabhandler['object']['livevlans'] = 'renderVLANMembership';
127 $tabhandler['object']['liveports'] = 'renderPortsInfo';
128 $tabhandler['object']['livecdp'] = 'renderDiscoveredNeighbors';
129 $tabhandler['object']['livelldp'] = 'renderDiscoveredNeighbors';
130 $tabhandler['object']['livehndp'] = 'renderDiscoveredNeighbors';
131 $tabhandler['object']['snmpportfinder'] = 'renderSNMPPortFinder';
132 $tabhandler['object']['lvsconfig'] = 'renderLVSConfig';
133 $tabhandler['object']['autoports'] = 'renderAutoPortsForm';
134 $tabhandler['object']['tags'] = 'renderEntityTags';
135 $tabhandler['object']['files'] = 'renderFilesForEntity';
136 $tabhandler['object']['editrspvs'] = 'renderObjectSLB';
137 $tabhandler['object']['8021qorder'] = 'render8021QOrderForm';
138 $tabhandler['object']['8021qports'] = 'renderObject8021QPorts';
139 $tabhandler['object']['8021qsync'] = 'renderObject8021QSync';
140 $trigger['object']['rackspace'] = 'trigger_rackspace';
141 $trigger['object']['ipv4'] = 'trigger_ipv4';
142 $trigger['object']['ipv6'] = 'trigger_ipv6';
143 $trigger['object']['nat4'] = 'trigger_natv4';
144 $trigger['object']['livevlans'] = 'trigger_livevlans';
145 $trigger['object']['liveports'] = 'trigger_liveports';
146 $trigger['object']['livecdp'] = 'trigger_LiveCDP';
147 $trigger['object']['livelldp'] = 'trigger_LiveLLDP';
148 $trigger['object']['livehndp'] = 'trigger_LiveHNDP';
149 $trigger['object']['snmpportfinder'] = 'trigger_snmpportfinder';
150 $trigger['object']['editrspvs'] = 'trigger_isloadbalancer';
151 $trigger['object']['lvsconfig'] = 'trigger_isloadbalancer';
152 $trigger['object']['autoports'] = 'trigger_autoports';
153 $trigger['object']['tags'] = 'trigger_tags';
154 $trigger['object']['8021qorder'] = 'trigger_object_8021qorder';
155 $trigger['object']['8021qports'] = 'trigger_object_8021qports';
156 $trigger['object']['8021qsync'] = 'trigger_object_8021qsync';
157 $ophandler['object']['rackspace']['updateObjectAllocation'] = 'updateObjectAllocation';
158 $ophandler['object']['ports']['addPort'] = 'addPortForObject';
159 $ophandler['object']['ports']['delPort'] = 'delPortFromObject';
160 $ophandler['object']['ports']['editPort'] = 'editPortForObject';
161 $ophandler['object']['ports']['linkPort'] = 'linkPortForObject';
162 $ophandler['object']['ports']['unlinkPort'] = 'unlinkPortForObject';
163 $ophandler['object']['ports']['addMultiPorts'] = 'addMultiPorts';
164 $ophandler['object']['ports']['addBulkPorts'] = 'addBulkPorts';
165 $ophandler['object']['ports']['useup'] = 'useupPort';
166 $ophandler['object']['ipv4']['updIPv4Allocation'] = 'updIPv4Allocation';
167 $ophandler['object']['ipv4']['addIPv4Allocation'] = 'addIPv4Allocation';
168 $ophandler['object']['ipv4']['delIPv4Allocation'] = 'delIPv4Allocation';
169 $ophandler['object']['ipv6']['updIPv6Allocation'] = 'updIPv6Allocation';
170 $ophandler['object']['ipv6']['addIPv6Allocation'] = 'addIPv6Allocation';
171 $ophandler['object']['ipv6']['delIPv6Allocation'] = 'delIPv6Allocation';
172 $ophandler['object']['edit']['clearSticker'] = 'clearSticker';
173 $ophandler['object']['edit']['update'] = 'updateObject';
174 $ophandler['object']['edit']['resetObject'] = 'resetObject';
175 $ophandler['object']['log']['add'] = 'addObjectlog';
176 $ophandler['object']['log']['del'] = 'deleteObjectLog';
177 $ophandler['object']['nat4']['addNATv4Rule'] = 'addPortForwarding';
178 $ophandler['object']['nat4']['delNATv4Rule'] = 'delPortForwarding';
179 $ophandler['object']['nat4']['updNATv4Rule'] = 'updPortForwarding';
180 $ophandler['object']['livevlans']['setPortVLAN'] = 'setPortVLAN';
181 $ophandler['object']['livecdp']['importDPData'] = 'importDPData';
182 $ophandler['object']['livelldp']['importDPData'] = 'importDPData';
183 $ophandler['object']['autoports']['generate'] = 'generateAutoPorts';
184 $ophandler['object']['tags']['saveTags'] = 'saveEntityTags';
185 $ophandler['object']['files']['addFile'] = 'addFileToEntity';
186 $ophandler['object']['files']['linkFile'] = 'linkFileToEntity';
187 $ophandler['object']['files']['unlinkFile'] = 'unlinkFile';
188 $ophandler['object']['editrspvs']['addLB'] = 'addLoadBalancer';
189 $ophandler['object']['editrspvs']['delLB'] = 'deleteLoadBalancer';
190 $ophandler['object']['editrspvs']['updLB'] = 'updateLoadBalancer';
191 $ophandler['object']['lvsconfig']['submitSLBConfig'] = 'submitSLBConfig';
192 $ophandler['object']['snmpportfinder']['querySNMPData'] = 'querySNMPData';
193 $ophandler['object']['8021qorder']['add'] = 'add8021QOrder';
194 $ophandler['object']['8021qorder']['del'] = 'del8021QOrder';
195 $ophandler['object']['8021qports']['save8021QConfig'] = 'save8021QPorts';
196 $ophandler['object']['8021qports']['exec8021QRecalc'] = 'process8021QRecalcRequest';
197 $ophandler['object']['8021qsync']['exec8021QPull'] = 'process8021QSyncRequest';
198 $ophandler['object']['8021qsync']['exec8021QPush'] = 'process8021QSyncRequest';
199 $ophandler['object']['8021qsync']['resolve8021QConflicts'] = 'resolve8021QConflicts';
200 $delayauth['object']['8021qports']['save8021QConfig'] = TRUE;
201 $delayauth['object']['livevlans']['setPortVLAN'] = TRUE;
202
203 $page['ipv4space']['parent'] = 'index';
204 $tab['ipv4space']['default'] = 'Browse';
205 $tab['ipv4space']['newrange'] = 'Manage';
206 $tabhandler['ipv4space']['default'] = 'renderIPv4Space';
207 $tabhandler['ipv4space']['newrange'] = 'renderIPv4SpaceEditor';
208 $ophandler['ipv4space']['newrange']['addIPv4Prefix'] = 'addIPv4Prefix';
209 $ophandler['ipv4space']['newrange']['delIPv4Prefix'] = 'delIPv4Prefix';
210
211 $page['ipv6space']['parent'] = 'index';
212 $tab['ipv6space']['default'] = 'Browse';
213 $tab['ipv6space']['newrange'] = 'Manage';
214 $tabhandler['ipv6space']['default'] = 'renderIPv6Space';
215 $tabhandler['ipv6space']['newrange'] = 'renderIPv6SpaceEditor';
216 $ophandler['ipv6space']['newrange']['addIPv6Prefix'] = 'addIPv6Prefix';
217 $ophandler['ipv6space']['newrange']['delIPv6Prefix'] = 'delIPv6Prefix';
218
219 $page['ipv4net']['parent'] = 'ipv4space';
220 $page['ipv4net']['bypass'] = 'id';
221 $page['ipv4net']['bypass_type'] = 'uint';
222 $tab['ipv4net']['default'] = 'Browse';
223 $tab['ipv4net']['properties'] = 'Properties';
224 $tab['ipv4net']['liveptr'] = 'Live PTR';
225 $tab['ipv4net']['tags'] = 'Tags';
226 $tab['ipv4net']['files'] = 'Files';
227 $tab['ipv4net']['8021q'] = '802.1Q';
228 $tabhandler['ipv4net']['default'] = 'renderIPv4Network';
229 $tabhandler['ipv4net']['properties'] = 'renderIPNetworkProperties';
230 $tabhandler['ipv4net']['liveptr'] = 'renderLivePTR';
231 $tabhandler['ipv4net']['tags'] = 'renderEntityTags';
232 $tabhandler['ipv4net']['files'] = 'renderFilesForEntity';
233 $tabhandler['ipv4net']['8021q'] = 'renderVLANIPLinks';
234 $trigger['ipv4net']['tags'] = 'trigger_tags';
235 $trigger['ipv4net']['8021q'] = 'trigger_ipv4net_vlanconfig';
236 $ophandler['ipv4net']['properties']['editRange'] = 'updIPv4Prefix';
237 $ophandler['ipv4net']['liveptr']['importPTRData'] = 'importPTRData';
238 $ophandler['ipv4net']['tags']['saveTags'] = 'saveEntityTags';
239 $ophandler['ipv4net']['files']['addFile'] = 'addFileToEntity';
240 $ophandler['ipv4net']['files']['linkFile'] = 'linkFileToEntity';
241 $ophandler['ipv4net']['files']['unlinkFile'] = 'unlinkFile';
242 $ophandler['ipv4net']['8021q']['bind'] = 'bindVLANtoIPv4';
243 $ophandler['ipv4net']['8021q']['unbind'] = 'unbindVLANfromIPv4';
244
245 $page['ipv6net']['parent'] = 'ipv6space';
246 $page['ipv6net']['bypass'] = 'id';
247 $page['ipv6net']['bypass_type'] = 'uint';
248 $tab['ipv6net']['default'] = 'Browse';
249 $tab['ipv6net']['properties'] = 'Properties';
250 $tab['ipv6net']['tags'] = 'Tags';
251 $tab['ipv6net']['files'] = 'Files';
252 $tab['ipv6net']['8021q'] = '802.1Q';
253 $tabhandler['ipv6net']['default'] = 'renderIPv6Network';
254 $tabhandler['ipv6net']['properties'] = 'renderIPNetworkProperties';
255 $tabhandler['ipv6net']['tags'] = 'renderEntityTags';
256 $tabhandler['ipv6net']['files'] = 'renderFilesForEntity';
257 $tabhandler['ipv6net']['8021q'] = 'renderVLANIPLinks';
258 $trigger['ipv6net']['tags'] = 'trigger_tags';
259 $trigger['ipv6net']['8021q'] = 'trigger_ipv6net_vlanconfig';
260 $ophandler['ipv6net']['properties']['editRange'] = 'updIPv6Prefix';
261 $ophandler['ipv6net']['tags']['saveTags'] = 'saveEntityTags';
262 $ophandler['ipv6net']['files']['addFile'] = 'addFileToEntity';
263 $ophandler['ipv6net']['files']['linkFile'] = 'linkFileToEntity';
264 $ophandler['ipv6net']['files']['unlinkFile'] = 'unlinkFile';
265 $ophandler['ipv6net']['8021q']['bind'] = 'bindVLANtoIPv6';
266 $ophandler['ipv6net']['8021q']['unbind'] = 'unbindVLANfromIPv6';
267
268 $page['ipaddress']['parent'] = 'ipv4net';
269 $page['ipaddress']['bypass'] = 'ip';
270 $page['ipaddress']['bypass_type'] = 'inet4';
271 $tab['ipaddress']['default'] = 'Browse';
272 $tab['ipaddress']['properties'] = 'Properties';
273 $tab['ipaddress']['assignment'] = 'Allocation';
274 $tabhandler['ipaddress']['default'] = 'renderIPAddress';
275 $tabhandler['ipaddress']['properties'] = 'renderIPAddressProperties';
276 $tabhandler['ipaddress']['assignment'] = 'renderIPAddressAllocations';
277 $ophandler['ipaddress']['properties']['editAddress'] = 'editAddress';
278 $ophandler['ipaddress']['assignment']['delIPv4Allocation'] = 'delIPv4Allocation';
279 $ophandler['ipaddress']['assignment']['updIPv4Allocation'] = 'updIPv4Allocation';
280 $ophandler['ipaddress']['assignment']['addIPv4Allocation'] = 'addIPv4Allocation';
281
282 $page['ipv6address']['parent'] = 'ipv6net';
283 $page['ipv6address']['bypass'] = 'ip';
284 $page['ipv6address']['bypass_type'] = 'string';
285 $tab['ipv6address']['default'] = 'Browse';
286 $tab['ipv6address']['properties'] = 'Properties';
287 $tab['ipv6address']['assignment'] = 'Allocation';
288 $tabhandler['ipv6address']['default'] = 'renderIPAddress';
289 $tabhandler['ipv6address']['properties'] = 'renderIPAddressProperties';
290 $tabhandler['ipv6address']['assignment'] = 'renderIPAddressAllocations';
291 $ophandler['ipv6address']['properties']['editAddress'] = 'editv6Address';
292 $ophandler['ipv6address']['assignment']['delIPv6Allocation'] = 'delIPv6Allocation';
293 $ophandler['ipv6address']['assignment']['updIPv6Allocation'] = 'updIPv6Allocation';
294 $ophandler['ipv6address']['assignment']['addIPv6Allocation'] = 'addIPv6Allocation';
295
296 $page['ipv4slb']['title'] = 'IPv4 SLB';
297 $page['ipv4slb']['parent'] = 'index';
298 $tab['ipv4slb']['default'] = 'Browse';
299 $tab['ipv4slb']['defconfig'] = 'Default configs';
300 $tabhandler['ipv4slb']['default'] = 'renderIPv4SLB';
301 $tabhandler['ipv4slb']['defconfig'] = 'renderSLBDefConfig';
302 $ophandler['ipv4slb']['defconfig']['save'] = 'updateSLBDefConfig';
303
304 $page['ipv4vslist']['title'] = 'Virtual services';
305 $page['ipv4vslist']['parent'] = 'ipv4slb';
306 $tab['ipv4vslist']['default'] = 'View';
307 $tab['ipv4vslist']['edit'] = 'Edit';
308 $tabhandler['ipv4vslist']['default'] = 'renderVSList';
309 $tabhandler['ipv4vslist']['edit'] = 'renderVSListEditForm';
310 $ophandler['ipv4vslist']['edit']['add'] = 'addVService';
311 $ophandler['ipv4vslist']['edit']['del'] = 'deleteVService';
312
313 $page['ipv4vs']['parent'] = 'ipv4vslist';
314 $page['ipv4vs']['bypass'] = 'vs_id';
315 $page['ipv4vs']['bypass_type'] = 'uint';
316 $tab['ipv4vs']['default'] = 'View';
317 $tab['ipv4vs']['edit'] = 'Edit';
318 $tab['ipv4vs']['editlblist'] = 'Load balancers';
319 $tab['ipv4vs']['tags'] = 'Tags';
320 $tab['ipv4vs']['files'] = 'Files';
321 $tabhandler['ipv4vs']['default'] = 'renderVirtualService';
322 $tabhandler['ipv4vs']['edit'] = 'renderEditVService';
323 $tabhandler['ipv4vs']['editlblist'] = 'renderVServiceLBForm';
324 $tabhandler['ipv4vs']['tags'] = 'renderEntityTags';
325 $tabhandler['ipv4vs']['files'] = 'renderFilesForEntity';
326 $trigger['ipv4vs']['tags'] = 'trigger_tags';
327 $ophandler['ipv4vs']['edit']['updIPv4VS'] = 'updateVService';
328 $ophandler['ipv4vs']['editlblist']['addLB'] = 'addLoadBalancer';
329 $ophandler['ipv4vs']['editlblist']['delLB'] = 'deleteLoadBalancer';
330 $ophandler['ipv4vs']['editlblist']['updLB'] = 'updateLoadBalancer';
331 $ophandler['ipv4vs']['tags']['saveTags'] = 'saveEntityTags';
332 $ophandler['ipv4vs']['files']['addFile'] = 'addFileToEntity';
333 $ophandler['ipv4vs']['files']['linkFile'] = 'linkFileToEntity';
334 $ophandler['ipv4vs']['files']['unlinkFile'] = 'unlinkFile';
335
336 $page['ipv4rsplist']['title'] = 'RS pools';
337 $page['ipv4rsplist']['parent'] = 'ipv4slb';
338 $tab['ipv4rsplist']['default'] = 'View';
339 $tab['ipv4rsplist']['edit'] = 'Edit';
340 $tabhandler['ipv4rsplist']['default'] = 'renderRSPoolList';
341 $tabhandler['ipv4rsplist']['edit'] = 'editRSPools';
342 $ophandler['ipv4rsplist']['edit']['add'] = 'addRSPool';
343 $ophandler['ipv4rsplist']['edit']['del'] = 'deleteRSPool';
344
345 $page['ipv4rspool']['parent'] = 'ipv4rsplist';
346 $page['ipv4rspool']['bypass'] = 'pool_id';
347 $page['ipv4rspool']['bypass_type'] = 'uint';
348 $tab['ipv4rspool']['default'] = 'View';
349 $tab['ipv4rspool']['edit'] = 'Edit';
350 $tab['ipv4rspool']['editlblist'] = 'Load balancers';
351 $tab['ipv4rspool']['editrslist'] = 'RS list';
352 $tab['ipv4rspool']['rsinservice'] = 'RS in service';
353 $tab['ipv4rspool']['tags'] = 'Tags';
354 $tab['ipv4rspool']['files'] = 'Files';
355 $trigger['ipv4rspool']['rsinservice'] = 'trigger_poolrscount';
356 $trigger['ipv4rspool']['tags'] = 'trigger_tags';
357 $tabhandler['ipv4rspool']['default'] = 'renderRSPool';
358 $tabhandler['ipv4rspool']['edit'] = 'renderEditRSPool';
359 $tabhandler['ipv4rspool']['editrslist'] = 'renderRSPoolServerForm';
360 $tabhandler['ipv4rspool']['editlblist'] = 'renderRSPoolLBForm';
361 $tabhandler['ipv4rspool']['rsinservice'] = 'renderRSPoolRSInServiceForm';
362 $tabhandler['ipv4rspool']['tags'] = 'renderEntityTags';
363 $tabhandler['ipv4rspool']['files'] = 'renderFilesForEntity';
364 $ophandler['ipv4rspool']['edit']['updIPv4RSP'] = 'updateRSPool';
365 $ophandler['ipv4rspool']['editrslist']['addRS'] = 'addRealServer';
366 $ophandler['ipv4rspool']['editrslist']['delRS'] = 'deleteRealServer';
367 $ophandler['ipv4rspool']['editrslist']['updRS'] = 'updateRealServer';
368 $ophandler['ipv4rspool']['editrslist']['addMany'] = 'addRealServers';
369 $ophandler['ipv4rspool']['editlblist']['addLB'] = 'addLoadBalancer';
370 $ophandler['ipv4rspool']['editlblist']['delLB'] = 'deleteLoadBalancer';
371 $ophandler['ipv4rspool']['editlblist']['updLB'] = 'updateLoadBalancer';
372 $ophandler['ipv4rspool']['rsinservice']['upd'] = 'updateRSInService';
373 $ophandler['ipv4rspool']['tags']['saveTags'] = 'saveEntityTags';
374 $ophandler['ipv4rspool']['files']['addFile'] = 'addFileToEntity';
375 $ophandler['ipv4rspool']['files']['linkFile'] = 'linkFileToEntity';
376 $ophandler['ipv4rspool']['files']['unlinkFile'] = 'unlinkFile';
377
378 $page['rservers']['title'] = 'Real servers';
379 $page['rservers']['parent'] = 'ipv4slb';
380 $page['rservers']['handler'] = 'renderRealServerList';
381
382 $page['lbs']['title'] = 'Load balancers';
383 $page['lbs']['parent'] = 'ipv4slb';
384 $page['lbs']['handler'] = 'renderLBList';
385
386 $page['search']['handler'] = 'searchHandler';
387 $page['search']['parent'] = 'index';
388 $page['search']['bypass'] = 'q';
389
390 $page['config']['title'] = 'Configuration';
391 $page['config']['handler'] = 'renderConfigMainpage';
392 $page['config']['parent'] = 'index';
393
394 $page['userlist']['title'] = 'Local users';
395 $page['userlist']['parent'] = 'config';
396 $tab['userlist']['default'] = 'View';
397 $tab['userlist']['edit'] = 'Edit';
398 $tabhandler['userlist']['default'] = 'renderUserList';
399 $tabhandler['userlist']['edit'] = 'renderUserListEditor';
400 $ophandler['userlist']['edit']['updateUser'] = 'updateUser';
401 $ophandler['userlist']['edit']['createUser'] = 'createUser';
402
403 $page['user']['parent'] = 'userlist';
404 $page['user']['bypass'] = 'user_id';
405 $page['user']['bypass_type'] = 'uint';
406 $tab['user']['default'] = 'View';
407 $tab['user']['tags'] = 'Tags';
408 $tab['user']['files'] = 'Files';
409 $tabhandler['user']['default'] = 'renderUser';
410 $tabhandler['user']['tags'] = 'renderEntityTags';
411 $tabhandler['user']['files'] = 'renderFilesForEntity';
412 $ophandler['user']['tags']['saveTags'] = 'saveEntityTags';
413 $ophandler['user']['files']['addFile'] = 'addFileToEntity';
414 $ophandler['user']['files']['linkFile'] = 'linkFileToEntity';
415 $ophandler['user']['files']['unlinkFile'] = 'unlinkFile';
416
417 $page['perms']['title'] = 'Permissions';
418 $page['perms']['parent'] = 'config';
419 $tab['perms']['default'] = 'View';
420 $tab['perms']['edit'] = 'Edit';
421 $tabhandler['perms']['default'] = 'renderRackCodeViewer';
422 $tabhandler['perms']['edit'] = 'renderRackCodeEditor';
423 $ophandler['perms']['edit']['saveRackCode'] = 'saveRackCode';
424
425 $page['portmap']['title'] = 'Port compatibility';
426 $page['portmap']['parent'] = 'config';
427 $tab['portmap']['default'] = 'View';
428 $tab['portmap']['edit'] = 'Edit';
429 $tabhandler['portmap']['default'] = 'renderPortOIFCompatViewer';
430 $tabhandler['portmap']['edit'] = 'renderPortOIFCompatEditor';
431 $ophandler['portmap']['edit']['add'] = 'addPortOIFCompat';
432 $ophandler['portmap']['edit']['del'] = 'delPortOIFCompat';
433
434 $page['portifcompat']['title'] = 'Enabled port types';
435 $page['portifcompat']['parent'] = 'config';
436 $tab['portifcompat']['default'] = 'View';
437 $tab['portifcompat']['edit'] = 'Edit';
438 $tabhandler['portifcompat']['default'] = 'renderPortIFCompat';
439 $tabhandler['portifcompat']['edit'] = 'renderPortIFCompatEditor';
440 $ophandler['portifcompat']['edit']['add'] = 'addPortInterfaceCompat';
441 $ophandler['portifcompat']['edit']['del'] = 'delPortInterfaceCompat';
442 $ophandler['portifcompat']['edit']['addPack'] = 'addPortInterfaceCompatPack';
443 $ophandler['portifcompat']['edit']['delPack'] = 'delPortInterfaceCompatPack';
444
445 $page['attrs']['title'] = 'Attributes';
446 $page['attrs']['parent'] = 'config';
447 $tab['attrs']['default'] = 'View';
448 $tab['attrs']['editattrs'] = 'Edit attributes';
449 $tab['attrs']['editmap'] = 'Edit map';
450 $tabhandler['attrs']['default'] = 'renderAttributes';
451 $tabhandler['attrs']['editattrs'] = 'renderEditAttributesForm';
452 $tabhandler['attrs']['editmap'] = 'renderEditAttrMapForm';
453 $ophandler['attrs']['editattrs']['add'] = 'createAttribute';
454 $ophandler['attrs']['editattrs']['upd'] = 'changeAttribute';
455 $ophandler['attrs']['editattrs']['del'] = 'deleteAttribute';
456 $ophandler['attrs']['editmap']['add'] = 'supplementAttrMap';
457 $ophandler['attrs']['editmap']['del'] = 'reduceAttrMap';
458
459 $page['dict']['title'] = 'Dictionary';
460 $page['dict']['parent'] = 'config';
461 $tab['dict']['default'] = 'View';
462 $tab['dict']['chapters'] = 'Manage chapters';
463 $tabhandler['dict']['default'] = 'renderDictionary';
464 $tabhandler['dict']['chapters'] = 'renderChaptersEditor';
465 $ophandler['dict']['chapters']['del'] = 'delChapter';
466 $ophandler['dict']['chapters']['upd'] = 'updateChapter';
467 $ophandler['dict']['chapters']['add'] = array
468 (
469 'table' => 'Chapter',
470 'action' => 'INSERT',
471 'arglist' => array
472 (
473 array ('url_argname' => 'chapter_name', 'table_colname' => 'name', 'assertion' => 'string')
474 ),
475 );
476
477 $page['chapter']['parent'] = 'dict';
478 $page['chapter']['bypass'] = 'chapter_no';
479 $page['chapter']['bypass_type'] = 'uint';
480 $tab['chapter']['default'] = 'View';
481 $tab['chapter']['edit'] = 'Edit';
482 $tabhandler['chapter']['default'] = 'renderChapter';
483 $tabhandler['chapter']['edit'] = 'renderChapterEditor';
484 $ophandler['chapter']['edit']['del'] = 'reduceDictionary';
485 $ophandler['chapter']['edit']['upd'] = 'updateDictionary';
486 $ophandler['chapter']['edit']['add'] = array
487 (
488 'table' => 'Dictionary',
489 'action' => 'INSERT',
490 'arglist' => array
491 (
492 array ('url_argname' => 'chapter_no', 'table_colname' => 'chapter_id', 'assertion' => 'uint'),
493 array ('url_argname' => 'dict_value', 'assertion' => 'string'),
494 ),
495 );
496
497 $page['ui']['title'] = 'User interface';
498 $page['ui']['parent'] = 'config';
499 $tab['ui']['default'] = 'View';
500 $tab['ui']['edit'] = 'Change';
501 $tab['ui']['reset'] = 'Reset';
502 $tabhandler['ui']['default'] = 'renderUIConfig';
503 $tabhandler['ui']['edit'] = 'renderUIConfigEditForm';
504 $tabhandler['ui']['reset'] = 'renderUIResetForm';
505 $ophandler['ui']['edit']['upd'] = 'updateUI';
506 $ophandler['ui']['reset']['go'] = 'resetUIConfig';
507
508 $page['tagtree']['title'] = 'Tag tree';
509 $page['tagtree']['parent'] = 'config';
510 $tab['tagtree']['default'] = 'View';
511 $tab['tagtree']['edit'] = 'Edit';
512 $tabhandler['tagtree']['default'] = 'renderTagTree';
513 $tabhandler['tagtree']['edit'] = 'renderTagTreeEditor';
514 $ophandler['tagtree']['edit']['destroyTag'] = 'destroyTag';
515 $ophandler['tagtree']['edit']['updateTag'] = 'updateTag';
516 $ophandler['tagtree']['edit']['createTag'] = array
517 (
518 'table' => 'TagTree',
519 'action' => 'INSERT',
520 'arglist' => array
521 (
522 array ('url_argname' => 'tag_name', 'table_colname' => 'tag', 'assertion' => 'tag'),
523 array ('url_argname' => 'parent_id', 'assertion' => 'uint0', 'if_empty' => 'NULL'),
524 ),
525 );
526
527 $page['myaccount']['title'] = 'My account';
528 $page['myaccount']['parent'] = 'config';
529 $tab['myaccount']['default'] = 'Info';
530 $tab['myaccount']['mypassword'] = 'Password change';
531 $tab['myaccount']['interface'] = 'Interface preferences';
532 $trigger['myaccount']['mypassword'] = 'trigger_passwdchange';
533 $tabhandler['myaccount']['default'] = 'renderMyAccount';
534 $tabhandler['myaccount']['mypassword'] = 'renderMyPasswordEditor';
535 $tabhandler['myaccount']['interface'] = 'renderMyPreferences';
536 $ophandler['myaccount']['mypassword']['changeMyPassword'] = 'changeMyPassword';
537 $ophandler['myaccount']['interface']['upd'] = 'saveMyPreferences';
538 $ophandler['myaccount']['interface']['reset'] = 'resetMyPreference';
539
540 $page['reports']['title'] = 'Reports';
541 $page['reports']['parent'] = 'index';
542 $tab['reports']['default'] = 'System';
543 $tab['reports']['rackcode'] = 'RackCode';
544 $tab['reports']['ipv4'] = 'IPv4';
545 $tab['reports']['ipv6'] = 'IPv6';
546 $tab['reports']['ports'] = 'Ports';
547 $tab['reports']['8021q'] = '802.1Q';
548 $tab['reports']['local'] = getConfigVar ('enterprise');
549 $trigger['reports']['local'] = 'trigger_localreports';
550 $tabhandler['reports']['default'] = 'renderSystemReports';
551 $tabhandler['reports']['rackcode'] = 'renderRackCodeReports';
552 $tabhandler['reports']['ipv4'] = 'renderIPv4Reports';
553 $tabhandler['reports']['ipv6'] = 'renderIPv6Reports';
554 $tabhandler['reports']['ports'] = 'renderPortsReport';
555 $tabhandler['reports']['8021q'] = 'render8021QReport';
556 $tabhandler['reports']['local'] = 'renderLocalReports';
557
558 $page['files']['title'] = 'Files';
559 $page['files']['parent'] = 'index';
560 $tab['files']['default'] = 'Browse';
561 $tab['files']['manage'] = 'Manage';
562 $tabhandler['files']['default'] = 'renderFileBrowser';
563 $tabhandler['files']['manage'] = 'renderFileManager';
564 $ophandler['files']['manage']['addFile'] = 'addFileWithoutLink';
565 $ophandler['files']['manage']['unlinkFile'] = 'unlinkFile';
566 $ophandler['files']['manage']['deleteFile'] = 'deleteFile';
567
568 $page['file']['bypass'] = 'file_id';
569 $page['file']['bypass_type'] = 'uint';
570 $page['file']['parent'] = 'files';
571 $tab['file']['default'] = 'View';
572 $tab['file']['edit'] = 'Properties';
573 $tab['file']['tags'] = 'Tags';
574 $tab['file']['editText'] = 'Edit text';
575 $tab['file']['replaceData'] = 'Upload replacement';
576 $tab['file']['download'] = 'Download';
577 $trigger['file']['tags'] = 'trigger_tags';
578 $trigger['file']['editText'] = 'trigger_file_editText';
579 $tabhandler['file']['default'] = 'renderFile';
580 $tabhandler['file']['edit'] = 'renderFileProperties';
581 $tabhandler['file']['tags'] = 'renderEntityTags';
582 $tabhandler['file']['editText'] = 'renderTextEditor';
583 $tabhandler['file']['replaceData'] = 'renderFileReuploader';
584 $tabhandler['file']['download'] = 'renderFileDownloader';
585 $ophandler['file']['edit']['updateFile'] = 'updateFile';
586 $ophandler['file']['tags']['saveTags'] = 'saveEntityTags';
587 $ophandler['file']['editText']['updateFileText'] = 'updateFileText';
588 $ophandler['file']['replaceData']['replaceFile'] = 'replaceFile';
589
590 $page['8021q']['title'] = '802.1Q';
591 $page['8021q']['parent'] = 'index';
592 $tab['8021q']['default'] = 'Status';
593 $tab['8021q']['vdlist'] = 'Manage domains';
594 $tab['8021q']['vstlist'] = 'Manage templates';
595 $tabhandler['8021q']['default'] = 'render8021QStatus';
596 $tabhandler['8021q']['vdlist'] = 'renderVLANDomainListEditor';
597 $tabhandler['8021q']['vstlist'] = 'renderVSTListEditor';
598 $ophandler['8021q']['vdlist']['add'] = 'createVLANDomain';
599 $ophandler['8021q']['vdlist']['del'] = 'destroyVLANDomain';
600 $ophandler['8021q']['vdlist']['upd'] = 'updateVLANDomain';
601 $ophandler['8021q']['vstlist']['add'] = 'addVLANSwitchTemplate';
602 $ophandler['8021q']['vstlist']['del'] = 'delVLANSwitchTemplate';
603 $ophandler['8021q']['vstlist']['upd'] = 'updVLANSwitchTemplate';
604
605 $page['vlandomain']['parent'] = '8021q';
606 $page['vlandomain']['bypass'] = 'vdom_id';
607 $page['vlandomain']['bypass_type'] = 'uint';
608 $tab['vlandomain']['default'] = 'View';
609 $tab['vlandomain']['vlanlist'] = 'VLAN list';
610 $tab['vlandomain']['8021qorder'] = '802.1Q orders';
611 $tabhandler['vlandomain']['default'] = 'renderVLANDomain';
612 $tabhandler['vlandomain']['8021qorder'] = 'render8021QOrderForm';
613 $tabhandler['vlandomain']['vlanlist'] = 'renderVLANDomainVLANList';
614 $ophandler['vlandomain']['8021qorder']['add'] = 'add8021QOrder';
615 $ophandler['vlandomain']['8021qorder']['del'] = 'del8021QOrder';
616 $ophandler['vlandomain']['vlanlist']['del'] = 'delVLANDescription';
617 $ophandler['vlandomain']['vlanlist']['upd'] = 'updVLANDescription';
618 $ophandler['vlandomain']['vlanlist']['add'] = array
619 (
620 'table' => 'VLANDescription',
621 'action' => 'INSERT',
622 'arglist' => array
623 (
624 array ('url_argname' => 'vdom_id', 'table_colname' => 'domain_id', 'assertion' => 'uint'),
625 array ('url_argname' => 'vlan_id', 'assertion' => 'uint'),
626 array ('url_argname' => 'vlan_type', 'assertion' => 'string'), // ENUM actually
627 array ('url_argname' => 'vlan_descr', 'assertion' => 'string0', 'if_empty' => 'NULL'),
628 ),
629 );
630
631 $page['vlan']['parent'] = 'vlandomain';
632 $page['vlan']['bypass'] = 'vlan_ck';
633 $page['vlan']['bypass_type'] = 'string';
634 $tab['vlan']['default'] = 'View';
635 $tab['vlan']['ipv4'] = 'IPv4';
636 $tab['vlan']['ipv6'] = 'IPv6';
637 $trigger['vlan']['ipv4'] = 'trigger_vlan_ipv4net';
638 $trigger['vlan']['ipv6'] = 'trigger_vlan_ipv6net';
639 $tabhandler['vlan']['default'] = 'renderVLANInfo';
640 $tabhandler['vlan']['ipv4'] = 'renderVLANIPLinks';
641 $tabhandler['vlan']['ipv6'] = 'renderVLANIPLinks';
642 $ophandler['vlan']['ipv4']['bind'] = 'bindVLANtoIPv4';
643 $ophandler['vlan']['ipv4']['unbind'] = 'unbindVLANfromIPv4';
644 $ophandler['vlan']['ipv6']['bind'] = 'bindVLANtoIPv6';
645 $ophandler['vlan']['ipv6']['unbind'] = 'unbindVLANfromIPv6';
646
647 $page['vst']['parent'] = '8021q';
648 $page['vst']['bypass'] = 'vst_id';
649 $page['vst']['bypass_type'] = 'uint';
650 $tab['vst']['default'] = 'View';
651 $tab['vst']['editrules'] = 'Edit';
652 $tab['vst']['8021qorder'] = '802.1Q orders';
653 $trigger['vst']['editrules'] = 'trigger_vst_editrules';
654 $tabhandler['vst']['default'] = 'renderVST';
655 $tabhandler['vst']['editvst'] = 'renderVSTEditor';
656 $tabhandler['vst']['editrules'] = 'renderVSTRulesEditor';
657 $tabhandler['vst']['8021qorder'] = 'render8021QOrderForm';
658 $ophandler['vst']['editvst']['upd'] = 'updVLANSwitchTemplate';
659 $ophandler['vst']['editrules']['clone'] = 'cloneVSTRule';
660 $ophandler['vst']['editrules']['upd'] = 'updVSTRule';
661 $ophandler['vst']['8021qorder']['add'] = 'add8021QOrder';
662 $ophandler['vst']['8021qorder']['del'] = 'del8021QOrder';
663
664 $page['dqueue']['parent'] = '8021q';
665 $page['dqueue']['bypass'] = 'dqcode';
666 $page['dqueue']['bypass_type'] = 'string';
667 $tab['dqueue']['default'] = 'View';
668 $tabhandler['dqueue']['default'] = 'renderDeployQueue';
669
670 $page['objectlog']['title'] = 'Log records';
671 $page['objectlog']['parent'] = 'index';
672 $tab['objectlog']['default'] = 'View';
673 #$tab['objectlog']['add'] = 'Add'; // FIXME: finish, then enable
674 $tabhandler['objectlog']['default'] = 'allObjectLogs';
675 #$tabhandler['objectlog']['add'] = 'renderGlobalLogEditor';
676
677 ?>