diff --git a/htdocs/accountancy/admin/report_list.php b/htdocs/accountancy/admin/report_list.php
index b7bac53db41..85208e80d1e 100644
--- a/htdocs/accountancy/admin/report_list.php
+++ b/htdocs/accountancy/admin/report_list.php
@@ -742,7 +742,7 @@ if ($resql) {
// Active
print '
';
if ($canbedisabled) {
- print ''.$actl[$obj->active].'';
+ print ''.$actl[$obj->active].'';
} else {
print $langs->trans("AlwaysActive");
}
@@ -796,12 +796,8 @@ $db->close();
*/
function fieldListAccountingReport($fieldlist, $obj = null, $tabname = '', $context = '')
{
- global $db;
global $form, $mysoc;
- $formadmin = new FormAdmin($db);
- $formcompany = new FormCompany($db);
-
foreach ($fieldlist as $field => $value) {
if ($fieldlist[$field] == 'country') {
print ' | ';
diff --git a/htdocs/adherents/class/adherent.class.php b/htdocs/adherents/class/adherent.class.php
index 96a9cf398e4..4c5703e4540 100644
--- a/htdocs/adherents/class/adherent.class.php
+++ b/htdocs/adherents/class/adherent.class.php
@@ -1836,6 +1836,13 @@ class Adherent extends CommonObject
}
}
$invoice->socid = $this->fk_soc;
+ // set customer's bank account on the invoice
+ if (!empty($customer->fk_account)) {
+ $invoice->fk_account = $customer->fk_account;
+ } elseif (getDolGlobalString('FACTURE_RIB_NUMBER')) {
+ // set default bank account from invoice module settings
+ $invoice->fk_account = (int) getDolGlobalString('FACTURE_RIB_NUMBER');
+ }
//$invoice->date = $datesubscription;
$invoice->date = dol_now();
diff --git a/htdocs/admin/delivery.php b/htdocs/admin/delivery.php
index d66b1af0d9e..97608479ae5 100644
--- a/htdocs/admin/delivery.php
+++ b/htdocs/admin/delivery.php
@@ -235,8 +235,8 @@ if (!getDolGlobalString('MAIN_SUBMODULE_DELIVERY')) {
print ' '.img_picto($langs->trans("Enabled"), 'switch_on').'';
}
-print ' '.info_admin($langs->trans("NoNeedForDeliveryReceipts"), 0, 1).'';
-print ' ';
+print '
'.info_admin($langs->trans("NoNeedForDeliveryReceipts"), 0, 1).'';
+print '
';
print ' ';
diff --git a/htdocs/commande/list.php b/htdocs/commande/list.php
index 0cb24104d9e..659c2781e97 100644
--- a/htdocs/commande/list.php
+++ b/htdocs/commande/list.php
@@ -224,7 +224,7 @@ $arrayfields = array(
'c.multicurrency_total_ht' => array('label' => 'MulticurrencyAmountHT', 'checked' => 0, 'enabled' => (!isModEnabled("multicurrency") ? 0 : 1), 'position' => 100),
'c.multicurrency_total_vat' => array('label' => 'MulticurrencyAmountVAT', 'checked' => 0, 'enabled' => (!isModEnabled("multicurrency") ? 0 : 1), 'position' => 105),
'c.multicurrency_total_ttc' => array('label' => 'MulticurrencyAmountTTC', 'checked' => 0, 'enabled' => (!isModEnabled("multicurrency") ? 0 : 1), 'position' => 110),
- 'u.login' => array('label' => "Author", 'checked' => 1, 'position' => 115),
+ 'u.login' => array('label' => "Author", 'checked' => -1, 'position' => 115),
'sale_representative' => array('label' => "SaleRepresentativesOfThirdParty", 'checked' => 0, 'position' => 116),
'total_pa' => array('label' => (getDolGlobalString('MARGIN_TYPE') == '1' ? 'BuyingPrice' : 'CostPrice'), 'checked' => 0, 'position' => 300, 'enabled' => (!isModEnabled('margin') || !$user->hasRight("margins", "liretous") ? 0 : 1)),
'total_margin' => array('label' => 'Margin', 'checked' => 0, 'position' => 301, 'enabled' => (!isModEnabled('margin') || !$user->hasRight("margins", "liretous") ? 0 : 1)),
@@ -2569,7 +2569,7 @@ while ($i < $imaxinloop) {
// Author
if (!empty($arrayfields['u.login']['checked'])) {
- print ' | ';
+ print ' | ';
if ($userstatic->id) {
print $userstatic->getNomUrl(-1);
} else {
diff --git a/htdocs/compta/cashcontrol/cashcontrol_list.php b/htdocs/compta/cashcontrol/cashcontrol_list.php
index e3ddf77133e..a9dbd994ebe 100644
--- a/htdocs/compta/cashcontrol/cashcontrol_list.php
+++ b/htdocs/compta/cashcontrol/cashcontrol_list.php
@@ -344,7 +344,7 @@ if ($num == 1 && getDolGlobalString('MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE') && $s
// Output page
// --------------------------------------------------------------------
-llxHeader('', $title, $help_url, '', 0, 0, '', '', '', 'classforhorizontalscrolloftabs');
+llxHeader('', $title, $help_url, '', 0, 0, '', '', '', 'bodyforlist');
$arrayofselected = is_array($toselect) ? $toselect : array();
@@ -497,7 +497,7 @@ foreach ($object->fields as $key => $val) {
$formadmin = new FormAdmin($db);
print $formadmin->select_language((isset($search[$key]) ? $search[$key] : ''), 'search_lang', 0, array(), 1, 0, 0, 'minwidth100imp maxwidth125', 2);
} else {
- print '';
+ print '';
}
print ' | ';
}
diff --git a/htdocs/compta/cashcontrol/class/cashcontrol.class.php b/htdocs/compta/cashcontrol/class/cashcontrol.class.php
index a8ab833cde1..d2bbbf5b545 100644
--- a/htdocs/compta/cashcontrol/class/cashcontrol.class.php
+++ b/htdocs/compta/cashcontrol/class/cashcontrol.class.php
@@ -76,7 +76,7 @@ class CashControl extends CommonObject
'entity' => array('type' => 'integer', 'label' => 'Entity', 'enabled' => 1, 'visible' => 0, 'notnull' => 1, 'position' => 15),
'ref' => array('type' => 'varchar(64)', 'label' => 'Ref', 'enabled' => 1, 'visible' => 1, 'notnull' => 1, 'position' => 18),
'posmodule' => array('type' => 'varchar(30)', 'label' => 'Module', 'enabled' => 1, 'visible' => 1, 'notnull' => 1, 'position' => 19),
- 'posnumber' => array('type' => 'varchar(30)', 'label' => 'Terminal', 'enabled' => 1, 'visible' => 1, 'notnull' => 1, 'position' => 20, 'css' => 'center'),
+ 'posnumber' => array('type' => 'varchar(30)', 'label' => 'Terminal', 'enabled' => 1, 'visible' => 1, 'notnull' => 1, 'position' => 20, 'csslist' => 'width50 center'),
'label' => array('type' => 'varchar(255)', 'label' => 'Label', 'enabled' => 1, 'visible' => 0, 'position' => 24),
'opening' => array('type' => 'price', 'label' => 'Opening', 'enabled' => 1, 'visible' => 1, 'position' => 25, 'csslist' => 'amount'),
'cash' => array('type' => 'price', 'label' => 'Cash', 'enabled' => 1, 'visible' => 1, 'position' => 30, 'csslist' => 'amount'),
diff --git a/htdocs/compta/localtax/clients.php b/htdocs/compta/localtax/clients.php
index 1fd89b74965..2a32737c487 100644
--- a/htdocs/compta/localtax/clients.php
+++ b/htdocs/compta/localtax/clients.php
@@ -36,6 +36,7 @@ require_once DOL_DOCUMENT_ROOT.'/compta/localtax/class/localtax.class.php';
* @var Conf $conf
* @var DoliDB $db
* @var HookManager $hookmanager
+ * @var Societe $mysoc
* @var Translate $langs
* @var User $user
*/
diff --git a/htdocs/compta/localtax/index.php b/htdocs/compta/localtax/index.php
index 8641dd247ca..9dea8b1c87a 100644
--- a/htdocs/compta/localtax/index.php
+++ b/htdocs/compta/localtax/index.php
@@ -37,6 +37,7 @@ require_once DOL_DOCUMENT_ROOT.'/compta/localtax/class/localtax.class.php';
* @var Conf $conf
* @var DoliDB $db
* @var HookManager $hookmanager
+ * @var Societe $mysoc
* @var Translate $langs
* @var User $user
*/
diff --git a/htdocs/compta/resultat/clientfourn.php b/htdocs/compta/resultat/clientfourn.php
index 77adb2a2bc7..7885424ffe4 100644
--- a/htdocs/compta/resultat/clientfourn.php
+++ b/htdocs/compta/resultat/clientfourn.php
@@ -3,7 +3,7 @@
* Copyright (C) 2004-2017 Laurent Destailleur
* Copyright (C) 2005-2012 Regis Houssin
* Copyright (C) 2012 Cédric Salvador
- * Copyright (C) 2012-2014 Raphaël Dourseanud
+ * Copyright (C) 2012-2014 Raphaël Doursenaud
* Copyright (C) 2014-2106 Ferran Marcet
* Copyright (C) 2014 Juanjo Menent
* Copyright (C) 2014 Florian Henry
diff --git a/htdocs/compta/resultat/projects.php b/htdocs/compta/resultat/projects.php
index 0fceb60fdfb..d001c8610bb 100644
--- a/htdocs/compta/resultat/projects.php
+++ b/htdocs/compta/resultat/projects.php
@@ -1,16 +1,16 @@
- * Copyright (C) 2004-2017 Laurent Destailleur
- * Copyright (C) 2005-2012 Regis Houssin
- * Copyright (C) 2012 Cédric Salvador
- * Copyright (C) 2012-2014 Raphaël Dourseanud
- * Copyright (C) 2014-2106 Ferran Marcet
- * Copyright (C) 2014 Juanjo Menent
- * Copyright (C) 2014 Florian Henry
- * Copyright (C) 2018 Frédéric France
- * Copyright (C) 2020 Maxime DEMAREST
- * Copyright (C) 2021 Alexandre Spangaro
- * Copyright (C) 2024 Yoan Mollard
+/* Copyright (C) 2002-2006 Rodolphe Quiedeville
+ * Copyright (C) 2004-2017 Laurent Destailleur
+ * Copyright (C) 2005-2012 Regis Houssin
+ * Copyright (C) 2012 Cédric Salvador
+ * Copyright (C) 2012-2014 Raphaël Doursenaud
+ * Copyright (C) 2014-2016 Ferran Marcet
+ * Copyright (C) 2014 Juanjo Menent
+ * Copyright (C) 2014 Florian Henry
+ * Copyright (C) 2018 Frédéric France
+ * Copyright (C) 2020 Maxime DEMAREST
+ * Copyright (C) 2021-2024 Alexandre Spangaro
+ * Copyright (C) 2024 Yoan Mollard
*
* 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
@@ -44,6 +44,14 @@ require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountancycategory.class.php';
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
+/**
+ * @var Conf $conf
+ * @var DoliDB $db
+ * @var HookManager $hookmanager
+ * @var Translate $langs
+ * @var User $user
+ */
+
// Load translation files required by the page
$langs->loadLangs(array('compta', 'bills', 'donation', 'salaries', 'accountancy', 'loan'));
@@ -55,6 +63,8 @@ $date_endday = GETPOSTINT('date_endday');
$date_endyear = GETPOSTINT('date_endyear');
$showaccountdetail = GETPOST('showaccountdetail', 'aZ09') ? GETPOST('showaccountdetail', 'aZ09') : 'yes';
+$search_project_ref = GETPOST('search_project_ref', 'alpha');
+
$limit = GETPOSTINT('limit') ? GETPOSTINT('limit') : $conf->liste_limit;
$sortfield = GETPOST('sortfield', 'aZ09comma');
$sortorder = GETPOST('sortorder', 'aZ09comma');
@@ -139,7 +149,8 @@ $nbofyear = ($year_end - $year_start) + 1;
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES' or 'BOOKKEEPING')
$modecompta = getDolGlobalString('ACCOUNTING_MODE');
if (isModEnabled('accounting')) {
- $modecompta = 'BOOKKEEPING';
+ // $modecompta = 'BOOKKEEPING';
+ $modecompta = 'CREANCES-DETTES';
}
if (GETPOST("modecompta", 'alpha')) {
$modecompta = GETPOST("modecompta", 'alpha');
@@ -175,7 +186,11 @@ $exportlink = '';
$total_ht = 0;
$total_ttc = 0;
-// Affiche en-tete de rapport
+$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);
+$builddate = dol_now();
+
+// Display report header
if ($modecompta == "CREANCES-DETTES") {
$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);
@@ -200,10 +215,12 @@ if ($modecompta == "CREANCES-DETTES") {
// Define $calcmode line
$calcmode = '';
+/*
if (isModEnabled('accounting')) {
$calcmode .= '';
$calcmode .= '
';
}
+*/
$calcmode .= '