fix: [ bug #272 ] Impossible afficher Créances-Dettes sur période

d'analyse choisie
This commit is contained in:
Laurent Destailleur 2012-01-14 13:45:42 +01:00
parent 9ea69cffb8
commit e528ac97a8
4 changed files with 16 additions and 13 deletions

View File

@ -87,7 +87,7 @@ else
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES') // Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
$modecompta = $conf->global->COMPTA_MODE; $modecompta = $conf->global->COMPTA_MODE;
if ($_GET["modecompta"]) $modecompta=$_GET["modecompta"]; if (GETPOST("modecompta")) $modecompta=GETPOST("modecompta");
@ -122,7 +122,7 @@ else {
$builddate=time(); $builddate=time();
//$exportlink=$langs->trans("NotYetAvailable"); //$exportlink=$langs->trans("NotYetAvailable");
} }
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink); report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,array('modecompta'=>$modecompta));
// Show report array // Show report array
print '<table class="noborder" width="100%">'; print '<table class="noborder" width="100%">';

View File

@ -45,7 +45,7 @@ accessforbidden();
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES') // Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
$modecompta = $conf->global->COMPTA_MODE; $modecompta = $conf->global->COMPTA_MODE;
if ($_GET["modecompta"]) $modecompta=$_GET["modecompta"]; if (GETPOST("modecompta")) $modecompta=GETPOST("modecompta");
@ -79,7 +79,7 @@ else {
$builddate=time(); $builddate=time();
//$exportlink=$langs->trans("NotYetAvailable"); //$exportlink=$langs->trans("NotYetAvailable");
} }
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink); report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,array('modecompta'=>$modecompta));
/* /*

View File

@ -78,7 +78,9 @@ else {
$builddate=time(); $builddate=time();
//$exportlink=$langs->trans("NotYetAvailable"); //$exportlink=$langs->trans("NotYetAvailable");
} }
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink); $moreparam=array();
if (! empty($modecompta)) $moreparam['modecompta']=$modecompta;
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$moreparam);
if ($modecompta == 'CREANCES-DETTES') if ($modecompta == 'CREANCES-DETTES')

View File

@ -25,14 +25,15 @@
/** /**
* Show header of a VAT report * Show header of a VAT report
* *
* @param $nom Name of report * @param string $nom Name of report
* @param $variante Link for alternate report * @param string $variante Link for alternate report
* @param $period Period of report * @param string $period Period of report
* @param $periodlink Link to switch period * @param string $periodlink Link to switch period
* @param $description Description * @param string $description Description
* @param $builddate Date generation * @param date $builddate Date generation
* @param $exportlink Link for export or '' * @param string $exportlink Link for export or ''
* @param $moreparam Array with list of params to add into form * @param array $moreparam Array with list of params to add into form
* @return void
*/ */
function report_header($nom,$variante='',$period,$periodlink,$description,$builddate,$exportlink='',$moreparam=array()) function report_header($nom,$variante='',$period,$periodlink,$description,$builddate,$exportlink='',$moreparam=array())
{ {