/[dolibarr]/dolibarr/htdocs/fourn/fournisseur.class.php
ViewVC logotype

Diff of /dolibarr/htdocs/fourn/fournisseur.class.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5 by eldy, Sun Sep 11 16:51:41 2005 UTC revision 1.6 by eldy, Mon Oct 10 19:48:22 2005 UTC
# Line 103  class Fournisseur extends Societe { Line 103  class Fournisseur extends Societe {
103    
104    }    }
105    
   function create_commande($user)  
   {  
     $result = -1;  
     dolibarr_syslog("Fournisseur::Create_Commande");  
     $comm = new CommandeFournisseur($this->db);  
     $comm->soc_id = $this->id;  
   
     if ( $comm->create($user) == 0 )  
       {  
         dolibarr_syslog("Fournisseur::Create_Commande : Success");  
106    
107          $this->single_open_commande = $comm->id;      /**
108         *      \brief      Créé la commande au statut brouillon
109         *      \param      user        Utilisateur qui crée
110         *      \return     int         <0 si ko, id de la commande créée si ok
111         */
112        function create_commande($user)
113        {
114            dolibarr_syslog("Fournisseur::Create_Commande");
115            $comm = new CommandeFournisseur($this->db);
116            $comm->soc_id = $this->id;
117        
118            if ($comm->create($user) > 0)
119            {
120                dolibarr_syslog("Fournisseur::Create_Commande : Success");
121                $this->single_open_commande = $comm->id;
122        
123                return $comm->id;
124            }
125            else
126            {
127                dolibarr_syslog("Fournisseur::Create_Commande : Failed");
128                return -1;
129            }
130        }
131    
         $result = 0;  
       }  
     else  
       {  
         dolibarr_syslog("Fournisseur::Create_Commande : Failed");  
         $result = -2;  
       }  
   
     return $result;  
   }  
132    
133    function ProductCommande($user, $product_id)    function ProductCommande($user, $product_id)
134    {    {

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26