Subversion Repositories Applications.referentiel

Rev

Rev 24 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
33 jpm 1
<!-- REF - DEBUT TEST -->
2
<script type="text/javascript">
3
$(document).ready(function() {
4
	$('#ref-dem-ok').click(function(e) {
5
		var ok = false;
6
		if (confirm('Êtes vous sûr de vouloir lancer un nouveau traitement ?')) {
7
			ok = true;
8
		}
9
		return ok;
10
	});
11
});
12
</script>
13
<h1>Tests du référentiel «&nbsp;<?=$ref;?>&nbsp;»</h1>
23 jpm 14
 
33 jpm 15
<h2>Demande de traitement</h2>
16
<?php if (isset($ref)) : ?>
17
<div id="zone-form">
18
	<form id="ref-demande-traitement" name="ref-demande-traitement" action="<?=$url_form;?>" method="get">
19
		<input name="module" type="hidden" value="<?=$url_module;?>" />
20
		<input name="action" type="hidden" value="<?=$url_action_demande;?>" />
21
		<input name="ref" type="hidden" value="<?=$ref;?>" />
22
		<label id="ref-dem-label"for="ref-dem-ok">Faire une demande de traitement</label>
23
		<input id="ref-dem-ok" type="submit" value="Demander" />
24
	</form>
25
	<form id="ref-rafraichir" name="ref-rafraichir" action="<?=$url_form;?>" method="get">
26
		<input name="module" type="hidden" value="<?=$url_module;?>" />
27
		<input name="action" type="hidden" value="<?=$url_action_rafraichir;?>" />
28
		<input name="ref" type="hidden" value="<?=$ref;?>" />
29
		<input id="ref-raf-ok" type="submit" value="Rafraichir" />
30
	</form>
31
</div>
32
<?php endif; ?>
33
 
23 jpm 34
<?php if (isset($messages)) : ?>
35
<h2>Messages</h2>
36
<?php foreach ($messages as $message) : ?>
37
<p class="information"><?=$message;?></p>
38
<?php endforeach; ?>
39
<?php endif; ?>
40
 
33 jpm 41
<h2>Traitements en cours</h2>
42
<?php if (isset($traitements_en_cours)) : ?>
43
<table>
44
	<caption>Traitements en cours</caption>
45
	<thead>
46
		<tr>
47
			<th>Nom (#)</th>
48
			<th>Date début</th>
49
		</tr>
50
	</thead>
51
	<tbody>
52
	<?php foreach ($traitements_en_cours as $traitement) : ?>
53
		<tr>
54
			<td><?=$traitement['nom']?> <span class="discretion">(id:<?=$traitement['id_traitement']?>)</span></td>
55
			<td><?=$traitement['date_debut']?></td>
56
		</tr>
57
	<?php endforeach; ?>
58
	</tbody>
59
</table>
60
<?php else : ?>
61
<p class="information">Aucun traitement en cours.</p>
24 jpm 62
<?php endif; ?>
63
 
33 jpm 64
<h2>Traitements terminés</h2>
65
<?php if (isset($traitements_termines)) : ?>
66
<table>
67
	<caption>Traitements terminées</caption>
68
	<thead>
69
		<tr>
70
			<th>Nom (#)</th>
71
			<th>Date début</th>
72
			<th>Date fin</th>
73
			<th>Durée</th>
74
		</tr>
75
	</thead>
76
	<tbody>
77
	<?php foreach ($traitements_termines as $traitement) : ?>
78
		<tr>
79
			<td><a href="<?=$traitement['url']?>"><?=$traitement['nom']?> <span class="discretion">(id:<?=$traitement['id_traitement']?>)</span></a></td>
80
			<td><?=$traitement['date_debut']?></td>
81
			<td><?=$traitement['date_fin']?></td>
82
			<td><?=$traitement['duree']?></td>
83
		</tr>
84
	<?php endforeach; ?>
85
	</tbody>
86
</table>
87
<?php else : ?>
88
<p class="information">Aucun traitement terminé.</p>
89
<?php endif; ?>
90
<!-- REF - FIN TEST -->