| 416 |
aurelien |
1 |
<?php
|
|
|
2 |
|
|
|
3 |
|
|
|
4 |
Class InventoryContributionList extends DBAccessor {
|
|
|
5 |
|
|
|
6 |
|
|
|
7 |
protected $config;
|
|
|
8 |
|
|
|
9 |
function InventoryContributionList($config) {
|
|
|
10 |
|
|
|
11 |
$this->config=$config;
|
|
|
12 |
}
|
|
|
13 |
|
|
|
14 |
function getRessource() {
|
|
|
15 |
echo '';
|
|
|
16 |
}
|
|
|
17 |
|
|
|
18 |
|
|
|
19 |
function getElement($uid){
|
|
|
20 |
|
|
|
21 |
if(!isset($uid[0])) {
|
|
|
22 |
echo '';
|
|
|
23 |
}
|
|
|
24 |
|
|
|
25 |
$DB=$this->connectDB($this->config,'database_cel');
|
|
|
26 |
|
|
|
27 |
$query="SELECT * FROM cel_inventory ".
|
|
|
28 |
"WHERE identifiant = '".$DB->escapeSimple($uid[0])."' ".
|
|
|
29 |
"ORDER BY date_modification DESC LIMIT 0,5";
|
|
|
30 |
|
|
|
31 |
$res =& $DB->query($query);
|
|
|
32 |
|
|
|
33 |
if (DB::isError($res)) {
|
|
|
34 |
die($res->getMessage());
|
|
|
35 |
}
|
|
|
36 |
|
|
|
37 |
$resume = "";
|
|
|
38 |
|
|
|
39 |
|
|
|
40 |
while ($row =& $res->fetchrow(DB_FETCHMODE_ASSOC)) {
|
|
|
41 |
$row['nom_sel'] = htmlspecialchars($row['nom_sel']);
|
|
|
42 |
$row['identifiant'] = htmlspecialchars($row['identifiant']);
|
|
|
43 |
$row['location'] = htmlspecialchars($row['location']);
|
|
|
44 |
$row['id_location'] = htmlspecialchars($row['id_location']);
|
|
|
45 |
$row['station'] = htmlspecialchars($row['station']);
|
|
|
46 |
$row['milieu'] = htmlspecialchars($row['milieu']);
|
|
|
47 |
$row['commentaire'] = htmlspecialchars($row['commentaire']);
|
|
|
48 |
$row['transmission'] = htmlspecialchars($row['transmission']);
|
|
|
49 |
|
|
|
50 |
|
|
|
51 |
$resume.= '<p>'.$row['nom_sel'] ." (".$row['num_nom_sel'].") ".
|
|
|
52 |
'Location : '. $row['location'].",". $row['station'] . "," . $row['milieu'] . "," . $row['commentaire'] . "," . $row['transmission'] .
|
|
|
53 |
'</p>';
|
|
|
54 |
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
|
|
|
58 |
header("Content-Type: text/html; charset=ISO-8859-1");
|
|
|
59 |
print $resume;
|
|
|
60 |
exit;
|
|
|
61 |
}
|
|
|
62 |
|
|
|
63 |
}
|
|
|
64 |
|
|
|
65 |
|
|
|
66 |
/* +--Fin du code ---------------------------------------------------------------------------------------+
|
|
|
67 |
* $Log$
|
|
|
68 |
* Revision 1.5 2008-11-13 11:29:12 ddelon
|
|
|
69 |
* Reecriture gwt-ext
|
|
|
70 |
*
|
|
|
71 |
* Revision 1.4 2007-06-06 13:31:16 ddelon
|
|
|
72 |
* v0.09
|
|
|
73 |
*
|
|
|
74 |
* Revision 1.3 2007-05-22 12:54:09 ddelon
|
|
|
75 |
* Securisation acces utilisateur
|
|
|
76 |
*
|
|
|
77 |
*
|
|
|
78 |
*
|
|
|
79 |
*/
|
|
|
80 |
|
|
|
81 |
?>
|