Ajout onglet aperu sur la fiche commande client

This commit is contained in:
Regis Houssin
2006-02-09 13:35:26 +00:00
parent a0ef7174b8
commit 3d7f0402bb

View File

@@ -545,6 +545,33 @@ class Commande
return -1;
}
}
/*
*
*
*
*/
function set_pdf_model($user, $modelpdf)
{
if ($user->rights->commande->creer)
{
$sql = "UPDATE ".MAIN_DB_PREFIX."commande SET model_pdf = '$modelpdf'";
$sql .= " WHERE rowid = $this->id AND fk_statut = 0 ;";
if ($this->db->query($sql) )
{
return 1;
}
else
{
dolibarr_print_error($this->db);
return 0;
}
}
}
/**
*
*