[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 52/162: Bug 1600 : alphanumeric accounting mu
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 52/162: Bug 1600 : alphanumeric accounting must be case insensitive |
Date: |
Sat, 11 Jul 2020 13:23:33 -0400 (EDT) |
sparkyx pushed a commit to annotated tag E-4
in repository noalyss.
commit f5f5e55296f8540fb021c669943359a34827a088
Author: Dany De Bontridder <danydb@noalyss.eu>
AuthorDate: Tue May 8 22:40:31 2018 +0200
Bug 1600 : alphanumeric accounting must be case insensitive
---
include/class/acc_account.class.php | 3 ++-
include/class/fiche.class.php | 4 ++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/include/class/acc_account.class.php
b/include/class/acc_account.class.php
index 68cb964..4a41f69 100644
--- a/include/class/acc_account.class.php
+++ b/include/class/acc_account.class.php
@@ -53,6 +53,7 @@ class Acc_Account
$this->db=$p_cn;
$id=-1;
if ( trim($pcm_val) != "" ) {
+ $pcm_val=mb_strtoupper($pcm_val);
$pcm_val=$this->db->get_value("select format_account($1)",
array($pcm_val));
$id=$p_cn->get_value("select id from tmp_pcmn where
pcm_val=$1",[$pcm_val]);
@@ -128,7 +129,7 @@ class Acc_Account
function verify() {
// check for Duplicate key, parent ... see Acc_Plan_MTable
$count=$this->data_sql->count(" where pcm_val =$1 and id <> $2",
- [$this->data_sql->pcm_val,$this->data_sql->id]);
+
[mb_strtoupper($this->data_sql->pcm_val),$this->data_sql->id]);
if ( $count > 0)
throw new Exception (_("Poste en double"),EXC_DUPLICATE);
diff --git a/include/class/fiche.class.php b/include/class/fiche.class.php
index 3c4d146..a989727 100644
--- a/include/class/fiche.class.php
+++ b/include/class/fiche.class.php
@@ -805,7 +805,7 @@ class Fiche
// account
if ($id==ATTR_DEF_ACCOUNT)
{
- $v=sql_string($value);
+ $v=mb_strtoupper(sql_string($value));
try
{
@@ -973,7 +973,7 @@ class Fiche
// account
if ($id==ATTR_DEF_ACCOUNT)
{
- $v=sql_string($value);
+ $v=mb_strtoupper(sql_string($value));
if (trim($v)!='')
{
if (strpos($v, ',')!=0)
- [Noalyss-commit] [noalyss] 42/162: remove debug, (continued)
- [Noalyss-commit] [noalyss] 42/162: remove debug, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 43/162: Missing ob_start, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 45/162: typo, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 39/162: integrate fix for bug in insert_quant_purchase which cannot save private fee, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 48/162: Protect function nb , return the string if the parameter is not a float, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 34/162: Task #448 : Currency : purchase, fix bug for autoreverse VAT, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 37/162: comment, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 46/162: Task #448 : add currency to card -> history + export CSV, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 50/162: Create invoice : New version of libreoffice use the numeric in another way, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 55/162: Security : direct injection, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 52/162: Bug 1600 : alphanumeric accounting must be case insensitive,
Dany De Bontridder <=
- [Noalyss-commit] [noalyss] 56/162: Fix : security fixes see rapport exakat (Damien Seguy), Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 57/162: Security fix : f_id is a number, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 62/162: Merge master, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 38/162: Task #448 : currency improve detail of operation, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 40/162: Fix bug quant_purchase , private fee not saved, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 44/162: Task #448 : add info about currency into History of cards and accounting, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 47/162: Update documentation, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 54/162: Fix todo_list : if list empty , gets an error in php 7.2, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 49/162: New version of libreoffice use the numeric in another way, Dany De Bontridder, 2020/07/11
- [Noalyss-commit] [noalyss] 51/162: Missing class : missing class for acc_ledger, Dany De Bontridder, 2020/07/11