From 7419b6d6138539cd9af31996d02f304b184021b2 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Thu, 27 Mar 2003 20:25:47 +0000 Subject: [PATCH] Suppresion du lien vers la fiche si le livre n'est pas en vente --- htdocs/boutique/livre/index.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/htdocs/boutique/livre/index.php b/htdocs/boutique/livre/index.php index 3aa497e36c2..38355cc7d16 100644 --- a/htdocs/boutique/livre/index.php +++ b/htdocs/boutique/livre/index.php @@ -38,9 +38,21 @@ if ($page == -1) { $page = 0 ; } $limit = $conf->liste_limit; $offset = $limit * $page ; -print_barre_liste("Liste des Livres", $page, $PHP_SELF, "", $sortfield, $sortorder); +$form = '
'. +''. +''. +'Titre :  '. +'
'; + + +print_barre_liste("Liste des Livres", $page, $PHP_SELF, "", $sortfield, $sortorder, $form); $sql = "SELECT l.rowid, l.title, l.oscid, l.ref, l.status FROM llx_livre as l"; + +if ($searchvalue) +{ + $sql .= " WHERE l.title like '%$searchvalue%'"; +} $sql .= " ORDER BY $sortfield $sortorder "; $sql .= $db->plimit( $limit ,$offset); @@ -73,14 +85,16 @@ if ( $db->query($sql) ) { print ''; print ''; + print 'Fiche en ligne'; + } else { print ''; print ''; + print ' '; } - print 'Fiche en ligne'; print "\n"; $i++; }