ENHANCEMENT "Database Configuration" section in installer shows database version and database type (without the "Database" suffix) for reference

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/phpinstaller/branches/2.4@111874 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
sharvey 2010-10-11 04:55:34 +00:00 committed by Sam Minnee
parent 73996de04b
commit c9f7ba1c6d

View File

@ -221,9 +221,9 @@ class InstallRequirements {
array(
"Database Configuration",
"Database support",
"Database support in PHP")
"Database support in PHP"
)
) {
)) {
if($this->requireDatabaseServer(
$databaseConfig,
array(
@ -246,7 +246,8 @@ class InstallRequirements {
array(
"Database Configuration",
"Database server meets required version",
""
'',
$this->getDatabaseTypeNice($databaseConfig['type']) . ' ' . $this->getDatabaseConfigurationHelper($databaseConfig['type'])->getDatabaseVersion($databaseConfig)
)
)) {
$this->requireDatabaseOrCreatePermissions(
@ -684,6 +685,10 @@ class InstallRequirements {
}
}
function getDatabaseTypeNice($databaseClass) {
return substr($databaseClass, 0, -8);
}
/**
* Get an instance of a helper class for the specific database.
* @param string $databaseClass e.g. MySQLDatabase or MSSQLDatabase