Files
2026-09-03 11:24:19 +02:00

55 lines
1.9 KiB
PHP

<?php
if (!empty($_SESSION['site301_edit']))
{
?>
<div class="tag100">
<div class="head_tag"><?php echo $lab_Tag_site306_001 ;?></div>
<div class="tag">
<table WIDTH="100%" class="tag">
<TR>
<TD class="label"><?php echo $lab_Field_site302_001 ;?></TD>
<TD class="label"><?php echo $lab_Field_site302_002 ;?></TD>
<TD class="label"><?php echo $lab_Field_site306_005 ;?></TD>
</TR>
<?php
$cableArray = sqlGetResAsArray("select SES_EQU_ID,EQU_NAME,MCF_NAME,sum(SES_VALUE) ILE,(select sum(SDE_VALUE) from seg_dev_equipments_rel where SDE_PARAM3='".$_SESSION['syndis_eq_stock']."' and SDE_DRS_EQU_ID=SES_EQU_ID) USED from seg_equipments_stock left join seg_equipments on SES_EQU_ID=EQU_ID left join seg_manufacturers on EQU_MCF_ID=MCF_ID where SES_TYPE=13 and SES_PARAM3='".$_SESSION['syndis_eq_stock']."' group by SES_EQU_ID");
for ($i=0; $i<count($cableArray); $i++)
{
echo"
<TR STYLE='cursor: pointer;' onclick=".chr(34)."document.location.href='?pg=site301infAkbm&dev=".$_GET['dev']."&up=".$cableArray[$i]['SES_EQU_ID']."'".chr(34).">
<TD class='field_center'>".$cableArray[$i]['EQU_NAME']."</TD>
<TD class='field_center'>".$cableArray[$i]['MCF_NAME']."</TD>
<TD class='field_right'>".(int) ($cableArray[$i]['ILE'] - $cableArray[$i]['USED'])."</TD>
</TR>
";
}
unset($cableArray);
?>
</table>
</div>
<div class="tag_buttons">
<a class="btn btn-info btn-sm" style="text-decoration: none;" href="./?pg=site301inf&dev=<?php echo $_GET['dev']; ?>" role="button"><?php echo $lab_ButtonName_Cancel; ?></a>
</div>
</div>
<?php
}
else showFooterWarningAccessNotification($lab_FooterWarningAccessNotification_001);
?>