Adding conditions to check enviroment configuration dateformat.

This commit is contained in:
ralph
2013-04-04 17:34:14 -04:00
parent 736c693d0f
commit 3a26f1c262
2 changed files with 16 additions and 3 deletions

View File

@@ -88,6 +88,11 @@ class Configurations // extends Configuration
}
}
}
public function exists($cfgID)
{
return $this->Configuration->exists($cfgID,"",'','','');
}
/**
* configObject

View File

@@ -393,7 +393,11 @@ class SkinEngine
G::LoadClass( "configuration" );
$conf = new Configurations();
$smarty->assign('udate', $conf->getSystemDate(date('Y-m-d')));//G::getformatedDate(date('Y-m-d'), $currentFormat, SYS_LANG));
if (defined('SYS_SYS') && $conf->exists("ENVIRONMENT_SETTINGS")) {
$smarty->assign('udate', $conf->getSystemDate(date('Y-m-d')));
} else {
$smarty->assign('udate', G::getformatedDate(date('Y-m-d'), 'M d, yyyy', SYS_LANG));
}
}
if (defined('SYS_SYS')) {
@@ -647,8 +651,12 @@ class SkinEngine
G::LoadClass( "configuration" );
$conf = new Configurations();
$smarty->assign('udate', $conf->getSystemDate(date('Y-m-d')));//G::getformatedDate(date('Y-m-d'), $currentFormat, SYS_LANG));
if ( defined('SYS_SYS') && $conf->exists("ENVIRONMENT_SETTINGS")) {
$smarty->assign('udate', $conf->getSystemDate(date('Y-m-d')));
} else {
$smarty->assign('udate', G::getformatedDate(date('Y-m-d'), 'M d, yyyy', SYS_LANG));
}
}
if(class_exists('pmLicenseManager')){
$pmLicenseManagerO = &pmLicenseManager::getSingleton();