diff --git a/.copier-answers.yml b/.copier-answers.yml index a3cea546d..653dedb99 100644 --- a/.copier-answers.yml +++ b/.copier-answers.yml @@ -1,15 +1,20 @@ # Do NOT update manually; changes here will be overwritten by Copier -_commit: v1.2.0 +_commit: v1.6.1 _src_path: gh:oca/oca-addons-repo-template +ci: GitHub dependency_installation_mode: PIP generate_requirements_txt: true include_wkhtmltopdf: false odoo_version: 14.0 -rebel_module_groups: [] +org_name: Odoo Community Association (OCA) +org_slug: OCA +rebel_module_groups: +- web_widget_model_viewer repo_description: "This project aims to deal with modules related to the webclient\ \ of Odoo. You'll find modules that:\n\n - Add facilities to the UI\n - Add widgets\n\ \ - Ease the import/export features\n - Generally add clientside functionality" repo_name: Web addons for Odoo repo_slug: web +repo_website: https://github.com/OCA/web travis_apt_packages: [] travis_apt_sources: [] diff --git a/.eslintrc.yml b/.eslintrc.yml index 16a185f1b..9429bc688 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -4,7 +4,13 @@ env: # See https://github.com/OCA/odoo-community.org/issues/37#issuecomment-470686449 parserOptions: - ecmaVersion: 2017 + ecmaVersion: 2019 + +overrides: + - files: + - "**/*.esm.js" + parserOptions: + sourceType: module # Globals available in Odoo that shouldn't produce errorings globals: diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 9ae4699f7..c05220662 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -2,7 +2,12 @@ name: pre-commit on: pull_request: + branches: + - "14.0*" push: + branches: + - "14.0" + - "14.0-ocabot-*" jobs: pre-commit: @@ -12,4 +17,21 @@ jobs: - uses: actions/setup-python@v4 with: python-version: "3.10" - - uses: pre-commit/action@v2.0.0 + - name: Get python version + run: echo "PY=$(python -VV | sha256sum | cut -d' ' -f1)" >> $GITHUB_ENV + - uses: actions/cache@v1 + with: + path: ~/.cache/pre-commit + key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }} + - name: Install pre-commit + run: pip install pre-commit + - name: Run pre-commit + run: pre-commit run --all-files --show-diff-on-failure --color=always + - name: Check that all files generated by pre-commit are in git + run: | + newfiles="$(git ls-files --others --exclude-from=.gitignore)" + if [ "$newfiles" != "" ] ; then + echo "Please check-in the following files:" + echo "$newfiles" + exit 1 + fi diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 90d4589a9..1693a1253 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -8,18 +8,19 @@ jobs: stale: runs-on: ubuntu-latest steps: - # 120+30 day stale policy for PRs - # * Except PRs marked as "no stale" - - name: Stale PRs policy + - name: Stale PRs and issues policy uses: actions/stale@v4 with: repo-token: ${{ secrets.GITHUB_TOKEN }} - exempt-pr-labels: "no stale" - days-before-stale: 120 - days-before-close: 30 - days-before-issue-stale: -1 - days-before-issue-close: -1 + # General settings. + ascending: true remove-stale-when-updated: true + # Pull Requests settings. + # 120+30 day stale policy for PRs + # * Except PRs marked as "no stale" + days-before-pr-stale: 120 + days-before-pr-close: 30 + exempt-pr-labels: "no stale" stale-pr-label: "stale" stale-pr-message: > There hasn't been any activity on this pull request in the past 4 months, so @@ -28,19 +29,12 @@ jobs: If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label. - - # 180+30 day stale policy for open issues - # * Except Issues marked as "no stale" - - name: Stale Issues policy - uses: actions/stale@v4 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} + # Issues settings. + # 180+30 day stale policy for open issues + # * Except Issues marked as "no stale" + days-before-issue-stale: 180 + days-before-issue-close: 30 exempt-issue-labels: "no stale,needs more information" - days-before-stale: 180 - days-before-close: 30 - days-before-pr-stale: -1 - days-before-pr-close: -1 - remove-stale-when-updated: true stale-issue-label: "stale" stale-issue-message: > There hasn't been any activity on this issue in the past 6 months, so it has @@ -57,6 +51,7 @@ jobs: uses: actions/stale@v4 with: repo-token: ${{ secrets.GITHUB_TOKEN }} + ascending: true only-labels: "needs more information" exempt-issue-labels: "no stale" days-before-stale: 15 diff --git a/.github/workflows/stale.yml.rej b/.github/workflows/stale.yml.rej new file mode 100644 index 000000000..f41569091 --- /dev/null +++ b/.github/workflows/stale.yml.rej @@ -0,0 +1,9 @@ +diff a/.github/workflows/stale.yml b/.github/workflows/stale.yml (rejected hunks) +@@ -15,2 +15,3 @@ jobs: + # General settings. ++ ascending: true + remove-stale-when-updated: true +@@ -52,2 +53,3 @@ jobs: + repo-token: ${{ secrets.GITHUB_TOKEN }} ++ ascending: true + only-labels: "needs more information" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 000000000..2500f55a7 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,81 @@ +name: tests + +on: + pull_request: + branches: + - "14.0*" + push: + branches: + - "14.0" + - "14.0-ocabot-*" + +jobs: + unreleased-deps: + runs-on: ubuntu-latest + name: Detect unreleased dependencies + steps: + - uses: actions/checkout@v2 + - run: | + for reqfile in requirements.txt test-requirements.txt ; do + if [ -f ${reqfile} ] ; then + result=0 + # reject non-comment lines that contain a / (i.e. URLs, relative paths) + grep "^[^#].*/" ${reqfile} || result=$? + if [ $result -eq 0 ] ; then + echo "Unreleased dependencies found in ${reqfile}." + exit 1 + fi + fi + done + test: + runs-on: ubuntu-latest + container: ${{ matrix.container }} + name: ${{ matrix.name }} + strategy: + fail-fast: false + matrix: + include: + - container: ghcr.io/oca/oca-ci/py3.6-odoo14.0:latest + include: "web_widget_model_viewer" + makepot: "true" + name: test with Odoo + - container: ghcr.io/oca/oca-ci/py3.6-ocb14.0:latest + include: "web_widget_model_viewer" + name: test with OCB + - container: ghcr.io/oca/oca-ci/py3.6-odoo14.0:latest + exclude: "web_widget_model_viewer" + makepot: "true" + name: test with Odoo + - container: ghcr.io/oca/oca-ci/py3.6-ocb14.0:latest + exclude: "web_widget_model_viewer" + name: test with OCB + services: + postgres: + image: postgres:9.6 + env: + POSTGRES_USER: odoo + POSTGRES_PASSWORD: odoo + POSTGRES_DB: odoo + ports: + - 5432:5432 + env: + INCLUDE: "${{ matrix.include }}" + EXCLUDE: "${{ matrix.exclude }}" + steps: + - uses: actions/checkout@v2 + with: + persist-credentials: false + - name: Install addons and dependencies + run: oca_install_addons + - name: Check licenses + run: manifestoo -d . check-licenses + - name: Check development status + run: manifestoo -d . check-dev-status --default-dev-status=Beta + - name: Initialize test db + run: oca_init_test_database + - name: Run tests + run: oca_run_tests + - uses: codecov/codecov-action@v1 + - name: Update .pot files + run: oca_export_and_push_pot https://x-access-token:${{ secrets.GIT_PUSH_TOKEN }}@github.com/${{ github.repository }} + if: ${{ matrix.makepot == 'true' && github.event_name == 'push' && github.repository_owner == 'OCA' }} diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8de6b9fe3..5bedc50c4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -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$| + .svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/| # Maybe reactivate this when all README files include prettier ignore tags? ^README\.md$| # Library files can have extraneous formatting (even minimized) @@ -120,7 +120,7 @@ repos: name: flake8 additional_dependencies: ["flake8-bugbear==20.1.4"] - repo: https://github.com/PyCQA/pylint - rev: pylint-2.5.3 + rev: v2.11.1 hooks: - id: pylint name: pylint with optional checks @@ -129,7 +129,7 @@ repos: - --exit-zero verbose: true additional_dependencies: &pylint_deps - - pylint-odoo==3.5.0 + - pylint-odoo==5.0.5 - id: pylint name: pylint with mandatory checks args: diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5e8e3a666..000000000 --- a/.travis.yml +++ /dev/null @@ -1,42 +0,0 @@ -language: python -cache: - directories: - - $HOME/.cache/pip - - $HOME/.cache/pre-commit - -python: - - "3.6" - -addons: - postgresql: "9.6" - apt: - packages: - - expect-dev # provides unbuffer utility - -stages: - - test - -jobs: - include: - - stage: test - env: - - TESTS=1 ODOO_REPO="odoo/odoo" MAKEPOT="1" - - stage: test - env: - - TESTS=1 ODOO_REPO="OCA/OCB" -env: - global: - - VERSION="14.0" TESTS="0" LINT_CHECK="0" MAKEPOT="0" - - MQT_DEP=PIP - -install: - - git clone --depth=1 https://github.com/OCA/maintainer-quality-tools.git - ${HOME}/maintainer-quality-tools - - export PATH=${HOME}/maintainer-quality-tools/travis:${PATH} - - travis_install_nightly - -script: - - travis_run_tests - -after_success: - - travis_after_tests_success diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 9ac71fee4..000000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,10 +0,0 @@ -# OCA Guidelines - -Please follow the official guide from the -[OCA Guidelines page](https://odoo-community.org/page/contributing). - -## Project Specific Guidelines - - - -This project does not have specific coding guidelines. diff --git a/README.md b/README.md index 311eea1de..a7d2f2ccd 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ -[![Runbot Status](https://runbot.odoo-community.org/runbot/badge/flat/162/14.0.svg)](https://runbot.odoo-community.org/runbot/repo/github-com-oca-web-162) -[![Build Status](https://travis-ci.com/OCA/web.svg?branch=14.0)](https://travis-ci.com/OCA/web) + +[![Runboat](https://img.shields.io/badge/runboat-Try%20me-875A7B.png)](https://runboat.odoo-community.org/builds?repo=OCA/web&target_branch=14.0) +[![Pre-commit Status](https://github.com/OCA/web/actions/workflows/pre-commit.yml/badge.svg?branch=14.0)](https://github.com/OCA/web/actions/workflows/pre-commit.yml?query=branch%3A14.0) +[![Build Status](https://github.com/OCA/web/actions/workflows/test.yml/badge.svg?branch=14.0)](https://github.com/OCA/web/actions/workflows/test.yml?query=branch%3A14.0) [![codecov](https://codecov.io/gh/OCA/web/branch/14.0/graph/badge.svg)](https://codecov.io/gh/OCA/web) [![Translation Status](https://translation.odoo-community.org/widgets/web-14-0/-/svg-badge.svg)](https://translation.odoo-community.org/engage/web-14-0/?utm_source=widget) @@ -24,37 +26,58 @@ Available addons ---------------- addon | version | maintainers | summary --- | --- | --- | --- +[support_branding](support_branding/) | 14.0.1.0.0 | | Adds your branding to an Odoo instance [web_access_rule_buttons](web_access_rule_buttons/) | 14.0.1.0.0 | | Disable Edit button if access rules prevent this action +[web_action_conditionable](web_action_conditionable/) | 14.0.1.0.1 | | web_action_conditionable [web_advanced_search](web_advanced_search/) | 14.0.1.0.1 | | Easier and more powerful searching tools -[web_company_color](web_company_color/) | 14.0.1.0.0 | | Web Company Color +[web_calendar_color_field](web_calendar_color_field/) | 14.0.1.0.0 | | Calendar Color Field +[web_calendar_slot_duration](web_calendar_slot_duration/) | 14.0.1.0.0 | [![Yajo](https://github.com/Yajo.png?size=30px)](https://github.com/Yajo) | Customizable calendar slot durations +[web_company_color](web_company_color/) | 14.0.1.2.0 | | Web Company Color [web_copy_confirm](web_copy_confirm/) | 14.0.1.0.0 | | Show confirmation dialogue before copying records [web_decimal_numpad_dot](web_decimal_numpad_dot/) | 14.0.1.0.0 | | Allows using numpad dot to enter period decimal separator [web_dialog_size](web_dialog_size/) | 14.0.1.0.0 | | A module that lets the user expand a dialog box to the full screen width. -[web_domain_field](web_domain_field/) | 14.0.1.0.0 | | Use computed field as domain -[web_drop_target](web_drop_target/) | 14.0.1.0.0 | | Allows to drag files into Odoo +[web_disable_export_group](web_disable_export_group/) | 14.0.1.0.0 | | Web Disable Export Group +[web_domain_field](web_domain_field/) | 14.0.1.0.1 | | Use computed field as domain +[web_drop_target](web_drop_target/) | 14.0.1.1.1 | | Allows to drag files into Odoo [web_environment_ribbon](web_environment_ribbon/) | 14.0.1.0.0 | | Web Environment Ribbon [web_group_expand](web_group_expand/) | 14.0.1.0.0 | | Group Expand Buttons [web_ir_actions_act_multi](web_ir_actions_act_multi/) | 14.0.1.0.0 | | Enables triggering of more than one action on ActionManager [web_ir_actions_act_view_reload](web_ir_actions_act_view_reload/) | 14.0.1.0.0 | | Enables reload of the current view via ActionManager +[web_ir_actions_act_window_message](web_ir_actions_act_window_message/) | 14.0.1.0.0 | | Show a message box to users [web_listview_range_select](web_listview_range_select/) | 14.0.1.0.0 | | Enables selecting a range of records using the shift key -[web_m2x_options](web_m2x_options/) | 14.0.1.0.0 | | web_m2x_options +[web_m2x_options](web_m2x_options/) | 14.0.1.1.0 | | web_m2x_options +[web_m2x_options_manager](web_m2x_options_manager/) | 14.0.1.1.0 | | Adds an interface to manage the "Create" and "Create and Edit" options for specific models and fields. [web_no_bubble](web_no_bubble/) | 14.0.1.0.0 | | Remove the bubbles from the web interface -[web_notify](web_notify/) | 14.0.1.0.0 | | Send notification messages to user -[web_refresher](web_refresher/) | 14.0.1.0.0 | | Web Refresher -[web_responsive](web_responsive/) | 14.0.1.0.2 | [![Yajo](https://github.com/Yajo.png?size=30px)](https://github.com/Yajo) [![Tardo](https://github.com/Tardo.png?size=30px)](https://github.com/Tardo) | Responsive web client, community-supported +[web_notify](web_notify/) | 14.0.1.0.1 | | Send notification messages to user +[web_pwa_oca](web_pwa_oca/) | 14.0.1.0.0 | [![eLBati](https://github.com/eLBati.png?size=30px)](https://github.com/eLBati) | Make Odoo a PWA +[web_refresher](web_refresher/) | 14.0.2.0.0 | | Web Refresher +[web_responsive](web_responsive/) | 14.0.1.2.0 | [![Yajo](https://github.com/Yajo.png?size=30px)](https://github.com/Yajo) [![Tardo](https://github.com/Tardo.png?size=30px)](https://github.com/Tardo) | Responsive web client, community-supported +[web_search_with_and](web_search_with_and/) | 14.0.1.0.0 | | Use AND conditions on omnibar search [web_send_message_popup](web_send_message_popup/) | 14.0.1.0.0 | | Web Send Message as Popup [web_sheet_full_width](web_sheet_full_width/) | 14.0.1.0.1 | | Use the whole available screen width when displaying sheets [web_switch_context_warning](web_switch_context_warning/) | 14.0.1.0.0 | | Show a warning if current user, company or database have been switched in another tab or window. -[web_timeline](web_timeline/) | 14.0.1.0.0 | [![tarteo](https://github.com/tarteo.png?size=30px)](https://github.com/tarteo) | Interactive visualization chart to show events in time +[web_timeline](web_timeline/) | 14.0.2.0.0 | [![tarteo](https://github.com/tarteo.png?size=30px)](https://github.com/tarteo) | Interactive visualization chart to show events in time [web_tree_dynamic_colored_field](web_tree_dynamic_colored_field/) | 14.0.1.0.0 | | Allows you to dynamically color fields on tree views [web_tree_image_tooltip](web_tree_image_tooltip/) | 14.0.1.0.0 | | Show images in tree views via tooltip -[web_tree_many2one_clickable](web_tree_many2one_clickable/) | 14.0.1.0.1 | | Open the linked resource when clicking on their name +[web_tree_many2one_clickable](web_tree_many2one_clickable/) | 14.0.1.0.2 | | Open the linked resource when clicking on their name +[web_view_calendar_list](web_view_calendar_list/) | 14.0.1.0.0 | | Show calendars as a List [web_widget_bokeh_chart](web_widget_bokeh_chart/) | 14.0.2.3.1 | [![LoisRForgeFlow](https://github.com/LoisRForgeFlow.png?size=30px)](https://github.com/LoisRForgeFlow) | This widget allows to display charts using Bokeh library. +[web_widget_char_size](web_widget_char_size/) | 14.0.1.0.1 | | Add size option to Char widget +[web_widget_child_selector](web_widget_child_selector/) | 14.0.1.0.1 | | Widget used for navigation on hierarchy fields +[web_widget_ckeditor](web_widget_ckeditor/) | 14.0.1.0.2 | [![ivantodorovich](https://github.com/ivantodorovich.png?size=30px)](https://github.com/ivantodorovich) | Provides a widget for editing HTML fields using CKEditor +[web_widget_domain_editor_dialog](web_widget_domain_editor_dialog/) | 14.0.1.0.1 | | Recovers the Domain Editor Dialog functionality [web_widget_dropdown_dynamic](web_widget_dropdown_dynamic/) | 14.0.1.0.0 | | This module adds support for dynamic dropdown widget +[web_widget_image_download](web_widget_image_download/) | 14.0.1.0.0 | | Allows to download any image from its widget +[web_widget_image_webcam](web_widget_image_webcam/) | 14.0.1.0.1 | | Allows to take image with WebCam +[web_widget_many2one_simple](web_widget_many2one_simple/) | 14.0.1.0.0 | [![Tardo](https://github.com/Tardo.png?size=30px)](https://github.com/Tardo) | Simple many2one widget +[web_widget_model_viewer](web_widget_model_viewer/) | 14.0.1.0.0 | [![eLBati](https://github.com/eLBati.png?size=30px)](https://github.com/eLBati) | Easily display interactive 3D models on the web & in AR [web_widget_mpld3_chart](web_widget_mpld3_chart/) | 14.0.1.0.0 | | This widget allows to display charts using MPLD3 library. [web_widget_numeric_step](web_widget_numeric_step/) | 14.0.1.0.0 | | Web Widget Numeric Step +[web_widget_open_tab](web_widget_open_tab/) | 14.0.1.0.0 | | Allow to open record from trees on new tab from tree views +[web_widget_plotly_chart](web_widget_plotly_chart/) | 14.0.1.0.0 | [![robyf70](https://github.com/robyf70.png?size=30px)](https://github.com/robyf70) | Allow to draw plotly charts. +[web_widget_text_markdown](web_widget_text_markdown/) | 14.0.1.0.0 | | Widget to text fields that adds markdown support [web_widget_url_advanced](web_widget_url_advanced/) | 14.0.1.0.1 | | This module extends URL widget for displaying anchors with custom labels. -[web_widget_x2many_2d_matrix](web_widget_x2many_2d_matrix/) | 14.0.1.0.1 | | Show list fields as a matrix +[web_widget_x2many_2d_matrix](web_widget_x2many_2d_matrix/) | 14.0.1.1.0 | | Show list fields as a matrix [//]: # (end addons) @@ -66,7 +89,7 @@ addon | version | maintainers | summary ## Licenses This repository is licensed under [AGPL-3.0](LICENSE). -However, each module can have a totally different license, as long as they adhere to OCA +However, each module can have a totally different license, as long as they adhere to Odoo Community Association (OCA) policy. Consult each module's `__manifest__.py` file, which contains a `license` key that explains its license. diff --git a/requirements.txt b/requirements.txt index 0162c2845..14c501fa3 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,4 @@ # generated from manifests external_dependencies bokeh==2.3.1 mpld3 +plotly==5.4.0 diff --git a/setup/_metapackage/VERSION.txt b/setup/_metapackage/VERSION.txt index 0762f4b63..5ad9b2a08 100644 --- a/setup/_metapackage/VERSION.txt +++ b/setup/_metapackage/VERSION.txt @@ -1 +1 @@ -14.0.20210921.0 \ No newline at end of file +14.0.20221021.0 \ No newline at end of file diff --git a/setup/_metapackage/setup.py b/setup/_metapackage/setup.py index 72e89faeb..bdb305453 100644 --- a/setup/_metapackage/setup.py +++ b/setup/_metapackage/setup.py @@ -8,24 +8,33 @@ setuptools.setup( description="Meta package for oca-web Odoo addons", version=version, install_requires=[ + 'odoo14-addon-support_branding', 'odoo14-addon-web_access_rule_buttons', + 'odoo14-addon-web_action_conditionable', 'odoo14-addon-web_advanced_search', + 'odoo14-addon-web_calendar_color_field', + 'odoo14-addon-web_calendar_slot_duration', 'odoo14-addon-web_company_color', 'odoo14-addon-web_copy_confirm', 'odoo14-addon-web_decimal_numpad_dot', 'odoo14-addon-web_dialog_size', + 'odoo14-addon-web_disable_export_group', 'odoo14-addon-web_domain_field', 'odoo14-addon-web_drop_target', 'odoo14-addon-web_environment_ribbon', 'odoo14-addon-web_group_expand', 'odoo14-addon-web_ir_actions_act_multi', 'odoo14-addon-web_ir_actions_act_view_reload', + 'odoo14-addon-web_ir_actions_act_window_message', 'odoo14-addon-web_listview_range_select', 'odoo14-addon-web_m2x_options', + 'odoo14-addon-web_m2x_options_manager', 'odoo14-addon-web_no_bubble', 'odoo14-addon-web_notify', + 'odoo14-addon-web_pwa_oca', 'odoo14-addon-web_refresher', 'odoo14-addon-web_responsive', + 'odoo14-addon-web_search_with_and', 'odoo14-addon-web_send_message_popup', 'odoo14-addon-web_sheet_full_width', 'odoo14-addon-web_switch_context_warning', @@ -33,15 +42,28 @@ setuptools.setup( 'odoo14-addon-web_tree_dynamic_colored_field', 'odoo14-addon-web_tree_image_tooltip', 'odoo14-addon-web_tree_many2one_clickable', + 'odoo14-addon-web_view_calendar_list', 'odoo14-addon-web_widget_bokeh_chart', + 'odoo14-addon-web_widget_char_size', + 'odoo14-addon-web_widget_child_selector', + 'odoo14-addon-web_widget_ckeditor', + 'odoo14-addon-web_widget_domain_editor_dialog', 'odoo14-addon-web_widget_dropdown_dynamic', + 'odoo14-addon-web_widget_image_download', + 'odoo14-addon-web_widget_image_webcam', + 'odoo14-addon-web_widget_many2one_simple', + 'odoo14-addon-web_widget_model_viewer', 'odoo14-addon-web_widget_mpld3_chart', 'odoo14-addon-web_widget_numeric_step', + 'odoo14-addon-web_widget_open_tab', + 'odoo14-addon-web_widget_plotly_chart', + 'odoo14-addon-web_widget_text_markdown', 'odoo14-addon-web_widget_url_advanced', 'odoo14-addon-web_widget_x2many_2d_matrix', ], classifiers=[ 'Programming Language :: Python', 'Framework :: Odoo', + 'Framework :: Odoo :: 14.0', ] ) diff --git a/setup/support_branding/odoo/addons/support_branding b/setup/support_branding/odoo/addons/support_branding new file mode 120000 index 000000000..3eb64a52d --- /dev/null +++ b/setup/support_branding/odoo/addons/support_branding @@ -0,0 +1 @@ +../../../../support_branding \ No newline at end of file diff --git a/setup/support_branding/setup.py b/setup/support_branding/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/support_branding/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_action_conditionable/odoo/addons/web_action_conditionable b/setup/web_action_conditionable/odoo/addons/web_action_conditionable new file mode 120000 index 000000000..048ff8cb6 --- /dev/null +++ b/setup/web_action_conditionable/odoo/addons/web_action_conditionable @@ -0,0 +1 @@ +../../../../web_action_conditionable \ No newline at end of file diff --git a/setup/web_action_conditionable/setup.py b/setup/web_action_conditionable/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_action_conditionable/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_calendar_color_field/odoo/addons/web_calendar_color_field b/setup/web_calendar_color_field/odoo/addons/web_calendar_color_field new file mode 120000 index 000000000..bd453a8a0 --- /dev/null +++ b/setup/web_calendar_color_field/odoo/addons/web_calendar_color_field @@ -0,0 +1 @@ +../../../../web_calendar_color_field \ No newline at end of file diff --git a/setup/web_calendar_color_field/setup.py b/setup/web_calendar_color_field/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_calendar_color_field/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_calendar_slot_duration/odoo/addons/web_calendar_slot_duration b/setup/web_calendar_slot_duration/odoo/addons/web_calendar_slot_duration new file mode 120000 index 000000000..d091ca281 --- /dev/null +++ b/setup/web_calendar_slot_duration/odoo/addons/web_calendar_slot_duration @@ -0,0 +1 @@ +../../../../web_calendar_slot_duration \ No newline at end of file diff --git a/setup/web_calendar_slot_duration/setup.py b/setup/web_calendar_slot_duration/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_calendar_slot_duration/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_disable_export_group/odoo/addons/web_disable_export_group b/setup/web_disable_export_group/odoo/addons/web_disable_export_group new file mode 120000 index 000000000..d8a2f35c1 --- /dev/null +++ b/setup/web_disable_export_group/odoo/addons/web_disable_export_group @@ -0,0 +1 @@ +../../../../web_disable_export_group \ No newline at end of file diff --git a/setup/web_disable_export_group/setup.py b/setup/web_disable_export_group/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_disable_export_group/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_ir_actions_act_window_message/odoo/addons/web_ir_actions_act_window_message b/setup/web_ir_actions_act_window_message/odoo/addons/web_ir_actions_act_window_message new file mode 120000 index 000000000..9ba0c510a --- /dev/null +++ b/setup/web_ir_actions_act_window_message/odoo/addons/web_ir_actions_act_window_message @@ -0,0 +1 @@ +../../../../web_ir_actions_act_window_message \ No newline at end of file diff --git a/setup/web_ir_actions_act_window_message/setup.py b/setup/web_ir_actions_act_window_message/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_ir_actions_act_window_message/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_m2x_options_manager/odoo/addons/web_m2x_options_manager b/setup/web_m2x_options_manager/odoo/addons/web_m2x_options_manager new file mode 120000 index 000000000..53b3da28c --- /dev/null +++ b/setup/web_m2x_options_manager/odoo/addons/web_m2x_options_manager @@ -0,0 +1 @@ +../../../../web_m2x_options_manager \ No newline at end of file diff --git a/setup/web_m2x_options_manager/setup.py b/setup/web_m2x_options_manager/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_m2x_options_manager/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_pwa_oca/odoo/addons/web_pwa_oca b/setup/web_pwa_oca/odoo/addons/web_pwa_oca new file mode 120000 index 000000000..1b7095260 --- /dev/null +++ b/setup/web_pwa_oca/odoo/addons/web_pwa_oca @@ -0,0 +1 @@ +../../../../web_pwa_oca \ No newline at end of file diff --git a/setup/web_pwa_oca/setup.py b/setup/web_pwa_oca/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_pwa_oca/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_search_with_and/odoo/addons/web_search_with_and b/setup/web_search_with_and/odoo/addons/web_search_with_and new file mode 120000 index 000000000..d32981712 --- /dev/null +++ b/setup/web_search_with_and/odoo/addons/web_search_with_and @@ -0,0 +1 @@ +../../../../web_search_with_and \ No newline at end of file diff --git a/setup/web_search_with_and/setup.py b/setup/web_search_with_and/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_search_with_and/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_view_calendar_list/odoo/addons/web_view_calendar_list b/setup/web_view_calendar_list/odoo/addons/web_view_calendar_list new file mode 120000 index 000000000..2557cb64f --- /dev/null +++ b/setup/web_view_calendar_list/odoo/addons/web_view_calendar_list @@ -0,0 +1 @@ +../../../../web_view_calendar_list \ No newline at end of file diff --git a/setup/web_view_calendar_list/setup.py b/setup/web_view_calendar_list/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_view_calendar_list/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_char_size/odoo/addons/web_widget_char_size b/setup/web_widget_char_size/odoo/addons/web_widget_char_size new file mode 120000 index 000000000..abd6fe84b --- /dev/null +++ b/setup/web_widget_char_size/odoo/addons/web_widget_char_size @@ -0,0 +1 @@ +../../../../web_widget_char_size \ No newline at end of file diff --git a/setup/web_widget_char_size/setup.py b/setup/web_widget_char_size/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_char_size/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_child_selector/odoo/addons/web_widget_child_selector b/setup/web_widget_child_selector/odoo/addons/web_widget_child_selector new file mode 120000 index 000000000..e35e692af --- /dev/null +++ b/setup/web_widget_child_selector/odoo/addons/web_widget_child_selector @@ -0,0 +1 @@ +../../../../web_widget_child_selector \ No newline at end of file diff --git a/setup/web_widget_child_selector/setup.py b/setup/web_widget_child_selector/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_child_selector/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_ckeditor/odoo/addons/web_widget_ckeditor b/setup/web_widget_ckeditor/odoo/addons/web_widget_ckeditor new file mode 120000 index 000000000..79281285a --- /dev/null +++ b/setup/web_widget_ckeditor/odoo/addons/web_widget_ckeditor @@ -0,0 +1 @@ +../../../../web_widget_ckeditor \ No newline at end of file diff --git a/setup/web_widget_ckeditor/setup.py b/setup/web_widget_ckeditor/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_ckeditor/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_domain_editor_dialog/odoo/addons/web_widget_domain_editor_dialog b/setup/web_widget_domain_editor_dialog/odoo/addons/web_widget_domain_editor_dialog new file mode 120000 index 000000000..a36691af2 --- /dev/null +++ b/setup/web_widget_domain_editor_dialog/odoo/addons/web_widget_domain_editor_dialog @@ -0,0 +1 @@ +../../../../web_widget_domain_editor_dialog \ No newline at end of file diff --git a/setup/web_widget_domain_editor_dialog/setup.py b/setup/web_widget_domain_editor_dialog/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_domain_editor_dialog/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_image_download/odoo/addons/web_widget_image_download b/setup/web_widget_image_download/odoo/addons/web_widget_image_download new file mode 120000 index 000000000..ab050eae8 --- /dev/null +++ b/setup/web_widget_image_download/odoo/addons/web_widget_image_download @@ -0,0 +1 @@ +../../../../web_widget_image_download \ No newline at end of file diff --git a/setup/web_widget_image_download/setup.py b/setup/web_widget_image_download/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_image_download/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_image_webcam/odoo/addons/web_widget_image_webcam b/setup/web_widget_image_webcam/odoo/addons/web_widget_image_webcam new file mode 120000 index 000000000..21d7b390b --- /dev/null +++ b/setup/web_widget_image_webcam/odoo/addons/web_widget_image_webcam @@ -0,0 +1 @@ +../../../../web_widget_image_webcam \ No newline at end of file diff --git a/setup/web_widget_image_webcam/setup.py b/setup/web_widget_image_webcam/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_image_webcam/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_many2one_simple/odoo/addons/web_widget_many2one_simple b/setup/web_widget_many2one_simple/odoo/addons/web_widget_many2one_simple new file mode 120000 index 000000000..841068953 --- /dev/null +++ b/setup/web_widget_many2one_simple/odoo/addons/web_widget_many2one_simple @@ -0,0 +1 @@ +../../../../web_widget_many2one_simple \ No newline at end of file diff --git a/setup/web_widget_many2one_simple/setup.py b/setup/web_widget_many2one_simple/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_many2one_simple/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_model_viewer/odoo/addons/web_widget_model_viewer b/setup/web_widget_model_viewer/odoo/addons/web_widget_model_viewer new file mode 120000 index 000000000..44e6bb1b5 --- /dev/null +++ b/setup/web_widget_model_viewer/odoo/addons/web_widget_model_viewer @@ -0,0 +1 @@ +../../../../web_widget_model_viewer \ No newline at end of file diff --git a/setup/web_widget_model_viewer/setup.py b/setup/web_widget_model_viewer/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_model_viewer/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_open_tab/odoo/addons/web_widget_open_tab b/setup/web_widget_open_tab/odoo/addons/web_widget_open_tab new file mode 120000 index 000000000..8d41af8dc --- /dev/null +++ b/setup/web_widget_open_tab/odoo/addons/web_widget_open_tab @@ -0,0 +1 @@ +../../../../web_widget_open_tab \ No newline at end of file diff --git a/setup/web_widget_open_tab/setup.py b/setup/web_widget_open_tab/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_open_tab/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_plotly_chart/odoo/addons/web_widget_plotly_chart b/setup/web_widget_plotly_chart/odoo/addons/web_widget_plotly_chart new file mode 120000 index 000000000..37aa8c388 --- /dev/null +++ b/setup/web_widget_plotly_chart/odoo/addons/web_widget_plotly_chart @@ -0,0 +1 @@ +../../../../web_widget_plotly_chart \ No newline at end of file diff --git a/setup/web_widget_plotly_chart/setup.py b/setup/web_widget_plotly_chart/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_plotly_chart/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/setup/web_widget_text_markdown/odoo/addons/web_widget_text_markdown b/setup/web_widget_text_markdown/odoo/addons/web_widget_text_markdown new file mode 120000 index 000000000..872e5f4ad --- /dev/null +++ b/setup/web_widget_text_markdown/odoo/addons/web_widget_text_markdown @@ -0,0 +1 @@ +../../../../web_widget_text_markdown \ No newline at end of file diff --git a/setup/web_widget_text_markdown/setup.py b/setup/web_widget_text_markdown/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/web_widget_text_markdown/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) diff --git a/support_branding/README.rst b/support_branding/README.rst new file mode 100644 index 000000000..18faf9ab0 --- /dev/null +++ b/support_branding/README.rst @@ -0,0 +1,80 @@ +================ +Support Branding +================ + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |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%2Fweb-lightgray.png?logo=github + :target: https://github.com/OCA/web/tree/14.0/support_branding + :alt: OCA/web +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/web-14-0/web-14-0-support_branding + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/162/14.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +If you run an Odoo support company and you support customers without an OPW, +you can brand the Odoo instance accordingly using this module. This module will +add a support company url to profile menu under, `Support`. Moreover, +it will add a button to mail exception messages to your support email address. + +**Table of contents** + +.. contents:: + :local: + +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 smashing it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Therp BV +* Sunflower IT + +Contributors +~~~~~~~~~~~~ + +* Holger Brunn +* Stefan Rijnhart +* Robert Rottermann +* Kevin Kamau + +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/web `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/support_branding/__init__.py b/support_branding/__init__.py new file mode 100644 index 000000000..9416c2a04 --- /dev/null +++ b/support_branding/__init__.py @@ -0,0 +1,7 @@ +# Copyright 2012-2015 Therp BV () +# Copyright 2016 - Tecnativa - Angel Moya +# Copyright 2017 - redO2oo - Robert Rottermann +# Copyright 2021 Sunflower IT +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from . import models diff --git a/support_branding/__manifest__.py b/support_branding/__manifest__.py new file mode 100644 index 000000000..94c4d76b4 --- /dev/null +++ b/support_branding/__manifest__.py @@ -0,0 +1,24 @@ +# Copyright 2012-2015 Therp BV () +# Copyright 2016 - Tecnativa - Angel Moya +# Copyright 2017 - redO2oo - Robert Rottermann +# Copyright 2021 Sunflower IT () +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +{ + "name": "Support Branding", + "summary": "Adds your branding to an Odoo instance", + "category": "Hidden/Tools", + "version": "14.0.1.0.0", + "license": "AGPL-3", + "author": "Therp BV,Sunflower IT,Odoo Community Association (OCA)", + "website": "https://github.com/OCA/web", + "depends": ["web", "base_setup"], + "qweb": [ + "static/src/xml/base.xml", + ], + "data": ["views/asset.xml", "views/res_config_settings.xml"], + "demo": [ + "demo/ir_config_parameter_data.xml", + ], + "installable": True, +} diff --git a/support_branding/demo/ir_config_parameter_data.xml b/support_branding/demo/ir_config_parameter_data.xml new file mode 100644 index 000000000..ef9bf9417 --- /dev/null +++ b/support_branding/demo/ir_config_parameter_data.xml @@ -0,0 +1,25 @@ + + + + + support_company + Odoo Community Association + + + support_company_url + https://odoo-community.org + + + support_branding_color + #fff + + + support_email + oca@example.com + + + support_release + 14.0 + + + diff --git a/support_branding/i18n/nl.po b/support_branding/i18n/nl.po new file mode 100644 index 000000000..6c9c84f4c --- /dev/null +++ b/support_branding/i18n/nl.po @@ -0,0 +1,49 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * support_branding +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 8.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-01-30 10:05+0000\n" +"PO-Revision-Date: 2015-01-30 10:05+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: support_branding +#: model:ir.ui.view,arch_db:support_branding.menu_secondary +msgid ", supported by" +msgstr ", ondersteund door" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/js/support_branding.js:88 +#, python-format +msgid "Email to %s" +msgstr "E-mail naar %s" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:12 +#, python-format +msgid "Email to support company" +msgstr "E-mail naar ondersteunend bedrijf" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:10 +#, python-format +msgid "Please fill in how you produced this error..." +msgstr "Beschrijft u alstublieft de stappen om deze fout te reproduceren..." + +#. module: support_branding +#: model:ir.ui.view,arch_db:support_branding.menu_secondary +#, fuzzy +msgid "Version" +msgstr "Versie " diff --git a/support_branding/i18n/sl.po b/support_branding/i18n/sl.po new file mode 100644 index 000000000..461e00346 --- /dev/null +++ b/support_branding/i18n/sl.po @@ -0,0 +1,51 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * support_branding +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 8.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-08-02 10:23+0200\n" +"PO-Revision-Date: 2015-08-02 10:24+0200\n" +"Last-Translator: Matjaz Mozetic \n" +"Language-Team: \n" +"Language: sl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n" +"%100==4 ? 2 : 3);\n" +"X-Generator: Poedit 1.8.2\n" + +#. module: support_branding +#: model:ir.ui.view,arch_db:support_branding.menu_secondary +msgid ", supported by" +msgstr ", podpora" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/js/support_branding.js:88 +#, python-format +msgid "Email to %s" +msgstr "E-pošta za %s" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:12 +#, fuzzy, python-format +msgid "Email to support company" +msgstr "E-pošta za družbo" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:10 +#, python-format +msgid "Please fill in how you produced this error..." +msgstr "Opišite, kako ste prišli do te napake..." + +#. module: support_branding +#: model:ir.ui.view,arch_db:support_branding.menu_secondary +#, fuzzy +msgid "Version" +msgstr "Verzija" diff --git a/support_branding/i18n/support_branding.pot b/support_branding/i18n/support_branding.pot new file mode 100644 index 000000000..72fd297d8 --- /dev/null +++ b/support_branding/i18n/support_branding.pot @@ -0,0 +1,179 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * support_branding +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 14.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "" +"Add a branding color\n" +" e.g #b163a3" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "" +"Add the support company URL\n" +" e.g https://odoo-community.org" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "" +"Add the support company name\n" +" e.g Odoo Community Association (OCA)" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "" +"Add the support email to send issues\n" +" e.g info@helpdesksupport.com" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "Add the support release" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__support_branding_color +msgid "Branding color" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__support_company +msgid "Company Name" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__support_company_url +msgid "Company URL" +msgstr "" + +#. module: support_branding +#: model:ir.model,name:support_branding.model_res_config_settings +msgid "Config Settings" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "Creates an error (i.e ZeroDivisionError) to test support branding" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__display_name +msgid "Display Name" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/js/support_branding.js:0 +#, python-format +msgid "Email to %s" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "" +"Email to support\n" +" company" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "For Support visit our" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__id +msgid "ID" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings____last_update +msgid "Last Modified on" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "Please fill in how you produced this error..." +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "Support Company Settings" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "Support Settings" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__support_email +msgid "Support email" +msgstr "" + +#. module: support_branding +#: model:ir.model.fields,field_description:support_branding.field_res_config_settings__support_release +msgid "Support release" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "Technical Support By" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "Test Support Branding" +msgstr "" + +#. module: support_branding +#: model_terms:ir.ui.view,arch_db:support_branding.support_res_config_settings_view_form +msgid "" +"The below button generates a\n" +" division by zero python error which\n" +" allows a user to test the modules\n" +" functionality." +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "Use HTML Editor" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "or mail us at" +msgstr "" + +#. module: support_branding +#. openerp-web +#: code:addons/support_branding/static/src/xml/base.xml:0 +#, python-format +msgid "website" +msgstr "" diff --git a/support_branding/models/__init__.py b/support_branding/models/__init__.py new file mode 100644 index 000000000..4124bd743 --- /dev/null +++ b/support_branding/models/__init__.py @@ -0,0 +1,4 @@ +# Copyright 2021 Sunflower IT +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import res_config_settings diff --git a/support_branding/models/res_config_settings.py b/support_branding/models/res_config_settings.py new file mode 100644 index 000000000..6cbb58341 --- /dev/null +++ b/support_branding/models/res_config_settings.py @@ -0,0 +1,39 @@ +# Copyright 2021 Sunflower IT +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import fields, models + + +class ResConfigSettings(models.TransientModel): + _inherit = "res.config.settings" + + def get_values(self): + res = super(ResConfigSettings, self).get_values() + param_obj = self.env["ir.config_parameter"].sudo() + res.update( + support_company=param_obj.get_param("support_company"), + support_company_url=param_obj.get_param("support_company_url"), + support_email=param_obj.get_param("support_email"), + support_release=param_obj.get_param("support_release"), + support_branding_color=param_obj.get_param("support_branding_color"), + ) + return res + + def set_values(self): + res = super(ResConfigSettings, self).set_values() + param_obj = self.env["ir.config_parameter"].sudo() + param_obj.set_param("support_company", self.support_company) + param_obj.set_param("support_company_url", self.support_company_url) + param_obj.set_param("support_email", self.support_email) + param_obj.set_param("support_release", self.support_release) + param_obj.set_param("support_branding_color", self.support_branding_color) + return res + + support_company = fields.Char(string="Company Name") + support_company_url = fields.Char(string="Company URL") + support_branding_color = fields.Char(string="Branding color") + support_email = fields.Char(string="Support email") + support_release = fields.Char(string="Support release") + + def test_support_branding_error(self): + return 9 / 0 diff --git a/support_branding/readme/CONTRIBUTORS.rst b/support_branding/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..697abcab5 --- /dev/null +++ b/support_branding/readme/CONTRIBUTORS.rst @@ -0,0 +1,4 @@ +* Holger Brunn +* Stefan Rijnhart +* Robert Rottermann +* Kevin Kamau diff --git a/support_branding/readme/DESCRIPTION.rst b/support_branding/readme/DESCRIPTION.rst new file mode 100644 index 000000000..1191583f6 --- /dev/null +++ b/support_branding/readme/DESCRIPTION.rst @@ -0,0 +1,4 @@ +If you run an Odoo support company and you support customers without an OPW, +you can brand the Odoo instance accordingly using this module. This module will +add a support company url to profile menu under, `Support`. Moreover, +it will add a button to mail exception messages to your support email address. diff --git a/support_branding/static/description/icon.png b/support_branding/static/description/icon.png new file mode 100644 index 000000000..3a0328b51 Binary files /dev/null and b/support_branding/static/description/icon.png differ diff --git a/support_branding/static/description/index.html b/support_branding/static/description/index.html new file mode 100644 index 000000000..8ce513490 --- /dev/null +++ b/support_branding/static/description/index.html @@ -0,0 +1,426 @@ + + + + + + +Support Branding + + + +
+

Support Branding

+ + +

Beta License: AGPL-3 OCA/web Translate me on Weblate Try me on Runbot

+

If you run an Odoo support company and you support customers without an OPW, +you can brand the Odoo instance accordingly using this module. This module will +add a support company url to profile menu under, Support. Moreover, +it will add a button to mail exception messages to your support email address.

+

Table of contents

+ +
+

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 smashing it by providing a detailed and welcomed +feedback.

+

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

+
+
+

Credits

+
+

Authors

+
    +
  • Therp BV
  • +
  • Sunflower IT
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

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/web project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/support_branding/static/src/css/support_branding.css b/support_branding/static/src/css/support_branding.css new file mode 100644 index 000000000..c68217286 --- /dev/null +++ b/support_branding/static/src/css/support_branding.css @@ -0,0 +1,20 @@ +.support-branding-submit-form { + display: inline; + margin: 0; + width: 100%; +} + +.support-statement { + margin: 10px 0 10px 0; +} + +.support-statement .note-editor { + height: 230px; + overflow: scroll; +} + +.support-desc { + resize: block; + max-height: 139px; + box-sizing: border-box; +} diff --git a/support_branding/static/src/js/res_config_edition.js b/support_branding/static/src/js/res_config_edition.js new file mode 100644 index 000000000..48ac99cc3 --- /dev/null +++ b/support_branding/static/src/js/res_config_edition.js @@ -0,0 +1,33 @@ +odoo.define("support_branding.ResConfigEdition", function (require) { + "use strict"; + + var ResConfigEdition = require("base_setup.ResConfigEdition"); + + ResConfigEdition.include({ + willStart: function () { + var self = this; + var def_1 = this._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_company"], + }).then(function (name) { + self.support_cp_name = name; + }); + var def_2 = this._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_company_url"], + }).then(function (url) { + self.support_cp_url = url; + }); + var def_3 = this._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_email"], + }).then(function (email) { + self.support_cp_email = email; + }); + return $.when(this._super.apply(this, arguments), def_1, def_2, def_3); + }, + }); +}); diff --git a/support_branding/static/src/js/support_branding.js b/support_branding/static/src/js/support_branding.js new file mode 100644 index 000000000..95db62a55 --- /dev/null +++ b/support_branding/static/src/js/support_branding.js @@ -0,0 +1,195 @@ +/* Copyright 2012-2015 Therp + * Copyright 2016 - Tecnativa - Angel Moya + * Copyright 2017 - redO2oo - Robert Rottermann + * Copyright 2018 - Therp BV + * Copyright 2021 - Sunflower IT + * License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). */ + +odoo.define("support_branding.CrashManager", function (require) { + "use strict"; + var CrashManager = require("web.CrashManager").CrashManager; + var session = require("web.session"); + var core = require("web.core"); + var Wysiwyg = require("web_editor.wysiwyg.root"); + + var _t = core._t; + + CrashManager.include({ + init: function () { + var self = this; + $.when(this._super.apply(this, arguments)).then(function () { + self._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_company"], + }).then(function (name) { + self.support_cp_name = name; + }); + + self._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_company_url"], + }).then(function (url) { + self.support_cp_url = url; + }); + + self._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_email"], + }).then(function (email) { + self.support_cp_email = email; + }); + + self._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_release"], + }).then(function (release) { + self.support_cp_release = release; + }); + + self._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_branding_color"], + }).then(function (color) { + self.support_cp_color = color; + }); + }); + }, + show_error: function (error) { + var self = this; + this.wysiwyg = new Wysiwyg(self, {}); + var subject = + session.username + + "@" + + session.db + + "[" + + session.server + + "]:" + + error.message; + var body = error.data.debug; + var inputs = + "" + + '\n" + + '"; + return this._super.apply(this, arguments).opened(function () { + var $form = $(".support-branding-submit-form"); + var $statement = $(".support-statement"); + var $description = $(".support-desc"); + var $button = $(".support-btn"); + var $use_html_ck = $("#use_html_checker"); + var $close_btn = $(".close"); + var $body = $(".sp-body"); + var $header = $form.parents(".modal-dialog").find(".modal-header"); + var $footer = $form.parents(".modal-dialog").find(".modal-footer"); + // Self.wysiwyg.attachTo($description); + + $statement.prepend(inputs); + if (self.support_cp_email) { + if (self.support_cp_name) { + var title = "Support by " + self.support_cp_name; + $('

' + title + "

").insertBefore( + ".support-branding-submit-form" + ); + $button.text( + _.str.sprintf(_t("Email to %s"), self.support_cp_name) + ); + } + $form + .parents(".modal") + .find(".modal-body") + .css("max-height", "70vh"); + $use_html_ck.on("change", function () { + if (this.checked) { + if (self.wysiwyg.isDestroyed()) { + self.wysiwyg = new Wysiwyg(self, {}); + self.wysiwyg.attachTo($description); + } else self.wysiwyg.attachTo($description); + } else { + self.wysiwyg.destroy(); + $(".support-statement").append($description); + if ($description.is(":hidden")) + $description.css({display: "block"}); + } + }); + + $button.on("click", function (ev) { + var $btn = $(this); + if (!$description.val()) { + $description.parent().addClass("oe_form_invalid"); + ev.preventDefault(); + return; + } + ev.preventDefault(); + var error_code = ""; + var body_html = ""; + var desc = + self.wysiwyg.$editor && self.wysiwyg.$editor.length + ? self.wysiwyg.getValue() + : $description.val(); + desc = `
${desc}
`; + error_code = `
${body}
`; + body_html = `
${desc}
${error_code}
`; + var params = { + state: "outgoing", + auto_delete: true, + email_to: self.support_cp_email, + subject: subject, + body_html: body_html, + }; + self._rpc({ + model: "mail.mail", + method: "create", + args: [params], + }).then( + function (mail_id) { + if (mail_id) { + self._rpc({ + model: "mail.mail", + method: "send", + args: [mail_id], + }).then(function () { + self.do_notify( + "Success", + "Support mail created!" + ); + $close_btn.click(); + }); + } + }, + function () { + $body.val(desc + "\n\n" + $body.val()); + $btn.unbind("click"); + $btn.click(); + } + ); + }); + } else { + $description.css({display: "none"}); + $button.css({display: "none"}); + } + $form.prependTo($footer); + // Hide "Ok" button since we have close on the dialog top + // Allow send email btn to close once done. + $footer.find("button:eq(1)").css({display: "none"}); + + if (self.support_cp_color) { + $header.css({background: self.support_cp_color}); + $footer.css({background: self.support_cp_color}); + } else { + $header.css({background: ""}); + $footer.css({background: ""}); + } + }); + }, + }); +}); diff --git a/support_branding/static/src/js/user_menu.js b/support_branding/static/src/js/user_menu.js new file mode 100644 index 000000000..f0c76ba45 --- /dev/null +++ b/support_branding/static/src/js/user_menu.js @@ -0,0 +1,27 @@ +odoo.define("support_branding.UserMenu", function (require) { + "use strict"; + + var user_menu = require("web.UserMenu"); + + user_menu.include({ + _onMenuSupport: function () { + var url = this.support_url || "https://www.odoo.com/buy"; + window.open(url, "_blank"); + }, + willStart: function () { + var self = this; + var def = self + ._rpc({ + model: "ir.config_parameter", + method: "get_param", + args: ["support_company_url"], + }) + .then(function (site) { + if (site && site !== "") { + self.support_url = site; + } + }); + return $.when(this._super.apply(this, arguments), def); + }, + }); +}); diff --git a/support_branding/static/src/tests/support_branding_tests.js b/support_branding/static/src/tests/support_branding_tests.js new file mode 100644 index 000000000..bc97daf26 --- /dev/null +++ b/support_branding/static/src/tests/support_branding_tests.js @@ -0,0 +1,80 @@ +odoo.define("support_branding.crash_manager_tests", function (require) { + "use strict"; + + /* global QUnit*/ + + const CrashManager = require("web.CrashManager").CrashManager; + const testUtils = require("web.test_utils"); + const createActionManager = testUtils.createActionManager; + + QUnit.module("support_branding", {}, function () { + QUnit.test("Error Dialog is created", async function (assert) { + // No of assertion expected. + assert.expect(5); + + // Create action manager to trigger error dialog + var actionManager = await createActionManager({ + services: { + crash_manager: CrashManager, + }, + }); + + // Check if action with crash manager service was created. + assert.notOk( + _.isEmpty(actionManager), + "Action manager with " + + "crash manager service should be created and not empty" + ); + + // Test custom error + const error = { + type: "Support Branding Odoo Client Error", + message: "Message", + data: { + debug: "Traceback", + }, + }; + // NB: This will use the saved res.config settings of support + // branding containing the support mail. It is fetched in crash + // manager init function as saved in res.config settings. + // attached is a default data xml with sample data. + actionManager.call("crash_manager", "show_error", error); + await testUtils.nextTick(); + var $mail_dialog = "form.support-branding-submit-form"; + + // Confirm if we have a form and its required elements. + assert.containsOnce( + $, + $mail_dialog, + "Error dialog should be opened and showing mail section on footer" + ); + assert.containsOnce( + $, + ".support-desc", + "We should have a textarea to add our issues" + ); + assert.containsOnce( + $, + "button.support-btn", + "We should have a send mail button to send support mail" + ); + + // Add a test text mail. + $(".support-desc").val( + "Send this as a test mail to configured support mail" + ); + + // Try to send mail, by default a popup will be triggered + // defaulting to form call of 'mailto'. + await testUtils.dom.click($("button.support-btn"), {allowInvisible: true}); + + // Close error dialog + await testUtils.dom.click($("button.close"), {allowInvisible: true}); + + // Confirm dialog was closed + assert.containsNone($, $mail_dialog, "Error Dialog should be closed"); + + actionManager.destroy(); + }); + }); +}); diff --git a/support_branding/static/src/xml/base.xml b/support_branding/static/src/xml/base.xml new file mode 100644 index 000000000..cf88e7e68 --- /dev/null +++ b/support_branding/static/src/xml/base.xml @@ -0,0 +1,80 @@ + + + + +
+
+
+ + +
+
+