From 2448b9ee55ed0eef1844aba8383e63842c600a21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcos=20Garci=CC=81a=20de=20La=20Fuente?= Date: Thu, 30 Mar 2017 14:52:26 +0200 Subject: [PATCH 1/6] FIX #6619 Template invoices list do not respect restricted thirdparty user rights --- htdocs/compta/facture/fiche-rec.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/htdocs/compta/facture/fiche-rec.php b/htdocs/compta/facture/fiche-rec.php index c7bf362ab7d..3a55c8b57c2 100644 --- a/htdocs/compta/facture/fiche-rec.php +++ b/htdocs/compta/facture/fiche-rec.php @@ -1384,8 +1384,14 @@ else $sql = "SELECT s.nom as name, s.rowid as socid, f.rowid as facid, f.titre, f.total, f.tva as total_vat, f.total_ttc, f.frequency,"; $sql.= " f.date_last_gen, f.date_when"; $sql.= " FROM ".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."facture_rec as f"; + if (! $user->rights->societe->client->voir && ! $socid) { + $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + } $sql.= " WHERE f.fk_soc = s.rowid"; $sql.= " AND f.entity = ".$conf->entity; + if (! $user->rights->societe->client->voir && ! $socid) { + $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = ".$user->id; + } if ($search_ref) $sql .= natural_search('f.titre', $search_ref); if ($search_societe) $sql .= natural_search('s.nom', $search_societe); if ($search_frequency) $sql .= natural_search('f.frequency', $search_frequency); From cd5b074a4829abf1bcaa32d1f1dfe925d8aaca19 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcos=20Garci=CC=81a=20de=20La=20Fuente?= Date: Thu, 30 Mar 2017 15:21:20 +0200 Subject: [PATCH 2/6] FIX #6621 Documents tab shows greyed out upload form even if the option to show actions not available is disabled --- htdocs/core/class/html.formfile.class.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/htdocs/core/class/html.formfile.class.php b/htdocs/core/class/html.formfile.class.php index c117417e428..0821b9b2d2b 100644 --- a/htdocs/core/class/html.formfile.class.php +++ b/htdocs/core/class/html.formfile.class.php @@ -89,6 +89,11 @@ class FormFile } else { + //If there is no permission and the option to hide unauthorized actions is enabled, then nothing is printed + if (!$perm && !empty($conf->global->MAIN_BUTTON_HIDE_UNAUTHORIZED)) { + return 1; + } + $maxlength=$size; $out = "\n\n\n"; From 4d7b059eb33ecf74c8443f125d735c2df8c8767a Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 2 Apr 2017 18:50:34 +0200 Subject: [PATCH 3/6] Release 4.0.5 --- ChangeLog | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/ChangeLog b/ChangeLog index cc6f1364f17..5fe3c741499 100644 --- a/ChangeLog +++ b/ChangeLog @@ -12,6 +12,42 @@ Upgrading to any other version or any other database system is abolutely require make a Dolibarr upgrade. +***** ChangeLog for 4.0.5 to 4.0.4 ***** +FIX: #6234 +FIX: #6259 +FIX: #6330 +FIX: #6360 +FIX: #6411 +FIX: #6443 +FIX: #6444 +FIX: #6453 +FIX: #6503: SQL error in "Last pending payment invoices" +FIX: #6505 Project elements page shows greyed-out links even if the option to show actions not available is disabled +FIX: #6507: Statistics counter show wrong total Contract numbers when the user does not have full access +FIX: #6533 #6590 +FIX: #6619 Template invoices list do not respect restricted thirdparty user rights +FIX: #6621 Documents tab shows greyed out upload form even if the option to show actions not available is disabled +FIX: add entity param to document link +FIX: Can use quote into supplier ref on order line add +FIX: Change the customer code only if error on duplicate +FIX: Creation of credit note on invoice with deposit stole the discount. +FIX: delete bank class lines when we delete bank_categ +FIX: deletion of bank tag +FIX: detail of deposit and credit not was not visible into final invoice +FIX: Error management during bank account creation +FIX: error management in bank account deletion. +FIX: event status is not modified when assign an user +FIX: forgotten fk_facture_fourn attribute on supplierinvoice line object +FIX: If bank module on, field must be required to register payment of expense report. +FIX: load multicurrency informations on supplier order and bill lines fetch +FIX: Missing total on project overview. +FIX: multicurrency_subprice +FIX: param billed when we change page +FIX: protection against infinite loop on hierarchy +FIX: Supplier Order list filter by project +FIX: the dolCopyDir fails if target dir does not exists. +FIX: use param for http links + ***** ChangeLog for 4.0.4 to 4.0.3 ***** FIX: #6227 Document models table header "Unit" is shown in 2 lines in Spanish FIX: #6230 From 00d485b2c5eff2416d621bb3ebf4c4791f0f5f14 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 2 Apr 2017 22:09:06 +0200 Subject: [PATCH 4/6] Start 4.0.6 --- htdocs/filefunc.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/filefunc.inc.php b/htdocs/filefunc.inc.php index c0f95fe76f7..d2ca04278ff 100644 --- a/htdocs/filefunc.inc.php +++ b/htdocs/filefunc.inc.php @@ -31,7 +31,7 @@ */ if (! defined('DOL_APPLICATION_TITLE')) define('DOL_APPLICATION_TITLE','Dolibarr'); -if (! defined('DOL_VERSION')) define('DOL_VERSION','4.0.5'); +if (! defined('DOL_VERSION')) define('DOL_VERSION','4.0.6'); if (! defined('EURO')) define('EURO',chr(128)); From 5b5380659e1be3b2512a99a897afce05edb221fa Mon Sep 17 00:00:00 2001 From: BENKE Charlie Date: Mon, 3 Apr 2017 15:58:48 +0200 Subject: [PATCH 5/6] ERROR Categories Bank vs categories transactions PB since 4.0, present in 5.0 and develop version There is a confusion between the categorization function of bank accounts and the categorization function of the records. The categorization of the entries has been removed or it is not replaced by the categorization of the bank accounts. I propose for the moment to restore the old category of writings but to envisage the creation of a new type of category "bank records" (or if it is not necessary with the new account) to leave so --- htdocs/core/menus/standard/eldy.lib.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php index 748a4532cb5..eab8f5a8c19 100644 --- a/htdocs/core/menus/standard/eldy.lib.php +++ b/htdocs/core/menus/standard/eldy.lib.php @@ -1071,10 +1071,11 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu if (! empty($conf->categorie->enabled)) { $langs->load("categories"); - //$newmenu->add("/compta/bank/categ.php",$langs->trans("Rubriques"),1,$user->rights->banque->configurer); $newmenu->add("/categories/index.php?type=5",$langs->trans("Rubriques"),0,$user->rights->categorie->creer, '', $mainmenu, 'tags'); $newmenu->add("/categories/card.php?action=create&type=5",$langs->trans("NewCategory"),1,$user->rights->categorie->creer); - } + $newmenu->add("/compta/bank/categ.php",$langs->trans("RubriquesTransactions"),1,$user->rights->banque->configurer); + + } // Prelevements if (! empty($conf->prelevement->enabled)) From fe4f71296f13a2231bfbe603d8ed9dd256026cfd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 6 Apr 2017 21:55:23 +0200 Subject: [PATCH 6/6] FIX #6636 Complete fix --- htdocs/compta/bank/categ.php | 2 +- htdocs/core/menus/standard/eldy.lib.php | 4 ++-- htdocs/langs/en_US/categories.lang | 1 + 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/htdocs/compta/bank/categ.php b/htdocs/compta/bank/categ.php index 51030242fce..ae35eee80fa 100644 --- a/htdocs/compta/bank/categ.php +++ b/htdocs/compta/bank/categ.php @@ -80,7 +80,7 @@ if ($categid) { llxHeader(); -print load_fiche_titre($langs->trans("Rubriques"), '', 'title_bank.png'); +print load_fiche_titre($langs->trans("RubriquesTransactions"), '', 'title_bank.png'); print '
'; print ''; diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php index eab8f5a8c19..aa98f23b2ad 100644 --- a/htdocs/core/menus/standard/eldy.lib.php +++ b/htdocs/core/menus/standard/eldy.lib.php @@ -1073,8 +1073,8 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu $langs->load("categories"); $newmenu->add("/categories/index.php?type=5",$langs->trans("Rubriques"),0,$user->rights->categorie->creer, '', $mainmenu, 'tags'); $newmenu->add("/categories/card.php?action=create&type=5",$langs->trans("NewCategory"),1,$user->rights->categorie->creer); - $newmenu->add("/compta/bank/categ.php",$langs->trans("RubriquesTransactions"),1,$user->rights->banque->configurer); - + $newmenu->add("/compta/bank/categ.php",$langs->trans("RubriquesTransactions"),0,$user->rights->categorie->creer, '', $mainmenu, 'tags'); + $newmenu->add("/compta/bank/categ.php",$langs->trans("NewCategory"),1,$user->rights->categorie->creer, '', $mainmenu, 'tags'); } // Prelevements diff --git a/htdocs/langs/en_US/categories.lang b/htdocs/langs/en_US/categories.lang index 976c8a50d93..b8a1e5ef58b 100644 --- a/htdocs/langs/en_US/categories.lang +++ b/htdocs/langs/en_US/categories.lang @@ -1,6 +1,7 @@ # Dolibarr language file - Source file is en_US - categories Rubrique=Tag/Category Rubriques=Tags/Categories +RubriquesTransactions=Tags/Categories of transactions categories=tags/categories NoCategoryYet=No tag/category of this type created In=In