BUG 5978 Add getVersion to System class and use it instead of PM_VERSION
Instead of every page defining it's own PM_VERSION interpretation, there is now a single getVersion function in the System class to always get the right version.
This commit is contained in:
@@ -75,13 +75,7 @@ function file_get_conditional_contents($szURL){
|
||||
function buildData(){
|
||||
G::LoadClass ( 'serverConfiguration' );
|
||||
$oServerConf = & serverConf::getSingleton ();
|
||||
if (! defined ( 'PM_VERSION' )) {
|
||||
if (file_exists ( PATH_METHODS . 'login/version-pmos.php' )) {
|
||||
require_once (PATH_METHODS . 'login/version-pmos.php');
|
||||
} else {
|
||||
define ( 'PM_VERSION', 'Development Version' );
|
||||
}
|
||||
}
|
||||
G::LoadClass("system");
|
||||
|
||||
$os = '';
|
||||
if (file_exists ( '/etc/redhat-release' )) {
|
||||
@@ -106,7 +100,7 @@ $oServerConf = & serverConf::getSingleton ();
|
||||
$params ['os'] = $os;
|
||||
$params ['webserver'] = getenv ( 'SERVER_SOFTWARE' );
|
||||
$params ['php'] = phpversion ();
|
||||
$params ['pmVersion'] = PM_VERSION;
|
||||
$params ['pmVersion'] = System::getVersion();
|
||||
if(class_exists('pmLicenseManager')){
|
||||
$params ['pmProduct'] = 'PMEE';
|
||||
}else{
|
||||
@@ -210,4 +204,4 @@ $oServerConf = & serverConf::getSingleton ();
|
||||
|
||||
$this->saveSingleton ();
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user