Nouveau titre

This commit is contained in:
Rodolphe Quiedeville 2003-06-22 14:24:13 +00:00
parent 3c6b93786e
commit 29dce9d24d

View File

@ -21,30 +21,32 @@
*/
$info_box_head = array();
$info_box_head[] = array('text' => "Factures");
$info_box_head[] = array('text' => "Les 5 dernières factures");
$info_box_contents = array();
$sql = "SELECT s.nom,s.idp,f.facnumber,f.amount,".$db->pdate("f.datef")." as df,f.paye,f.rowid as facid";
$sql .= " FROM llx_societe as s,llx_facture as f WHERE f.fk_soc = s.idp";
$sql .= " ORDER BY f.datef DESC, f.facnumber DESC ";
$sql .= $db->plimit(5, 0);
$result = $db->query($sql);
if ($result) {
if ($result)
{
$num = $db->num_rows();
$i = 0;
while ($i < $num) {
$objp = $db->fetch_object( $i);
$info_box_contents[$i] = array('align' => 'center',
'text' => $objp->facnumber . " " . $objp->nom,
'url' => "/compta/facture.php3?facid=".$objp->facid);
$i++;
}
while ($i < $num)
{
$objp = $db->fetch_object( $i);
$info_box_contents[$i] = array('align' => 'center',
'text' => $objp->facnumber . " " . $objp->nom,
'url' => DOL_URL_ROOT."/compta/facture.php3?facid=".$objp->facid);
$i++;
}
}
new infoBox($info_box_head, $info_box_contents);