Trad: Traductions oubliés sur la page des commandes.
Look: Picto incorrects sur page des commandes
This commit is contained in:
parent
85f6fb053e
commit
d7f8f2d79e
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2003-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2003-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -154,31 +154,33 @@ if ( $db->query($sql) )
|
|||||||
/*
|
/*
|
||||||
* Commandes à traiter
|
* Commandes à traiter
|
||||||
*/
|
*/
|
||||||
$sql = "SELECT c.rowid, c.ref, s.nom, s.idp FROM ".MAIN_DB_PREFIX."commande as c, ".MAIN_DB_PREFIX."societe as s";
|
$max=5;
|
||||||
$sql .= " WHERE c.fk_soc = s.idp AND c.fk_statut > 2 ";
|
|
||||||
if ($socidp)
|
$sql = "SELECT c.rowid, c.ref, s.nom, s.idp";
|
||||||
|
$sql.= " FROM ".MAIN_DB_PREFIX."commande as c, ".MAIN_DB_PREFIX."societe as s";
|
||||||
|
$sql.= " WHERE c.fk_soc = s.idp AND c.fk_statut > 2";
|
||||||
|
if ($socidp) $sql .= " AND c.fk_soc = $socidp";
|
||||||
|
$sql.= " ORDER BY c.rowid DESC";
|
||||||
|
$sql.= $db->plimit($max, 0);
|
||||||
|
|
||||||
|
$resql=$db->query($sql);
|
||||||
|
if ($resql)
|
||||||
{
|
{
|
||||||
$sql .= " AND c.fk_soc = $socidp";
|
$num = $db->num_rows($resql);
|
||||||
}
|
|
||||||
$sql .= " ORDER BY c.rowid DESC";
|
|
||||||
$sql .= $db->plimit(5, 0);
|
|
||||||
if ( $db->query($sql) )
|
|
||||||
{
|
|
||||||
$num = $db->num_rows();
|
|
||||||
if ($num)
|
if ($num)
|
||||||
{
|
{
|
||||||
$i = 0;
|
$i = 0;
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print '<td colspan="2">5 dernières commandes</td></tr>';
|
print '<td colspan="2">'.$langs->trans("LastOrders",$max).'</td></tr>';
|
||||||
$var = True;
|
$var = True;
|
||||||
while ($i < $num)
|
while ($i < $num)
|
||||||
{
|
{
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
$obj = $db->fetch_object();
|
$obj = $db->fetch_object($resql);
|
||||||
print "<tr $bc[$var]><td width=\"30%\"><a href=\"fiche.php?id=$obj->rowid\">".img_file()."</a> ";
|
print "<tr $bc[$var]><td width=\"30%\"><a href=\"fiche.php?id=$obj->rowid\">".img_object($langs->trans("ShowOrders"),"order").' ';
|
||||||
print "<a href=\"fiche.php?id=$obj->rowid\">$obj->ref</a></td>";
|
print $obj->ref.'</a></td>';
|
||||||
print '<td><a href="'.DOL_URL_ROOT.'/comm/fiche.php?socid='.$obj->idp.'">'.$obj->nom.'</a></td></tr>';
|
print '<td><a href="'.DOL_URL_ROOT.'/comm/fiche.php?socid='.$obj->idp.'">'.img_object($langs->trans("ShowCompany"),"company").' '.$obj->nom.'</a></td></tr>';
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
print "</table><br>";
|
print "</table><br>";
|
||||||
@ -192,5 +194,6 @@ print '</td></tr></table>';
|
|||||||
|
|
||||||
$db->close();
|
$db->close();
|
||||||
|
|
||||||
llxFooter("<em>Dernière modification $Date$ révision $Revision$</em>");
|
llxFooter('$Date$ - $Revision$');
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user