From c0db3fe3227b08c0f60c95a3a048f2f7e7627b28 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 31 Jan 2005 18:47:14 +0000 Subject: [PATCH] =?UTF-8?q?New:=20Ajout=20lien=20suivant-pr=E9c=E9dent=20s?= =?UTF-8?q?ur=20pages=20des=20rapports=20mensuels.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/compta/resultat/index.php | 51 +++++++++++++++++--------------- 1 file changed, 27 insertions(+), 24 deletions(-) diff --git a/htdocs/compta/resultat/index.php b/htdocs/compta/resultat/index.php index b2b97e6ca97..f48e071302f 100644 --- a/htdocs/compta/resultat/index.php +++ b/htdocs/compta/resultat/index.php @@ -1,6 +1,6 @@ - * Copyright (C) 2004 Laurent Destailleur +/* Copyright (C) 2003 Rodolphe Quiedeville + * Copyright (C) 2004-2005 Laurent Destailleur * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -20,11 +20,25 @@ * $Source$ * */ + +/** + \file htdocs/compta/resultat/index.php + \brief Page reporting resultat + \version $Revision$ +*/ + require("./pre.inc.php"); -/* - * - */ +$year_start=isset($_GET["year_start"])?$_GET["year_start"]:$_POST["year_start"]; +$year_current = strftime("%Y",time()); +if (! $year_start) { + $year_start = $year_current - 2; + $year_end = $year_current; +} +else { + $year_end=$year_start+2; +} + llxHeader(); @@ -36,12 +50,13 @@ if ($user->societe_id > 0) $socidp = $user->societe_id; } -$year_current = $_GET["year"]; -if (! $year_current) { $year_current = strftime("%Y", time()); } $modecompta = $conf->compta->mode; if ($_GET["modecompta"]) $modecompta=$_GET["modecompta"]; -print_titre("Résultat comptable, résumé annuel"); + +$title="Résultat comptable, résumé annuel"; +$lien=($year_start?"".img_previous()." ".img_next()."":""); +print_fiche_titre($title,$lien); print '
'; print "Ce rapport présente la balance entre les recettes et les dépenses facturées aux clients ou fournisseurs. Les dépenses de charges ne sont pas incluses.
\n"; @@ -124,26 +139,14 @@ else { dolibarr_print_error($db); } -/* - * Charges sociales - */ +/* + * Tableau + */ print ''; print ''; - -if ($year_current < (MAIN_START_YEAR + 2)) -{ - $year_start = MAIN_START_YEAR; - $year_end = (MAIN_START_YEAR + 2); -} -else -{ - $year_start = $year_current - 2; - $year_end = $year_current; -} - for ($annee = $year_start ; $annee <= $year_end ; $annee++) { print ''; @@ -187,7 +190,7 @@ for ($mois = 1 ; $mois < 13 ; $mois++) } $var=!$var; -print ""; +print ""; for ($annee = $year_start ; $annee <= $year_end ; $annee++) { print '';
'.$langs->trans("Month").''.$annee.'
Total annuel
".$langs->trans("Total")."'.price($totentrees[$annee]).''.price($totsorties[$annee]).'