| [ Index ] |
|
Code source de Dolibarr 2.0.1 |
1 <?PHP 2 /* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation; either version 2 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program; if not, write to the Free Software 16 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 17 * 18 * $Id: index.php,v 1.5 2005/09/02 11:49:51 rodolphe Exp $ 19 * $Source: /cvsroot/dolibarr/dolibarr/htdocs/telephonie/service/index.php,v $ 20 * 21 */ 22 require ("./pre.inc.php"); 23 24 if (!$user->rights->telephonie->service->lire) accessforbidden(); 25 26 llxHeader('','Telephonie - Services'); 27 28 /* 29 * 30 * 31 * 32 */ 33 34 print_titre("Services"); 35 36 print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">'; 37 38 print '<tr><td width="30%" valign="top">'; 39 40 $sql = "SELECT s.rowid , libelle, count(cs.rowid) "; 41 $sql .= " FROM ".MAIN_DB_PREFIX."telephonie_service as s"; 42 $sql .= " , ".MAIN_DB_PREFIX."telephonie_contrat_service as cs"; 43 $sql .= " WHERE cs.fk_service = s.rowid"; 44 $sql .= " GROUP by s.rowid DESC"; 45 //print $sql; 46 if ($db->query($sql)) 47 { 48 $num = $db->num_rows(); 49 $i = 0; 50 51 print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">'; 52 print '<tr class="liste_titre"><td>Libellé</td><td>-</td>'; 53 print "</tr>\n"; 54 $var=True; 55 56 while ($i < min($num,$conf->liste_limit)) 57 { 58 $row = $db->fetch_row(); 59 print '<tr><td><a href="fiche.php?id='.$row[0].'">'.stripslashes($row[1])."</a></td>"; 60 print '<td>'.$row[2]."</td></tr>"; 61 $i++; 62 } 63 64 65 66 print "</table>"; 67 $db->free(); 68 } 69 else 70 { 71 print $db->error() . ' ' . $sql; 72 } 73 74 print '<br />'; 75 print '</td><td width="70%" valign="top"> '; 76 77 print '</td>'; 78 79 80 print '</table>'; 81 82 83 84 $db->close(); 85 86 llxFooter("<em>Dernière modification $Date: 2005/09/02 11:49:51 $ révision $Revision: 1.5 $</em>"); 87 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
| Généré le : Mon Nov 26 12:29:37 2007 | par Balluche grâce à PHPXref 0.7 |
|