diff --git a/htdocs/compta/facture/fiche-rec.php b/htdocs/compta/facture/fiche-rec.php
index 0573a00ce3c..df8b7e5a517 100644
--- a/htdocs/compta/facture/fiche-rec.php
+++ b/htdocs/compta/facture/fiche-rec.php
@@ -521,7 +521,6 @@ else
/*
* List mode
*/
-
$sql = "SELECT s.nom, s.rowid as socid, f.titre, f.total, f.rowid as facid";
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."facture_rec as f";
$sql.= " WHERE f.fk_soc = s.rowid";
@@ -531,13 +530,14 @@ else
//$sql .= " ORDER BY $sortfield $sortorder, rowid DESC ";
// $sql .= $db->plimit($limit + 1,$offset);
- $result = $db->query($sql);
-
- if ($result)
+ $resql = $db->query($sql);
+ if ($resql)
{
- $num = $db->num_rows($result);
+ $num = $db->num_rows($resql);
print_barre_liste($langs->trans("RepeatableInvoices"),$page,$_SERVER['PHP_SELF'],"&socid=$socid",$sortfield,$sortorder,'',$num);
+ print $langs->trans("ToCreateAPredefinedInvoice").'
';
+
$i = 0;
print '
';
print '';
@@ -552,7 +552,7 @@ else
$var=True;
while ($i < min($num,$limit))
{
- $objp = $db->fetch_object($result);
+ $objp = $db->fetch_object($resql);
$var=!$var;
print "
";
@@ -586,9 +586,10 @@ else
$i++;
}
}
+ else print '
| '.$langs->trans("NoneF").' |
';
print "
";
- $db->free();
+ $db->free($resql);
}
else
{
@@ -601,5 +602,4 @@ else
llxFooter();
$db->close();
-
-?>
+?>
\ No newline at end of file
diff --git a/htdocs/langs/en_US/compta.lang b/htdocs/langs/en_US/compta.lang
index c2a27fe8b7d..b33fde21141 100644
--- a/htdocs/langs/en_US/compta.lang
+++ b/htdocs/langs/en_US/compta.lang
@@ -154,4 +154,5 @@ InvoiceLinesToDispatch=Invoice lines to dispatch
InvoiceDispatched=Dispatched invoices
AccountancyDashboard=Accountancy summary
ByProductsAndServices=By products and services
-RefExt=External ref
\ No newline at end of file
+RefExt=External ref
+ToCreateAPredefinedInvoice=To create a predefined invoice, create a standard invoice then, without validating it, click onto button "Convert to predefined invoice".
\ No newline at end of file
diff --git a/htdocs/langs/fr_FR/compta.lang b/htdocs/langs/fr_FR/compta.lang
index b3a1bf5347a..691ee95d388 100644
--- a/htdocs/langs/fr_FR/compta.lang
+++ b/htdocs/langs/fr_FR/compta.lang
@@ -155,3 +155,4 @@ InvoiceDispatched=Factures ventilées
AccountancyDashboard=Synthèse compta/tréso
ByProductsAndServices=Par produits et services
RefExt=Référence externe
+ToCreateAPredefinedInvoice=Pour créer une facture prédéfinie, créer une facture standard puis sans la valider, cliquer sur le bouton "Convertir en facture prédéfine".
\ No newline at end of file