From 4928db70adfc2f0811c5fcef3fdefc36565c0228 Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Mon, 23 Feb 2015 15:27:45 +0100 Subject: [PATCH] [FIX] account: partner form buttons access rights When having account installed, but having as only access right "Contacts creation", it wasn't possible to display the partner form. Setting the "groups" on the button itself has as effect to hide the button, but not to prevent its value computation. If you did not had the access rights required to compute the buttons values, it leaded to security issues. Put the "groups" on the view instead prevent the button to be loaded, and its value to be computed. It therefore avoids both a useless computation (computing the value of a hidden button is not really useful), and prevent any access rights warnings. Besides, 3 different groups were needed to display the three buttons: - account.group_account_invoice - account.group_account_user - analytic.group_analytic_accounting Not having one of these tree groups could lead to security warnings. We therefore split this view into three sub-views, with each one a group set (and a button) opw-628668 --- addons/account/partner_view.xml | 31 ++++++++++++++++++++++++++++--- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/addons/account/partner_view.xml b/addons/account/partner_view.xml index 45d92f21d23..ebc485c5f76 100644 --- a/addons/account/partner_view.xml +++ b/addons/account/partner_view.xml @@ -70,6 +70,7 @@ res.partner + - + + + + + + partner.view.button.contracts_count + res.partner + + + + +