<?php
/*********************************************************      
WXC2 SP configuration.

*********************************************************/

require("../sub_inc/commfunc.php");
$helpId = "1.1.1";
$DEBUG = 0;

//==========================================================
//变量定义
//==========================================================

if($flag)
{
	//Spname
	{
		$tmpobj		= 'OBJ_222';
		$tmpparam = 'param_99';
		$tmpoid = '2.4.1';
		$objWhereStr = getLevelWhere($tmpoid);
		$paramSql = " SELECT initValue,readValue,instanceNo FROM $tmpparam  
					WHERE subSysNo = '99' AND  $objWhereStr AND instanceNo ='$linkset' 
					";
		
		$Result  = mysqli_query($pubConn,$paramSql);				
		$Row		 = mysqli_fetch_array($Result);
		$TypeIn	 = getBitValue($Row[initValue],'4.0-4.7');
		$TypeIn  = hexdec($TypeIn);
		
//		$this_subSysNo	 = getBitValue($Row[initValue],'5.4-5.7');
//		$this_subSysNo  = bindec($this_subSysNo);
//		
//		$this_sysNo	 = getBitValue($Row[initValue],'5.0-5.3');
//		$this_sysNo  = bindec($this_sysNo);
		
		$this_sysNo = 0;
		$this_subSysNo = $subSysNo;
		
		$Spname = "CNF";
		if($TypeIn !=5)
		{
			$Spname = "Undefined CNF";	
		}
		$webname = $Spname;
		$Spname = $Spname."-$this_sysNo"."-$this_subSysNo";
		{
		$sysId = "160_$this_sysNo" . "_$this_subSysNo";
		$sysIdPub = "160_$this_sysNo" . "_99";
		
		$objDB = 'OBJ_160';
		$paramTab = 'param_'.$this_sysNo;	
		
		$center_objDB='OBJ_270';
		$center_paramTab='param_0';
		$center_sysId = "270_0_0";
		}
	}
	checkDevices(160);
	
	$oidsysarr=array(
		array('oid'=>'2.2.1',		'sysid'=> $sysId,			'selectsysid'=>'-1'),										
		array('oid'=>'2.2.2',		'sysid'=> $sysId,			'selectsysid'=>'-1'),										
		array('oid'=>'2.2.3',		'sysid'=> $sysId,			'selectsysid'=>'-1'),
												
		array('oid'=>'2.1.1',		'sysid'=> $sysIdPub,			'selectsysid'=>'-1'),										
		array('oid'=>'2.1.2',		'sysid'=> $sysIdPub,			'selectsysid'=>'-1'),										
		array('oid'=>'2.1.3',		'sysid'=> $sysIdPub,			'selectsysid'=>'-1')		
	);
	//==========================================================
	//数据处理
	//==========================================================

	echo "<br>Loading <br>";
	session_register("linksetGetFlag");
		
	GetParam($oidsysarr,1);
	echo "<br><br><h4><font color=\"#0000ff\">Finished!</font></h4>";	
}

echo "<input type=\"hidden\" name=\"linkset\" value=\"$linkset\">";
echo "<input type=\"hidden\" name=\"trunkgp\" value=\"$trunkgp\">";
echo "<input type=\"hidden\" name=\"subSysNo\" value=\"$subSysNo\">";

if($DEBUG) exit();
echo "<script LANGUAGE=\"JavaScript\">";
echo " location='./CNFconf.php?infoNo=$infoNo&trunkgp=$trunkgp&linkset=$linkset&subSysNo=$subSysNo&page_top=$page_top';";
echo "</script>";

exit();
?>