Added all the changes which done before for php5.3 in pmos9b

This commit is contained in:
abraar
2010-12-03 15:43:29 +00:00
parent 0525681d79
commit 5715059f24
11 changed files with 35 additions and 30 deletions

View File

@@ -1704,6 +1704,7 @@ class G
*/
function SendTemporalMessage($msgID, $strType, $sType='LABEL', $time=null, $width=null, $customLabels= null)
{
echo"Inside Send Temporal Message";
if( isset($width) ){
$_SESSION['G_MESSAGE_WIDTH'] = $width;
}

View File

@@ -164,12 +164,10 @@ class RBAC
return;
}
}
$this->sSystem = $sSystem;
$fieldsSystem = $this->systemObj->loadByCode($sSystem);
$fieldsRoles = $this->usersRolesObj->getRolesBySystem ($fieldsSystem['SYS_UID'], $sUser );
$fieldsPermissions = $this->usersRolesObj->getAllPermissions ($fieldsRoles['ROL_UID'], $sUser );
$this->aUserInfo[ $sSystem ]['SYS_UID'] = $fieldsSystem['SYS_UID'];
$this->aUserInfo[ $sSystem ]['ROLE'] = $fieldsRoles;
$this->aUserInfo[ $sSystem ]['PERMISSIONS'] = $fieldsPermissions;

View File

@@ -307,7 +307,7 @@ class DB
return $tmp;
}
@$obj =& new $classname;
@$obj = new $classname;
foreach ($options as $option => $value) {
$test = $obj->setOption($option, $value);
@@ -381,7 +381,7 @@ class DB
return $tmp;
}
@$obj =& new $classname;
@$obj = new $classname;
foreach ($options as $option => $value) {
$test = $obj->setOption($option, $value);
@@ -887,7 +887,7 @@ class DB_result
if ($object_class == 'stdClass') {
$arr = (object) $arr;
} else {
$arr = &new $object_class($arr);
$arr = new $object_class($arr);
}
}
return $arr;

View File

@@ -190,7 +190,7 @@ class PMPluginRegistry {
if ( $sNamespace == $namespace ) {
$this->registerFolder($sNamespace, $sNamespace, $detail->sPluginFolder ); //register the default directory, later we can have more
$this->_aPluginDetails[$sNamespace]->enabled = true;
$oPlugin =& new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$oPlugin = new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$this->_aPlugins[$detail->sNamespace] =& $oPlugin;
if (method_exists($oPlugin, 'enable')) {
$oPlugin->enable();
@@ -209,7 +209,7 @@ class PMPluginRegistry {
foreach ( $this->_aPluginDetails as $namespace=>$detail ) {
if ( $sNamespace == $namespace ) {
unset ($this->_aPluginDetails[$sNamespace]);
$oPlugin =& new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$oPlugin = new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$this->_aPlugins[$detail->sNamespace] =& $oPlugin;
if (method_exists($oPlugin, 'disable')) {
$oPlugin->disable();
@@ -298,7 +298,7 @@ class PMPluginRegistry {
try {
foreach ( $this->_aPluginDetails as $namespace=>$detail ) {
if ( $sNamespace == $namespace ) {
$oPlugin =& new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$oPlugin = new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$this->_aPlugins[$detail->sNamespace] =& $oPlugin;
$oPlugin->install();
}
@@ -769,7 +769,7 @@ class PMPluginRegistry {
$sFilename = PATH_PLUGINS . $aux[ count($aux) -1];
if (! file_exists($sFilename) ) continue;
require_once( $sFilename);
$oPlugin =& new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$oPlugin = new $detail->sClassName( $detail->sNamespace, $detail->sFilename );
$this->_aPlugins[$detail->sNamespace] =& $oPlugin;
$iPlugins++;

View File

@@ -140,6 +140,6 @@ class Configuration extends BaseConfiguration {
public function exists($CfgUid, $ObjUid, $ProUid, $UsrUid, $AppUid)
{
$oRow = ConfigurationPeer::retrieveByPK( $CfgUid, $ObjUid, $ProUid, $UsrUid, $AppUid );
return ( get_class ($oRow) == 'Configuration' );
return ( get_class ($oRow) == 'Configuration' && $oRow != '');
}
} // Configuration

View File

@@ -165,7 +165,7 @@ protected $depo_title = '';
$con = Propel::getConnection(DepartmentPeer::DATABASE_NAME);
try {
$oDept = DepartmentPeer::retrieveByPk( $DepUid );
if ( get_class ($oDept) == 'Department' ) {
if (is_object ($oDept) && get_class ($oDept) == 'Department' ) {
$aFields = $oDept->toArray(BasePeer::TYPE_FIELDNAME);
$this->fromArray ($aFields, BasePeer::TYPE_FIELDNAME );
$aFields['DEPO_TITLE'] = $oDept->getDepTitle();

View File

@@ -214,7 +214,7 @@ class Process extends BaseProcess {
$con = Propel::getConnection(ProcessPeer::DATABASE_NAME);
try {
$oPro = ProcessPeer::retrieveByPk( $ProUid );
if ( get_class($oPro) == 'Process' ) {
if (is_object($oPro) && get_class($oPro) == 'Process' ) {
return true;
}
else {

View File

@@ -18,7 +18,10 @@ class UsersProperties extends BaseUsersProperties {
function UserPropertyExists($sUserUID) {
try {
$oUserProperty = UsersPropertiesPeer::retrieveByPk($sUserUID);
if (get_class($oUserProperty) == 'UsersProperties') {
var_dump($oUserProperty);
var_dump($sUserUID);
if (get_class($oUserProperty) == 'UsersProperties' && $oUserProperty != '') {
echo"inside";
return true;
}
else {

View File

@@ -72,7 +72,7 @@ var installer=function()
var tr = this.table.insertRow(-1);
$(tr).append(
new DOM('td',{innerHTML:"PHP Version >= 5.1.x and PHP Version < 5.3.0",className:"inst_td0",colSpan:2}),
new DOM('td',{innerHTML:"PHP Version < 5.3.0",className:"inst_td0",colSpan:2}),
this.phpVersion = new DOM('td',{innerHTML:'Loading...',className:"inst_td1",colSpan:2})
);

View File

@@ -66,7 +66,7 @@ if($action==="check")
)
));
$data=null;
$data->phpVersion =(version_compare(PHP_VERSION,"5.1.0",">=") && version_compare(PHP_VERSION,"5.3.0","<") )?true:false;
$data->phpVersion =(version_compare(PHP_VERSION,"5.1.0",">="))?true:false;
if(trim($dataClient->mysqlH)=='' || trim($dataClient->mysqlU)=='')
{
$con = array('connection'=>false,'grant'=>false,'message'=>'Please complete the input fields (Hostname/Username)');

View File

@@ -31,6 +31,7 @@
try {
$frm = $_POST['form'];
$usr = '';
$pwd = '';
@@ -203,6 +204,7 @@ try {
$oUserProperty = new UsersProperties();
$aUserProperty = $oUserProperty->loadOrCreateIfNotExists($_SESSION['USER_LOGGED'], array('USR_PASSWORD_HISTORY' => serialize(array(md5($currentPwd)))));
$aErrors = $oUserProperty->validatePassword($_POST['form']['USR_PASSWORD'], $aUserProperty['USR_LAST_UPDATE_DATE'], $aUserProperty['USR_LOGGED_NEXT_TIME']);
if (!empty($aErrors)) {
if (!defined('NO_DISPLAY_USERNAME')) {
define('NO_DISPLAY_USERNAME', 1);
@@ -251,6 +253,7 @@ try {
$oHeadPublisher->assign('uriReq', $sLocation);
G::RenderPage('publish', 'extJs');
//G::header('Location: ' . $sLocation);
die;
}