FIX #yogosha4430
This commit is contained in:
parent
d0c02f3714
commit
dec73da206
@ -47,7 +47,7 @@ if ($user->socid > 0)
|
|||||||
$dir = $conf->fournisseur->facture->dir_output.'/payments';
|
$dir = $conf->fournisseur->facture->dir_output.'/payments';
|
||||||
if (!$user->rights->societe->client->voir || $socid) $dir .= '/private/'.$user->id; // If user has no permission to see all, output dir is specific to user
|
if (!$user->rights->societe->client->voir || $socid) $dir .= '/private/'.$user->id; // If user has no permission to see all, output dir is specific to user
|
||||||
|
|
||||||
$year = $_GET["year"];
|
$year = GETPOST("year", 'int');
|
||||||
if (!$year) { $year = date("Y"); }
|
if (!$year) { $year = date("Y"); }
|
||||||
|
|
||||||
|
|
||||||
@ -69,7 +69,7 @@ if ($action == 'builddoc')
|
|||||||
// We save charset_output to restore it because write_file can change it if needed for
|
// We save charset_output to restore it because write_file can change it if needed for
|
||||||
// output format that does not support UTF8.
|
// output format that does not support UTF8.
|
||||||
$sav_charset_output = $outputlangs->charset_output;
|
$sav_charset_output = $outputlangs->charset_output;
|
||||||
if ($rap->write_file($dir, $_POST["remonth"], $_POST["reyear"], $outputlangs) > 0)
|
if ($rap->write_file($dir, GETPOST("remonth", 'int'), GETPOST("reyear", 'int'), $outputlangs) > 0)
|
||||||
{
|
{
|
||||||
$outputlangs->charset_output = $sav_charset_output;
|
$outputlangs->charset_output = $sav_charset_output;
|
||||||
} else {
|
} else {
|
||||||
@ -77,7 +77,7 @@ if ($action == 'builddoc')
|
|||||||
dol_print_error($db, $obj->error);
|
dol_print_error($db, $obj->error);
|
||||||
}
|
}
|
||||||
|
|
||||||
$year = $_POST["reyear"];
|
$year = GETPOST("reyear", 'int');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -27,6 +27,8 @@ require_once DOL_DOCUMENT_ROOT.'/reception/class/reception.class.php';
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/reception/class/receptionstats.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/reception/class/receptionstats.class.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/class/dolgraph.class.php';
|
||||||
|
|
||||||
|
$year = GETPOST("year", 'int');
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* View
|
* View
|
||||||
@ -39,10 +41,10 @@ $HEIGHT = DolGraph::getDefaultGraphSizeForStats('height');
|
|||||||
|
|
||||||
$mesg = '';
|
$mesg = '';
|
||||||
|
|
||||||
print load_fiche_titre($langs->trans("StatisticsOfReceptions").' '.$_GET["year"], $mesg);
|
print load_fiche_titre($langs->trans("StatisticsOfReceptions").' '.GETPOST("year", 'int'), $mesg);
|
||||||
|
|
||||||
$stats = new ReceptionStats($db);
|
$stats = new ReceptionStats($db);
|
||||||
$data = $stats->getNbReceptionByMonth($_GET["year"]);
|
$data = $stats->getNbReceptionByMonth(GETPOST("year", 'int'));
|
||||||
|
|
||||||
dol_mkdir($conf->reception->dir_temp);
|
dol_mkdir($conf->reception->dir_temp);
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user