53 lines
2.0 KiB
PHP
53 lines
2.0 KiB
PHP
<?php
|
|
if (!empty($_SESSION['site301_edit']))
|
|
{
|
|
?>
|
|
|
|
<?php
|
|
if(!empty($_GET['param']))
|
|
{
|
|
$paramArray = explode(',',$_GET['param']);
|
|
$_GET['dev'] = $paramArray[0];
|
|
$_GET['eq'] = $paramArray[1];
|
|
// $tpmArray = sqlGetResAsArray("select SES_STOCK,DIC_POL_LANG from seg_equipments_stock left join sys_dictionaries on DIC_ID=SES_PARAM2 where SES_ID=".$recID);
|
|
$tpmArray = sqlGetResAsArray("select EQU_NAME,sum(SES_VALUE) TOT_VAL,(select sum(SDE_VALUE) from seg_dev_equipments_rel where SDE_PARAM3='".$_SESSION['syndis_eq_stock']."' and SDE_DRS_EQU_ID=SES_EQU_ID) TOT_STOCK from seg_equipments_stock,seg_equipments where SES_EQU_ID=EQU_ID and SES_EQU_ID=".$_GET['eq']);
|
|
unset($paramArray);
|
|
}
|
|
|
|
|
|
?>
|
|
|
|
|
|
<div class="tag100">
|
|
<FORM ACTION="./?pg=site301inf&dev=<?php echo $_GET['dev'];?>" METHOD="POST" name="insert_count">
|
|
<input type="hidden" name="dev" value="<?php echo $_GET['dev']; ?>">
|
|
<input type="hidden" name="eq" value="<?php echo $_GET['eq']; ?>">
|
|
<input type="hidden" id="inAvValue" value="<?php echo round($tpmArray[0]['TOT_VAL']-$tpmArray[0]['TOT_STOCK'],2); ?>">
|
|
|
|
<div class="head_tag">Ilość sztuk [<?php echo $tpmArray[0]['EQU_NAME'];?>]</div>
|
|
<div class="tag">
|
|
<table class="desc_val">
|
|
<tr>
|
|
<td class="desc">Ilość</td>
|
|
<td class="desc_value"><INPUT class="float_req" TYPE="TEXT" NAME="inRuValue" id="inRuValue">
|
|
|
|
Dostępne <?php echo round($tpmArray[0]['TOT_VAL']-$tpmArray[0]['TOT_STOCK'],2);?>
|
|
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tag_buttons">
|
|
<INPUT class='btn btn-info btn-sm' TYPE='SUBMIT' NAME='subRuCancel' VALUE="<?php echo $lab_ButtonName_Cancel; ?>">
|
|
<INPUT class='btn btn-success btn-sm' TYPE='SUBMIT' NAME='subRuSave' VALUE="<?php echo $lab_ButtonName_Save; ?>" id="subRuSave" >
|
|
</div>
|
|
</FORM>
|
|
</div>
|
|
|
|
|
|
<?php
|
|
}
|
|
else showFooterWarningAccessNotification($lab_FooterWarningAccessNotification_001);
|
|
?>
|