2011-04-14 14:24:35 +00:00

47 lines
1.8 KiB
PHP

<h1>RATIO</h1>
<?php
foreach($PeerGroup as $peer) {
foreach($peer->FlexibleComparisonItems->ComparisonItemsGroup as $valeur) {
$y = explode('/', _setDateWithGiant($valeur->Period->EndDate->format, $valeur->Period->EndDate->_));
foreach($valeur->FlexibleComparisonItem as $champ => $val){
$year[$y[2]]->$champ = $val;
}
}
}
?>
<table class="PeerGroup">
<tr>
<td><b><?php echo SelectTrueLabel($this->labelConfig['Section_rapportPeerGroup'], 'IndustryCodes');?></b></td>
<td><?php echo $PeerGroup->IndustryCodes->NaceCode .' : ' .SelectTrueLabel($this->naceCodeList, $PeerGroup->IndustryCodes->NaceCode);?></td>
</tr>
<tr>
<td><b><?php echo SelectTrueLabel($this->labelConfig['Section_rapportPeerGroup'], 'Period');?></b></td>
<td>
<form name="select" method="POST" action="index.php?page=RapportGiant&pays=FR&company=55214450300018&level=Immediate&type=Full&lang=fr">
<select name="y" onChange="this.form.submit()" >
<?php foreach($PeerGroup as $peer) {?>
<?php foreach($peer->FlexibleComparisonItems->ComparisonItemsGroup as $valeur) {?>
<?php $y = explode('/', _setDateWithGiant($valeur->Period->EndDate->format, $valeur->Period->EndDate->_));?>
<option <?php echo (isset($_POST['y']) and $_POST['y'] == $y[2])? 'Selected="true"' : ''; ?> value="<?php echo $y[2]?>"><?php echo _setDateWithGiant($valeur->Period->EndDate->format, $valeur->Period->EndDate->_);?></option>
<?php }?>
<?php }?>
</select>
</form>
</td>
</tr>
</table>
<br />
<br />
<?php if(!isset($_POST['y'])) {$_POST['y'] = $y[2];}?>
<table class="PeerGroupAff">
<?php foreach($year[$_POST['y']] as $y) {?>
<tr>
<td><?php echo $y->ItemName->_?></td>
<td><?php echo $y->SubjectValue?></td>
<td><?php echo $y->AverageValue?></td>
</tr>
<?php }?>
</table>