New: task #3370 : Changement de modle sur les factures la gnration
This commit is contained in:
parent
e283c1516c
commit
3673315c33
@ -605,7 +605,7 @@ if ($_REQUEST['action'] == 'builddoc') // En get ou en post
|
||||
{
|
||||
$outputlangs = new Translate(DOL_DOCUMENT_ROOT ."/langs");
|
||||
$outputlangs->setDefaultLang($_REQUEST['lang_id']);
|
||||
$result=facture_pdf_create($db, $_REQUEST['facid'], '', '', $outputlangs);
|
||||
$result=facture_pdf_create($db, $_REQUEST['facid'], '', $_REQUEST['model'], $outputlangs);
|
||||
if ($result <= 0)
|
||||
{
|
||||
exit;
|
||||
@ -1975,7 +1975,7 @@ else
|
||||
$var=true;
|
||||
|
||||
print '<br>';
|
||||
$html->show_documents('facture',$filename,$filedir,$urlsource,$genallowed,$delallowed);
|
||||
$html->show_documents('facture',$filename,$filedir,$urlsource,$genallowed,$delallowed,$conf->global->FACTURE_ADDON_PDF);
|
||||
|
||||
/*
|
||||
* Propales rattachées
|
||||
|
||||
@ -59,10 +59,12 @@ class ModelePDFFactures extends FPDF
|
||||
*/
|
||||
function liste_modeles($db)
|
||||
{
|
||||
$liste=array();
|
||||
$sql ="SELECT value, value from ".MAIN_DB_PREFIX."const";
|
||||
$sql.=" where name='FACTURE_ADDON_PDF'";
|
||||
|
||||
$type='invoice';
|
||||
$liste=array();
|
||||
$sql ="SELECT nom as id, nom as lib";
|
||||
$sql.=" FROM ".MAIN_DB_PREFIX."document_model";
|
||||
$sql.=" WHERE type = '".$type."'";
|
||||
|
||||
$resql = $db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user