[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 40/54: Task #1759 = PRINTBAL sur 4 colonnes
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 40/54: Task #1759 = PRINTBAL sur 4 colonnes |
Date: |
Sat, 11 Jul 2020 13:26:58 -0400 (EDT) |
sparkyx pushed a commit to annotated tag entreprise-0500
in repository noalyss.
commit d48cffe4aa005150ad291a87acc50ddfd2e10094
Author: Dany De Bontridder <danydb@noalyss.eu>
AuthorDate: Fri Oct 11 19:39:12 2019 +0200
Task #1759 = PRINTBAL sur 4 colonnes
---
include/export/export_balance_csv.php | 21 ++++++++++++++-------
1 file changed, 14 insertions(+), 7 deletions(-)
diff --git a/include/export/export_balance_csv.php
b/include/export/export_balance_csv.php
index 2201270..0d174e9 100644
--- a/include/export/export_balance_csv.php
+++ b/include/export/export_balance_csv.php
@@ -27,6 +27,8 @@ include_once ("lib/ac_common.php");
include_once("class/acc_balance.class.php");
require_once NOALYSS_INCLUDE.'/class/database.class.php';
require_once NOALYSS_INCLUDE.'/class/dossier.class.php';
+
+$http=new HttpInput();
$gDossier=dossier::id();
require_once NOALYSS_INCLUDE.'/class/acc_ledger.class.php';
@@ -38,7 +40,8 @@ $http=new HttpInput();
$export=new Noalyss_Csv('balance');
$bal=new Acc_Balance($cn);
$bal->jrn=null;
-switch( $_GET['p_filter'])
+$p_filter=$http->get("p_filter");
+switch( $p_filter)
{
case 0:
$bal->jrn=null;
@@ -46,7 +49,7 @@ case 0:
case 1:
if ( isset($_GET['r_jrn']))
{
- $selected=$http->get('r_jrn','number');
+ $selected=$http->get('r_jrn');
$array_ledger=$g_user->get_ledger('ALL',3);
$array=get_array_column($array_ledger,'jrn_def_id');
for ($e=0;$e<count($selected);$e++)
@@ -73,7 +76,7 @@ $row=$bal->get_row($http->get('from_periode','number'),
$prev = ( isset ($row[0]['sum_cred_previous'])) ?1:0;
$title=array('poste','libelle');
if ($prev == 1 ) $title=array_merge($title,array('deb n-1','cred n-1','solde
n-1','d/c;'));
-$title=array_merge($title,array(_('deb'),_('cred'),_('solde'),_('d/c')));
+$title=array_merge($title,array(_('Débit'),_('Crédit'),_("Solde
débiteur"),_("Solde créditeur")));
$export->send_header();
$pstart = new Periode($cn,$http->get("from_periode"));
@@ -100,12 +103,16 @@ foreach ($row as $r)
}
$delta=bcsub($r['solde_deb'],$r['solde_cred']);
- $sign=($delta<0)?'C':'D';
- $sign=($delta == 0)?'=':$sign;
$export->add($r['sum_deb'],"number");
$export->add($r['sum_cred'],"number");
- $export->add(abs($delta),"number");
- $export->add($sign);
+
+ if ( $delta < 0 ){
+ $export->add("0","number");
+ $export->add(abs($delta),"number");
+ }else {
+ $export->add(abs($delta),"number");
+ $export->add("0","number");
+ }
$export->write();
}
- [Noalyss-commit] [noalyss] 30/54: Merge branch 'Cosmetic-7100' into 'entreprise', (continued)
- [Noalyss-commit] [noalyss] 30/54: Merge branch 'Cosmetic-7100' into 'entreprise', Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 29/54: Merge branch 'accept7100' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 31/54: Merge branch 'entreprise' of gitlab.noalyss.eu:noalyss/noalyss into entreprise * index.css logo size, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 33/54: Task #0001698: Problème affichage historique fiches, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 26/54: Merge branch 'accept7100' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 32/54: task #0001698: Problème affichage historique fiches Prevent direct use of http_request translation Cosmetic, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 34/54: Task #0001703: Faciliter effacement montants dans les filtres, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 35/54: Improve PHPUNIT Test for phpunit7 and phpunit8, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 38/54: Merge branch 'accept7100' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 39/54: Bug with p_jrn, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 40/54: Task #1759 = PRINTBAL sur 4 colonnes,
Dany De Bontridder <=
- [Noalyss-commit] [noalyss] 44/54: gitlab #5 Achat propose l'anc pour toutes les lignes, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 36/54: documentation + traduction, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 37/54: Merge branch 'accept7100' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 41/54: Merge branch 'bug-printtva' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 42/54: If currency not given then supposed to be the default one (id=0), Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 43/54: Save_form_plan must use the array, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 49/54: Adapt printtva to entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 52/54: test : find the accounting with the biggest number of records, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 47/54: Merge branch 'dev7102' into entreprise, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 48/54: Acc_Ledger : problem with acc_ledger::load(), Dany De Bontridder, 2020/07/11