mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-26 01:43:47 +01:00
fix not displayed requrested and comment
This commit is contained in:
parent
7e4c23ca56
commit
e53482289a
@ -204,7 +204,11 @@ class admin_account
|
|||||||
$account['account_groups'][] = $account['account_primary_group'];
|
$account['account_groups'][] = $account['account_primary_group'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$cmd = new admin_cmd_edit_user((int)$content['account_id'], $account, null, null, $old);
|
$cmd = new admin_cmd_edit_user(array(
|
||||||
|
'account' => (int)$content['account_id'],
|
||||||
|
'set' => $account,
|
||||||
|
'old' => $old,
|
||||||
|
)+(array)$content['admin_cmd']);
|
||||||
$cmd->run();
|
$cmd->run();
|
||||||
|
|
||||||
Api\Json\Response::get()->call('egw.refresh', '', 'admin', $cmd->account, $content['account_id'] ? 'edit' : 'add');
|
Api\Json\Response::get()->call('egw.refresh', '', 'admin', $cmd->account, $content['account_id'] ? 'edit' : 'add');
|
||||||
|
@ -5,9 +5,8 @@
|
|||||||
* @link http://www.egroupware.org
|
* @link http://www.egroupware.org
|
||||||
* @author Ralf Becker <RalfBecker-AT-outdoor-training.de>
|
* @author Ralf Becker <RalfBecker-AT-outdoor-training.de>
|
||||||
* @package admin
|
* @package admin
|
||||||
* @copyright (c) 2007-16 by Ralf Becker <RalfBecker-AT-outdoor-training.de>
|
* @copyright (c) 2007-18 by Ralf Becker <RalfBecker-AT-outdoor-training.de>
|
||||||
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
|
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
|
||||||
* @version $Id$
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
use EGroupware\Api;
|
use EGroupware\Api;
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
</row>
|
</row>
|
||||||
<row class="row $row_cont[class]">
|
<row class="row $row_cont[class]">
|
||||||
<description id="${row}[title]" statustext="$row_cont[data]"/>
|
<description id="${row}[title]" statustext="$row_cont[data]"/>
|
||||||
<url-email id="${row}[requested]" options=",,,$row_cont[requested_email]" readonly="true"/>
|
<url-email id="${row}[requested_email]" readonly="true" statustext="$row_cont[comment]"/>
|
||||||
<date-time id="${row}[scheduled]" readonly="true"/>
|
<date-time id="${row}[scheduled]" readonly="true"/>
|
||||||
<select id="${row}[remote_id]" readonly="true"/>
|
<select id="${row}[remote_id]" readonly="true"/>
|
||||||
<date-time id="${row}[created]" readonly="true"/>
|
<date-time id="${row}[created]" readonly="true"/>
|
||||||
|
@ -198,18 +198,36 @@ egw.extend('user', egw.MODULE_GLOBAL, function()
|
|||||||
*
|
*
|
||||||
* @param {et2_widget} _src_widget widget to select the user
|
* @param {et2_widget} _src_widget widget to select the user
|
||||||
* @param {string} _target_name name of widget to set the data
|
* @param {string} _target_name name of widget to set the data
|
||||||
* @param {string} _field name of data to set eg. "account_email"
|
* @param {string} _field name of data to set eg. "account_email" or "{account_fullname} <{account_email}>"
|
||||||
*/
|
*/
|
||||||
set_account_data: function(_src_widget, _target_name, _field)
|
set_account_data: function(_src_widget, _target_name, _field)
|
||||||
{
|
{
|
||||||
var user = _src_widget.get_value();
|
var user = _src_widget.get_value();
|
||||||
var target = _src_widget.getRoot().getWidgetById(_target_name);
|
var target = _src_widget.getRoot().getWidgetById(_target_name);
|
||||||
|
var field = _field;
|
||||||
|
|
||||||
if (user && target)
|
if (user && target)
|
||||||
{
|
{
|
||||||
egw.accountData(user, _field, false, function(_data)
|
egw.accountData(user, _field, false, function(_data)
|
||||||
{
|
{
|
||||||
target.set_value(_data[user]);
|
var data;
|
||||||
|
if (field.indexOf('{') == -1)
|
||||||
|
{
|
||||||
|
data = _data[user];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
data = field;
|
||||||
|
var match;
|
||||||
|
while((match = data.match(/{([^}]+)}/)))
|
||||||
|
{
|
||||||
|
egw.accountData(user, match[1], false, function(_data)
|
||||||
|
{
|
||||||
|
data = data.replace(/{([^}]+)}/, _data[user]);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
target.set_value(data);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user