Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

17.0 mig website whatsapp #2

Merged
merged 51 commits into from
Feb 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
5a2bf0c
[ADD] website_conditional_visibility_user_group: New module
chienandalu Jul 8, 2024
43b867d
[UPD] Update website_conditional_visibility_user_group.pot
Jul 12, 2024
0f14f18
[BOT] post-merge updates
OCA-git-bot Jul 12, 2024
c376697
[IMP] website_conditional_visibility_user_group: pre-commit auto fixes
pilarvargas-tecnativa Jan 10, 2025
e70867a
[MIG] website_conditional_visibility_user_group: Migration to version…
pilarvargas-tecnativa Jan 13, 2025
343351d
Merge PR #1082 into 17.0
OCA-git-bot Jan 14, 2025
e5495a2
[UPD] Update website_conditional_visibility_user_group.pot
Jan 14, 2025
83f6936
[BOT] post-merge updates
OCA-git-bot Jan 14, 2025
846c7cc
Added translation using Weblate (Italian)
mymage Jan 15, 2025
03a6d3c
Translated using Weblate (Italian)
mymage Jan 15, 2025
c128637
Add module website_crm_quick_answer.
yajo Oct 15, 2015
78b8781
Remove unexisting field.
yajo Oct 16, 2015
deaf085
Filter by medium too.
yajo Nov 16, 2015
a3b0c10
Allowing all users to read filter when creating a lead or an opportunity
antespi Nov 24, 2015
72039e1
[MIG] website_crm_quick_answer: Migration to 10.0
chienandalu Jun 22, 2017
ec95be6
Update README.rst
rafaelbn Aug 23, 2017
c444952
[IMP] website_crm_quick_answer: Remove unneeded dependency
pedrobaeza Sep 4, 2017
1f76eb0
[12.0][MIG] website_crm_quick_answer: Migration to v12
cristinamartinrod Feb 27, 2019
adc7ab1
Translated using Weblate (French)
Jul 28, 2019
89c2f06
Translated using Weblate (Portuguese (Brazil))
Aug 26, 2019
aec33a6
[IMP]website_crm_quick_answer: black, isort, prettier
manuelregidor Aug 17, 2021
771bbdb
[14.0][MIG]website_crm_quick_answer: Migration to 14.0
manuelregidor Aug 17, 2021
32add08
[MIG]website_crm_quick_answer: Migration to 15.0
manuelregidor Apr 28, 2022
5db3627
website_crm_quick_answer 15.0.1.0.1
OCA-git-bot May 3, 2022
83c4c79
Added translation using Weblate (Italian)
mymage Dec 27, 2022
7d49915
Translated using Weblate (Italian)
mymage Dec 27, 2022
b99b2c1
Added translation using Weblate (Spanish)
chienandalu Jan 27, 2023
86b3302
Translated using Weblate (Spanish)
chienandalu Jan 27, 2023
eb5e049
[IMP] website_crm_quick_answer: pre-commit auto fixes
pilarvargas-tecnativa Jan 15, 2025
6e479ec
[MIG] website_crm_quick_answer: Migration to version 17.0
pilarvargas-tecnativa Jan 15, 2025
0b6ac57
Merge PR #1084 into 17.0
OCA-git-bot Jan 16, 2025
56c0caa
[UPD] Update website_crm_quick_answer.pot
Jan 16, 2025
661c124
[BOT] post-merge updates
OCA-git-bot Jan 16, 2025
f283039
Update translation files
weblate Jan 16, 2025
d7ff90c
Translated using Weblate (Italian)
mymage Jan 19, 2025
ee4249e
[IMP] update dotfiles
OCA-git-bot Feb 9, 2025
5a04dfd
[15.0][ADD] website_whatsapp: Whatsapp integration
ioans73 Nov 24, 2022
c808aa0
[MIG] website_whatsapp: Migration to 16.0
ioans73 Jan 17, 2023
418e596
[UPD] Update website_whatsapp.pot
Oct 30, 2023
2091095
[BOT] post-merge updates
OCA-git-bot Oct 30, 2023
6e42765
Added translation using Weblate (Italian)
mymage Nov 13, 2023
631433d
Translated using Weblate (Italian)
mymage Nov 14, 2023
89cad34
Added translation using Weblate (Spanish)
Pablocce Jan 2, 2024
7ec017e
Translated using Weblate (Spanish)
Ivorra78 Jan 2, 2024
d271230
[16.0][IMP] website_whatsapp: Lighthouse accesibility
ioans73 Jul 3, 2024
62b3474
[UPD] Update website_whatsapp.pot
Jul 3, 2024
6e2eb51
[BOT] post-merge updates
OCA-git-bot Jul 3, 2024
aa6fb94
Update translation files
weblate Jul 3, 2024
e7a6435
Translated using Weblate (Italian)
mymage Jul 8, 2024
2b35afd
[IMP] website_whatsapp: pre-commit auto fixes
eugenios73 Dec 16, 2024
56e9ec6
[MIG] website_whatsapp: Migration to 17.0
eugenios73 Dec 16, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .copier-answers.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# Do NOT update manually; changes here will be overwritten by Copier
_commit: v1.21.1
_commit: v1.29
_src_path: gh:oca/oca-addons-repo-template
additional_ruff_rules: []
ci: GitHub
convert_readme_fragments_to_markdown: true
enable_checklog_odoo: false
generate_requirements_txt: true
github_check_license: true
github_ci_extra_env: {}
Expand Down
2 changes: 1 addition & 1 deletion .eslintrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ env:

# See https://github.com/OCA/odoo-community.org/issues/37#issuecomment-470686449
parserOptions:
ecmaVersion: 2019
ecmaVersion: 2022

overrides:
- files:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ jobs:
pre-commit:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v2
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Get python version
run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV
- uses: actions/cache@v1
- uses: actions/cache@v4
with:
path: ~/.cache/pre-commit
key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
runs-on: ubuntu-latest
name: Detect unreleased dependencies
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- run: |
for reqfile in requirements.txt test-requirements.txt ; do
if [ -f ${reqfile} ] ; then
Expand Down Expand Up @@ -50,7 +50,7 @@ jobs:
ports:
- 5432:5432
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
persist-credentials: false
- name: Install addons and dependencies
Expand Down
13 changes: 13 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,19 @@ var/
*.egg
*.eggs

# Windows installers
*.msi

# Debian packages
*.deb

# Redhat packages
*.rpm

# MacOS packages
*.dmg
*.pkg

# Installer logs
pip-log.txt
pip-delete-this-directory.txt
Expand Down
34 changes: 23 additions & 11 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ exclude: |
# Files and folders generated by bots, to avoid loops
^setup/|/static/description/index\.html$|
# We don't want to mess with tool-generated files
.svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|
.svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|^eslint.config.cjs|^prettier.config.cjs|
# Maybe reactivate this when all README files include prettier ignore tags?
^README\.md$|
# Library files can have extraneous formatting (even minimized)
Expand Down Expand Up @@ -39,11 +39,11 @@ repos:
language: fail
files: '[a-zA-Z0-9_]*/i18n/en\.po$'
- repo: https://github.com/sbidoul/whool
rev: v0.5
rev: v1.2
hooks:
- id: whool-init
- repo: https://github.com/oca/maintainer-tools
rev: 9a170331575a265c092ee6b24b845ec508e8ef75
rev: d5fab7ee87fceee858a3d01048c78a548974d935
hooks:
# update the NOT INSTALLABLE ADDONS section above
- id: oca-update-pre-commit-excluded-addons
Expand All @@ -64,25 +64,37 @@ repos:
hooks:
- id: oca-checks-odoo-module
- id: oca-checks-po
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.7.1
args:
- --disable=po-pretty-format
- repo: local
hooks:
- id: prettier
name: prettier (with plugin-xml)
entry: prettier
args:
- --write
- --list-different
- --ignore-unknown
types: [text]
files: \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
language: node
additional_dependencies:
- "[email protected]"
- "@prettier/[email protected]"
args:
- --plugin=@prettier/plugin-xml
files: \.(css|htm|html|js|json|jsx|less|md|scss|toml|ts|xml|yaml|yml)$
- repo: https://github.com/pre-commit/mirrors-eslint
rev: v8.24.0
- repo: local
hooks:
- id: eslint
verbose: true
name: eslint
entry: eslint
args:
- --color
- --fix
verbose: true
types: [javascript]
language: node
additional_dependencies:
- "[email protected]"
- "eslint-plugin-jsdoc@"
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
Expand Down
1 change: 1 addition & 0 deletions .ruff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ extend-select = [
"I", # isort
"UP", # pyupgrade
]
extend-safe-fixes = ["UP008"]
exclude = ["setup/*"]

[format]
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,10 @@ Available addons
----------------
addon | version | maintainers | summary
--- | --- | --- | ---
[website_conditional_visibility_user_group](website_conditional_visibility_user_group/) | 17.0.1.0.0 | | Only internal users will see the blocks you add this condition to
[website_cookiebot](website_cookiebot/) | 17.0.1.0.1 | | Ask for cookies consent connecting with Cookiebot
[website_cookiefirst](website_cookiefirst/) | 17.0.1.0.0 | | Cookiefirst integration
[website_crm_quick_answer](website_crm_quick_answer/) | 17.0.1.0.0 | | Add an automatic answer for contacts asking for info
[website_form_require_legal](website_form_require_legal/) | 17.0.1.0.0 | | Add possibility to require confirm legal terms.
[website_forum_subscription](website_forum_subscription/) | 17.0.1.0.0 | | Adds a button to allow subscription from the website
[website_google_tag_manager](website_google_tag_manager/) | 17.0.1.0.1 | | Add support for Google Tag Manager
Expand Down
Binary file added pandoc-3.6-1-amd64.deb
Binary file not shown.
4 changes: 3 additions & 1 deletion setup/_metapackage/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
[project]
name = "odoo-addons-oca-website"
version = "17.0.20250110.0"
version = "17.0.20250116.0"
dependencies = [
"odoo-addon-website_conditional_visibility_user_group>=17.0dev,<17.1dev",
"odoo-addon-website_cookiebot>=17.0dev,<17.1dev",
"odoo-addon-website_cookiefirst>=17.0dev,<17.1dev",
"odoo-addon-website_crm_quick_answer>=17.0dev,<17.1dev",
"odoo-addon-website_form_require_legal>=17.0dev,<17.1dev",
"odoo-addon-website_forum_subscription>=17.0dev,<17.1dev",
"odoo-addon-website_google_tag_manager>=17.0dev,<17.1dev",
Expand Down
95 changes: 95 additions & 0 deletions website_conditional_visibility_user_group/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
====================================================
Conditional visibility for internal users in Website
====================================================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:3bbca96da1873574321a715ab9006d10573854d43eafe55f064b7346fc4fd883
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fwebsite-lightgray.png?logo=github
:target: https://github.com/OCA/website/tree/17.0/website_conditional_visibility_user_group
:alt: OCA/website
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/website-17-0/website-17-0-website_conditional_visibility_user_group
: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/website&target_branch=17.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module adds extra granularity in the visibility of the website
snippets allowing to set if the users that can see a block are internal
or portal ones.

**Table of contents**

.. contents::
:local:

Configuration
=============

To configure the user group visibility:

- With the frontend editor opened select the block you want to set the
visibility for.
- In *Style* tab of the editor panel set the *Visibility* option to
*Conditional* and unfold it.
- Set the *Users* option to *Visible for logged in*.
- Now you'll see the new *Groups* option.
- You can choose between *Only internal users*, *Only portal users* or
*No restriction*, which is the default value.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/website/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 <https://github.com/OCA/website/issues/new?body=module:%20website_conditional_visibility_user_group%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* Tecnativa

Contributors
------------

- `Tecnativa <https://tecnativa.com>`__

- David Vidal
- Pilar Vargas

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

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.

This module is part of the `OCA/website <https://github.com/OCA/website/tree/17.0/website_conditional_visibility_user_group>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions website_conditional_visibility_user_group/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
28 changes: 28 additions & 0 deletions website_conditional_visibility_user_group/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Copyright 2024 Tecnativa - David Vidal
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
{
"name": "Conditional visibility for internal users in Website",
"summary": "Only internal users will see the blocks you add this condition to",
"version": "17.0.1.0.0",
"category": "Product",
"website": "https://github.com/OCA/website",
"author": "Tecnativa, Odoo Community Association (OCA)",
"license": "AGPL-3",
"depends": ["website"],
"data": ["views/snippet_options_template.xml"],
"assets": {
"web.assets_frontend_minimal": [
"website_conditional_visibility_user_group/static/src/js/*.js",
],
"web.assets_frontend_lazy": [
# Remove assets_frontend_minimal
(
"remove",
"website_conditional_visibility_user_group/static/src/js/*.js",
),
],
"web.assets_tests": [
"website_conditional_visibility_user_group/static/src/tests/*.js"
],
},
}
43 changes: 43 additions & 0 deletions website_conditional_visibility_user_group/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_conditional_visibility_user_group
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 15.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-07-12 05:20+0000\n"
"PO-Revision-Date: 2024-07-12 07:21+0200\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Poedit 3.4.4\n"

#. module: website_conditional_visibility_user_group
#: model:ir.model,name:website_conditional_visibility_user_group.model_ir_http
msgid "HTTP Routing"
msgstr "Ruta HTTP"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "No restriction"
msgstr "Sin restricciones"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "Only internal users"
msgstr "Solo usuarios internos"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "Only portal users"
msgstr "Solo usuarios de portal"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "⌙ Groups"
msgstr "⌙ Grupos"
42 changes: 42 additions & 0 deletions website_conditional_visibility_user_group/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_conditional_visibility_user_group
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 17.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2025-01-15 10:06+0000\n"
"Last-Translator: mymage <[email protected]>\n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.6.2\n"

#. module: website_conditional_visibility_user_group
#: model:ir.model,name:website_conditional_visibility_user_group.model_ir_http
msgid "HTTP Routing"
msgstr "Instradamento HTTP"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "No restriction"
msgstr "Nessuna restrizione"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "Only internal users"
msgstr "Solo utenti interni"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "Only portal users"
msgstr "Solo utenti portale"

#. module: website_conditional_visibility_user_group
#: model_terms:ir.ui.view,arch_db:website_conditional_visibility_user_group.snippet_options
msgid "⌙ Groups"
msgstr "⌙ Gruppi"
Loading