diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index 53740d2c6..49d10c506 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -179,13 +179,10 @@ EOF } $oPage->add("

".$this->GetIcon()." \n"); - if (!$oPage->IsPrintableVersion() && ($_SERVER['REQUEST_METHOD'] == 'GET')) - { - $aIcons[] = ''; - } // Master data sources $bSynchronized = false; + $aIcons = array(); if (!$oPage->IsPrintableVersion()) { $oCreatorTask = null; diff --git a/application/displayblock.class.inc.php b/application/displayblock.class.inc.php index f39aa0b54..7d80763d3 100644 --- a/application/displayblock.class.inc.php +++ b/application/displayblock.class.inc.php @@ -1382,6 +1382,7 @@ class MenuBlock extends DisplayBlock } } $bIsCreationAllowed = (UserRights::IsActionAllowed($sClass, UR_ACTION_CREATE) == UR_ALLOWED_YES) && ($oReflectionClass->IsSubclassOf('cmdbAbstractObject')); + $sRefreshAction = ''; switch($oSet->Count()) { case 0: @@ -1401,6 +1402,15 @@ class MenuBlock extends DisplayBlock else { $id = $oObj->GetKey(); + if ($_SERVER['REQUEST_METHOD'] == 'GET') + { + $sRefreshAction = "window.location.reload();"; + } + else + { + $sRefreshAction = "window.location.href='".ApplicationContext::MakeObjectUrl(get_class($oObj), $id)."';"; + } + $bLocked = false; if (MetaModel::GetConfig()->Get('concurrent_lock_enabled')) { @@ -1671,8 +1681,12 @@ class MenuBlock extends DisplayBlock { $sHtml .= "
    \n
  • ".Dict::S('UI:Menu:Actions')."\n
      \n"; } - + $sHtml .= $oPage->RenderPopupMenuItems($aActions, $aFavoriteActions); + if (!$oPage->IsPrintableVersion() && ($sRefreshAction!='')) + { + $sHtml .= "
      "; + } } static $bPopupScript = false; diff --git a/css/light-grey.css b/css/light-grey.css index 3931031d2..b4e4e56af 100644 --- a/css/light-grey.css +++ b/css/light-grey.css @@ -2069,3 +2069,12 @@ select.multiselect { } +span.refresh-button { + display: inline-block; + width: 21px; + height: 18px; + cursor: pointer; + background: transparent url(../images/refresh-fff.png) left center no-repeat; +} + + diff --git a/css/light-grey.scss b/css/light-grey.scss index eb35e2441..e35643f78 100644 --- a/css/light-grey.scss +++ b/css/light-grey.scss @@ -302,7 +302,6 @@ input.textSearch { border: 1px solid #7f9db9; background: #fff url(../images/ac-background.gif) no-repeat right; } - /* By Rom */ .csvimport_createobj { color: #AA0000; @@ -1524,4 +1523,11 @@ h2.printable-tab-title { } select.multiselect { max-width: 150px; +} +span.refresh-button { + display: inline-block; + width: 21px; + height: 18px; + cursor: pointer; + background: transparent url(../images/refresh-fff.png) left center no-repeat; } \ No newline at end of file diff --git a/images/refresh-fff.png b/images/refresh-fff.png new file mode 100755 index 000000000..9d01f7d90 Binary files /dev/null and b/images/refresh-fff.png differ