Merge pull request #594 from julceslauhub/master

Improvement in get the workspace info in the user authentication
This commit is contained in:
julceslauhub
2012-09-24 11:47:18 -07:00
5 changed files with 24 additions and 4 deletions

View File

@@ -213,7 +213,7 @@ class serverConf {
/**
* Will return a list of all WS in this system and their related information.
* @uses getWorkspaceInfo
* @uses getWSList
* param
* @return array
*/
@@ -226,7 +226,6 @@ class serverConf {
if (($file != ".") && ($file != "..")) {
if (file_exists ( PATH_DB . $file . '/db.php' )) { //print $file."/db.php <hr>";
$statusl = ($this->isWSDisabled ( $file )) ? 'DISABLED' : 'ENABLED';
//$wsInfo = $this->getWorkspaceInfo ( $file );
if(isset($this->aWSinfo[$file])){
$wsInfo = $this->aWSinfo[$file];
}else{

View File

@@ -68,6 +68,15 @@
<parameter name="Seq_in_index" value="1"/>
</vendor>
</index>
<index name="indexAppStatus">
<index-column name="APP_STATUS"/>
<vendor type="mysql">
<parameter name="Table" value="APPLICATION"/>
<parameter name="Non_unique" value="1"/>
<parameter name="Key_name" value="indexAppStatus"/>
<parameter name="Seq_in_index" value="1"/>
</vendor>
</index>
</table>
<table name="APP_DELEGATION">
<vendor type="mysql">

View File

@@ -53,6 +53,10 @@ CREATE TABLE [APPLICATION]
CREATE INDEX [indexApp] ON [APPLICATION] ([PRO_UID],[APP_STATUS],[APP_UID]);
CREATE INDEX [indexAppNumber] ON [APPLICATION] ([APP_NUMBER]);
CREATE INDEX [indexAppStatus] ON [APPLICATION] ([APP_STATUS]);
/* ---------------------------------------------------------------------- */
/* APP_DELEGATION */
/* ---------------------------------------------------------------------- */

View File

@@ -30,7 +30,8 @@ CREATE TABLE `APPLICATION`
`APP_PIN` VARCHAR(32) default '' NOT NULL,
PRIMARY KEY (`APP_UID`),
KEY `indexApp`(`PRO_UID`, `APP_STATUS`, `APP_UID`),
KEY `indexAppNumber`(`APP_NUMBER`)
KEY `indexAppNumber`(`APP_NUMBER`),
KEY `indexAppStatus`(`APP_STATUS`)
)ENGINE=MyISAM DEFAULT CHARSET='utf8' COMMENT='The application';
#-----------------------------------------------------------------------------
#-- APP_DELEGATION

View File

@@ -212,7 +212,14 @@ try {
/**end log**/
//************** background processes, here we are putting some back office routines **********
$oServerConf->setWsInfo(SYS_SYS,$oServerConf->getWorkspaceInfo(SYS_SYS) );
$heartBeatNWIDate = $oServerConf->getHeartbeatProperty('HB_NEXT_GWI_DATE','HEART_BEAT_CONF');
if (is_null($heartBeatNWIDate)) {
$heartBeatNWIDate = time();
}
if (time() >= $heartBeatNWIDate) {
$oServerConf->setWsInfo(SYS_SYS, $oServerConf->getWorkspaceInfo(SYS_SYS));
$oServerConf->setHeartbeatProperty('HB_NEXT_GWI_DATE', strtotime('+1 day'), 'HEART_BEAT_CONF');
}
//**** defining and saving server info, this file has the values of the global array $_SERVER ****
//this file is useful for command line environment (no Browser), I mean for triggers, crons and other executed over command line