noalyss Version-9
follow_up-view_list.php
Go to the documentation of this file.
1<?php
2/*
3 * This file is part of NOALYSS.
4 *
5 * NOALYSS is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * NOALYSS is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with NOALYSS; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18*/
19// Copyright Author Dany De Bontridder danydb@aevalys.eu 13/02/24
20/*!
21 * \file
22 * \brief display list of followup
23 */
24global $cn;
25$array=$cn->get_array($sql);
26if (empty ($array)) {
27 echo_warning("Aucun suivi ");
28 return;
29}
31echo \HtmlInput::filter_table("view_list_tb", "0,1,2,3,4,5", 1);
32?>
33
34<table class="result" id="view_list_tb">
35 <thead>
36
37 <tr>
38 <th>Date</th>
39 <th>Référence</th>
40 <th>Titre</th>
41 <th>QCODE</th>
42 <th>Dernier commentaire</th>
43 <th>Etat</th>
44 <th></th>
45 </tr>
46 </thead>
47 <tbody>
48 <?php
49 foreach($array as $item) {
50 $even=($idx%2==0)?'class="odd"':'class="even"';
51 $idx++;
52 ?>
53 <tr <?=$even?>>
54 <td><?=$item['my_date']?></td>
55 <td>
56 <?php
57 echo \HtmlInput::detail_action($item['ag_id'], $item['ag_ref']);
58
59
60 ?>
61
62 </td>
63 <td><?=h($item['ag_title'])?></td>
64 <td><?=h($item['qcode'])?></td>
65 <td><?=$item['str_last_comment']?></td>
66 <td><?=h($item['s_value'])?></td>
67 <td>
68
69 <?php
70 if ($item['tags']!="") {
71 $aColor = explode(",", $item["tags_color"]);
72 $aTags = explode(",", $item["tags"]);
73 $nb_tag = count($aTags);
74 for ($x = 0; $x < $nb_tag; $x++) {
75 printf('<span style="font-size:75%%;padding:1px;border-color:transparent" class="tagcell tagcell-color%s">%s</span>', $aColor[$x], $aTags[$x]);
76 printf("&nbsp;");
77 } // end loop $x
78
79 }
80 ?>
81 </td>
82 </tr>
83 <?php
84 }
85
86 ?>
87 </tbody>
88</table>
th($p_string, $p_extra='', $raw='')
Definition: ac_common.php:58
echo_warning($p_string)
warns
Definition: ac_common.php:589
tr($p_string, $p_extra='')
Definition: ac_common.php:88
td($p_string='', $p_extra='')
surround the string with td
Definition: ac_common.php:83
h( $row[ 'oa_description'])
$all table
global $cn
if(empty($array)) $idx