';
+ print '';
print_titre(''.$langs->trans("Document").'');
@@ -665,7 +664,7 @@ if ($_GET["propalid"])
print '';
- $file = PROPALE_OUTPUTDIR . "/$propal->ref/$propal->ref.pdf";
+ $file = $conf->propal->dir_output . "/$propal->ref/$propal->ref.pdf";
if (file_exists($file))
{
print "| PDF | ";
@@ -765,7 +764,7 @@ if ($_GET["propalid"])
}
else
{
- print $db->error();
+ dolibarr_print_error($db);
}
/*
*
@@ -797,11 +796,12 @@ if ($_GET["propalid"])
print '';
print_titre("Envoyer la propale par mail");
+ $form=new Form($db);
// Formulaire envoi mail
print '";
+*/
+$form->mail_topicmessagefile(0,1,1,$message);
print "trans("Send")."\">";
print "";
@@ -916,7 +919,7 @@ else
print " propalid\">$objp->ref\n";
if ($objp->client == 1)
{
- $url ='fiche.php?socid='.$objp->idp;
+ $url = DOL_URL_ROOT.'/comm/fiche.php?socid='.$objp->idp;
}
else
{
diff --git a/htdocs/comm/propal/stats/index.php b/htdocs/comm/propal/stats/index.php
index 51c75972a8c..cf71aee1133 100644
--- a/htdocs/comm/propal/stats/index.php
+++ b/htdocs/comm/propal/stats/index.php
@@ -39,10 +39,10 @@ $stats = new PropaleStats($db);
$year = strftime("%Y", time());
$data = $stats->getNbByMonthWithPrevYear($year);
-if (! is_dir($conf->propale->dir_images)) { mkdir($conf->propale->dir_images); }
+if (! is_dir($conf->propal->dir_images)) { mkdir($conf->propal->dir_images); }
-$filename = $conf->propale->dir_images."/nbpropale2year-$year.png";
-$fileurl = $conf->propale->url_images."/nbpropale2year-$year.png";
+$filename = $conf->propal->dir_images."/nbpropale2year-$year.png";
+$fileurl = $conf->propal->url_images."/nbpropale2year-$year.png";
$px = new BarGraph($data);
$mesg = $px->isGraphKo();
diff --git a/htdocs/comm/propal/stats/month.php b/htdocs/comm/propal/stats/month.php
index 9b935258b9f..1d9ab61cc46 100644
--- a/htdocs/comm/propal/stats/month.php
+++ b/htdocs/comm/propal/stats/month.php
@@ -49,10 +49,10 @@ print_fiche_titre('Statistiques des propositions commerciales', $mesg);
$stats = new PropaleStats($db);
$data = $stats->getNbByMonth($year);
-if (! is_dir($conf->propale->dir_images)) { mkdir($conf->propale->dir_images); }
+if (! is_dir($conf->propal->dir_images)) { mkdir($conf->propal->dir_images); }
-$filename = $conf->propale->dir_images."/propale$year.png";
-$fileurl = $conf->propale->url_images."/propale$year.png";
+$filename = $conf->propal->dir_images."/propale$year.png";
+$fileurl = $conf->propal->url_images."/propale$year.png";
$px = new BarGraph($data);
$mesg = $px->isGraphKo();
@@ -72,8 +72,8 @@ for ($i = 1 ; $i < 13 ; $i++)
$data[$i-1] = array(strftime("%b",mktime(12,12,12,$i,1,$year)), $res[$i]);
}
-$filename_amount = $conf->propale->dir_images."/propaleamount$year.png";
-$fileurl_amount = $conf->propale->url_images."/propaleamount$year.png";
+$filename_amount = $conf->propal->dir_images."/propaleamount$year.png";
+$fileurl_amount = $conf->propal->url_images."/propaleamount$year.png";
$px = new BarGraph($data);
$mesg = $px->isGraphKo();
@@ -93,8 +93,8 @@ for ($i = 1 ; $i < 13 ; $i++)
$data[$i-1] = array(strftime("%b",mktime(12,12,12,$i,1,$year)), $res[$i]);
}
-$filename_avg = $conf->propale->dir_images."/propalaverage$year.png";
-$fileurl_avg = $conf->propale->url_images."/propalaverage$year.png";
+$filename_avg = $conf->propal->dir_images."/propalaverage$year.png";
+$fileurl_avg = $conf->propal->url_images."/propalaverage$year.png";
$px = new BarGraph($data);
$mesg = $px->isGraphKo();
diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php
index 6715dbc4e70..721cd33d4dd 100644
--- a/htdocs/master.inc.php
+++ b/htdocs/master.inc.php
@@ -306,10 +306,10 @@ if (defined("MAIN_MODULE_FACTURE"))
if (defined("MAIN_MODULE_PROPALE"))
{
$conf->propal->enabled=MAIN_MODULE_PROPALE;
- $conf->propale->dir_output=DOL_DATA_ROOT."/propale";
- if (defined(PROPALE_OUTPUTDIR) && PROPALE_OUTPUTDIR) { $conf->propale->dir_output=PROPALE_OUTPUTDIR; } # Pour passer outre le rep par défaut
- $conf->propale->dir_images=DOL_DOCUMENT_ROOT."/images/propale";
- $conf->propale->url_images=DOL_URL_ROOT."/images/propale";
+ $conf->propal->dir_output=DOL_DATA_ROOT."/propale";
+ if (defined(PROPALE_OUTPUTDIR) && PROPALE_OUTPUTDIR) { $conf->propal->dir_output=PROPALE_OUTPUTDIR; } # Pour passer outre le rep par défaut
+ $conf->propal->dir_images=DOL_DOCUMENT_ROOT."/images/propale";
+ $conf->propal->url_images=DOL_URL_ROOT."/images/propale";
require_once(DOL_DOCUMENT_ROOT ."/includes/modules/propale/modules_propale.php");
if (!defined("PROPALE_NEW_FORM_NB_PRODUCT"))
|
|