Skip to content

Commit

Permalink
FIX: Withdrawals lines not filter by company name and not respect dro…
Browse files Browse the repository at this point in the history
…pdown limit lines by page
  • Loading branch information
Juanjo Menent committed Feb 6, 2018
1 parent 2d4624a commit 9b56555
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions htdocs/compta/prelevement/list.php
Expand Up @@ -2,7 +2,7 @@
/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2005-2016 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2010-2012 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2010-2018 Juanjo Menent <jmenent@2byte.es>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -101,7 +101,7 @@
if ($search_line) $sql.= " AND pl.rowid = '".$db->escape($search_line)."'";
if ($search_bon) $sql.= natural_search("p.ref", $search_bon);
if ($search_code) $sql.= natural_search("s.code_client", $search_code);
if ($search_company) natural_search("s.nom", $search_company);
if ($search_company) $sql.= natural_search("s.nom", $search_company);

$sql.= $db->order($sortfield,$sortorder);

Expand All @@ -123,13 +123,14 @@

$urladd = "&amp;statut=".$statut;
$urladd .= "&amp;search_bon=".$search_bon;

print_barre_liste($langs->trans("WithdrawalsLines"), $page, $_SERVER["PHP_SELF"], $urladd, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'title_generic', 0, '', '', $limit);
if ($limit > 0 && $limit != $conf->liste_limit) $urladd.='&limit='.urlencode($limit);

print"\n<!-- debut table -->\n";
print '<form action="'.$_SERVER["PHP_SELF"].'" method="GET">';

$moreforfilter='';
print_barre_liste($langs->trans("WithdrawalsLines"), $page, $_SERVER["PHP_SELF"], $urladd, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'title_generic', 0, '', '', $limit);

$moreforfilter='';

print '<div class="div-table-responsive">';
print '<table class="tagtable liste'.($moreforfilter?" listwithfilterbefore":"").'">'."\n";
Expand Down

0 comments on commit 9b56555

Please sign in to comment.