[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 152/238: New function findSide return D if nu
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 152/238: New function findSide return D if number is <0 |
Date: |
Sat, 26 Oct 2019 04:40:55 -0400 (EDT) |
sparkyx pushed a commit to annotated tag rel7110
in repository noalyss.
commit 7b488dfd3964fbf6877b95d222fb6a4876093e03
Author: Dany De Bontridder <address@hidden>
Date: Tue Jan 8 17:53:22 2019 +0100
New function findSide return D if number is <0
---
include/lib/ac_common.php | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/include/lib/ac_common.php b/include/lib/ac_common.php
index c57d20a..ca7d654 100644
--- a/include/lib/ac_common.php
+++ b/include/lib/ac_common.php
@@ -114,6 +114,22 @@ function nb($p_number)
}
/**
+ * return D if the number is smaller than 0 , C if bigger and an empty string
if
+ * equal to 0. Used for displaying saldo D / C (debit / credit )
+ * @param float $p_number
+ */
+function findSide($p_number)
+{
+ $return ='';
+ if ( $p_number > 0 ) {
+ $return ='D';
+ }else {
+ $return =($p_number== 0)?"":"C";
+ }
+ return $return;
+}
+
+/**
* format the number with a sep. for the thousand
* @param $p_number number
* @param $p_dec number of decimal to display
- [Noalyss-commit] [noalyss] 237/238: Acc_Ledger : problem with acc_ledger::load(), (continued)
- [Noalyss-commit] [noalyss] 237/238: Acc_Ledger : problem with acc_ledger::load(), Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 229/238: Task #1759 = PRINTBAL sur 4 colonnes, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 224/238: Improve PHPUNIT Test for phpunit7 and phpunit8, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 91/238: PHP 7.2 : fix incomptability, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 117/238: Currency : cosmetic display history : show only the value of the card/accounting, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 138/238: Translation, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 122/238: Currency : display correctly the saldo at the end / beginning operation, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 130/238: typo doc, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 123/238: Currency = payment automatic for Sales and Purchases, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 147/238: Currency : detail operation Purchase , the amount in currency were wrong in the summary, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 152/238: New function findSide return D if number is <0,
Dany De Bontridder <=
- [Noalyss-commit] [noalyss] 168/238: translation, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 174/238: Merge branch 'r700-currency' of gitlab.noalyss.eu:noalyss/noalyss into r700-currency, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 193/238: Php7.2 incompatibility, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 176/238: Mantis #1626: AFFICHAGE BALANCE FICHE - soldes nuls au débit, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 192/238: Mantis #0001618: Journaux - choix du type en premier, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 195/238: mantis #1690: Bug : impossible d'utiliser < dans Inplace_Edit Replace strip_tags , add a space before the "<", Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 228/238: Bug with p_jrn, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 223/238: Task #0001703: Faciliter effacement montants dans les filtres, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 234/238: fixup! Printtva , under some circumstance tva_summary::check fails, Dany De Bontridder, 2019/10/26
- [Noalyss-commit] [noalyss] 201/238: Merge branch 'dev7109' into entreprise, Dany De Bontridder, 2019/10/26