init web ems all

This commit is contained in:
agtuser
2024-09-27 17:13:36 +08:00
parent 81c97acbe9
commit 5cc56f8078
4263 changed files with 798779 additions and 0 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,340 @@
<?php
/*********************************************************
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD>
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѡ<EFBFBD><D1A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD>񣬲<EFBFBD>ɾ<EFBFBD><C9BE><EFBFBD><EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD>Ļ<EFBFBD><C4BB><EFBFBD>
<20><><EFBFBD>ù<EFBFBD>ϵ<EFBFBD><CFB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: header.inc
<20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD>
<20><><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>
<20><><EFBFBD>ߣ<EFBFBD><DFA3><EFBFBD><EFBFBD><EFBFBD>ɭ 2002-05-29
<EFBFBD>޸<EFBFBD>ע<EFBFBD>ͣ<EFBFBD>
NO.1
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
ʱ<EFBFBD>
<EFBFBD>޸<EFBFBD>˵<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
*********************************************************/
require("../../inc/header.inc");
$DEBUG=0;
$showDate = date("d",mktime(0,0,0,date("m"),date("d")-$sel_date,date("Y")));
$timeItem = date("Y-m-d",mktime(0,0,0,date("m"),date("d")-$sel_date,date("Y")));
$showDate = omc_keep_length($showDate,0,2);
$db = $csta_db;
$sort_field = 'csta_datetime'; //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֶ<EFBFBD><D6B6><EFBFBD>
$sort_direction = 'DESC'; //<2F><><EFBFBD><EFBFBD>˳<EFBFBD><CBB3>
$number_records_to_display = 200; //ÿҳ<C3BF><D2B3>¼<EFBFBD><C2BC>
$time_column = "csta_datetime"; //ʱ<><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$sysType = isset($sysType)?$sysType:$DEFAULT_SYS; //<2F><EFBFBD><E8B1B8>
$csta_type = isset($csta_type)?$csta_type:'csta-h';
$table_name = omc_table_name($sysType,$csta_type); //ȡ<><C8A1><EFBFBD><EFBFBD><EFBFBD>ݿ<EFBFBD><DDBF><EFBFBD>
if($sysType == 'CNF' || $sysType == 'VPS'){
$table_name="vpsDetail";
}
$table_name = $table_name."_".$showDate;
$query_type = isset($query_type)?$query_type:'0'; //ȡ<>ò<EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>
$where = isset($where) ? urldecode($where) : ''; //<2F><><EFBFBD>ر<EFBFBD><D8B1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>url<72><6C>
$where = isset($where) ? stripslashes($where) : ''; //<2F><><EFBFBD><EFBFBD>һЩ'/'
$sysIdFiled="key_sys_id";
$subsysIdFiled="key_subsys_id";
//echo "$table_name<br>";
$sel_field_list= @mysql_list_fields($db,$table_name);
if(!$sel_field_list)
{
echo "<br>$strNotFindRecord.";
exit();
}
//ɾ<><C9BE><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if($delete)
{
$sql_query="DELETE FROM $table_name ".$where;
$sql_query=urlencode($sql_query); //<2F><><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʺϴ<CABA><CFB4><EFBFBD>
echo " <meta http-equiv=\"refresh\" content=\"0; url=./csta_del.php?del_sql=$sql_query\"> ";
}//endif($delete)
//<2F><>ת<EFBFBD><D7AA>ָ<EFBFBD><D6B8>ҳ<EFBFBD><D2B3>
if($go)
{
$initial_record = $number_records_to_display * ( $gotopage - 1 );
if($initial_record >= $number_of_records || $initial_record < 0)
{
echo "<script language=\"javascript\"> ";
echo "alert('";
echo $strInputPageNumberHasAMistake;
echo "'); ";
echo "</script>";
$initial_record = 0;
}
}//endif($go)
// <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if (!$number_of_records)
{
//<2F><>תҳ<D7AA><EFBFBD><E6B2BB><EFBFBD>г<EFBFBD>ʼ<EFBFBD><CABC>
//-------ȷ<><C8B7><EFBFBD><EFBFBD><EFBFBD>ڷ<EFBFBD>Χ-----
if($sel_date<0){
$bgn_date=date("Y-m-d H:i:s", mktime(0,0,0,date("m"),date("d")-6,date("Y")));
$end_date=date("Y-m-d H:i:s", mktime());
}elseif($sel_date>0){
if($sel_time){
$bgn_date=date("Y-m-d H:i:s", mktime($hou_1,$mid_1,$sec_1,date("m"),date("d")-$sel_date,date("Y")));
$end_date=date("Y-m-d H:i:s", mktime($hou_2,$mid_2,$sec_2,date("m"),date("d")-$sel_date,date("Y")));
}else{
$bgn_date=date("Y-m-d H:i:s", mktime(0,0,0,date("m"),date("d")-$sel_date,date("Y")));
$end_date=date("Y-m-d H:i:s", mktime(0,0,0,date("m"),date("d")-$sel_date+1,date("Y")));
}
}else{
if($sel_time){
$bgn_date=date("Y-m-d H:i:s", mktime($hou_1,$mid_1,$sec_1,date("m"),date("d")-$sel_date,date("Y")));
$end_date=date("Y-m-d H:i:s", mktime($hou_2,$mid_2,$sec_2,date("m"),date("d")-$sel_date,date("Y")));
}else{
$bgn_date=date("Y-m-d H:i:s", mktime(0,0,0,date("m"),date("d"),date("Y")));
$end_date=date("Y-m-d H:i:s", mktime());
}
}
//where<72><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w0
$w0=" key_type<17 ";
//where<72><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w1
$w1=" AND $time_column > '$bgn_date' AND $time_column <= '$end_date'";
//where<72><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵͳid<69><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w2
if($sys_num!='-1' && $sys_num!=''){
$w2=" AND $sysIdFiled=$sys_num";
}
//where<72><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵͳid<69><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w3
if($subsys_num!='-1' && $subsys_num!=''){
$w3=" AND $subsysIdFiled=$subsys_num";
}
//where<72><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD>E1id<69><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w4
if($e1_num!='-1' && $e1_num!='' && $query_type<5 && $query_type>0){
$w4=" AND key_e1_tg=$e1_num";
}
//where<72><65><EFBFBD><EFBFBD><EFBFBD>ĺ<EFBFBD><C4BA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɲ<EFBFBD><C9B2><EFBFBD>$w5
if($query_type>0)
{
$w5=" AND key_type=$query_type ";
}
if($sysType == 'VPS'){
$w6=" AND key_type=1 ";
}elseif($sysType == 'CNF'){
$w6=" AND key_type=2 ";
}
//<2F>ϳɲ<CFB3>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>$where
$where=" WHERE ".$w0.$w1.$w2.$w3.$w4.$w5.$w6;
//echo "$where<br>";
$initial_record = 0;//<2F><>ʼ<EFBFBD><CABC>¼<EFBFBD><C2BC>
$str_sql_all="SELECT count(*) as number_of_records FROM $table_name ".$where;
if ($DEBUG) echo "<br>str_sql_all=$str_sql_all";
$csta_result= mysqli_query($pubConn,$str_sql_all);
$record = mysql_fetch_object($csta_result);
$number_of_records = $record->number_of_records;
if(!$number_of_records)
{
echo $strNotFindRecord;
exit();
} //endif(!$number_of_records)
}//endif(!$number_of_records)
$page_num= ($initial_record / $number_records_to_display) +1; //<2F><>ҳҳ<D2B3><D2B3>
$all_page_num= ceil($number_of_records / $number_records_to_display); //<2F><>ҳ<EFBFBD><D2B3>
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>־
if($page_num <=1)
{
insertLog("CSTA data query",2,1);
}
//<2F><><EFBFBD><EFBFBD><EFBFBD>ǿ<EFBFBD><C7BF>Ʒ<EFBFBD>ҳ<EFBFBD><D2B3>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD><EFBFBD>ݱ<EFBFBD><DDB1><EFBFBD>
if ($number_of_records >= 1)
{
$next_index = $initial_record + $number_records_to_display; //<2F><>ҳ<EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD>Ŀ
if ($next_index > $number_of_records)
{
$next_index = $number_of_records;
}
$t1 = $initial_record + 1;
$prev_index = $initial_record - $number_records_to_display;
if($prev_index < 0)
{
$prev_index = 0;
}
}
$show_initial_record=$initial_record+1;
?>
<base target="_self">
<body leftmargin=0 topmargin=0>
<script LANGUAGE="JavaScript">
function goto(){
var url_1,url_2,url_3,url_4,url_5,initial_record,gotopage,number_records_to_display,where,number_of_records,sort_field,sel_date;
gotopage=document.selectform.gotopage.value;
number_records_to_display=<?php echo $number_records_to_display; ?>;
where=document.selectform.where.value;
initial_record=number_records_to_display*(gotopage-1);
number_of_records=document.selectform.number_of_records.value;
sort_field=document.selectform.sort_field.value;
sel_date=document.selectform.sel_date.value;
url_1='<?php echo $PHP_SELF;?>?initial_record='+initial_record;
url_2="&where="+where;
url_3="&number_of_records="+number_of_records;
url_4="&sort_field="+sort_field;
url_5="&sel_date="+sel_date;
window.location.href=url_1+url_2+url_3+url_4+url_5;
}
</script>
<table border="1" width="100%" cellpadding="2" cellspacing="0" bordercolor="#666666" bordercolordark="#FFFFFF" bgcolor="#FFFFFF">
<tr>
<td width="50%">
<?php
echo "$strDisplayRecords:<FONT color=#0000ff>&nbsp;$show_initial_record - $next_index</FONT>, ($strTotalRecords:$number_of_records )&nbsp;&nbsp;";
?>
</td>
<td width="10%" align="center">&nbsp;
<?php
// NEW: Display a link for the previous set of records.
if ($initial_record != 0)
{
$t1 = "initial_record=$prev_index&number_of_records=$number_of_records&sys_id=$sys_id&sysType=$sysType&csta_type=$csta_type&query_type=$query_type";
$where=urlencode($where); //<2F><><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʺϴ<CABA><CFB4><EFBFBD>
echo "<a href=\"$PHP_SELF?$t1&where=$where&end_date=$end_date&bgn_date=$bgn_date&sel_date=$sel_date\">";
echo "<IMG alt=\"$strPreviousPage\" src=\"../../images/pre_page.gif\" border=\"0\"></a>&nbsp;";
}
// NEW: Display a link for the next set of records.
if ($next_index != $number_of_records && $number_of_records >0 && $number_of_records > $number_records_to_display )
{
$t1 = "initial_record=$next_index&number_of_records=$number_of_records&sys_id=$sys_id&sysType=$sysType&csta_type=$csta_type&query_type=$query_type";
$where=urlencode($where); //<2F><><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʺϴ<CABA><CFB4><EFBFBD>
echo "<a href=\"$PHP_SELF?$t1&where=$where&end_date=$end_date&bgn_date=$bgn_date&sel_date=$sel_date\">";
echo "<IMG alt=\"$strNextPage\" src=\"../../images/next_page.gif\" border=\"0\"></a>";
}
?>
</td>
<form name="selectform" method="post" action="<?php echo "$PHP_SELF?initial_record=$prev_index&number_of_records=$number_of_records&where=$where&sys_id=$sys_id&sysType=$sysType&csta_type=$csta_type&query_type=$query_type";?>" >
<td width="20%" align="center"><?php echo $strTopage;?>
<select size="1" name="gotopage" onChange="javascript:goto()">
<?php
for($i=1;$i<=$all_page_num;$i++)
{
if($i== $page_num ){
echo "<option selected value=\"$i\" >$i</option>";
}else{
echo "<option value=\"$i\">$i</option>";
}
}
?>
</select>
</td>
<!--
<td width="10%" align="center"><input type="submit" value="<?php echo $strDeleteQueryResult;?>" name="delete" ></td>
-->
</tr>
</table>
<?php
$where = isset($where) ? urldecode($where) : ''; //<2F><><EFBFBD>ر<EFBFBD><D8B1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>url<72><6C>
$where = isset($where) ? urldecode($where) : ''; //<2F><><EFBFBD>ر<EFBFBD><D8B1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>url<72><6C>
$where = isset($where) ? stripslashes($where) : ''; //<2F><><EFBFBD><EFBFBD>һЩ'/'
//<2F><>ѯ<EFBFBD><D1AF><EFBFBD>ݲ<EFBFBD><DDB2><EFBFBD><EFBFBD><EFBFBD>myrows<77><73><EFBFBD><EFBFBD><EFBFBD>С<EFBFBD>
//<2F>ϳ<EFBFBD>sql<71><6C><EFBFBD><EFBFBD>
$order=" ORDER BY $sort_field $sort_direction";
$limit=" LIMIT $initial_record, $number_records_to_display";
$csta_sql="SELECT * FROM $table_name"."\n".$where.$order.$limit;
//echo "$csta_sql<br>";
$csta_result = mysqli_query($pubConn,$csta_sql);
$csta_rows = mysqli_fetch_array($csta_result);
?>
<table border="1" width="100%" cellpadding="2" cellspacing="0" bordercolor="#666666" bordercolordark="#FFFFFF" bgcolor="#FFFFFF" >
<tr bgcolor="#E6E6E6">
<td colspan="3" align="center" ><?php echo $strEquipment; ?>
</td>
<td colspan="9" align="center" >
<?php
echo "{$defineQueryType[$query_type][name]}";
?>
</td>
<td align="center" >&nbsp; </td>
</tr>
<tr bgcolor="#E6E6E6">
<td align="center"><?php echo $strSystem; ?></td>
<td align="center"><?php echo $strType; ?></td>
<td align="center">TG</td>
<td align="center"><?php echo "Attempt"; ?></td>
<td align="center"><?php echo "Success"; ?></td>
<td align="center"><?php echo "Call Deny"; ?></td>
<td align="center"><?php echo "Net Busy"; ?></td>
<td align="center"><?php echo "Caller clear"; ?></td>
<td align="center"><?php echo "Sub Busy"; ?></td>
<td align="center"><?php echo "No Answer"; ?></td>
<td align="center"><?php echo "Signal Error"; ?></td>
<td align="center"><?php echo "Total Call Duration"; ?></td>
<td align="center"><?php echo "$strTime($timeItem)"; ?></td>
</tr>
<?php
do{
?>
<tr>
<td align="center"><?php
$csta_rows[0]=$csta_rows[$sysIdFiled];
$csta_rows[1]=$csta_rows[$subsysIdFiled];
echo "$sysType"."_"."$csta_rows[0]_$csta_rows[1]";?></td>
<td align="center">
<?php
echo $csta_rows[2];
?>
</td>
<td align="center">
<?php
if($sysType==$DEFAULT_SYS){
echo $csta_rows[3];
}else{
echo "--";
}
?>
</td>
<td align="center"><?php echo "$csta_rows[Attempt]";?></td>
<td align="center"><?php echo "$csta_rows[Success]";?></td>
<td align="center"><?php echo "$csta_rows[CallDeny]";?></td>
<td align="center"><?php echo "$csta_rows[NetBusy]";?></td>
<td align="center"><?php echo "$csta_rows[CallerClear]";?></td>
<td align="center"><?php echo "$csta_rows[SubBusy]";?></td>
<td align="center"><?php echo "$csta_rows[NoAnswer]";?></td>
<td align="center"><?php echo "$csta_rows[SignalErr]";?></td>
<td align="center"><?php echo "$csta_rows[Duration]";?></td>
<td align="center">
<?php
$tmpArray = explode(" ",$csta_rows[csta_datetime]);
echo "$tmpArray[1] ";
?>
</td>
</tr>
<?php
}while($csta_rows= mysqli_fetch_array($csta_result));
?>
<input type="hidden" name="where" value="<?php echo $where; ?>">
<input type="hidden" name="number_of_records" value="<?php echo $number_of_records; ?>">
<input type="hidden" name="sort_field" value="<?php echo $sort_field; ?>">
<input type="hidden" name="sel_date" value="<?php echo $sel_date; ?>">
</form>
</table>
</body>
</html>

View File

@@ -0,0 +1,17 @@
<?php
require("../../inc/header.inc");
?>
<frameset framespacing="0" border="0" rows="80,*" frameborder="0">
<frame name="header" scrolling="no" noresize target="main" src="dataUp.php?sysType=<?php echo $sysType; ?>">
<frame name="main" src="dataDown.php?sysType=<?php echo $sysType; ?>" scrolling="auto" target="_self">
<noframes>
<body>
<p><3E><><EFBFBD><EFBFBD>ҳʹ<D2B3><CAB9><EFBFBD>˿<EFBFBD><CBBF>ܣ<EFBFBD><DCA3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>֧<EFBFBD>ֿ<EFBFBD><D6BF>ܡ<EFBFBD></p>
</body>
</noframes>
</frameset>
</html>

View File

@@ -0,0 +1,147 @@
<?php
/*********************************************************
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD>
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>ѡ<EFBFBD><D1A1>
<20><><EFBFBD>ù<EFBFBD>ϵ<EFBFBD><CFB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: header.inc
<20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:
<20><><EFBFBD><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD>
<20><><EFBFBD><EFBFBD>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD>
<20><><EFBFBD>ߣ<EFBFBD><DFA3><EFBFBD><EFBFBD><EFBFBD>ɭ 2002-05-29
<EFBFBD>޸<EFBFBD>ע<EFBFBD>ͣ<EFBFBD>
NO.1
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
ʱ<EFBFBD>
<EFBFBD>޸<EFBFBD>˵<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
NO.2
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
ʱ<EFBFBD>
<EFBFBD>޸<EFBFBD>˵<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
*********************************************************/
require("../../inc/header.inc");
$helpId = "3.2.1";
$device_name=isset($device_name)?$device_name:$DEFAULT_SYS;
$db=$omc_db;
?>
<base target="main">
<script language="javascript">
<!--
function display(){
if(document.selectform.sel_time.checked){
document.all["set_time"].style.visibility="visible";
}else{
document.all["set_time"].style.visibility="hidden";
}
}
function select_device(){
var base_url,url_add,url;
base_url='<?php echo"$PHP_SELF";?>?device_name=';
url_add=document.selectform.device_list.value;
url=base_url+url_add;
window.location=url;
}
//-->
</script>
<body leftmargin=12 topmargin=0>
<?php
echo "<table border=\"0\" width=\"100%\">";
echo "<tr>";
echo "<td width=\"50%\">";
echo "$strAdvanced > $strTitlePerformance > $sysType > $strData";
echo "</td>";
echo "<td width=\"50%\" align=\"right\" title=\"Help\">";
//showHelp($helpId);
echo "</td>";
echo "</tr>";
echo "</table>";
$day0=date("Y-m-d",mktime(0,0,0,date("m"),date("d"),date("Y")));
$day1=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-1,date("Y")));
$day2=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-2,date("Y")));
$day3=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-3,date("Y")));
$day4=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-4,date("Y")));
$day5=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-5,date("Y")));
$day6=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-6,date("Y")));
?>
<form method="post" name="selectform" id="selectform" action="dataDown.php" >
<table border="0" width="100%" cellpadding="2" cellspacing="0">
<tr bgcolor="#FFFFFF">
<?php
$sys_num= get_sys_total($device_name);
$subsys_num= get_subsys_total($device_name);
$e1_num= get_e1_total($device_name);
echo "<td width=\"100\">";
echo "<nobr>";
if($sysType == $DEFAULT_SYS){
echo "<select style=\"font-family: Verdana; font-size: 8pt\" name=\"query_type\" size=\"1\">";
echo "<option value=\"0\">All</option>";
echo "<option value=\"5\">Sub to sub</option>";
echo "<option value=\"6\">Sub to trunk</option>";
echo "<option value=\"7\">Trunk to sub</option>";
echo "<option value=\"8\">Trunk to trunk</option>";
echo "<option value=\"9\">Interconnection</option>";
echo "<option value=\"10\">Sub to ip</option>";
echo "<option value=\"11\">Trunk to ip</option>";
echo "<option value=\"12\">Mobile originated</option>";
echo "<option value=\"13\">Mobile terminated</option>";
echo "<option value=\"14\">In trunk</option>";
echo "<option value=\"15\">Out trunk</option>";
echo "<option value=\"16\">Ip terminated</option>";
echo "</select>";
echo "&nbsp;";
}
echo "<select style=\"font-family: Verdana; font-size: 8pt\" name=\"sel_date\" size=\"1\">";
echo "<OPTION selected value=\"0\">$day0</OPTION>";
echo "<OPTION value=\"1\">$day1</OPTION>";
echo "<OPTION value=\"2\">$day2</OPTION>";
echo "<OPTION value=\"3\">$day3</OPTION>";
echo "<OPTION value=\"4\">$day4</OPTION>";
echo "<OPTION value=\"5\">$day5</OPTION>";
echo "<OPTION value=\"6\">$day6</OPTION>";
echo "</SELECT></nobr></td>";
?>
<td bgcolor="#FFFFFF">
<div onClick="javascript:document.selectform.submit();" style="cursor:hand">
<IMG align=absBottom border=0 src="../../images/search.gif" ><?php echo "$strSearch"; ?>
<div>
</td>
<td bgcolor="#FFFFFF" width="30">
</td>
<td width="100" bgcolor="#FFFFFF">
<?php echo "$strSpecifyTime" ?><input style="font-family: Verdana; font-size: 8pt" name=sel_time onClick=display() value="true" type="checkbox" >
</td>
<td bgcolor="#FFFFFF">
<DIV align=left id=set_time style="VISIBILITY: hidden;">
<table width="100%">
<tr>
<td align="center">
<?php echo "$strFrom"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" name="hou_1" size="2" value="00" maxLength="2">&nbsp;<?php echo "$strHour"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" name="mid_1" size="2" value="00" maxLength="2">&nbsp;<?php echo "$strMinute"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" name="sec_1" size="2" value="00" maxLength="2">&nbsp;<?php echo "$strSencond"; ?>&nbsp;
<?php echo "$strTo"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" maxLength="2" name="hou_2" size="2" value="23">&nbsp;<?php echo "$strHour"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" name="mid_2" size="2" value="59" maxLength="2">&nbsp;<?php echo "$strMinute"; ?>&nbsp;
<input style="font-family: Verdana; font-size: 8pt" name="sec_2" size="2" value="59" maxLength="2">&nbsp;<?php echo "$strSencond"; ?>&nbsp;
</td>
</tr>
</table>
</DIV>
</td>
</tr>
</table>
<input type="hidden" name="sysType" value="<?php echo $sysType;?>">
</form>
</body>
</html>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,27 @@
<?php
/*
File Name: service_detail_index.php
Description: show the detail service page main frame
Author: JianHui Zheng
*/
?>
<?php
//==============initial the data=======================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($service_type))
$service_type=0;
if(!isset($on_top_index))
$on_top_index=0;
?>
<frameset rows="75,*" frameborder=0 border=0>
<?php
echo "<frame scrolling=\"no\" name=\"service_detail_up\" src=\"service_detail_up.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to&service_type=$service_type\">";
echo "<frame name=\"service_detail_down\" src=\"service_detail_down.php?on_top_index=$on_top_index&service_type=$service_type&sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">";
?>
</frameset>

View File

@@ -0,0 +1,125 @@
<?php
//Include the head file
require("../../inc/header.inc");
?>
<base target="service_detail_down">
<script language="JavaScript">
function sel_date_from_change()
{
//sel_date_from,sel_date_to,scroll_y,on_top_index1,on_top_index2
var down_date_from=document.myform.sel_date_from.value;
var down_date_to=document.myform.sel_date_to.value;
var ser_type=document.myform.service_type.value;
var on_top=parent.service_detail_down.document.myform.on_top_index.value;
//var scrolly=document.body.scrollTop;
if(down_date_from<=down_date_to)
down_date_to=down_date_from;
var urll='./service_detail_up.php?sel_date_from='+down_date_from+'&sel_date_to='+down_date_to+'&service_type='+ser_type+"&on_top_index="+on_top;
window.location.href=urll;
}
</script>
<body leftmargin="15" rightmargin="10" onload="javascript:adjust_frame('up');" onresize="javascript:adjust_frame('up');" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;">
<form name="myform" action="service_detail_down.php" method="post">
<?php
adjust_head_frame("up");
adjust_title_head_frame("up");
//==================get the parameter the previous transfer====================
$old_sel_date_from=$sel_date_from;
$old_sel_date_to=$sel_date_to;
//===========================page title========================================
echo "<table id=\"table_up\" border=0 width=\"100%\">";
echo "<tr>";
echo "<td width=50% align=\"left\">";
echo "$strTitlePerformance > iPALIM > $strService";
echo "</td>";
echo "<td align=\"right\">";
$helpId="3.11.1";
showHelp($helpId);
echo "</td>";
echo "</tr>";
echo "<tr>";
echo "<td align=\"left\">";
//=======================data initial==========================================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($service_type))
$service_type=0;
if(!isset($on_top_index))
$on_top_index=0;
//selection date define
$day0=date("Y-m-d",mktime(0,0,0,date("m"),date("d"),date("Y")));
$day1=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-1,date("Y")));
$day2=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-2,date("Y")));
$day3=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-3,date("Y")));
$day4=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-4,date("Y")));
$day5=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-5,date("Y")));
$day6=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-6,date("Y")));
echo "<input type=\"hidden\" name=\"service_type\" value=$service_type>";
?>
<!--=========================date from selection=================================-->
<select name="sel_date_from" onChange="javascript:sel_date_from_change()">
<?php
for($i=0;$i<7;$i++)
{
if($i==$sel_date_from)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>to
<!--=========================date to selection=================================-->
<select name="sel_date_to">
<?php
for($i=0;$i<=$sel_date_from;$i++)
{
if($i==$sel_date_to)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>
<!--=========================the search button============================-->
<span onClick="javascript:myform.submit()" style="cursor:hand">
<IMG align=absBottom border=0 src="../../images/search.gif" ><?php echo "$strSearch"; ?>
</span>
<?php
echo "</td>";
echo "<td align=\"right\">";
//===================the back link button======================================
echo "<span style=\"cursor:hand;\">";
echo "<a target=\"_parent\" href=\"../../performance/ipalimCsta/service_general_index.php?sel_date_from=$old_sel_date_from&sel_date_to=$old_sel_date_to&scroll_y=0\"><img src=\"../../images/left.gif\" border=0></img>back</a>";
echo "</span>";
?>
<span onClick="window.print();" style="cursor:hand">
<img align=absBottom border=0 src="../../images/printer.gif" width="16" height="16">
</span>
<?php
echo "</td>";
echo "</tr>";
echo "</table>";
adjust_title_tail_frame("up");
adjust_content_head_frame("up");
adjust_content_tail_frame("up");
?>

View File

@@ -0,0 +1,735 @@
<?php
require("../../inc/header.inc");
?>
<script language="JavaScript">
function hide_and_show_table1()
{
if(document.all.t1.style.display=="none")
{
document.all.t0.style.display="";
document.all.t1.style.display="";
document.all.t2.style.display="";
document.all.t3.style.display="";
document.all.t4.style.display="";
document.all.flag1.value="Hide";
}
else
{
document.all.t0.style.display="none";
document.all.t1.style.display="none";
document.all.t2.style.display="none";
document.all.t3.style.display="none";
document.all.t4.style.display="none";
document.all.flag1.value="Show";
}
}
function hide_and_show_table2()
{
if(document.all.t5.style.display=="none")
{
document.all.t5.style.display="";
document.all.t6.style.display="";
document.all.t7.style.display="";
document.all.flag2.value="Hide";
}
else
{
document.all.t5.style.display="none";
document.all.t6.style.display="none";
document.all.t7.style.display="none";
document.all.flag2.value="Show";
}
}
function hide_and_show_table3()
{
if(document.all.t8.style.display=="none")
{
document.all.t8.style.display="";
document.all.t9.style.display="";
document.all.t10.style.display="";
document.all.t11.style.display="";
document.all.t12.style.display="";
document.all.flag3.value="Hide";
}
else
{
document.all.t8.style.display="none";
document.all.t9.style.display="none";
document.all.t10.style.display="none";
document.all.t11.style.display="none";
document.all.t12.style.display="none";
document.all.flag3.value="Show";
}
}
</script>
<?php
//============scroll the page====================
if($scroll_y > 0){
//echo "<body style=\"overflow-x:hidden\" topmargin=\"5\" leftmargin=\"12\" onLoad='self.scrollBy(0,$scroll_y)'>";
echo "<body leftmargin=\"15\" rightmargin=\"10\" onload=\"javascript:scroll_div('$scroll_y');javascript:adjust_frame('down');\" onresize=\"javascript:adjust_frame('down');\" style=\"overflow:hidden;overflow-x:hidden;overflow-y:hidden;\">";
}else{
echo "<body leftmargin=\"15\" rightmargin=\"10\" onload=\"javascript:adjust_frame('down');\" onresize=\"javascript:adjust_frame('down');\" style=\"overflow:hidden;overflow-x:hidden;overflow-y:hidden;\">";
}
adjust_head_frame("down");
adjust_title_head_frame("down");
adjust_title_tail_frame("down");
adjust_content_head_frame("down");
echo "<br>";
//=====================================================================================|
//============================Function Flag============================================|
//=====================================================================================|
$Hide_Show_Function_On=0;
$DEBUG=0;
//=====================================================================================|
//============================Data From Index Page=====================================|
//=====================================================================================|
if(0)
{
$url_temp=$_SERVER["REQUEST_URI"];
echo "This page URL:$url_temp<br>";
echo "sel_date_from:$sel_date_from<br>";
echo "sel_date_to:$sel_date_to<br>";
}
//=====================================================================================|
//============================Define The Data==========================================|
//=====================================================================================|
//data define
for($i=0;$i<6;$i++)
{
for($j=0;$j<22;$j++)
{
/* 0 attempt
0 call mo 1 success
1 call mt 2 duration
2 sm mo 3 lu_normal
3 sm mt 4 lu_resNotOk
4 lu 5 lu_serNotOk
6 lu_serNoImp
7 lu_msgError
8 lu_proError
9 cc_normal
10 cc_callDeny
11 cc_netBusy
12 cc_callerClear
13 cc_subBusy
14 cc_noAnswer
15 cc_sigError
16 sm_normal
17 sm_errSub
18 sm_serNotOk
19 sm_netBusy
20 sm_msgError
21 sm_proError
22 sm_resNotOk
*/
$service_csta[$i][$j]=0;
}
}
//===================================================================================|
//========================Get The Data From DB=======================================|
//===================================================================================|
$db=$csta_db;
$bgn_time=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-$sel_date_from,date("Y")));
$end_time=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-$sel_date_to,date("Y")));
//get the numbers of days that selected
$slot=$sel_date_from-$sel_date_to+1;
if(0)
{
echo "bgn_time:$bgn_time<br>";
echo "end_time:$end_time<br>";
echo "slot:$slot<br>";
echo "db:$csta_db<br>";
}
$detailTableFields=array("Attempt",
"Success",
"Duration",
"lu_normal",
"lu_res_not_ok",
"lu_ser_not_ok",
"lu_ser_no_imp",
"lu_msg_error",
"lu_pro_error",
"cc_normal",
"cc_call_deny",
"cc_net_busy",
"cc_caller_clear",
"cc_sub_busy",
"cc_no_answer",
"cc_sig_error",
"sm_normal",
"sm_error_sub",
"sm_ser_not_ok",
"sm_net_busy",
"sm_msg_error",
"sm_pro_error",
"sm_res_not_ok"
);
$detailTableFieldsSql="";
for($i=0;$i<sizeof($detailTableFields);$i++)
{
$detailTableFieldsSql.="sum(".$detailTableFields[$i].") as ".$detailTableFields[$i];
if($i<sizeof($detailTableFields)-1)
$detailTableFieldsSql.=",";
}
//echo "$detailTableFieldsSql<br>";
$key_type_relation=array(5=>0,6=>1,7=>2,8=>3,9=>4,10=>5,11=>6,12=>7,13=>8,14=>9,15=>10,16=>11);
for($day=0;$day<$slot;$day++)
{
$table_name="ipalimSum";
$temp=date("d",mktime(0,0,0,date("m"),date("d")-$sel_date_from+$day,date("Y")));
$table_name=$table_name."_".$temp;
//echo "table_name:$table_name<br>";
$from_time=date("Y-m-d H:i:s",mktime(0,0,0,date("m"),date("d")-$sel_date_from+$day,date("Y")));
$to_time=date("Y-m-d H:i:s",mktime(23,0,0,date("m"),date("d")-$sel_date_from+$day,date("Y")));
//echo "from:$from_time--to:$to_time<br>";
$select="select key_type,".$detailTableFieldsSql." ";
$from="from $table_name ";
$service_where="and key_type>0 and key_type<6 ";
$where="where csta_datetime >='$from_time' and csta_datetime <'$to_time' ".$service_where;
$group="group by key_type ";
$order="order by key_type ";
$sql=$select.$from.$where.$group.$order;
//echo "$sql<br>";
$result=@mysqli_query($pubConn,$sql);
$rows=@mysqli_fetch_array($result);
if(!$rows)
continue;
do{
$key_type=$rows[key_type]+0;
for($tt=0;$tt<23;$tt++)
{
$service_csta[$key_type][$tt]+=$rows[$tt+1];
//echo "type-$key_type-$tt:{$service_csta[$key_type][$tt]}<br>";
}
}while($rows=mysqli_fetch_array($result));
}
//get the 0-hour of the day
for($day=0;$day<$slot;$day++)
{
$table_name="ipalimSum";
$temp=date("d",mktime(0,0,0,date("m"),date("d")-$sel_date_from+$day-1,date("Y")));
$table_name=$table_name."_".$temp;
//echo "table_name:$table_name<br>";
$from_time=date("Y-m-d H:i:s",mktime(23,0,0,date("m"),date("d")-$sel_date_from+$day-1,date("Y")));
$to_time=date("Y-m-d H:i:s",mktime(0,0,0,date("m"),date("d")-$sel_date_from+$day,date("Y")));
//echo "from:$from_time--to:$to_time<br>";
$select="select key_type,".$detailTableFieldsSql." ";
$from="from $table_name ";
$service_where="and key_type>0 and key_type<6 ";
$where="where csta_datetime >='$from_time' and csta_datetime <'$to_time' ".$service_where;
$group="group by key_type ";
$order="order by key_type ";
$sql=$select.$from.$where.$group.$order;
//echo "$sql<br>";
$result=@mysqli_query($pubConn,$sql);
$rows=@mysqli_fetch_array($result);
if(!$rows)
continue;
do{
$key_type=$rows[key_type]+0;
for($tt=0;$tt<22;$tt++)
{
$service_csta[$key_type][$tt]+=$rows[$tt+1];
//echo "type-$service_type-$tt:{$service_csta[$service_type][$tt]}<br>";
}
}while($rows=mysqli_fetch_array($result));
}
//===================================================================================|
//=======================Show The Table-1============================================|
//===================================================================================|
//===table lu
if($slot==1)
$table_title="Service statistic Date:".$bgn_time;
else
$table_title="Service statistic Date:".$bgn_time." to ".$end_time;
echo "<center><b>$table_title</b></center>";
echo "<table border=\"1\" width=\"100%\" cellpadding=\"2\" cellspacing=\"0\" bordercolor=\"#666666\" bordercolordark=\"#FFFFFF\" bgcolor=\"#FFFFFF\">";
echo "<tr bgcolor=\"#E6E6E6\">";
echo "<td align=\"center\" width=\"13%\">Type</td>";
echo "<td align=\"center\" width=\"8%\">Attempt</td>";
echo "<td align=\"center\" width=\"8%\">Success</td>";
echo "<td align=\"center\" width=\"8%\">Normal</td>";
echo "<td align=\"center\" width=\"8%\">No Resource</td>";
echo "<td align=\"center\" width=\"8%\">No Service</td>";
echo "<td align=\"center\" width=\"8%\">Invalid Service</td>";
echo "<td align=\"center\" width=\"8%\">Invalid Message</td>";
echo "<td align=\"center\" width=\"10%\">Signal Error</td>";
echo "<td align=\"center\" width=\"8%\">Duration</td>";
echo "<td align=\"center\" width=\"8%\">Average Duration</td>";
echo "</tr>";
$service_type_label=array(1=>"LU");
$type_map=array(0=>0,1=>1,2=>3,3=>4,4=>5,5=>6,6=>7,7=>8,8=>2);
//========show subs to subs,subs to local,subs to toll,trunk to subs,trunk to trunk==========
for($i=1;$i<2;$i++)
{
echo "<tr id=\"t$i\">";
echo "<td align=\"center\"><a target=\"_parent\" href=\"../../performance/ipalimCsta/service_detail_index.php?on_top_index=0&service_type=$i&sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">$service_type_label[$i]</a></td>";
for($j=0;$j<sizeof($type_map);$j++)
{
$m_j=$type_map[$j];
echo "<td align=\"center\">";
if($j==8)
{
echo "{$service_csta[$i][$m_j]}(s)";
$hour=floor($service_csta[$i][$m_j]/3600);
$minute=floor($service_csta[$i][$m_j]%3600/60);
$second=$service_csta[$i][$m_j]%60;
if($hour==0&&$minute==0&&$second==0)
echo "<br>";
else
echo "<br>$hour:$minute:$second";
}
else
{
echo "{$service_csta[$i][$m_j]}";
}
if($j != 0&&$j != 8)
{
if($service_csta[$i][0]==0)
$rate=0;
else
{
$rate=$service_csta[$i][$m_j]/$service_csta[$i][0];
$rate=$rate*100;
if($rate!=0&&$rate!=100)
$rate=number_format($rate, 2, '.', '');
}
echo "<br>$rate%";
}
echo "</td>";
}
echo "<td align=\"center\">";
if($service_csta[$i][1]!=0)
$ave=round($service_csta[$i][2]/$service_csta[$i][1]);
else
$ave=0;
echo "$ave";
echo "</td>";
echo "</tr>";
}
echo "</table>";
//mo mt
if($slot==1)
$table_title="Service statistic Date:".$bgn_time;
else
$table_title="Service statistic Date:".$bgn_time." to ".$end_time;
//echo "<center><b>$table_title</b></center>";
echo "<p><table border=\"1\" width=\"100%\" cellpadding=\"2\" cellspacing=\"0\" bordercolor=\"#666666\" bordercolordark=\"#FFFFFF\" bgcolor=\"#FFFFFF\">";
echo "<tr bgcolor=\"#E6E6E6\">";
echo "<td align=\"center\" width=\"13%\">Type</td>";
echo "<td align=\"center\" width=\"8%\">Attempt</td>";
echo "<td align=\"center\" width=\"8%\">Success</td>";
echo "<td align=\"center\" width=\"8%\">Normal</td>";
echo "<td align=\"center\" width=\"8%\">Call Deny</td>";
echo "<td align=\"center\" width=\"8%\">Net Busy</td>";
echo "<td align=\"center\" width=\"8%\">Caller Clear</td>";
echo "<td align=\"center\" width=\"8%\">Sub Busy</td>";
echo "<td align=\"center\" width=\"10%\">No Answer</td>";
echo "<td align=\"center\" width=\"10%\">Signal Error</td>";
echo "<td align=\"center\" width=\"8%\">Duration</td>";
echo "<td align=\"center\" width=\"8%\">Average Duration</td>";
echo "</tr>";
$service_type_label=array(2=>"Call MO",3=>"Call MT");
$type_map=array(0=>0,1=>1,2=>9,3=>10,4=>11,5=>12,6=>13,7=>14,8=>15,9=>2);
//========show subs to subs,subs to local,subs to toll,trunk to subs,trunk to trunk==========
for($i=2;$i<4;$i++)
{
echo "<tr id=\"t$i\">";
echo "<td align=\"center\"><a target=\"_parent\" href=\"../../performance/ipalimCsta/service_detail_index.php?on_top_index=0&service_type=$i&sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">$service_type_label[$i]</a></td>";
for($j=0;$j<sizeof($type_map);$j++)
{
$m_j=$type_map[$j];
echo "<td align=\"center\">";
if($j==9)
{
echo "{$service_csta[$i][$m_j]}(s)";
$hour=floor($service_csta[$i][$m_j]/3600);
$minute=floor($service_csta[$i][$m_j]%3600/60);
$second=$service_csta[$i][$m_j]%60;
if($hour==0&&$minute==0&&$second==0)
echo "<br>";
else
echo "<br>$hour:$minute:$second";
}
else
{
echo "{$service_csta[$i][$m_j]}";
}
if($j != 0&&$j != 9)
{
if($service_csta[$i][0]==0)
$rate=0;
else
{
$rate=$service_csta[$i][$m_j]/$service_csta[$i][0];
$rate=$rate*100;
if($rate!=0&&$rate!=100)
$rate=number_format($rate, 2, '.', '');
}
echo "<br>$rate%";
}
echo "</td>";
}
echo "<td align=\"center\">";
if($service_csta[$i][1]!=0)
$ave=round($service_csta[$i][2]/$service_csta[$i][1]);
else
$ave=0;
echo "$ave";
echo "</td>";
echo "</tr>";
}
echo "</table>";
//smo smt
if($slot==1)
$table_title="Service statistic Date:".$bgn_time;
else
$table_title="Service statistic Date:".$bgn_time." to ".$end_time;
//echo "<center><b>$table_title</b></center>";
echo "<p><table border=\"1\" width=\"100%\" cellpadding=\"2\" cellspacing=\"0\" bordercolor=\"#666666\" bordercolordark=\"#FFFFFF\" bgcolor=\"#FFFFFF\">";
echo "<tr bgcolor=\"#E6E6E6\">";
echo "<td align=\"center\" width=\"13%\">Type</td>";
echo "<td align=\"center\" width=\"8%\">Attempt</td>";
echo "<td align=\"center\" width=\"8%\">Success</td>";
echo "<td align=\"center\" width=\"8%\">Normal</td>";
echo "<td align=\"center\" width=\"8%\">Sub Error</td>";
echo "<td align=\"center\" width=\"8%\">No Service</td>";
echo "<td align=\"center\" width=\"8%\">Net Busy</td>";
echo "<td align=\"center\" width=\"8%\">Message Error</td>";
echo "<td align=\"center\" width=\"10%\">Signal Error</td>";
echo "<td align=\"center\" width=\"10%\">No Resource</td>";
echo "<td align=\"center\" width=\"8%\">Duration</td>";
echo "<td align=\"center\" width=\"8%\">Average Duration</td>";
echo "</tr>";
$service_type_label=array(4=>"SM MO",5=>"SM MT");
$type_map=array(0=>0,1=>1,2=>16,3=>17,4=>18,5=>19,6=>20,7=>21,8=>22,9=>2);
//========show subs to subs,subs to local,subs to toll,trunk to subs,trunk to trunk==========
for($i=4;$i<6;$i++)
{
echo "<tr id=\"t$i\">";
echo "<td align=\"center\"><a target=\"_parent\" href=\"../../performance/ipalimCsta/service_detail_index.php?on_top_index=0&service_type=$i&sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">$service_type_label[$i]</a></td>";
for($j=0;$j<sizeof($type_map);$j++)
{
$m_j=$type_map[$j];
echo "<td align=\"center\">";
if($j==9)
{
echo "{$service_csta[$i][$m_j]}(s)";
$hour=floor($service_csta[$i][$m_j]/3600);
$minute=floor($service_csta[$i][$m_j]%3600/60);
$second=$service_csta[$i][$m_j]%60;
if($hour==0&&$minute==0&&$second==0)
echo "<br>";
else
echo "<br>$hour:$minute:$second";
}
else
{
echo "{$service_csta[$i][$m_j]}";
}
if($j != 0&&$j != 9)
{
if($service_csta[$i][0]==0)
$rate=0;
else
{
$rate=$service_csta[$i][$m_j]/$service_csta[$i][0];
$rate=$rate*100;
if($rate!=0&&$rate!=100)
$rate=number_format($rate, 2, '.', '');
}
echo "<br>$rate%";
}
echo "</td>";
}
echo "<td align=\"center\">";
if($service_csta[$i][1]!=0)
$ave=round($service_csta[$i][2]/$service_csta[$i][1]);
else
$ave=0;
echo "$ave";
echo "</td>";
echo "</tr>";
}
echo "</table>";
//=====================================================================================|
//=======================Draw The Graphics-1===========================================|
//=====================================================================================|
echo "<p><b>2.Service(Attempt)</b><br>";
//=====graphics size=======
$sizex=500;
$sizey=250;
$im = ImageCreate ($sizex, $sizey);
$background_color=ImageColorAllocate($im,255,255,255);
$black_color=ImageColorAllocate($im,0,0,0);
$white_color= imagecolorallocate($im, 255, 255, 255);
$bgcolor=F8F8F8;
$fgcolor=000000;
$background_color = ImageColorAllocate ($im,
hexdec(substr($bgcolor, 0, 2)),
hexdec(substr($bgcolor, 2, 2)),
hexdec(substr($bgcolor, 4, 2)));
$text_color = ImageColorAllocate ($im,
hexdec(substr($fgcolor, 0, 2)),
hexdec(substr($fgcolor, 2, 2)),
hexdec(substr($fgcolor, 4, 2)));
//====graphics background=======
ImageFilledRectangle($im,0,0,$sizex,$sizey,ImageColorAllocate ($im, 198, 198, 198));
ImageFilledRectangle($im,2,2,$sizex,$sizey,ImageColorAllocate ($im, 130, 130, 130));
$pointArr=array(0,$sizey-1,3,$sizey-4,4,$sizey-1);
Imagefilledpolygon($im, $pointArr, 3, ImageColorAllocate ($im, 130, 130, 130));
$pointArr=array($sizex-1,0,$sizex-4,3,$sizex,4);
Imagefilledpolygon($im, $pointArr, 3, ImageColorAllocate ($im, 130, 130, 130));
ImageFilledRectangle($im,2,2,$sizex-3,$sizey-3,$background_color);
imagedashedline($im,30,30,100,100,$black_color);
//======draw the horizonal line========
$style = array($black_color,$black_color,$black_color,$black_color,$black_color,$white_color,$white_color,$white_color,$white_color,$white_color);
imagesetstyle($im, $style);
for($i=10;$i>0;$i--)
{
$x1=40;
$y1=20+(10-$i)*18;
$x2=447;
$y2=$y1;
if($i!=10)
{
imageline($im, $x1,$y1,$x2,$y2, IMG_COLOR_STYLED);
}
imagestring($im,2,$x1-22,$y2-5,($i*10)."%",$black_color);
}
//=======draw the vitical line=======
$u=floor(750/20);
for($i=0;$i<12;$i++)
{
$x1=40+$i*$u;
$y1=20;
$x2=$x1;
$y2=200;
ImageDashedLine($im,$x1,$y1,$x2,$y2,$black_color);
}
//=======get colors============
$color[0]=ImageColorAllocate($im,0x99,0x00,0x33);
$color[1]=ImageColorAllocate($im,0x99,0x00,0xcc);
$color[2]=ImageColorAllocate($im,0x99,0x99,0x00);
$color[3]=ImageColorAllocate($im,0x99,0xcc,0x99);
$color[4]=ImageColorAllocate($im,0x99,0xff,0x33);
$color[5]=ImageColorAllocate($im,0xff,0x99,0x66);
$color[6]=ImageColorAllocate($im,0xff,0x99,0xff);
$color[7]=ImageColorAllocate($im,0xff,0xff,0x00);
$color[8]=ImageColorAllocate($im,0x33,0x3,0x33);
$color[9]=ImageColorAllocate($im,0x00,0xcc,0xff);
$color[10]=ImageColorAllocate($im,0x00,0x66,0xcc);
$color[11]=ImageColorAllocate($im,0x33,0xff,0x99);
//=====get the precent and block height(Part-1)======
$attempt_sum_one=0;
for($i=0;$i<6;$i++)
{
$attempt_sum_one+=$service_csta[$i][0];
}
if($attempt_sum_one==0)
{
//lu precent
$lu_attempt_precent="0%";
//mo precent
$mo_attempt_precent="0%";
//mt precent
$mt_attempt_precent="0%";
//smo precent
$smo_attempt_precent="0%";
//smt precent
$smt_attempt_precent="0%";
for($t=0;$t<5;$t++)
$height[$t]=0;
}
else
{
//lu precent
$lu_attempt_precent=number_format($service_csta[1][0]*100/$attempt_sum_one,2,'.','')."%";
//mo precent
$mo_attempt_precent=number_format($service_csta[2][0]*100/$attempt_sum_one,2,'.','')."%";
//mt precent
$mt_attempt_precent=number_format($service_csta[3][0]*100/$attempt_sum_one,2,'.','')."%";
//smo precent
$smo_attempt_precent=number_format($service_csta[4][0]*100/$attempt_sum_one,2,'.','')."%";
//interconnection precent
$smt_attempt_precent=number_format($service_csta[5][0]*100/$attempt_sum_one,2,'.','')."%";
for($t=1;$t<6;$t++)
{
$height[$t-1]=floor(180*$service_csta[$t][0]/$attempt_sum_one);
}
}
//======draw the data block======
for($i=0;$i<5;$i++)
{
$x1=40+(2*$i+1)*$u;
if($height[$i]==0)
$height[$i]=1;
$y1=200-$height[$i];
$x2=40+(2*$i+2)*$u;
$y2=199;
imagefilledrectangle($im,$x1,$y1,$x2,$y2,$color[$i]);
}
//======draw the legend string=======
imagestring($im,2,90,205,"LU",$black_color);
imagestring($im,2,70,220,"(".$lu_attempt_precent.")",$black_color);
imagestring($im,2,150,205,"Call MO",$black_color);
imagestring($im,2,148,220,"(".$mo_attempt_precent.")",$black_color);
imagestring($im,2,225,205,"Call MT",$black_color);
imagestring($im,2,225,220,"(".$mt_attempt_precent.")",$black_color);
imagestring($im,2,305,205,"SM MO",$black_color);
imagestring($im,2,300,221,"(".$smo_attempt_precent.")",$black_color);
imagestring($im,2,380,205,"SM MT",$black_color);
imagestring($im,2,375,221,"(".$smt_attempt_precent.")",$black_color);
//draw the outline
imageLine($im,40,20,40,200,$black_color);
imageLine($im,40,20,447,20,$black_color);
imageLine($im,447,200,447,20,$black_color);
imageLine($im,40,200,447,200,$black_color);
//======show the service attempt graphics==========
//-----<2D><><EFBFBD><EFBFBD>ͼ<EFBFBD><CDBC><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>޸<EFBFBD>
//delete *.png
$handle=opendir('.');
while($file=readdir($handle)){
$retval="";
$pt=strrpos($file,".");
if($pt) $retval=substr($file,$pt+1,strlen($file)-$pt);
if($retval=='png') unlink($file);
}
$filename="ser3_".time().".png";
if(1){
ImagePng ($im,"$filename");
ImageDestroy($im);
}
//-----<2D><>ʾͼƬ
echo "<img src=\"$filename\"></img>";
//=====================================================================================|
//========================Draw The Graphics-2==========================================|
//=====================================================================================|
//=======draw the Success failure graphics==========
/*
echo "<p><b>3.Success/Failure<br>";
$sizex=500;
$sizey=250;
$image=imagecreate($sizex,$sizey);
$bgcolor=imagecolorallocate($image,255,255,255);
$black_color=ImageColorAllocate($image,0,0,0);
$bgcolor=F8F8F8;
$fgcolor=000000;
$background_color = ImageColorAllocate ($image,
hexdec(substr($bgcolor, 0, 2)),
hexdec(substr($bgcolor, 2, 2)),
hexdec(substr($bgcolor, 4, 2)));
$text_color = ImageColorAllocate ($image,
hexdec(substr($fgcolor, 0, 2)),
hexdec(substr($fgcolor, 2, 2)),
hexdec(substr($fgcolor, 4, 2)));
//=====background========
ImageFilledRectangle($image,0,0,$sizex,$sizey,ImageColorAllocate ($image, 198, 198, 198));
ImageFilledRectangle($image,2,2,$sizex,$sizey,ImageColorAllocate ($image, 130, 130, 130));
$pointArr=array(0,$sizey-1,3,$sizey-4,4,$sizey-1);
Imagefilledpolygon($image, $pointArr, 3, ImageColorAllocate ($image, 130, 130, 130));
$pointArr=array($sizex-1,0,$sizex-4,3,$sizex,4);
Imagefilledpolygon($image, $pointArr, 3, ImageColorAllocate ($image, 130, 130, 130));
ImageFilledRectangle($image,2,2,$sizex-3,$sizey-3,$background_color);
//first
imageLine($image,40,20,40,200,$black_color);
imageLine($image,40,20,450,20,$black_color);
imageLine($image,450,200,450,20,$black_color);
imageLine($image,40,200,450,200,$black_color);
//======show the answer failure graphics=====
$tt=time()-2500;
$file_name="ser4_".$tt.".png";
imagepng($image,$file_name);
imagedestroy($image);
echo "<img src=$file_name></img>";
*/
adjust_content_tail("down");
?>
</body>

View File

@@ -0,0 +1,23 @@
<?php
/*
File Name: service_general_index.php
Description: show the general service page main frame
Author: JianHui Zheng
*/
?>
<?php
//==============initial the data=======================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
?>
<frameset rows="75,*" frameborder=0 border=0>
<?php
echo "<frame scrolling=\"no\" name=\"service_general_up\" src=\"service_general_up.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">";
echo "<frame name=\"service_general_down\" src=\"service_general_down.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to\">";
?>
</frameset>

View File

@@ -0,0 +1,95 @@
<?php
//Include the head file
require("../../inc/header.inc");
?>
<script language="JavaScript">
//the function is called when the sel_date_from value changed
function sel_date_from_change()
{
var down_date_from=document.myform.sel_date_from.value;
var down_date_to=document.myform.sel_date_to.value;
//var scrollY=document.body.scrollTop;
if(down_date_from<=down_date_to)
down_date_to=down_date_from;
//var urll='<?php echo"$PHP_SELF";?>?sel_date_from='+down_date_from+'&sel_date_to='+down_date_to+'&scroll_y='+scrollY;
var urll='<?php echo"$PHP_SELF";?>?sel_date_from='+down_date_from+'&sel_date_to='+down_date_to;
window.location.href=urll;
}
</script>
<base target="service_general_down">
<body leftmargin="15" rightmargin="10" onload="javascript:adjust_frame('up');" onresize="javascript:adjust_frame('up');" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;">
<form action="service_general_down.php" method="post" name="myform">
<?php
adjust_head_frame("up");
adjust_title_head_frame("up");
echo "<table id=\"table_up\" border=0 width=\"100%\">";
echo "<tr>";
echo "<td width=50% align=\"left\">";
echo "$strTitlePerformance > iPALIM > $strService";
echo "</td>";
echo "<td align=\"right\">";
$helpId="3.11.1";
showHelp($helpId);
echo "</td>";
echo "</tr>";
echo "<tr>";
echo "<td width=50% align=\"left\">";
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
//selection date define
$day0=date("Y-m-d",mktime(0,0,0,date("m"),date("d"),date("Y")));
$day1=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-1,date("Y")));
$day2=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-2,date("Y")));
$day3=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-3,date("Y")));
$day4=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-4,date("Y")));
$day5=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-5,date("Y")));
$day6=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-6,date("Y")));
?>
<select name="sel_date_from" onChange="javascript:sel_date_from_change()">
<?php
for($i=0;$i<7;$i++)
{
if($i==$sel_date_from)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>to
<select name="sel_date_to">
<?php
for($i=0;$i<=$sel_date_from;$i++)
{
if($i==$sel_date_to)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>
<span onClick="javascript:myform.submit()" style="cursor:hand">
<IMG align=absBottom border=0 src="../../images/search.gif" ><?php echo "$strSearch"; ?>
</span>
<?php
echo "</td>";
echo "<td align=\"right\">";
?>
<span onClick="window.print();" style="cursor:hand">
<img align=absBottom border=0 src="../../images/printer.gif" width="16" height="16">
</span>
<?php
echo "</td>";
echo "</tr>";
echo "</table>";
adjust_title_tail_frame("up");
adjust_content_head_frame("up");
adjust_content_tail_frame("up");
?>
</form>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,32 @@
<?php
//==============initial the data=======================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($sel_in_out))
$sel_in_out=0;
if(!isset($trunk_no))
$trunk_no=0;
if(!isset($from_hour))
$from_hour="00";
if(!isset($from_minute))
$from_minute="00";
if(!isset($from_second))
$from_second="00";
if(!isset($to_hour))
$to_hour="23";
if(!isset($to_minute))
$to_minute="59";
if(!isset($to_second))
$to_second="59";
if(!isset($element_title))
$element_title="<EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
?>
<frameset rows="75,*" frameborder=0 border=0>
<?php
echo "<frame scrolling=\"no\" name=\"trunk_detail_up\" src=\"trunk_detail_up.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to&sel_in_out=$sel_in_out&trunk_no=$trunk_no&element_title=$element_title\">";
echo "<frame name=\"trunk_detail_down\" src=\"trunk_detail_down.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to&trunk_no=$trunk_no&sel_in_out=$sel_in_out&on_top_index=0&element_title=$element_title\">";
?>
</frameset>

View File

@@ -0,0 +1,141 @@
<?php
//Include the head file
require("../../inc/header.inc");
?>
<base target="trunk_detail_down">
<script language="JavaScript">
function page_refresh()
{
//sel_date_from,sel_date_to,scroll_y,on_top_index
var down_date_from=document.myform.sel_date_from.value;
var down_date_to=document.myform.sel_date_to.value;
var trunkno=document.myform.trunk_no.value;
var in_out=document.myform.sel_in_out.value;
var on_top=parent.trunk_detail_down.document.myform.on_top_index.value;
var scrolly=document.getElementById('content_down').scrollTop;
if(down_date_from<=down_date_to)
down_date_to=down_date_from;
var urll='<?php echo"$PHP_SELF";?>?sel_date_from='+down_date_from+'&sel_date_to='+down_date_to+'&trunk_no='+trunkno+"&on_top_index="+on_top+"&scroll_y="+scrolly+"&sel_in_out="+in_out;
window.location.href=urll;
}
</script>
<body leftmargin="15" rightmargin="10" onload="javascript:adjust_frame('up');" onresize="javascript:adjust_frame('up');" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;">
<form name="myform" action="trunk_detail_down.php" method="post">
<?php
adjust_head_frame("up");
adjust_title_head_frame("up");
//=================================test=======================================
//echo "trunk_no:$trunk_no<br>";
//echo "sel_date_from:$sel_date_from<br>";
//echo "sel_date_to:$sel_date_to<br>";
//echo "in_out:$sel_in_out<br>";
//==================get the parameter the previous transfer====================
$old_sel_date_from=$sel_date_from;
$old_sel_date_to=$sel_date_to;
$old_sel_in_out=$sel_in_out;
//===========================page title========================================
echo "<table id=\"table_up\" border=0 width=\"100%\">";
echo "<tr>";
echo "<td width=\"50%\" align=\"left\">";
echo "$strTitlePerformance > iPALIM > Trunk group";
echo "</td>";
echo "<td align=\"right\">";
$helpId = "3.11.2";
showHelp($helpId);
echo "</td>";
echo "</tr>";
echo "<tr>";
echo "<td align=\"left\">";
//=======================data initial==========================================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($trunk_no))
$trunk_no=0;
if(!isset($sel_in_out))
$sel_in_out=0;
if(!isset($on_top_index))
$on_top_index=0;
//selection date define
$day0=date("Y-m-d",mktime(0,0,0,date("m"),date("d"),date("Y")));
$day1=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-1,date("Y")));
$day2=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-2,date("Y")));
$day3=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-3,date("Y")));
$day4=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-4,date("Y")));
$day5=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-5,date("Y")));
$day6=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-6,date("Y")));
echo "<input type=\"hidden\" name=\"trunk_no\" value=$trunk_no>";
?>
<select name="sel_in_out" onChange="javascript:page_refresh()">
<?php
$in_out_string=array("LU","Call MO","Call MT","SM MO","SM MT");
for($i=0;$i<sizeof($in_out_string);$i++)
{
if($i==$sel_in_out)
echo "<option selected value=$i>$in_out_string[$i]</option>";
else
echo "<option value=$i>$in_out_string[$i]</option>";
}
?>
</select>
<select name="sel_date_from" onChange="javascript:page_refresh()">
<?php
for($i=0;$i<7;$i++)
{
if($i==$sel_date_from)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>to
<select name="sel_date_to">
<?php
for($i=0;$i<=$sel_date_from;$i++)
{
if($i==$sel_date_to)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>
<span onClick="javascript:myform.submit()" style="cursor:hand">
<IMG align=absBottom border=0 src="../../images/search.gif" ><?php echo "$strSearch"; ?>
</span>
<?php
echo "</td>";
echo "<td align=\"right\">";
//===================the back link button======================================
echo "<span style=\"cursor:hand;\">";
echo "<a target=\"_parent\" href=\"../../performance/ipalimCsta/trunk_general_index.php?sel_date_from=$old_sel_date_from&sel_date_to=$old_sel_date_to&sel_in_out=$old_sel_in_out\"><img src=\"../../images/left.gif\" border=0></img>back</a>";
echo "</span>";
?>
<span onClick="window.print();" style="cursor:hand">
<img align=absBottom border=0 src="../../images/printer.gif" width="16" height="16">
</span>
<?php
echo "</td>";
echo "</tr>";
echo "</table>";
adjust_title_tail_frame("up");
adjust_content_head_frame("up");
adjust_content_tail_frame("up");
?>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,28 @@
<?php
//==============initial the data=======================
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($sel_in_out))
$sel_in_out=0;
if(!isset($from_hour))
$from_hour="00";
if(!isset($from_minute))
$from_minute="00";
if(!isset($from_second))
$from_second="00";
if(!isset($to_hour))
$to_hour="23";
if(!isset($to_minute))
$to_minute="59";
if(!isset($to_second))
$to_second="59";
?>
<frameset rows="75,*" frameborder=0 border=0>
<?php
echo "<frame scrolling=\"no\" name=\"trunk_general_up\" src=\"trunk_general_up.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to&sel_in_out=$sel_in_out&from_hour=$from_hour&from_minute=$from_minute&from_second=$from_second&to_hour=$to_hour&to_minute=$to_minute&to_second=$to_second\">";
echo "<frame name=\"trunk_general_down\" src=\"trunk_general_down.php?sel_date_from=$sel_date_from&sel_date_to=$sel_date_to&sel_in_out=$sel_in_out&from_hour=$from_hour&from_minute=$from_minute&from_second=$from_second&to_hour=$to_hour&to_minute=$to_minute&to_second=$to_second\">";
?>
</frameset>

View File

@@ -0,0 +1,177 @@
<?php
//Include the head file
require("../../inc/header.inc");
?>
<base target="trunk_general_down">
<script language="JavaScript">
//the function is called when the page is refresh
function page_refresh()
{
//in&out,fromdate,todate,fromhour,fromminute,fromsecond,tohour,tominute,tosecond
var down_date_from=document.myform.sel_date_from.value;
var down_date_to=document.myform.sel_date_to.value;
var in_out=document.myform.sel_in_out.value;
var scrollY=document.getElementById('content_down').scrollTop;
var from_h=document.myform.from_hour.value;
var from_m=document.myform.from_minute.value;
var from_s=document.myform.from_second.value;
var to_h=document.myform.to_hour.value;
var to_m=document.myform.to_minute.value;
var to_s=document.myform.to_second.value;
var secondsFrom=from_h*3600+from_m*60+from_s;
var secondsTo=to_h*3600+to_m*60+to_s;
if(secondsFrom>secondsTo)
alert("Time error");
else
{
if(down_date_from<=down_date_to)
down_date_to=down_date_from;
var ur="&from_hour="+from_h+"&from_minute="+from_m+"&from_second="+from_s;
ur=ur+"&to_hour="+to_h+"&to_minute="+to_m+"&to_second="+to_s+"&sel_in_out="+in_out;
var urll='<?php echo"$PHP_SELF";?>?sel_date_from='+down_date_from+'&sel_date_to='+down_date_to+'&scroll_y='+scrollY+ur;
window.location.href=urll;
}
}
</script>
<body leftmargin="15" rightmargin="10" onload="javascript:adjust_frame('up');" onresize="javascript:adjust_frame('up');" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;">
<form action="trunk_general_down.php" method="post" name="myform">
<?php
adjust_head_frame("up");
adjust_title_head_frame("up");
echo "<table id=\"table_up\" border=0 width=\"100%\">";
echo "<tr>";
echo "<td width=\"50%\" align=\"left\">";
echo "$strTitlePerformance > iPALIM > Trunk group";
echo "</td>";
echo "<td align=\"right\">";
$helpId = "3.11.2";
showHelp($helpId);
echo "</td>";
echo "</tr>";
echo "<tr>";
echo "<td align=\"left\">";
if(!isset($scroll_y))
$scroll_y=0;
if(!isset($sel_date_from))
$sel_date_from=0;
if(!isset($sel_date_to))
$sel_date_to=0;
if(!isset($sel_in_out))
$sel_in_out=0;
if(!isset($from_hour))
$from_hour="00";
if(!isset($from_minute))
$from_minute="00";
if(!isset($from_second))
$from_second="00";
if(!isset($to_hour))
$to_hour="24";
if(!isset($to_minute))
$to_minute="00";
if(!isset($to_second))
$to_second="00";
//selection date define
$day0=date("Y-m-d",mktime(0,0,0,date("m"),date("d"),date("Y")));
$day1=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-1,date("Y")));
$day2=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-2,date("Y")));
$day3=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-3,date("Y")));
$day4=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-4,date("Y")));
$day5=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-5,date("Y")));
$day6=date("Y-m-d",mktime(0,0,0,date("m"),date("d")-6,date("Y")));
?>
<select name="sel_in_out" onChange="javascript:page_refresh()">
<?php
$in_out_string=array("LU","Call MO","Call MT","SM MO","SM MT");
for($i=0;$i<sizeof($in_out_string);$i++)
{
if($i==$sel_in_out)
echo "<option selected value=$i>$in_out_string[$i]</option>";
else
echo "<option value=$i>$in_out_string[$i]</option>";
}
?>
</select>
<select name="sel_date_from" onChange="javascript:page_refresh()">
<?php
for($i=0;$i<7;$i++)
{
if($i==$sel_date_from)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>to
<select name="sel_date_to" onChange="javascript:page_refresh()">
<?php
for($i=0;$i<=$sel_date_from;$i++)
{
if($i==$sel_date_to)
echo "<option selected value=$i>${day.$i}</option>";
else
echo "<option value=$i>${day.$i}</option>";
}
?>
</select>
<span onClick="javascript:myform.submit();" style="cursor:hand">
<img align=absBottom border=0 src="../../images/search.gif">Search
</span>
<?php
$slot=$sel_date_from-$sel_date_to+1;
//echo "slot:$slot<br>";
if($slot==1)
{
//===============================from_hour text=================================
echo "<input type=\"hidden\" name=\"from_hour\" value=$from_hour size=\"2\" maxLength=\"2\">";
//===============================from_minute text================================
echo "<input type=\"hidden\" name=\"from_minute\" value=$from_minute size=\"2\" maxLength=\"2\">";
//===============================from_second text================================
echo "<input type=\"hidden\" name=\"from_second\" value=$from_second size=\"2\" maxLength=\"2\">";
//===============================to_hour text=====================================
echo "<input type=\"hidden\" name=\"to_hour\" value=$to_hour size=\"2\" maxLength=\"2\">";
//===============================to_minute text===================================
echo "<input type=\"hidden\" name=\"to_minute\" value=$to_minute size=\"2\" maxLength=\"2\">";
//==============================to_second text====================================
echo "<input type=\"hidden\" name=\"to_second\" value=$to_second size=\"2\" maxLength=\"2\">";
}
else
{
//===============================from_hour hidden=================================
echo "<input type=\"hidden\" name=\"from_hour\" value=$from_hour>";
//===============================from_minute hidden================================
echo "<input type=\"hidden\" name=\"from_minute\" value=$from_minute>";
//===============================from_second hidden================================
echo "<input type=\"hidden\" name=\"from_second\" value=$from_second>";
//===============================to_hour hidden=====================================
echo "<input type=\"hidden\" name=\"to_hour\" value=$to_hour>";
//===============================to_minute hidden===================================
echo "<input type=\"hidden\" name=\"to_minute\" value=$to_minute>";
//==============================to_second hidden====================================
echo "<input type=\"hidden\" name=\"to_second\" value=$to_second>";
}
echo "</td>";
echo "<td align=\"right\">";
?>
<div onClick="window.print();" style="cursor:hand">
<img align=absBottom border=0 src="../../images/printer.gif" width="16" height="16">
</div>
<?php
echo "</td>";
echo "</tr>";
echo "</table>";
adjust_title_tail_frame("up");
adjust_content_head_frame("up");
adjust_content_tail_frame("up");
?>
</form>