N°9167 Use ExtensionDetails UIBlocks instead of table

This commit is contained in:
Timmy38
2026-05-12 12:01:41 +02:00
parent ba6cc9dcba
commit 9bc2cd0a38
11 changed files with 115 additions and 46 deletions

View File

@@ -486,7 +486,7 @@ class iTopExtensionsMap
'default' => true, // by default offer to install all modules
'modules' => $oExtension->aModules,
'mandatory' => $oExtension->bMandatory,
'source_label' => $this->GetExtensionSourceLabel($oExtension->sSource),
'source_label' => $oExtension->GetExtensionSourceLabel(),
'uninstallable' => $oExtension->CanBeUninstalled(),
'missing' => $oExtension->bRemovedFromDisk,
'version' => $oExtension->sVersion,
@@ -496,22 +496,6 @@ class iTopExtensionsMap
return $aRes;
}
protected function GetExtensionSourceLabel($sSource)
{
$sResult = '';
switch ($sSource) {
case iTopExtension::SOURCE_MANUAL:
$sResult = 'Local extensions folder';
break;
case iTopExtension::SOURCE_REMOTE:
$sResult = (ITOP_APPLICATION == 'iTop') ? 'iTop Hub' : 'ITSM Designer';
break;
}
return $sResult;
}
/**
* Mark the given extension as chosen
* @param string $sExtensionCode The code of the extension (code without version number)