function add()
 {
     $this->datecrea = date('Y-m-d H:i:s');
     $this->id = parent::add();
     $this->ref = date("ymdHi") . genid($this->id, 6);
     $this->maj();
     return $this->id;
 }
 function add()
 {
     $this->date = date("Y-m-d H:i:s");
     $this->id = parent::add();
     $this->ref = "C" . date("ymdHi") . genid($this->id, 6);
     $this->livraison = "L" . date("ymdHi") . genid($this->id, 6);
     $this->maj();
     return $this->id;
 }
 public function add()
 {
     unset(self::$_cache[$this->nom]);
     return parent::add();
 }
 public function add()
 {
     $this->before_add();
     return parent::add();
 }