Line 1... |
Line 1... |
1 |
<?php if (isset($messages)) : ?>
|
1 |
<?php if (isset($messages)) : ?>
|
2 |
<?php foreach ($messages as $message) : ?>
|
2 |
<?php foreach ($messages as $message) : ?>
|
3 |
<p class="information"><?=$message;?></p>
|
3 |
<p class="information"><?=$message;?></p>
|
4 |
<?php endforeach; ?>
|
4 |
<?php endforeach; ?>
|
5 |
<?php endif; ?>
|
5 |
<?php endif; ?>
|
6 |
<?php if ($preferences) : ?>
|
6 |
<?php if ($preferences) : ?>
|
7 |
<div id="preferences">
|
7 |
<div id="preferences">
|
8 |
<form class="centre" id="gestion_admin_pref" action="index.php?action=<?=GTT_ACTION_PREFERENCE_VALIDER;?>" name="gestion_admin_pref" method="post">
|
8 |
<form class="centre" id="gestion_admin_pref" action="index.php?action=<?=GTT_ACTION_PREFERENCE_VALIDER;?>" name="gestion_admin_pref" method="post">
|
9 |
<input name="champ_nb_total_proj" value="<?=$nbre_projets;?>" type="hidden"/>
|
9 |
<input name="champ_nb_total_proj" value="<?=$nbre_projets;?>" type="hidden"/>
|
Line 13... |
Line 13... |
13 |
<th> </th>
|
13 |
<th> </th>
|
14 |
<th>Nom</th>
|
14 |
<th>Nom</th>
|
15 |
<th>Description</th>
|
15 |
<th>Description</th>
|
16 |
<th>Date début</th>
|
16 |
<th>Date début</th>
|
17 |
<th>Date fin</th>
|
17 |
<th>Date fin</th>
|
18 |
<th>Durée prévue</th>
|
18 |
<th>Durée prévue (j)</th>
|
19 |
<th>Durée financée</th>
|
19 |
<th>Durée financée (j)</th>
|
- |
|
20 |
<th>Avancement (j)</th>
|
20 |
<th>Avancement (%)</th>
|
21 |
<th>Avancement (%)</th>
|
21 |
</tr>
|
22 |
</tr>
|
22 |
</thead>
|
23 |
</thead>
|
23 |
<tbody>
|
24 |
<tbody>
|
24 |
<?php foreach ($preferences as $categorie => $projets):?>
|
25 |
<?php foreach ($preferences as $categorie => $projets):?>
|
25 |
<tr class="categories"><th colspan="8"><?=$categorie;?></th></tr>
|
26 |
<tr class="categories"><th colspan="9"><?=$categorie;?></th></tr>
|
26 |
<?php $ligne = "impair"; ?>
|
27 |
<?php $ligne = "impair"; ?>
|
27 |
<?php foreach ($projets as $projet):?>
|
28 |
<?php foreach ($projets as $projet):?>
|
28 |
<tr class="<?=$ligne ; $ligne = ($ligne == "impair") ? "pair" : "impair" ;?>">
|
29 |
<tr class="<?=$ligne ; $ligne = ($ligne == "impair") ? "pair" : "impair" ;?>">
|
29 |
<td class="check"><input id="pr:<?=$projet['id'];?>" name="pr:<?=$projet['id'];?>" value="<?=$projet['valeur'];?>" type="checkbox" <?=$projet['coche']?'checked="checked"':'';?>/></td>
|
30 |
<td class="check"><input id="pr:<?=$projet['id'];?>" name="pr:<?=$projet['id'];?>" value="<?=$projet['valeur'];?>" type="checkbox" <?=$projet['coche']?'checked="checked"':'';?>/></td>
|
30 |
<td class="pr_no"><?=$projet['no'];?></td>
|
31 |
<td class="pr_no"><?=$projet['no'];?></td>
|
31 |
<td class="pr_de"><?=$projet['de'];?></td>
|
32 |
<td class="pr_de"><?=$projet['de'];?></td>
|
32 |
<td class="pr_dade"><?=($projet['dade'] != '0000-00-00') ? $projet['dade'] : ' ' ;?></td>
|
33 |
<td class="pr_dade"><?=($projet['dade'] != '0000-00-00') ? $projet['dade'] : ' ' ;?></td>
|
33 |
<td class="pr_dafi"><?=($projet['dafi'] != '0000-00-00') ? $projet['dafi'] : ' ' ;?></td>
|
34 |
<td class="pr_dafi"><?=($projet['dafi'] != '0000-00-00') ? $projet['dafi'] : ' ' ;?></td>
|
34 |
<td class="pr_dupr"><?=(!empty($projet['dupr'])) ? $projet['dupr'] : ' ' ;?></td>
|
35 |
<td class="pr_dupr"><?=(!empty($projet['dupr'])) ? $projet['dupr'] : ' ' ;?></td>
|
35 |
<td class="pr_dufi"><?=(!empty($projet['dufi'])) ? $projet['dufi'] : ' ' ;?></td>
|
36 |
<td class="pr_dufi"><?=(!empty($projet['dufi'])) ? $projet['dufi'] : ' ' ;?></td>
|
- |
|
37 |
|
- |
|
38 |
<!-- colonne "avancement en jours" -->
|
- |
|
39 |
<?php
|
- |
|
40 |
// calculs utiles pour la suite
|
- |
|
41 |
$pourcentageEffectue = 0;
|
- |
|
42 |
$pourcentageEnTrop = 0;
|
- |
|
43 |
$joursEnTrop = $projet['avc'] - $projet['dupr'];
|
- |
|
44 |
if ($projet['dupr'] > 0) {
|
- |
|
45 |
$pourcentageEffectue = round(($projet['avc'] / $projet['dupr']) * 100);
|
- |
|
46 |
$pourcentageEnTrop = round((($joursEnTrop) / $projet['dupr']) * 100);
|
- |
|
47 |
}
|
- |
|
48 |
?>
|
- |
|
49 |
<?php if ($projet['avc'] > ($projet['dupr'] * 1.15)): ?>
|
- |
|
50 |
<!-- on dépasse de 15%, alerte ! -->
|
- |
|
51 |
<td class="pr_av_j bg-alerte" title="<?= $joursEnTrop ?> jours ont été accordés au delà des prévisions">
|
- |
|
52 |
<?php else: ?>
|
36 |
<td class="pr_av">
|
53 |
<td class="pr_av_j">
|
- |
|
54 |
<?php endif; ?>
|
- |
|
55 |
<?= $projet['avc'] ?> / <?= $projet['dupr'] ?>
|
- |
|
56 |
</td>
|
- |
|
57 |
|
- |
|
58 |
<!-- colonne "avancement en %" -->
|
- |
|
59 |
<td class="pr_av" title="<?= $pourcentageEffectue ?>%">
|
- |
|
60 |
<div class="barre-avancement-ext">
|
- |
|
61 |
<div class="barre-avancement-int" style="width:<?= min(100, $pourcentageEffectue) ?>px;">
|
- |
|
62 |
</div>
|
- |
|
63 |
</div>
|
37 |
<?php if (!empty($projet['av'])) : ?>
|
64 |
<!--<?php if (!empty($projet['av'])) : ?>
|
38 |
<img height="10"
|
65 |
<img height="10"
|
39 |
width="<?=$projet['av'];?>"
|
66 |
width="<?=min(100, $projet['av']);?>"
|
40 |
title="<?=$projet['av'];?> %"
|
67 |
title="pipi <?=$projet['av'];?> %"
|
41 |
src="presentation/images/pixels/avancement.png"
|
68 |
src="presentation/images/pixels/avancement.png"
|
42 |
style="cursor:crosshair;padding-right:<?=(100 - $projet['av']);?>px;border:1px solid #DDD;"
|
69 |
style="cursor:help;padding-right:<?=(100 - $projet['av']);?>px;border:1px solid #DDD;"
|
43 |
alt="<?=$projet['av'];?> %" />
|
70 |
alt="<?=$projet['av'];?> %" />
|
44 |
<?php else : ?>
|
71 |
<?php else : ?>
|
45 |
<img height="10"
|
72 |
<img height="10"
|
46 |
width="100"
|
73 |
width="100"
|
47 |
style="cursor:crosshair;border:1px solid #DDD;"
|
74 |
style="cursor:help;border:1px solid #DDD;"
|
48 |
src="presentation/images/pixels/vide.png"
|
75 |
src="presentation/images/pixels/vide.png"
|
49 |
title="<?=$projet['av'];?> %"
|
76 |
title="caca <?=$projet['av'];?> %"
|
50 |
alt="0 %" />
|
77 |
alt="0 %" />
|
51 |
<?php endif; ?>
|
78 |
<?php endif; ?>-->
|
52 |
</td>
|
79 |
</td>
|
53 |
</tr>
|
80 |
</tr>
|
54 |
<?php endforeach; ?>
|
81 |
<?php endforeach; ?>
|
55 |
<?php endforeach; ?>
|
82 |
<?php endforeach; ?>
|
56 |
</tbody>
|
83 |
</tbody>
|