Skip to content

Commit

Permalink
Merge pull request #2047 from frederic34/patch-6
Browse files Browse the repository at this point in the history
#1685-1686 Clear sort filter works partially in supplier invoices
  • Loading branch information
eldy committed Nov 22, 2014
1 parent 830d470 commit e4804f9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions htdocs/fourn/facture/list.php
Expand Up @@ -74,7 +74,7 @@
$year = GETPOST("year","int");
$filter = GETPOST("filtre");

if (GETPOST("button_removefilter_x"))
if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter")) // Both test must be present to be compatible with all browsers
{
$search_ref="";
$search_ref_supplier="";
Expand Down Expand Up @@ -138,7 +138,7 @@
{
$sql .= " AND s.rowid = ".$socid;
}
if ($filter) && $filter != -1) // GETPOST('filtre') may be a string
if ($filter && $filter != -1) // GETPOST('filtre') may be a string
{
$filtrearr = explode(",", $filter);
foreach ($filtrearr as $fil)
Expand Down Expand Up @@ -219,7 +219,7 @@
if ($search_company) $param.='&search_company='.urlencode($search_company);
if ($search_amount_no_tax) $param.='&search_amount_no_tax='.urlencode($search_amount_no_tax);
if ($search_amount_all_tax) $param.='&search_amount_all_tax='.urlencode($search_amount_all_tax);
if ($filter) && $filter != -1) $param.='&filtre='.urlencode($filter);
if ($filter && $filter != -1) $param.='&filtre='.urlencode($filter);

print_barre_liste($langs->trans("BillsSuppliers").($socid?" $soc->name.":""),$page,$_SERVER["PHP_SELF"],$param,$sortfield,$sortorder,'',$num,$nbtotalofrecords);
print '<form method="GET" action="'.$_SERVER["PHP_SELF"].'">';
Expand Down Expand Up @@ -272,7 +272,7 @@
print '<input class="flat" type="text" size="8" name="search_amount_all_tax" value="'.$search_amount_all_tax.'">';
print '</td><td class="liste_titre" align="right">';
$liststatus=array('paye:0'=>$langs->trans("Unpaid"), 'paye:1'=>$langs->trans("Paid"));
print $form->selectarray('filtre', $liststatus, $filter), 1);
print $form->selectarray('filtre', $liststatus, $filter, 1);
print '</td><td class="liste_titre" align="right">';
print '<input type="image" class="liste_titre" name="button_search" src="'.img_picto($langs->trans("Search"),'search.png','','',1).'" value="'.dol_escape_htmltag($langs->trans("Search")).'" title="'.dol_escape_htmltag($langs->trans("Search")).'">';
print '<input type="image" class="liste_titre" name="button_removefilter" src="'.img_picto($langs->trans("Search"),'searchclear.png','','',1).'" value="'.dol_escape_htmltag($langs->trans("RemoveFilter")).'" title="'.dol_escape_htmltag($langs->trans("RemoveFilter")).'">';
Expand Down Expand Up @@ -331,7 +331,7 @@
//print $facturestatic->LibStatut($obj->paye,$obj->fk_statut,5,$objp->am);
print $facturestatic->LibStatut($obj->paye,$obj->fk_statut,5);
print '</td>';

print '<td align="center">&nbsp;</td>';

print "</tr>\n";
Expand Down

0 comments on commit e4804f9

Please sign in to comment.