mirror of
https://github.com/SuiteCRM/SuiteCRM-Core.git
synced 2025-09-13 01:04:24 +08:00
[Legacy] Fix broken subpanel configuration on OAuthTokens
This commit is contained in:
parent
bd5cdbecb3
commit
f0e4634f3b
3 changed files with 15 additions and 4 deletions
|
@ -304,9 +304,22 @@ class OAuthToken extends SugarBean
|
|||
function displayDateFromTs($focus, $field, $value, $view='ListView')
|
||||
{
|
||||
$field = strtoupper($field);
|
||||
if (!isset($focus[$field])) {
|
||||
|
||||
$fieldValue = '';
|
||||
|
||||
if (is_array($focus) && isset($focus[$field])) {
|
||||
$fieldValue = $focus[$field];
|
||||
}
|
||||
|
||||
if (is_object($focus) && !empty($focus->$field)) {
|
||||
$fieldValue = $focus->$field;
|
||||
}
|
||||
|
||||
if (empty($fieldValue)) {
|
||||
return '';
|
||||
}
|
||||
|
||||
global $timedate;
|
||||
return $timedate->asUser($timedate->fromTimestamp($focus[$field]));
|
||||
|
||||
return $timedate->asUser($timedate->fromTimestamp($fieldValue));
|
||||
}
|
||||
|
|
|
@ -64,7 +64,6 @@ $subpanel_layout = array(
|
|||
'name'=>'token_ts',
|
||||
'width' => '10%',
|
||||
'vname' => 'LBL_TS',
|
||||
'function' => 'testfunc',
|
||||
),
|
||||
'assigned_user_name' => array(
|
||||
'name' => 'assigned_user_name',
|
||||
|
|
|
@ -65,7 +65,6 @@ $subpanel_layout = array(
|
|||
'name'=>'token_ts',
|
||||
'width' => '10%',
|
||||
'vname' => 'LBL_TS',
|
||||
'function' => 'testfunc',
|
||||
),
|
||||
'consumer_name' => array(
|
||||
'name' => 'consumer_name',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue