Using iTop

Creating your iTop

iTop Customization

"How to" examples

User Interface

Automation & Ticket management

Portal Customization

You are browsing the documentation for iTop 3.1 which is not the current version.

Consider browsing to iTop 3.2 documentation

Hide History from Activity panel

Prerequisite: You must be familiar with the Syntax used in Tutorials and have already created an extension.

Hide History entries from object Activity panel
XML, PHP, snippet
min version:

This example is a quick solution to hide the history on objects for Users having Support Agent Profile

  • It's not fully secured as the hiding is done on client side
  • It can be enhanced by a JS snippet that would remove the information from the DOM completely, but an advanced user could still set a breakpoint in its browser to prevent the JS snippet from being executed and search in the history
  • Allowed profiles could be put in a module parameter, if they need to be changed over time.
itop_design 3.0
    <snippet id="hide_history_entries" _delta="define">
    class HideHistoryEntries implements iBackofficeStyleExtension
      public function GetStyle(): string
        // Check if current user has a profile for which we want to hide history entries
        $aCurrentUserProfiles = \UserRights::ListProfiles();
        $aProfilesToHideEntriesFor = ['Support Agent'];
        foreach ($aCurrentUserProfiles as $sCurrentUserProfile) {
          if (in_array($sCurrentUserProfile, $aProfilesToHideEntriesFor)) {
            // Then force edits entries to be hidden
            return <<<CSS
.ibo-activity-entry.ibo-edits-entry {
  display: none !important;
        // Current user doesn't have a restricted profile, leave CSS as-is
        return '';
3_1_0/customization/hide-history.txt ยท Last modified: 2023/08/23 16:12 (external edit)
Back to top
Contact us