From b8de54aac02bbe71f2d9fa75e1f8ed83ef97097b Mon Sep 17 00:00:00 2001
From: BENKE Charlene <1179011+defrance@users.noreply.github.com>
Date: Mon, 30 May 2022 08:08:28 +0200
Subject: [PATCH 1/5] php V8 warning
---
htdocs/accountancy/index.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/htdocs/accountancy/index.php b/htdocs/accountancy/index.php
index 18277eb6751..99ae0bd845b 100644
--- a/htdocs/accountancy/index.php
+++ b/htdocs/accountancy/index.php
@@ -86,7 +86,7 @@ if (!empty($conf->global->INVOICE_USE_SITUATION) && $conf->global->INVOICE_USE_S
print ''.$langs->trans("SorryThisModuleIsNotCompatibleWithTheExperimentalFeatureOfSituationInvoices")."\n";
print "
";
-} elseif ($conf->accounting->enabled) {
+} elseif (!empty($conf->accounting->enabled)) {
$step = 0;
$resultboxes = FormOther::getBoxesArea($user, "27"); // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb)
From 7dc93b35444f94c55b6b9e25876042d36f07ea93 Mon Sep 17 00:00:00 2001
From: BENKE Charlene <1179011+defrance@users.noreply.github.com>
Date: Mon, 30 May 2022 08:23:35 +0200
Subject: [PATCH 2/5] php v8 warning
---
htdocs/compta/stats/index.php | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/htdocs/compta/stats/index.php b/htdocs/compta/stats/index.php
index e7ec8c61db7..f7b0bc215e1 100644
--- a/htdocs/compta/stats/index.php
+++ b/htdocs/compta/stats/index.php
@@ -144,6 +144,8 @@ llxHeader();
$form = new Form($db);
+$exportlink="";
+$namelink="";
// Affiche en-tete du rapport
if ($modecompta == "CREANCES-DETTES") {
$name = $langs->trans("Turnover");
@@ -254,6 +256,11 @@ $sql .= " ORDER BY dm";
$minyearmonth = $maxyearmonth = 0;
+$cum = Array();
+$cum_ht = Array();
+$total_ht = Array();
+$total = Array();
+
$result = $db->query($sql);
if ($result) {
$num = $db->num_rows($result);
@@ -395,6 +402,12 @@ for ($mois = 1 + $nb_mois_decalage; $mois <= 12 + $nb_mois_decalage; $mois++) {
$case = dol_print_date(dol_mktime(1, 1, 1, $mois_modulo, 1, $annee_decalage), "%Y-%m");
$caseprev = dol_print_date(dol_mktime(1, 1, 1, $mois_modulo, 1, $annee_decalage - 1), "%Y-%m");
+ $total_ht[$annee]=0;
+ $total[$annee]=0;
+ $cum_ht[$case]=0;
+ $cum[$case]=0;
+
+
if ($annee >= $year_start) { // We ignore $annee < $year_start, we loop on it to be able to make delta, nothing is output.
if ($modecompta == 'CREANCES-DETTES') {
// Value turnover of month w/o VAT
From 2b76e67d427c16dc4bf7769c603faa2643631a84 Mon Sep 17 00:00:00 2001
From: BENKE Charlene <1179011+defrance@users.noreply.github.com>
Date: Mon, 30 May 2022 08:31:38 +0200
Subject: [PATCH 3/5] php V8 warning
---
htdocs/compta/stats/casoc.php | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/htdocs/compta/stats/casoc.php b/htdocs/compta/stats/casoc.php
index 0bef7ff555a..1df7ae4db62 100644
--- a/htdocs/compta/stats/casoc.php
+++ b/htdocs/compta/stats/casoc.php
@@ -179,6 +179,7 @@ $allparams = array_merge($commonparams, $headerparams, $tableparams);
$headerparams = array_merge($commonparams, $headerparams);
$tableparams = array_merge($commonparams, $tableparams);
+$paramslink="";
foreach ($allparams as $key => $value) {
$paramslink .= '&'.$key.'='.$value;
}
@@ -202,6 +203,9 @@ if ($modecompta == "BOOKKEEPINGCOLLECTED") {
$modecompta = "RECETTES-DEPENSES";
}
+$exportlink="";
+$namelink="";
+
// Show report header
if ($modecompta == "CREANCES-DETTES") {
$name = $langs->trans("Turnover").', '.$langs->trans("ByThirdParties");
From e8bc813a43ba86d1702680d73aeb638db22a6a2d Mon Sep 17 00:00:00 2001
From: stickler-ci
Date: Mon, 30 May 2022 06:36:37 +0000
Subject: [PATCH 4/5] Fixing style errors.
---
htdocs/compta/stats/index.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/htdocs/compta/stats/index.php b/htdocs/compta/stats/index.php
index f7b0bc215e1..8da07e6c860 100644
--- a/htdocs/compta/stats/index.php
+++ b/htdocs/compta/stats/index.php
@@ -407,7 +407,7 @@ for ($mois = 1 + $nb_mois_decalage; $mois <= 12 + $nb_mois_decalage; $mois++) {
$cum_ht[$case]=0;
$cum[$case]=0;
-
+
if ($annee >= $year_start) { // We ignore $annee < $year_start, we loop on it to be able to make delta, nothing is output.
if ($modecompta == 'CREANCES-DETTES') {
// Value turnover of month w/o VAT
From 93499d611c874adf83165baae5c6189c214009f3 Mon Sep 17 00:00:00 2001
From: Laurent Destailleur
Date: Wed, 1 Jun 2022 21:57:03 +0200
Subject: [PATCH 5/5] Update index.php
---
htdocs/compta/stats/index.php | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/htdocs/compta/stats/index.php b/htdocs/compta/stats/index.php
index 8da07e6c860..b99002fe609 100644
--- a/htdocs/compta/stats/index.php
+++ b/htdocs/compta/stats/index.php
@@ -256,10 +256,10 @@ $sql .= " ORDER BY dm";
$minyearmonth = $maxyearmonth = 0;
-$cum = Array();
-$cum_ht = Array();
-$total_ht = Array();
-$total = Array();
+$cum = array();
+$cum_ht = array();
+$total_ht = array();
+$total = array();
$result = $db->query($sql);
if ($result) {