Author: ralfbecker
New Revision: 56086
URL: http://svn.stylite.de/viewvc/egroupware?rev=56086&view=rev
Log:
port “Admin Queue and History” and “Remote Administration Instances” to eT2
Modified:
trunk/admin/inc/class.admin_cmds.inc.php
trunk/admin/inc/class.admin_hooks.inc.php
trunk/admin/templates/default/cmds.xet
trunk/admin/templates/default/remotes.xet
— trunk/admin/inc/class.admin_cmds.inc.php (original)
+++ trunk/admin/inc/class.admin_cmds.inc.php Sat May 7 18:57:18 2016
@@ -11,6 +11,7 @@
*/
use EGroupware\Api;
+use EGroupware\Api\Etemplate;
/**
- UI for the admin comand queue
@@ -47,7 +48,13 @@
catch (Exception $e) {
$row[‘title’] = $e->getMessage();
}
-
$row['data'] = !($data = json_php_unserialize($row['data'])) ? '' :
-
json_encode($data, JSON_PRETTY_PRINT|JSON_UNESCAPED_UNICODE|JSON_UNESCAPED_SLASHES);
-
-
if ($row['status'] == admin_cmd::scheduled)
-
{
-
$row['class'] = 'AllowDelete';
-
}
}
//_debug_array($rows);
return $total;
@@ -60,7 +67,7 @@
*/
static function index(array $content=null)
{
@@ -74,6 +81,9 @@
‘no_cat’ => true, // I disable the cat-selectbox
’order’ => ‘cmd_created’,
‘sort’ => ‘DESC’,
-
'row_id' => 'id',
-
'default_cols' => 'title,created,creator,status',
-
'actions' => self::cmd_actions(),
);
}
}
@@ -95,6 +105,21 @@
}
/**
-
- Acctions for command list/index
-
-
- As we only allow to delete scheduled command, which we currently can only create via admin-cli,
-
- I have not (yet) implemented delete of scheduled commands.
-
-
- */
- static function cmd_actions()
- {
-
return array(
-
-
);
- }
-
- /**
- get_rows for remote instances
-
-
@param array $query
@@ -114,7 +139,7 @@
*/
static function remotes(array $content=null)
{
@@ -128,7 +153,8 @@
‘no_cat’ => true, // I disable the cat-selectbox
’order’ => ‘remote_name’,
‘sort’ => ‘ASC’,
@@ -137,12 +163,17 @@
//_debug_array($content);
unset($content[‘msg’]);
-
if ($content['nm']['rows']['edit'])
-
{
-
list($id) = each($content['nm']['rows']['edit']);
-
unset($content['nm']['rows']);
-
-
$content['remote'] = admin_cmd::read_remote($id);
-
if ($content['nm']['action'])
-
{
-
switch($content['nm']['action'])
-
{
-
case 'edit':
-
$content['remote'] = admin_cmd::read_remote($content['nm']['selected'][0]);
-
break;
-
case 'add':
-
$content['remote'] = array('remote_domain' => 'default');
-
}
-
unset($content['nm']['action']);
}
elseif($content['remote']['button'])
{
@@ -180,6 +211,34 @@
}
}
$tpl->exec(‘admin.admin_cmds.remotes’,$content,array(),array(),$content);
— trunk/admin/inc/class.admin_hooks.inc.php (original)
+++ trunk/admin/inc/class.admin_hooks.inc.php Sat May 7 18:57:18 2016
@@ -133,8 +133,8 @@
{
$file[‘phpInfo’] = “javascript:egw.openPopup(’” . Egw::link(’/admin/phpinfo.php’,’’,false) . “’,960,600,‘phpinfoWindow’)”;
}
-
$file['Admin queue and history'] = Egw::link('/index.php','menuaction=admin.admin_cmds.index');
-
$file['Remote administration instances'] = Egw::link('/index.php','menuaction=admin.admin_cmds.remotes');
-
$file['Admin queue and history'] = Egw::link('/index.php','menuaction=admin.admin_cmds.index&ajax=true');
-
$file['Remote administration instances'] = Egw::link('/index.php','menuaction=admin.admin_cmds.remotes&ajax=true');
$file['Custom translation'] = Egw::link('/index.php','menuaction=admin.admin_customtranslation.index');
$file['Changelog and versions'] = Egw::link('/about.php');
— trunk/admin/templates/default/cmds.xet (original)
+++ trunk/admin/templates/default/cmds.xet Sat May 7 18:57:18 2016
@@ -5,14 +5,13 @@
-
<column/>
-
<column/>
-
<column/>
-
<column/>
-
<column/>
@@ -20,33 +19,27 @@
-
<nextmatch-sortheader label="Created" id="cmd_created"/>
-
<nextmatch-accountfilter id="creator" options="Creator"/>
-
<nextmatch-filterheader id="status" options="Status"/>
-
<nextmatch-sortheader label="Modified" id="cmd_modified"/>
-
<nextmatch-sortheader label="Created" id="created"/>
-
<nextmatch-accountfilter empty_label="Creator" id="creator"/>
-
<nextmatch-filterheader empty_label="Status" id="status"/>
-
<nextmatch-sortheader label="Modified" id="modified"/>
<nextmatch-accountfilter options="Modifier" id="modifier"/>
-
<row class="row $row_cont[class]">
-
<description id="${row}[title]" statustext="$row_cont[data]"/>
<url-email id="${row}[requested]" options=",,,$row_cont[requested_email]" readonly="true"/>
<date-time id="${row}[scheduled]" readonly="true"/>
-
<url-email id="${row}[creator]" options=",,,$row_cont[creator_email]" readonly="true"/>
-
<vbox options="0,0">
-
<menulist>
-
<menupopup id="${row}[status]" readonly="true"/>
-
</menulist>
-
<select-account id="${row}[creator]" readonly="true" statustext="$row_cont[creator_email]"/>
-
<vbox>
-
<select id="${row}[status]" readonly="true"/>
<description id="${row}[error]" class="redItalic"/>
</vbox>
<date-time id="${row}[modified]" readonly="true"/>
-
<url-email id="${row}[modifier]" readonly="true" options=",,,$row_cont[modifier_email]"/>
-
<button image="delete" label="Cancel" id="delete[$row_cont[id]]" statustext="Cancel this scheduled command" onclick="et2_dialog.confirm(widget,'Cancel this scheduled command','Cancel');"/>
— trunk/admin/templates/default/remotes.xet (original)
+++ trunk/admin/templates/default/remotes.xet Sat May 7 18:57:18 2016
@@ -41,19 +41,15 @@
@@ -63,18 +59,17 @@
-
<description value="Actions"/>
</row>
<row class="row">
<description id="${row}[remote_name]"/>
<description options=",$row_cont[remote_url]/?domain=$row_cont[remote_domain],,,_blank" id="${row}[remote_url]"/>
<description id="${row}[remote_domain]" no_lang="1"/>
-
<hbox align="center">
-
<button image="edit" label="Edit" id="edit[$row_cont[remote_id]]"/>
-
</hbox>
</row>
</rows>
</grid>
@@ -82,17 +77,11 @@
-
<row disabled="!@msg">
-
<description span="all" class="redItalic" id="msg"/>
-
</row>
<row disabled="!@remote">
<template content="remote" span="all" class="border" id="admin.remotes.edit"/>
</row>
-
<row disabled="1">
-
<template align="right" id="admin.remotes.header_right"/>
-
</row>
<row>
-
<nextmatch id="nm" options="admin.remotes.rows"/>
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
eGroupWare-cvs mailing list
eGroupWare-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/egroupware-cvs