diff --git a/htdocs/compta/resultat/projects.php b/htdocs/compta/resultat/projects.php index 7c69b13562e..491d0bbe74a 100644 --- a/htdocs/compta/resultat/projects.php +++ b/htdocs/compta/resultat/projects.php @@ -11,6 +11,7 @@ * Copyright (C) 2020 Maxime DEMAREST * Copyright (C) 2021-2024 Alexandre Spangaro * Copyright (C) 2024 Yoan Mollard + * Copyright (C) 2026 MDW * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -215,7 +216,7 @@ if ($modecompta == "CREANCES-DETTES") { } elseif ($modecompta == "BOOKKEEPING") { $name = $langs->trans("ReportInOut").', '.$langs->trans("ByProjects"); $period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); - $arraylist = array('no'=>$langs->trans("CustomerCode"), 'yes'=>$langs->trans("AccountWithNonZeroValues"), 'all'=>$langs->trans("All")); + $arraylist = array('no' => $langs->trans("CustomerCode"), 'yes' => $langs->trans("AccountWithNonZeroValues"), 'all' => $langs->trans("All")); $period .= '     '.$langs->trans("DetailBy").' '.$form->selectarray('showaccountdetail', $arraylist, $showaccountdetail, 0); $periodlink = ($year_start ? "".img_previous()." ".img_next()."" : ""); $description = $langs->trans("RulesAmountOnInOutBookkeepingRecord"); @@ -243,7 +244,7 @@ if (isModEnabled('accounting')) { } $calcmode .= ''; -report_header($name, '', $period, $periodlink, $description, $builddate, $exportlink, array('modecompta'=>$modecompta, 'showaccountdetail'=>$showaccountdetail), $calcmode); +report_header($name, '', $period, $periodlink, $description, $builddate, $exportlink, array('modecompta' => $modecompta, 'showaccountdetail' => $showaccountdetail), $calcmode); /* if (isModEnabled('accounting') && $modecompta != 'BOOKKEEPING') { @@ -378,7 +379,7 @@ if (isModEnabled('invoice') && ($modecompta == 'CREANCES-DETTES' || $modecompta } if ($modecompta == 'CREANCES-DETTES') { // In mode payment, we can't filter on date of invoice that is different than date of payment. $detailed_list_url = ''; - $detailed_list_url .= empty($objp->project_ref)? "?search_project_ref=^$": "?search_project_ref=".urlencode($objp->project_ref); + $detailed_list_url .= empty($objp->project_ref) ? "?search_project_ref=^$" : "?search_project_ref=".urlencode($objp->project_ref); $detailed_list_url .= $search_date_url; echo ' ('.$langs->trans("DetailedListLowercase").")\n"; } @@ -479,7 +480,7 @@ if (isModEnabled('invoice') && ($modecompta == 'CREANCES-DETTES' || $modecompta echo ''; echo ' '; - $project_ref = empty($obj->project_ref)? $langs->trans("None"): $obj->project_ref; + $project_ref = empty($obj->project_ref) ? $langs->trans("None") : $obj->project_ref; echo "".$langs->trans("Project").' '.$project_ref."\n"; echo ''; @@ -583,7 +584,7 @@ if (isModEnabled('invoice') && ($modecompta == 'CREANCES-DETTES' || $modecompta } $detailed_list_url = ''; //$detailed_list_url .= '?search_project='.urlencode($search_project_ref); - $detailed_list_url .= empty($objp->project_ref)? "?search_project_ref=^$": '?search_project_ref='.urlencode($objp->project_ref); + $detailed_list_url .= empty($objp->project_ref) ? "?search_project_ref=^$" : '?search_project_ref='.urlencode($objp->project_ref); $detailed_list_url .= $search_date_url; echo ' ('.$langs->trans("DetailedListLowercase").")\n"; echo "\n"; @@ -1005,6 +1006,7 @@ if (isModEnabled('invoice') && ($modecompta == 'CREANCES-DETTES' || $modecompta $action = "balanceclient"; $object = array(&$total_ht, &$total_ttc); +$parameters = array(); $parameters["mode"] = $modecompta; $parameters["date_start"] = $date_start; $parameters["date_end"] = $date_end; diff --git a/htdocs/core/tpl/list_print_total.tpl.php b/htdocs/core/tpl/list_print_total.tpl.php index 824d0f2a203..ef6d1fdd914 100644 --- a/htdocs/core/tpl/list_print_total.tpl.php +++ b/htdocs/core/tpl/list_print_total.tpl.php @@ -36,6 +36,7 @@ @phan-var-force array{nbfield:int,type?:array,pos?:array,val?:array} $totalarray @phan-var-force string $sql @phan-var-force ?string $sqlfields +@phan-var-force int $num @phan-var-force ?int $limit '; diff --git a/htdocs/core/triggers/interface_95_modWebhook_WebhookTriggers.class.php b/htdocs/core/triggers/interface_95_modWebhook_WebhookTriggers.class.php index 77074431854..b6bced23bd2 100644 --- a/htdocs/core/triggers/interface_95_modWebhook_WebhookTriggers.class.php +++ b/htdocs/core/triggers/interface_95_modWebhook_WebhookTriggers.class.php @@ -1,6 +1,7 @@ * Copyright (C) 2023 William Mead + * Copyright (C) 2026 MDW * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -157,7 +158,7 @@ class InterfaceWebhookTriggers extends DolibarrTriggers } if (empty($dbhistory)) { - $dbhistory = getDoliDBInstance($conf->db->type, $conf->db->host, (string) $conf->db->user, $dolibarr_main_db_pass, $conf->db->name, (int) $conf->db->port); + $dbhistory = getDoliDBInstance($conf->db->type, $conf->db->host, (string) $conf->db->user, $dolibarr_main_db_pass, (string) $conf->db->name, (int) $conf->db->port); } $dbhistory->begin();