Task #2128 : Comptabilité française : report, montre le solde de l'année
et depuis le début pour les fiches, postes en HTML et PDF
This commit is contained in:
parent
ded3cf9a27
commit
0219700f44
6 changed files with 55 additions and 5 deletions
|
|
@ -28,7 +28,7 @@ include_once("lib/ac_common.php");
|
|||
include_once("lib/impress.class.php");
|
||||
require_once NOALYSS_INCLUDE.'/header_print.php';
|
||||
$http=new HttpInput();
|
||||
|
||||
global $g_parameter;
|
||||
$f_id=$http->request("f_id", "number");
|
||||
$from_periode=$http->get("from_periode","date");
|
||||
$to_periode=$http->get("to_periode","date");
|
||||
|
|
@ -229,6 +229,19 @@ $pdf->write_cell(160,5,'Solde '.$solde,0,0,'R');
|
|||
$pdf->write_cell(30,5,$str_diff_solde,0,0,'R');
|
||||
$pdf->line_new();
|
||||
|
||||
// take saldo from 1st day until last
|
||||
if ($g_parameter->MY_REPORT=='N') {
|
||||
|
||||
$solde_until_now=$Fiche->get_solde_detail(" j_date <= to_date('$to_periode','DD.MM.YYYY') ");
|
||||
|
||||
$pdf->write_cell(40,5,"Solde global",0,0,'R');
|
||||
$pdf->write_cell(40,5,"D : ".nbm($solde_until_now['debit']),0,0,'R');
|
||||
$pdf->write_cell(40,5,"C : ".nbm($solde_until_now['credit']),0,0,'R');
|
||||
$pdf->write_cell(40,5,"Delta : ".nbm($solde_until_now['solde'])." ".$Fiche->get_amount_side($solde_until_now['debit']-$solde_until_now['credit']),0,0,'R');
|
||||
$pdf->line_new();
|
||||
|
||||
}
|
||||
|
||||
$fDate=date('dmy-Hi');
|
||||
$pdf->Output('fiche-'.$fDate.'.pdf','D');
|
||||
|
||||
|
|
|
|||
|
|
@ -25,6 +25,8 @@
|
|||
if ( ! defined ('ALLOWED') ) die('Appel direct ne sont pas permis');
|
||||
require_once NOALYSS_INCLUDE.'/lib/ac_common.php';
|
||||
require_once NOALYSS_INCLUDE.'/header_print.php';
|
||||
global $g_parameter;
|
||||
|
||||
$http=new HttpInput();
|
||||
|
||||
$poste_id=$http->request("poste_id");
|
||||
|
|
@ -32,7 +34,6 @@ $from_periode=$http->request("from_periode");
|
|||
$to_periode=$http->request("to_periode");
|
||||
$ople=$http->request("ople");
|
||||
$poste_fille=$http->request("poste_fille","string",-1);
|
||||
|
||||
$gDossier=dossier::id();
|
||||
|
||||
/* Security */
|
||||
|
|
@ -247,6 +248,18 @@ foreach ($a_poste as $poste)
|
|||
$pdf->write_cell(30,5,$str_diff_solde,0,0,'R');
|
||||
$pdf->line_new();
|
||||
|
||||
// take saldo from 1st day until last
|
||||
if ($g_parameter->MY_REPORT=='N') {
|
||||
|
||||
$solde_until_now=$Poste->get_solde_detail(" j_date <= to_date('$to_periode','DD.MM.YYYY') ");
|
||||
|
||||
$pdf->write_cell(40,5,"Solde global",0,0,'R');
|
||||
$pdf->write_cell(40,5,"D : ".nbm($solde_until_now['debit']),0,0,'R');
|
||||
$pdf->write_cell(40,5,"C : ".nbm($solde_until_now['credit']),0,0,'R');
|
||||
$pdf->write_cell(40,5,"Delta : ".nbm($solde_until_now['solde'])." ".$Poste->get_amount_side($solde_until_now['debit']-$solde_until_now['credit']),0,0,'R');
|
||||
$pdf->line_new();
|
||||
|
||||
}
|
||||
}
|
||||
$fDate=date('dmy-Hi');
|
||||
$pdf->Output('poste-'.$fDate.'-'.$poste_id.'.pdf','D');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue