From 13887a63f4c34def7b4be3c71d142501fbde971a Mon Sep 17 00:00:00 2001
From: bosd
Date: Thu, 2 Jan 2025 19:25:04 +0100
Subject: [PATCH] [MIG] brand: Migration to 18.0
---
brand/README.rst | 10 +++++-----
brand/__manifest__.py | 2 +-
brand/models/res_brand_mixin.py | 4 ++--
brand/static/description/index.html | 17 ++++++++++-------
brand/views/res_brand.xml | 20 ++++++++++----------
5 files changed, 28 insertions(+), 25 deletions(-)
diff --git a/brand/README.rst b/brand/README.rst
index d39ac6a93..17f2b00ae 100644
--- a/brand/README.rst
+++ b/brand/README.rst
@@ -17,13 +17,13 @@ Brand
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbrand-lightgray.png?logo=github
- :target: https://github.com/OCA/brand/tree/17.0/brand
+ :target: https://github.com/OCA/brand/tree/18.0/brand
:alt: OCA/brand
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/brand-17-0/brand-17-0-brand
+ :target: https://translation.odoo-community.org/projects/brand-18-0/brand-18-0-brand
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
- :target: https://runboat.odoo-community.org/builds?repo=OCA/brand&target_branch=17.0
+ :target: https://runboat.odoo-community.org/builds?repo=OCA/brand&target_branch=18.0
:alt: Try me on Runboat
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -74,7 +74,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -122,6 +122,6 @@ Current `maintainer `__:
|maintainer-sbejaoui|
-This module is part of the `OCA/brand `_ project on GitHub.
+This module is part of the `OCA/brand `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/brand/__manifest__.py b/brand/__manifest__.py
index 62f77b0eb..c0e37a593 100644
--- a/brand/__manifest__.py
+++ b/brand/__manifest__.py
@@ -7,7 +7,7 @@
This is a base addon for brand modules. It adds the brand object and
its menu and define an abstract model to be inherited from branded
objects""",
- "version": "17.0.1.1.1",
+ "version": "18.0.1.0.0",
"license": "AGPL-3",
"author": "Odoo Community Association (OCA), ACSONE SA/NV",
"website": "https://github.com/OCA/brand",
diff --git a/brand/models/res_brand_mixin.py b/brand/models/res_brand_mixin.py
index f476a0df4..10dc97eac 100644
--- a/brand/models/res_brand_mixin.py
+++ b/brand/models/res_brand_mixin.py
@@ -53,8 +53,8 @@ def _onchange_brand_id(self):
def _get_view(self, view_id=None, view_type="form", **options):
"""set visibility and requirement rules"""
arch, view = super()._get_view(view_id, view_type, **options)
- if self.env["res.brand"].check_access_rights("read", raise_exception=False):
- if view.type in ["form", "tree"]:
+ if self.env["res.brand"].check_access("read", raise_exception=False):
+ if view.type in ["form", "list"]:
brand_node = next(
iter(
arch.xpath(
diff --git a/brand/static/description/index.html b/brand/static/description/index.html
index 4f3f7b790..d10ff201b 100644
--- a/brand/static/description/index.html
+++ b/brand/static/description/index.html
@@ -8,10 +8,11 @@
/*
:Author: David Goodger (goodger@python.org)
-:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $
+:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $
:Copyright: This stylesheet has been placed in the public domain.
Default cascading style sheet for the HTML output of Docutils.
+Despite the name, some widely supported CSS2 features are used.
See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to
customize this style sheet.
@@ -274,7 +275,7 @@
margin-left: 2em ;
margin-right: 2em }
-pre.code .ln { color: grey; } /* line numbers */
+pre.code .ln { color: gray; } /* line numbers */
pre.code, code { background-color: #eeeeee }
pre.code .comment, code .comment { color: #5C6576 }
pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
@@ -300,7 +301,7 @@
span.pre {
white-space: pre }
-span.problematic {
+span.problematic, pre.problematic {
color: red }
span.section-subtitle {
@@ -368,7 +369,7 @@ Brand
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:dfca48afbbc980c86b0e1659f2fac237d7f98779ff9d9ad686ead39dc20dfadc
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
This is a base addon for brand modules. It adds the brand object and its
menu and define an abstract model to be inherited from branded objects.
Table of contents
@@ -421,7 +422,7 @@
Bugs are tracked on GitHub Issues.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
-feedback.
+feedback.
Do not contact contributors directly about support or help with technical issues.
@@ -452,13 +453,15 @@
This module is maintained by the OCA.
-
+
+
+
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
Current maintainer:
-
This module is part of the OCA/brand project on GitHub.
+
This module is part of the OCA/brand project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/brand/views/res_brand.xml b/brand/views/res_brand.xml
index f6afb0043..7687fe469 100644
--- a/brand/views/res_brand.xml
+++ b/brand/views/res_brand.xml
@@ -120,18 +120,18 @@
-
+
-
-
- res.brand.tree (in partner_brand)
+
+ res.brand.list (in partner_brand)
res.brand
primary
-
+
Brands
@@ -187,7 +187,7 @@
Brands
res.brand
- kanban,tree,form
+ kanban,list,form
{'default_customer': 0, 'default_supplier': 0,}