From 165741548136aad2464c7f5fdfdb439feaefac3b Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Mon, 11 Apr 2005 09:56:31 +0000 Subject: [PATCH] Modification appel de la fonction FactureFounisseur::Create --- htdocs/fourn/facture/fiche.php | 36 +++++++++++++++++----------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/htdocs/fourn/facture/fiche.php b/htdocs/fourn/facture/fiche.php index d91ff28b6d9..f2e12615293 100644 --- a/htdocs/fourn/facture/fiche.php +++ b/htdocs/fourn/facture/fiche.php @@ -98,17 +98,17 @@ if ($_POST["action"] == 'update') $sql .= " WHERE rowid = ".$_GET['facid']." ;"; $result = $db->query( $sql); } - -if ($_POST["action"] == 'add') +/* + * Création + */ +if ($_POST["action"] == 'add' && $user->rights->fournisseur->facture->creer) { if ($_POST["facnumber"]) { - $datefacture = $db->idate(mktime(12, - 0, - 0, - $_POST["remonth"], - $_POST["reday"], - $_POST["reyear"])); + $datefacture = mktime(12,0,0, + $_POST["remonth"], + $_POST["reday"], + $_POST["reyear"]); $tva = 0; $tva = ($_POST["tva_taux"] * $_POST["amount"]) / 100 ; $remise = 0; @@ -442,11 +442,11 @@ else * Facture */ print ''; - print ""; + print ""; print "\n"; print ""; - print '\n"; - print '\n"; + print '"; @@ -457,15 +457,15 @@ else $author->fetch(''); $authorfullname=$author->fullname; } - print ""; - print '"; + print ""; + print '"; - print "".'"; - print '"; - print "".'"; + print "".'"; + print '"; + print "".'"; if (strlen($fac->note)) { - print ''; } @@ -506,7 +506,7 @@ else $objp = $db->fetch_object(); $var=!$var; print ""; - print "\n"; + print "\n"; print "\n"; print "\n";
".$langs->trans("Company")."socidp\">$fac->socnom
".$langs->trans("Company")."socidp\">$fac->socnomsocidp\">".$langs->trans("OtherBills")."
'.$langs->trans("Date")."".dolibarr_print_date($fac->datep,"%A %d %B %Y")."
'.$langs->trans("Label").''; + print '
'.$langs->trans("Date")."".dolibarr_print_date($fac->datep,"%A %e %B %Y")."
'.$langs->trans("Label").''; print $fac->libelle; print "
".$langs->trans("Author")."$authorfullname
'.$langs->trans("Status").''.$fac->LibStatut($fac->paye,$fac->statut)."
".$langs->trans("Author")."$authorfullname
'.$langs->trans("Status").''.$fac->LibStatut($fac->paye,$fac->statut)."
 '.$langs->trans("TotalHT").''.price($fac->total_ht)."'.$langs->trans("VAT").''.price($fac->total_tva)."
 '.$langs->trans("TotalTTC").''.price($fac->total_ttc)."
'.$langs->trans("TotalHT").''.price($fac->total_ht)."'.$langs->trans("VAT").''.price($fac->total_tva)."
'.$langs->trans("TotalTTC").''.price($fac->total_ttc)."
'.$langs->trans("Comments").''; + print '
'.$langs->trans("Comments").''; print nl2br(stripslashes($fac->note)); print '
".strftime("%d %B %Y",$objp->dp)."".strftime("%e %B %Y",$objp->dp)."$objp->paiement_type $objp->num_paiement".price($objp->amount)."".$conf->monnaie."