dolibarr-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dolibarr-dev] ajout d'un paiement depuis une facture fournisseur


From: Christophe Combelles
Subject: [Dolibarr-dev] ajout d'un paiement depuis une facture fournisseur
Date: Sun, 26 Sep 2004 17:11:36 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20040924 Debian/1.7.3-2

Hello,

Voici un patch pour la création d'un paiement depuis une facture fournisseur. (variables POST/GET non récupérées dans fourn/facture/paiement.php)


Christophe
--- paiement.php.old    2004-09-26 16:55:48.000000000 +0200
+++ paiement.php        2004-09-26 16:37:02.000000000 +0200
@@ -24,6 +24,9 @@
 require("./pre.inc.php");
 require("./paiementfourn.class.php");
 
+$facid=isset($_GET["facid"])?$_GET["facid"]:$_POST["facid"];
+$action=isset($_GET["action"])?$_GET["action"]:$_POST["action"];
+
 /*
  * Sécurité accés client
  */
@@ -39,18 +42,18 @@
   $paiementfourn = new PaiementFourn($db);
 
   $paiementfourn->facid        = $facid;
-  $paiementfourn->facnumber    = $facnumber;
+  $paiementfourn->facnumber    = $_POST['facnumber'];
   $paiementfourn->datepaye     = $db->idate(mktime(12, 0 , 0,
                                              $_POST["remonth"], 
                                              $_POST["reday"], 
                                              $_POST["reyear"])); 
-  $paiementfourn->amount       = $amount;
-  $paiementfourn->accountid    = $accountid;
-  $paiementfourn->societe      = $societe;
-  $paiementfourn->author       = $author;
-  $paiementfourn->paiementid   = $paiementid;
-  $paiementfourn->num_paiement = $num_paiement;
-  $paiementfourn->note         = $note;
+  $paiementfourn->amount       = $_POST['amount'];
+  $paiementfourn->accountid    = $_POST['accountid'];
+  $paiementfourn->societe      = $_POST['societe'];
+  $paiementfourn->author       = $_POST['author'];
+  $paiementfourn->paiementid   = $_POST['paiementid'];
+  $paiementfourn->num_paiement = $_POST['num_paiement'];
+  $paiementfourn->note         = $_POST['note'];
 
   if ( $paiementfourn->create($user) )
     {

reply via email to

[Prev in Thread] Current Thread [Next in Thread]