Fix: No check box if no PDF

This commit is contained in:
Laurent Destailleur 2011-07-13 14:41:02 +00:00
parent 41b1886b55
commit 2e8ce5e513
2 changed files with 11 additions and 10 deletions

View File

@ -1,7 +1,7 @@
<?php <?php
/* Copyright (C) 2002-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org> /* Copyright (C) 2002-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com> * Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net> * Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr> * Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
@ -23,7 +23,7 @@
* \file htdocs/compta/facture/impayees.php * \file htdocs/compta/facture/impayees.php
* \ingroup facture * \ingroup facture
* \brief Page to list and build liste of unpaid invoices * \brief Page to list and build liste of unpaid invoices
* \version $Revision$ * \version $Revision: 1.83 $
*/ */
require("../../main.inc.php"); require("../../main.inc.php");
@ -268,7 +268,7 @@ if ($result)
print_fiche_titre($titre,$link); print_fiche_titre($titre,$link);
//print_barre_liste($titre,$page,$_SERVER["PHP_SELF"],$param,$sortfield,$sortorder,'',0); // We don't want pagination on this page //print_barre_liste($titre,$page,$_SERVER["PHP_SELF"],$param,$sortfield,$sortorder,'',0); // We don't want pagination on this page
if ($mesg) print $mesg; dol_htmloutput_mesg($mesg);
$i = 0; $i = 0;
print '<table class="liste" width="100%">'; print '<table class="liste" width="100%">';
@ -351,10 +351,10 @@ if ($result)
// PDF Picto // PDF Picto
print '<td width="16" align="right" class="nobordernopadding">'; print '<td width="16" align="right" class="nobordernopadding">';
$filename=dol_sanitizeFileName($objp->facnumber); $filename=dol_sanitizeFileName($objp->facnumber);
$filedir=$conf->facture->dir_output . '/' . dol_sanitizeFileName($objp->facnumber); $filedir=$conf->facture->dir_output . '/' . dol_sanitizeFileName($objp->facnumber);
$foundpdf=$formfile->show_documents('facture',$filename,$filedir,$urlsource,'','','',1,'',1,$param); $foundpdf=$formfile->show_documents('facture',$filename,$filedir,$urlsource,'','','',1,'',1,$param);
print '</td>'; print '</td>';
print '</tr></table>'; print '</tr></table>';
@ -425,5 +425,5 @@ if ($result)
$db->close(); $db->close();
llxFooter('$Date$ - $Revision$'); llxFooter('$Date: 2011/07/13 14:41:02 $ - $Revision: 1.83 $');
?> ?>

View File

@ -22,7 +22,7 @@
* \file htdocs/core/class/html.formfile.class.php * \file htdocs/core/class/html.formfile.class.php
* \ingroup core * \ingroup core
* \brief File of class to offer components to list and upload files * \brief File of class to offer components to list and upload files
* \version $Id: html.formfile.class.php,v 1.48 2011/07/13 07:38:11 hregis Exp $ * \version $Id: html.formfile.class.php,v 1.49 2011/07/13 14:41:03 eldy Exp $
*/ */
@ -152,6 +152,7 @@ class FormFile
*/ */
function show_documents($modulepart,$filename,$filedir,$urlsource,$genallowed,$delallowed=0,$modelselected='',$allowgenifempty=1,$forcenomultilang=0,$iconPDF=0,$maxfilenamelength=28,$noform=0,$param='',$title='',$buttonlabel='',$codelang='',$hooks='') function show_documents($modulepart,$filename,$filedir,$urlsource,$genallowed,$delallowed=0,$modelselected='',$allowgenifempty=1,$forcenomultilang=0,$iconPDF=0,$maxfilenamelength=28,$noform=0,$param='',$title='',$buttonlabel='',$codelang='',$hooks='')
{ {
$this->numoffiles=0;
print $this->showdocuments($modulepart,$filename,$filedir,$urlsource,$genallowed,$delallowed,$modelselected,$allowgenifempty,$forcenomultilang,$iconPDF,$maxfilenamelength,$noform,$param,$title,$buttonlabel,$codelang,$hooks); print $this->showdocuments($modulepart,$filename,$filedir,$urlsource,$genallowed,$delallowed,$modelselected,$allowgenifempty,$forcenomultilang,$iconPDF,$maxfilenamelength,$noform,$param,$title,$buttonlabel,$codelang,$hooks);
return $this->numoffiles; return $this->numoffiles;
} }