From 96805621a2f9968aff97c0a2494b881824eba080 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 1 Sep 2005 20:15:06 +0000 Subject: [PATCH] =?UTF-8?q?Possibilit=E9=20de=20modifier=20le=20descriptif?= =?UTF-8?q?=20et=20le=20taux=20de=20tva=20y=20compris=20sur=20les=20lignes?= =?UTF-8?q?=20de=20produits=20pr=E9d=E9finis.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/compta/facture.php | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/htdocs/compta/facture.php b/htdocs/compta/facture.php index c38c195f0bc..cca394cd328 100644 --- a/htdocs/compta/facture.php +++ b/htdocs/compta/facture.php @@ -284,7 +284,8 @@ if ($_POST["action"] == 'updateligne' && $user->rights->facture->creer && $_POST $_POST["qty"], $_POST["remise_percent"], $datestart, - $dateend + $dateend, + $_POST["tva_tx"] ); $_GET["facid"]=$_POST["facid"]; // Pour réaffichage de la fiche en cours d'édition @@ -1062,7 +1063,8 @@ else print ''.$langs->trans("AmountTTC").''.price($fac->total_ttc).''; print ''.$langs->trans("Currency".$conf->monnaie).''; - print ''.$langs->trans("Status").''.($fac->getLibStatut()).''; + // Statut + print ''.$langs->trans("Status").''.($fac->getLibStatut()).''; if ($fac->note) { @@ -1112,7 +1114,7 @@ else $objp = $db->fetch_object($resql); $var=!$var; - // Update ligne de facture + // Ligne en mode visu if ($_GET["action"] != 'editline' || $_GET["rowid"] != $objp->rowid) { print ''; @@ -1122,7 +1124,7 @@ else if ($objp->fk_product_type) print img_object($langs->trans('ShowService'),'service'); else print img_object($langs->trans('ShowProduct'),'product'); print ' '.$objp->ref.''; - print ' - '.nl2br($objp->product); + print ' - '.nl2br(stripslashes($objp->product)); if ($objp->date_start && $objp->date_end) { print ' (Du '.dolibarr_print_date($objp->date_start).' au '.dolibarr_print_date($objp->date_end).')'; @@ -1135,7 +1137,7 @@ else { print " (Jusqu'au ".dolibarr_print_date($objp->date_end).')'; } - print ($objp->description&&$objp->description!=$objp->product)?'
'.$objp->description:''; + print ($objp->description && $objp->description!=$objp->product)?'
'.$objp->description:''; print ''; } else @@ -1189,25 +1191,26 @@ else { print ''; print img_down(); - print ''; + print ''; } + print ''; } else { print ' '; } - print ""; + print ''; } - // Update ligne de facture - if ($_GET["action"] == 'editline' && $_GET["rowid"] == $objp->rowid) + // Ligne en mode update + if ($_GET["action"] == 'editline' && $user->rights->facture->creer && $_GET["rowid"] == $objp->rowid) { print '
'; print ''; print ''; print ''; - print ""; + print ''; print ''; if ($objp->fk_product > 0) { @@ -1220,8 +1223,7 @@ else } print ''; print ''; - //print $html->select_tva("tva_tx",$objp->tva_taux); - print $objp->tva_taux."%"; // Taux tva dépend du produit, donc on ne doit pas pouvoir le changer ici + print $html->select_tva("tva_tx",$objp->tva_taux); print ''; print ''; print ''; @@ -1316,7 +1318,7 @@ else { if ($user->rights->facture->valider) { - print " id."&action=valid\">".$langs->trans("Valid")."\n"; + print " id."&action=valid\">".$langs->trans("Validate")."\n"; } } else