124 lines
3.7 KiB
PHP
124 lines
3.7 KiB
PHP
<?php session_start();
|
||
?>
|
||
|
||
<!DOCTYPE html>
|
||
<html lang="pl">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||
<link rel="shortcut icon" href="../images/SoftSPM.ico">
|
||
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
|
||
<title>Bad SYNDIS to SoftSPM</title>
|
||
|
||
<!-- Bootstrap -->
|
||
<link href="bootstrap.min.css" rel="stylesheet">
|
||
|
||
</head>
|
||
<body>
|
||
|
||
<?php
|
||
date_default_timezone_set('Europe/Warsaw');
|
||
require_once("../func.php");
|
||
require_once("../dbaccess.php");
|
||
$polacz = mysql_connect($db_host, $db_user, $db_user_pass) or die ('cannot connect to db');
|
||
mysql_select_db($db_name);
|
||
mysql_query("SET NAMES utf8");
|
||
mysql_query("SET CHARACTER_SET utf8_general_ci");
|
||
?>
|
||
|
||
|
||
<div class="panel panel-danger">
|
||
<div class="panel-heading">
|
||
<h3 class="panel-title">Dane pobrane z SYNDIS wymagające analizy – studnie pracujące</h3>
|
||
</div>
|
||
<div class="panel-body">
|
||
Data odpytania SYNDIS:<b> <?php echo sqlStringValue("select max(SQD_AUDIT_CD) MAXDT from rep_soap_syndis_quality_data", "MAXDT"); ?></b>
|
||
</div>
|
||
<div class="panel-footer">
|
||
<a class="btn btn-default" href="#" role="button" onclick="window.print();">Drukuj</a>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
|
||
<table class="table table-bordered">
|
||
<thead>
|
||
<tr>
|
||
<th>Lp.</th>
|
||
<th>Studnia</th>
|
||
<th>Q</th>
|
||
<th>Flaga Q</th>
|
||
<th>P1</th>
|
||
<th>Flaga P1</th>
|
||
<th>P2</th>
|
||
<th>Flaga P2</th>
|
||
<th>I</th>
|
||
<th>Flaga I</th>
|
||
<th>U</th>
|
||
<th>Flaga U</th>
|
||
<th>cos(φ)</th>
|
||
<th>Flaga cos(φ)</th>
|
||
<th>PE</th>
|
||
<th>Flaga PE</th>
|
||
<th>PP</th>
|
||
<th>Flaga PP</th>
|
||
<th>HH</th>
|
||
<th>Flaga HH</th>
|
||
<th>HD</th>
|
||
<th>Flaga HD</th>
|
||
<th>Oddział</th>
|
||
</tr>
|
||
</thead>
|
||
|
||
<?php
|
||
unset($rep001Array);
|
||
$rep001Array = sqlGetResAsArray("select * from rep_soap_syndis_quality_data,seg_wells left join seg_dev_resources on (DRS_DEV_ID=WLL_ID and DRS_DEV_TYPE=12) where WLL_NAME=SQD_OBJECT_NAME and SQD_VAL_ONOFF=1 and (SQD_VAL_Q<=0 or SQD_FLG_Q<>'CORRECT' or (SQD_VAL_P2-1.5)>SQD_VAL_P1 or SQD_FLG_P1<>'CORRECT' or SQD_FLG_P2<>'CORRECT' or SQD_VAL_I<=0 or SQD_FLG_I<>'CORRECT' or SQD_VAL_U<=0 or SQD_FLG_U<>'CORRECT' or SQD_VAL_CF<=0 or SQD_FLG_CF<>'CORRECT' or SQD_VAL_PE<=0 or SQD_FLG_PE<>'CORRECT' or SQD_VAL_PP<=0 or SQD_FLG_PP<>'CORRECT' or SQD_VAL_HH<=0 or SQD_FLG_HH<>'CORRECT' or SQD_VAL_HD<=0 or SQD_FLG_HD<>'CORRECT')");
|
||
|
||
|
||
//print_r($rep001Array);
|
||
?>
|
||
|
||
<?php
|
||
for($i=0;$i<count($rep001Array);$i++)
|
||
{
|
||
echo"
|
||
<tr>
|
||
<td>".($i+1).".</td>
|
||
<td>".$rep001Array[$i]['SQD_OBJECT_NAME']."</td>
|
||
<td>".round($rep001Array[$i]['SQD_VAL_Q']/60,3)."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_Q']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_P1']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_P1']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_P2']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_P2']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_I']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_I']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_U']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_U']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_CF']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_CF']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_PE']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_PE']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_PP']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_PP']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_HH']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_HH']."</td>
|
||
<td>".$rep001Array[$i]['SQD_VAL_HD']."</td>
|
||
<td>".$rep001Array[$i]['SQD_FLG_HD']."</td>
|
||
<td>".$rep001Array[$i]['DRS_DEPARTMENT']."</td>
|
||
</tr>
|
||
";
|
||
}
|
||
?>
|
||
</table>
|
||
|
||
|
||
<?php
|
||
mysql_close($polacz);
|
||
|
||
?>
|
||
|
||
</body>
|
||
</html>
|