<?php
class PaDefault extends CustomPage {
	public $sErrorImg='';
	public $sErrorTxt='';
	public $sLogoutURL='';
	
	public function PaDefault(){
		$this->ComPage();
	}
	public function OnLoadModel(){
		$this->sMetaTitle='用户登出';
		$this->sErrorImg='../../../Ui/m_default/Img/Home/42.jpg';
		$this->sErrorTxt='您已经安全的退出用户自助平台。';
		$this->getUser('1,2,3,4,5,');
		$this->sApp=new netsuserinfo($this->sConnString);
		$this->sLogoutURL=$this->sysFileConfig['businessLoginAddress'];
		$this->OnLogout();
	}
	public function OnLogout(){
		//-- ------ #Logout ------ --
		//daily setting
		$this->sApp->sDbDescriptions_Other=array(
			array($this->sysDbDescriptions[$this->sysTableHead.'netsuserdaily'],
				$this->sysDbDescriptions[$this->sysTableHead.'netsuserdailycont'],),
			);
		$tmpSTR=$this->sysFileConfig['UserLogTemplate'];
		$tmpSTR=str_replace('{Nets.ID}',$this->sUserInfo[0]['Columns']['uitID']['Value'],$tmpSTR);
		$tmpSTR=str_replace('{Nets.Name}',$this->sUserInfo[0]['Columns']['uitName']['Value'],$tmpSTR);
		$tmpSTR=str_replace('{Nets.Time}',date($this->sysTimeFormat),$tmpSTR);
		$tmpSTR=str_replace('{Nets.ActionType}','登出',$tmpSTR);
		$tmpSTR=str_replace('{Nets.Platform}','用户自助平台',$tmpSTR);
		$tmpSTR=str_replace('{Nets.Unit}',$this->sUserInfo[2]['Columns']['uutName']['Value'],$tmpSTR);
		$tmpSTR=str_replace('{Nets.Type}',$this->sUserInfo[4]['Columns']['uttName']['Value'],$tmpSTR);
		$tmpSTR=str_replace('{Nets.Group}',$this->sUserInfo[8]['Columns']['ugtName']['Value'],$tmpSTR);
		$tmpAR0=explode($this->sysSPLIT4,$tmpSTR);
		$this->sApp->sDbDescriptions_Other[0][0]['Columns']['udtName']['Value']=$tmpAR0[0];
		$this->sApp->sDbDescriptions_Other[0][0]['Columns']['udtType']['Value']=1;
		$this->sApp->sDbDescriptions_Other[0][1]['Columns']['udctIpAddress']['Value']=$this->getIP();
		$this->sApp->sDbDescriptions_Other[0][1]['Columns']['udctIntroduct']['Value']=$tmpSTR;
		
		$this->sApp->Logout($this->sUserInfo);
		return 0;
	}
}
?>