コード例 #1
0
 public static function OnMenuCreation()
 {
     if (UserRights::IsAdministrator()) {
         $oAdminMenu = new MenuGroup('AdminTools', 80);
         new WebPageMenuNode('ConfigEditor', utils::GetAbsoluteUrlModulesRoot() . 'itop-config/config.php', $oAdminMenu->GetIndex(), 18);
     }
 }
コード例 #2
0
 public static function OnMenuCreation()
 {
     // Add the admin menus
     if (UserRights::IsAdministrator()) {
         $oAdminMenu = new MenuGroup('AdminTools', 80);
         new OQLMenuNode('UserAccountsMenu', 'SELECT User', $oAdminMenu->GetIndex(), 1, true);
         new OQLMenuNode('ProfilesMenu', 'SELECT URP_Profiles', $oAdminMenu->GetIndex(), 2);
         new WebPageMenuNode('NotificationsMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/notifications.php', $oAdminMenu->GetIndex(), 3);
         new OQLMenuNode('AuditCategories', 'SELECT AuditCategory', $oAdminMenu->GetIndex(), 4);
         new WebPageMenuNode('RunQueriesMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/run_query.php', $oAdminMenu->GetIndex(), 8);
         new OQLMenuNode('QueryMenu', 'SELECT Query', $oAdminMenu->GetIndex(), 8.5, true);
         new WebPageMenuNode('ExportMenu', utils::GetAbsoluteUrlAppRoot() . 'webservices/export-v2.php?interactive=1', $oAdminMenu->GetIndex(), 9);
         new WebPageMenuNode('DataModelMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/schema.php', $oAdminMenu->GetIndex(), 10);
         new WebPageMenuNode('UniversalSearchMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/UniversalSearch.php', $oAdminMenu->GetIndex(), 11);
     }
 }
コード例 #3
0
 public static function OnMenuCreation()
 {
     $oToolsMenu = new MenuGroup('DataAdministration', 70, 'Organization', UR_ACTION_MODIFY, UR_ALLOWED_YES | UR_ALLOWED_DEPENDS);
     new WebPageMenuNode('CSVImportMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/csvimport.php', $oToolsMenu->GetIndex(), 1);
     // Add the admin menus
     if (UserRights::IsAdministrator()) {
         $oAdminMenu = new MenuGroup('AdminTools', 80);
         new OQLMenuNode('UserAccountsMenu', 'SELECT User', $oAdminMenu->GetIndex(), 1);
         new OQLMenuNode('ProfilesMenu', 'SELECT URP_Profiles', $oAdminMenu->GetIndex(), 2);
         new WebPageMenuNode('NotificationsMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/notifications.php', $oAdminMenu->GetIndex(), 3);
         new OQLMenuNode('AuditCategories', 'SELECT AuditCategory', $oAdminMenu->GetIndex(), 4);
         new WebPageMenuNode('RunQueriesMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/run_query.php', $oAdminMenu->GetIndex(), 8);
         new OQLMenuNode('QueryMenu', 'SELECT Query', $oAdminMenu->GetIndex(), 8.5, true);
         new WebPageMenuNode('ExportMenu', utils::GetAbsoluteUrlAppRoot() . 'webservices/export.php', $oAdminMenu->GetIndex(), 9);
         new WebPageMenuNode('DataModelMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/schema.php', $oAdminMenu->GetIndex(), 10);
         new WebPageMenuNode('UniversalSearchMenu', utils::GetAbsoluteUrlAppRoot() . 'pages/UniversalSearch.php', $oAdminMenu->GetIndex(), 11);
     }
 }
コード例 #4
0
        if ($iMaxReplica) {
            // Consider a given subset, starting from replica iCurrPos, limited to the count of iMaxReplica
            // The replica have to be ordered by id
            $oSetToProcess = new DBObjectSet(DBObjectSearch::FromOQL($sSelectToDelete), array('id' => true), array('source_id' => $this->m_oDataSource->GetKey(), 'last_import' => $sDeletionDate, 'curr_pos' => $iCurrPos));
            $oSetToProcess->SetLimit($iMaxReplica);
        } else {
            $oSetToProcess = $oSetScope;
        }
        $iLastReplicaProcessed = -1;
        while ($oReplica = $oSetToProcess->Fetch()) {
            $iLastReplicaProcessed = $oReplica->GetKey();
            $this->m_oStatLog->AddTrace("Destination object to be DELETED", $oReplica);
            $oReplica->DeleteDestObject($this->m_oChange, $this->m_oStatLog);
        }
        if ($iMaxReplica) {
            if ($iMaxReplica < $iCountScope) {
                // Continue with this job!
                $this->m_oStatLog->Set('status_curr_pos', $iLastReplicaProcessed);
                return true;
            }
        }
        // Job complete!
        $this->m_oStatLog->Set('status_curr_job', 0);
        $this->m_oStatLog->Set('status_curr_pos', -1);
        return false;
    }
}
$oAdminMenu = new MenuGroup('AdminTools', 80, 'SynchroDataSource', UR_ACTION_MODIFY, UR_ALLOWED_YES);
new OQLMenuNode('DataSources', 'SELECT SynchroDataSource', $oAdminMenu->GetIndex(), 12, true, 'SynchroDataSource', UR_ACTION_MODIFY, UR_ALLOWED_YES);
//	new OQLMenuNode('Replicas', 'SELECT SynchroReplica', $oAdminMenu->GetIndex(), 12 /* fRank */, true, 'SynchroReplica', UR_ACTION_MODIFY, UR_ALLOWED_YES);
//	new WebPageMenuNode('Test:RunSynchro', '../synchro/synchro_exec.php', $oAdminMenu->GetIndex(), 13 /* fRank */, 'SynchroDataSource');
コード例 #5
0
 public static function OnMenuCreation()
 {
     if (UserRights::IsAdministrator()) {
         $oAdminMenu = new MenuGroup('AdminTools', 80);
         new WebPageMenuNode('BackupStatus', utils::GetAbsoluteUrlModulePage('itop-backup', 'status.php'), $oAdminMenu->GetIndex(), 15);
     }
 }