From 5f665760aed4884bf96b5b24274630293a5dccd7 Mon Sep 17 00:00:00 2001 From: benjamin <benjamin@le-filament.com> Date: Thu, 7 Apr 2022 10:05:25 +0200 Subject: [PATCH] [mig] Migration 14.0 + add pre-commit changes --- .editorconfig | 20 + .eslintrc.yml | 187 ++++++ .flake8 | 12 + .gitignore | 75 +++ .isort.cfg | 13 + .pre-commit-config.yaml | 127 ++++ .prettierrc.yml | 8 + .pylintrc | 87 +++ .pylintrc-mandatory | 64 +++ README.rst | 0 __init__.py | 3 +- __manifest__.py | 6 +- datas/exo_ur_notice_data.xml | 2 +- datas/ir_sequence_data.xml | 4 +- migration/14.0.1.0.0/post-migration.py | 67 +++ migration/14.0.1.0.0/pre-migration.py | 13 + models/__init__.py | 0 models/res_partner.py | 10 +- models/scop_bordereau.py | 30 +- models/scop_cotisation_cg.py | 17 +- models/scop_cotisation_cg_exo.py | 544 ++++++++++-------- models/scop_cotisation_cg_exo_line.py | 22 +- models/scop_cotisation_cg_exo_ur_notice.py | 6 +- models/scop_instance.py | 22 +- security/ir.model.access.csv | 0 security/security_rules.xml | 10 +- static/description/icon.png | Bin 9161 -> 15890 bytes templates/report_scop_exo.xml | 100 +++- views/res_partner.xml | 61 +- views/scop_bordereau_cg.xml | 23 +- views/scop_cotisation_cg_exo.xml | 300 +++++++--- views/scop_cotisation_cg_exo_ur_notice.xml | 30 +- views/scop_instance.xml | 82 ++- wizard/__init__.py | 0 wizard/scop_bordereau_update_liasse_wizard.py | 2 +- 35 files changed, 1470 insertions(+), 477 deletions(-) create mode 100644 .editorconfig create mode 100644 .eslintrc.yml create mode 100644 .flake8 create mode 100644 .gitignore create mode 100644 .isort.cfg create mode 100644 .pre-commit-config.yaml create mode 100644 .prettierrc.yml create mode 100644 .pylintrc create mode 100644 .pylintrc-mandatory mode change 100755 => 100644 README.rst mode change 100755 => 100644 __init__.py mode change 100755 => 100644 __manifest__.py create mode 100644 migration/14.0.1.0.0/post-migration.py create mode 100644 migration/14.0.1.0.0/pre-migration.py mode change 100755 => 100644 models/__init__.py mode change 100755 => 100644 security/ir.model.access.csv mode change 100755 => 100644 static/description/icon.png mode change 100755 => 100644 wizard/__init__.py diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..bfd7ac5 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,20 @@ +# Configuration for known file extensions +[*.{css,js,json,less,md,py,rst,sass,scss,xml,yaml,yml}] +charset = utf-8 +end_of_line = lf +indent_size = 4 +indent_style = space +insert_final_newline = true +trim_trailing_whitespace = true + +[*.{json,yml,yaml,rst,md}] +indent_size = 2 + +# Do not configure editor for libs and autogenerated content +[{*/static/{lib,src/lib}/**,*/static/description/index.html,*/readme/../README.rst}] +charset = unset +end_of_line = unset +indent_size = unset +indent_style = unset +insert_final_newline = false +trim_trailing_whitespace = false diff --git a/.eslintrc.yml b/.eslintrc.yml new file mode 100644 index 0000000..d4cc423 --- /dev/null +++ b/.eslintrc.yml @@ -0,0 +1,187 @@ +env: + browser: true + es6: true + +# See https://github.com/OCA/odoo-community.org/issues/37#issuecomment-470686449 +parserOptions: + ecmaVersion: 2017 + +overrides: + - files: + - "**/*.esm.js" + parserOptions: + sourceType: module + +# Globals available in Odoo that shouldn't produce errorings +globals: + _: readonly + $: readonly + fuzzy: readonly + jQuery: readonly + moment: readonly + odoo: readonly + openerp: readonly + owl: readonly + +# Styling is handled by Prettier, so we only need to enable AST rules; +# see https://github.com/OCA/maintainer-quality-tools/pull/618#issuecomment-558576890 +rules: + accessor-pairs: warn + array-callback-return: warn + callback-return: warn + capitalized-comments: + - warn + - always + - ignoreConsecutiveComments: true + ignoreInlineComments: true + complexity: + - warn + - 15 + constructor-super: warn + dot-notation: warn + eqeqeq: warn + global-require: warn + handle-callback-err: warn + id-blacklist: warn + id-match: warn + init-declarations: error + max-depth: warn + max-nested-callbacks: warn + max-statements-per-line: warn + no-alert: warn + no-array-constructor: warn + no-caller: warn + no-case-declarations: warn + no-class-assign: warn + no-cond-assign: error + no-const-assign: error + no-constant-condition: warn + no-control-regex: warn + no-debugger: error + no-delete-var: warn + no-div-regex: warn + no-dupe-args: error + no-dupe-class-members: error + no-dupe-keys: error + no-duplicate-case: error + no-duplicate-imports: error + no-else-return: warn + no-empty-character-class: warn + no-empty-function: error + no-empty-pattern: error + no-empty: warn + no-eq-null: error + no-eval: error + no-ex-assign: error + no-extend-native: warn + no-extra-bind: warn + no-extra-boolean-cast: warn + no-extra-label: warn + no-fallthrough: warn + no-func-assign: error + no-global-assign: error + no-implicit-coercion: + - warn + - allow: ["~"] + no-implicit-globals: warn + no-implied-eval: warn + no-inline-comments: warn + no-inner-declarations: warn + no-invalid-regexp: warn + no-irregular-whitespace: warn + no-iterator: warn + no-label-var: warn + no-labels: warn + no-lone-blocks: warn + no-lonely-if: error + no-mixed-requires: error + no-multi-str: warn + no-native-reassign: error + no-negated-condition: warn + no-negated-in-lhs: error + no-new-func: warn + no-new-object: warn + no-new-require: warn + no-new-symbol: warn + no-new-wrappers: warn + no-new: warn + no-obj-calls: warn + no-octal-escape: warn + no-octal: warn + no-param-reassign: warn + no-path-concat: warn + no-process-env: warn + no-process-exit: warn + no-proto: warn + no-prototype-builtins: warn + no-redeclare: warn + no-regex-spaces: warn + no-restricted-globals: warn + no-restricted-imports: warn + no-restricted-modules: warn + no-restricted-syntax: warn + no-return-assign: error + no-script-url: warn + no-self-assign: warn + no-self-compare: warn + no-sequences: warn + no-shadow-restricted-names: warn + no-shadow: warn + no-sparse-arrays: warn + no-sync: warn + no-this-before-super: warn + no-throw-literal: warn + no-undef-init: warn + no-undef: error + no-unmodified-loop-condition: warn + no-unneeded-ternary: error + no-unreachable: error + no-unsafe-finally: error + no-unused-expressions: error + no-unused-labels: error + no-unused-vars: error + no-use-before-define: error + no-useless-call: warn + no-useless-computed-key: warn + no-useless-concat: warn + no-useless-constructor: warn + no-useless-escape: warn + no-useless-rename: warn + no-void: warn + no-with: warn + operator-assignment: [error, always] + prefer-const: warn + radix: warn + require-yield: warn + sort-imports: warn + spaced-comment: [error, always] + strict: [error, function] + use-isnan: error + valid-jsdoc: + - warn + - prefer: + arg: param + argument: param + augments: extends + constructor: class + exception: throws + func: function + method: function + prop: property + return: returns + virtual: abstract + yield: yields + preferType: + array: Array + bool: Boolean + boolean: Boolean + number: Number + object: Object + str: String + string: String + requireParamDescription: false + requireReturn: false + requireReturnDescription: false + requireReturnType: false + valid-typeof: warn + yoda: warn diff --git a/.flake8 b/.flake8 new file mode 100644 index 0000000..e397e8e --- /dev/null +++ b/.flake8 @@ -0,0 +1,12 @@ +[flake8] +max-line-length = 88 +max-complexity = 16 +# B = bugbear +# B9 = bugbear opinionated (incl line length) +select = C,E,F,W,B,B9 +# E203: whitespace before ':' (black behaviour) +# E501: flake8 line length (covered by bugbear B950) +# W503: line break before binary operator (black behaviour) +ignore = E203,E501,W503 +per-file-ignores= + __init__.py:F401 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..818770f --- /dev/null +++ b/.gitignore @@ -0,0 +1,75 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +/.venv +/.pytest_cache + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +bin/ +build/ +develop-eggs/ +dist/ +eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +*.egg-info/ +.installed.cfg +*.egg +*.eggs + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.cache +nosetests.xml +coverage.xml + +# Translations +*.mo + +# Pycharm +.idea + +# Eclipse +.settings + +# Visual Studio cache/options directory +.vs/ +.vscode + +# OSX Files +.DS_Store + +# Django stuff: +*.log + +# Mr Developer +.mr.developer.cfg +.project +.pydevproject + +# Rope +.ropeproject + +# Sphinx documentation +docs/_build/ + +# Backup files +*~ +*.swp + +# OCA rules +!static/lib/ diff --git a/.isort.cfg b/.isort.cfg new file mode 100644 index 0000000..0ec187e --- /dev/null +++ b/.isort.cfg @@ -0,0 +1,13 @@ +[settings] +; see https://github.com/psf/black +multi_line_output=3 +include_trailing_comma=True +force_grid_wrap=0 +combine_as_imports=True +use_parentheses=True +line_length=88 +known_odoo=odoo +known_odoo_addons=odoo.addons +sections=FUTURE,STDLIB,THIRDPARTY,ODOO,ODOO_ADDONS,FIRSTPARTY,LOCALFOLDER +default_section=THIRDPARTY +ensure_newline_before_comments = True diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..1c6434b --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,127 @@ +exclude: | + (?x) + # NOT INSTALLABLE ADDONS + # END NOT INSTALLABLE ADDONS + # 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/| + # Maybe reactivate this when all README files include prettier ignore tags? + ^README\.md$| + # Library files can have extraneous formatting (even minimized) + /static/(src/)?lib/| + # Repos using Sphinx to generate docs don't need prettying + ^docs/_templates/.*\.html$| + # You don't usually want a bot to modify your legal texts + (LICENSE.*|COPYING.*) +default_language_version: + python: python3 + node: "14.13.0" +repos: + - repo: local + hooks: + # These files are most likely copier diff rejection junks; if found, + # review them manually, fix the problem (if needed) and remove them + - id: forbidden-files + name: forbidden files + entry: found forbidden files; remove them + language: fail + files: "\\.rej$" + - repo: https://github.com/oca/maintainer-tools + rev: ab1d7f6 + hooks: + # update the NOT INSTALLABLE ADDONS section above + - id: oca-update-pre-commit-excluded-addons + - id: oca-fix-manifest-website + args: ["https://le-filament.com"] + - repo: https://github.com/myint/autoflake + rev: v1.4 + hooks: + - id: autoflake + args: + - --expand-star-imports + - --ignore-init-module-imports + - --in-place + - --remove-all-unused-imports + - --remove-duplicate-keys + - --remove-unused-variables + - repo: https://github.com/psf/black + rev: 20.8b1 + hooks: + - id: black + - repo: https://github.com/pre-commit/mirrors-prettier + rev: v2.1.2 + hooks: + - id: prettier + name: prettier (with plugin-xml) + additional_dependencies: + - "prettier@2.1.2" + - "@prettier/plugin-xml@0.12.0" + 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: v7.8.1 + hooks: + - id: eslint + verbose: true + args: + - --color + - --fix + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v3.2.0 + hooks: + - id: trailing-whitespace + # exclude autogenerated files + exclude: /README\.rst$|\.pot?$ + - id: end-of-file-fixer + # exclude autogenerated files + exclude: /README\.rst$|\.pot?$ + - id: debug-statements + - id: fix-encoding-pragma + args: ["--remove"] + - id: check-case-conflict + - id: check-docstring-first + - id: check-executables-have-shebangs + - id: check-merge-conflict + # exclude files where underlines are not distinguishable from merge conflicts + exclude: /README\.rst$|^docs/.*\.rst$ + - id: check-symlinks + - id: check-xml + - id: mixed-line-ending + args: ["--fix=lf"] + - repo: https://github.com/asottile/pyupgrade + rev: v2.7.2 + hooks: + - id: pyupgrade + args: ["--keep-percent-format"] + - repo: https://github.com/PyCQA/isort + rev: 5.5.1 + hooks: + - id: isort + name: isort except __init__.py + args: + - --settings=. + exclude: /__init__\.py$ + - repo: https://gitlab.com/PyCQA/flake8 + rev: 3.8.3 + hooks: + - id: flake8 + name: flake8 + additional_dependencies: ["flake8-bugbear==20.1.4"] + - repo: https://github.com/PyCQA/pylint + rev: pylint-2.5.3 + hooks: + - id: pylint + name: pylint with optional checks + args: + - --rcfile=.pylintrc + - --exit-zero + verbose: true + additional_dependencies: &pylint_deps + - pylint-odoo==3.5.0 + - id: pylint + name: pylint with mandatory checks + args: + - --rcfile=.pylintrc-mandatory + additional_dependencies: *pylint_deps diff --git a/.prettierrc.yml b/.prettierrc.yml new file mode 100644 index 0000000..5b6d4b3 --- /dev/null +++ b/.prettierrc.yml @@ -0,0 +1,8 @@ +# Defaults for all prettier-supported languages. +# Prettier will complete this with settings from .editorconfig file. +bracketSpacing: false +printWidth: 88 +proseWrap: always +semi: true +trailingComma: "es5" +xmlWhitespaceSensitivity: "strict" diff --git a/.pylintrc b/.pylintrc new file mode 100644 index 0000000..dc6270e --- /dev/null +++ b/.pylintrc @@ -0,0 +1,87 @@ +[MASTER] +load-plugins=pylint_odoo +score=n + +[ODOOLINT] +readme_template_url="https://github.com/OCA/maintainer-tools/blob/master/template/module/README.rst" +manifest_required_authors=Le Filament +manifest_required_keys=license +manifest_deprecated_keys=description,active +license_allowed=AGPL-3,GPL-2,GPL-2 or any later version,GPL-3,GPL-3 or any later version,LGPL-3 +valid_odoo_versions=14.0 + +[MESSAGES CONTROL] +disable=all + +# This .pylintrc contains optional AND mandatory checks and is meant to be +# loaded in an IDE to have it check everything, in the hope this will make +# optional checks more visible to contributors who otherwise never look at a +# green travis to see optional checks that failed. +# .pylintrc-mandatory containing only mandatory checks is used the pre-commit +# config as a blocking check. + +enable=anomalous-backslash-in-string, + api-one-deprecated, + api-one-multi-together, + assignment-from-none, + attribute-deprecated, + class-camelcase, + dangerous-default-value, + dangerous-view-replace-wo-priority, + development-status-allowed, + duplicate-id-csv, + duplicate-key, + duplicate-xml-fields, + duplicate-xml-record-id, + eval-referenced, + eval-used, + incoherent-interpreter-exec-perm, + license-allowed, + manifest-author-string, + manifest-deprecated-key, + manifest-required-author, + manifest-required-key, + manifest-version-format, + method-compute, + method-inverse, + method-required-super, + method-search, + openerp-exception-warning, + pointless-statement, + pointless-string-statement, + print-used, + redundant-keyword-arg, + redundant-modulename-xml, + reimported, + relative-import, + return-in-init, + rst-syntax-error, + sql-injection, + too-few-format-args, + translation-field, + translation-required, + unreachable, + use-vim-comment, + wrong-tabs-instead-of-spaces, + xml-syntax-error, + # messages that do not cause the lint step to fail + consider-merging-classes-inherited, + create-user-wo-reset-password, + dangerous-filter-wo-user, + deprecated-module, + file-not-used, + invalid-commit, + missing-manifest-dependency, + missing-newline-extrafiles, + no-utf8-coding-comment, + odoo-addons-relative-import, + old-api7-method-defined, + redefined-builtin, + too-complex, + unnecessary-utf8-coding-comment + + +[REPORTS] +msg-template={path}:{line}: [{msg_id}({symbol}), {obj}] {msg} +output-format=colorized +reports=no diff --git a/.pylintrc-mandatory b/.pylintrc-mandatory new file mode 100644 index 0000000..43ea239 --- /dev/null +++ b/.pylintrc-mandatory @@ -0,0 +1,64 @@ +[MASTER] +load-plugins=pylint_odoo +score=n + +[ODOOLINT] +readme_template_url="https://github.com/OCA/maintainer-tools/blob/master/template/module/README.rst" +manifest_required_authors=Le Filament +manifest_required_keys=license +manifest_deprecated_keys=description,active +license_allowed=AGPL-3,GPL-2,GPL-2 or any later version,GPL-3,GPL-3 or any later version,LGPL-3 +valid_odoo_versions=14.0 + +[MESSAGES CONTROL] +disable=all + +enable=anomalous-backslash-in-string, + api-one-deprecated, + api-one-multi-together, + assignment-from-none, + attribute-deprecated, + class-camelcase, + dangerous-default-value, + dangerous-view-replace-wo-priority, + development-status-allowed, + duplicate-id-csv, + duplicate-key, + duplicate-xml-fields, + duplicate-xml-record-id, + eval-referenced, + eval-used, + incoherent-interpreter-exec-perm, + license-allowed, + manifest-author-string, + manifest-deprecated-key, + manifest-required-author, + manifest-required-key, + manifest-version-format, + method-compute, + method-inverse, + method-required-super, + method-search, + openerp-exception-warning, + pointless-statement, + pointless-string-statement, + print-used, + redundant-keyword-arg, + redundant-modulename-xml, + reimported, + relative-import, + return-in-init, + rst-syntax-error, + sql-injection, + too-few-format-args, + translation-field, + translation-required, + unreachable, + use-vim-comment, + wrong-tabs-instead-of-spaces, + xml-syntax-error + +[REPORTS] +msg-template={path}:{line}: [{msg_id}({symbol}), {obj}] {msg} +output-format=colorized +reports=no diff --git a/README.rst b/README.rst old mode 100755 new mode 100644 diff --git a/__init__.py b/__init__.py old mode 100755 new mode 100644 index f8a7089..a39f7c9 --- a/__init__.py +++ b/__init__.py @@ -1,5 +1,4 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from . import models -from . import wizard +from . import models, wizard diff --git a/__manifest__.py b/__manifest__.py old mode 100755 new mode 100644 index 3fdf794..d62ea0c --- a/__manifest__.py +++ b/__manifest__.py @@ -1,7 +1,7 @@ { "name": "CG SCOP - Cotisations CG - Enonérations", "summary": "Gestion des exonérations CG Scop", - "version": "12.0.0.0", + "version": "14.0.1.0.0", "author": "Le Filament", "license": "AGPL-3", "application": False, @@ -24,6 +24,6 @@ "views/scop_cotisation_cg_exo_ur_notice.xml", "views/scop_instance.xml", # templates - "templates/report_scop_exo.xml" - ] + "templates/report_scop_exo.xml", + ], } diff --git a/datas/exo_ur_notice_data.xml b/datas/exo_ur_notice_data.xml index 140746f..f58688c 100644 --- a/datas/exo_ur_notice_data.xml +++ b/datas/exo_ur_notice_data.xml @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <odoo> <data noupdate="1"> <record id="ur_notice_1" model="scop.cotisation.cg.exo.ur.notice"> diff --git a/datas/ir_sequence_data.xml b/datas/ir_sequence_data.xml index 3a5abd7..206170b 100644 --- a/datas/ir_sequence_data.xml +++ b/datas/ir_sequence_data.xml @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <!-- Copyright 2019 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> @@ -10,7 +10,7 @@ <field name="code">scop.cotisation.cg.exo</field> <field name="prefix">EXO-%(year)s-</field> <field name="padding">4</field> - <field name="company_id" ref="base.main_company"/> + <field name="company_id" ref="base.main_company" /> </record> </data> diff --git a/migration/14.0.1.0.0/post-migration.py b/migration/14.0.1.0.0/post-migration.py new file mode 100644 index 0000000..75d155f --- /dev/null +++ b/migration/14.0.1.0.0/post-migration.py @@ -0,0 +1,67 @@ +# © 2022 Le Filament (<http://www.le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from openupgradelib import openupgrade # pylint: disable=W7936 + + +def scop_cotisation_cg_exo_map_values(env): + openupgrade.map_values( + env.cr, + openupgrade.get_legacy_name("quarter_exo_start"), + "scop_cotisation_cg_exo", + [ + (1, "1"), + (2, "2"), + (3, "3"), + (4, "4"), + ], + table="scop_cotisation_cg_exo", + ) + openupgrade.map_values( + env.cr, + openupgrade.get_legacy_name("quarter_exo_end"), + "scop_cotisation_cg_exo", + [ + (1, "1"), + (2, "2"), + (3, "3"), + (4, "4"), + ], + table="scop_cotisation_cg_exo", + ) + openupgrade.map_values( + env.cr, + openupgrade.get_legacy_name("year_exo_start"), + "scop_cotisation_cg_exo", + [ + (2017, "2017"), + (2018, "2018"), + (2019, "2019"), + (2020, "2020"), + (2021, "2021"), + (2022, "2022"), + (2023, "2023"), + (2024, "2024"), + ], + table="scop_cotisation_cg_exo", + ) + openupgrade.map_values( + env.cr, + openupgrade.get_legacy_name("year_exo_end"), + "scop_cotisation_cg_exo", + [ + (2017, "2017"), + (2018, "2018"), + (2019, "2019"), + (2020, "2020"), + (2021, "2021"), + (2022, "2022"), + (2023, "2023"), + (2024, "2024"), + ], + table="scop_cotisation_cg_exo", + ) + +@openupgrade.migrate() +def migrate(env, version): + scop_cotisation_cg_exo_map_values(env) diff --git a/migration/14.0.1.0.0/pre-migration.py b/migration/14.0.1.0.0/pre-migration.py new file mode 100644 index 0000000..a064318 --- /dev/null +++ b/migration/14.0.1.0.0/pre-migration.py @@ -0,0 +1,13 @@ +# © 2022 Le Filament (<http://www.le-filament.com>) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from openupgradelib import openupgrade + +column_renames = { + "scop_cotisation_cg_exo": [("quarter_exo_start", None), ("quarter_exo_end", None), ("year_exo_start", None), ("year_exo_end", None)], +} + + +@openupgrade.migrate() +def migrate(env, version): + openupgrade.rename_columns(env.cr, column_renames) diff --git a/models/__init__.py b/models/__init__.py old mode 100755 new mode 100644 diff --git a/models/res_partner.py b/models/res_partner.py index 3d0a346..6b61de6 100644 --- a/models/res_partner.py +++ b/models/res_partner.py @@ -5,11 +5,11 @@ from odoo import fields, models class ResPartner(models.Model): - _inherit = 'res.partner' + _inherit = "res.partner" exo_ids = fields.One2many( - comodel_name='scop.cotisation.cg.exo', - inverse_name='partner_id', - domain=[('state', '=', 'done')], - string='Exonérations' + comodel_name="scop.cotisation.cg.exo", + inverse_name="partner_id", + domain=[("state", "=", "done")], + string="Exonérations", ) diff --git a/models/scop_bordereau.py b/models/scop_bordereau.py index 8048fb9..4905d68 100644 --- a/models/scop_bordereau.py +++ b/models/scop_bordereau.py @@ -1,28 +1,26 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from odoo import fields, models, api +from odoo import fields, models class ScopBordereau(models.Model): - _inherit = 'scop.bordereau' + _inherit = "scop.bordereau" exo_ids = fields.Many2many( - comodel_name='scop.cotisation.cg.exo', - relation='scop_bordereau_exo_rel', - column1='bordereau_id', - column2='exo_id', - string="Exonérations" + comodel_name="scop.cotisation.cg.exo", + relation="scop_bordereau_exo_rel", + column1="bordereau_id", + column2="exo_id", + string="Exonérations", ) exo_count = fields.Integer( - string='Nombre d\'exonérations', - compute='_compute_exo_count' + string="Nombre d'exonérations", compute="_compute_exo_count" ) # ------------------------------------------------------ # Compute fields # ------------------------------------------------------ - @api.multi def _compute_exo_count(self): for bdx in self: bdx.exo_count = len(bdx.exo_ids) @@ -35,12 +33,12 @@ class ScopBordereau(models.Model): Ouvre la vue sur les exonérations liées """ return { - 'type': 'ir.actions.act_window', - 'name': 'Exonérations', - 'view_mode': 'tree,form', - 'res_model': 'scop.cotisation.cg.exo', - 'target': 'current', - 'domain': [('id', 'in', self.exo_ids.ids)], + "type": "ir.actions.act_window", + "name": "Exonérations", + "view_mode": "tree,form", + "res_model": "scop.cotisation.cg.exo", + "target": "current", + "domain": [("id", "in", self.exo_ids.ids)], } # ------------------------------------------------------ diff --git a/models/scop_cotisation_cg.py b/models/scop_cotisation_cg.py index edff259..161e6c6 100644 --- a/models/scop_cotisation_cg.py +++ b/models/scop_cotisation_cg.py @@ -10,8 +10,7 @@ class ScopCotisation(models.Model): # ------------------------------------------------------ # Override parent # ------------------------------------------------------ - def create_bordereau( - self, member, nb_quarter, liasse=None, date=False): + def create_bordereau(self, member, nb_quarter, liasse=None, date=False): """ Surcharge la fonction parente pour créer les avoirs si il y a des exonérations @@ -22,12 +21,14 @@ class ScopCotisation(models.Model): bdx_id = self.bordereau_ids.browse(bordereau) # Search if exo - exo_ids = self.env['scop.cotisation.cg.exo'].search([ - ('partner_id', '=', bdx_id.partner_id.id), - ('year_exo_start', '<=', bdx_id.year), - ('year_exo_end', '>=', bdx_id.year), - ('state', '=', 'done') - ]) + exo_ids = self.env["scop.cotisation.cg.exo"].search( + [ + ("partner_id", "=", bdx_id.partner_id.id), + ("year_exo_start", "<=", bdx_id.year), + ("year_exo_end", ">=", bdx_id.year), + ("state", "=", "done"), + ] + ) if exo_ids: for exo in exo_ids: exo.create_exo_refund(bdx_id) diff --git a/models/scop_cotisation_cg_exo.py b/models/scop_cotisation_cg_exo.py index 031f204..6fb3041 100644 --- a/models/scop_cotisation_cg_exo.py +++ b/models/scop_cotisation_cg_exo.py @@ -1,234 +1,266 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from datetime import datetime, date +from datetime import date, datetime -from odoo import models, fields, api -from odoo.exceptions import ValidationError, UserError +from odoo import _, api, fields, models +from odoo.exceptions import UserError, ValidationError QUARTER_SELECTION = [ - (1, '1er trimestre'), - (2, '2ème trimestre'), - (3, '3ème trimestre'), - (4, '4ème trimestre') + ("1", "1er trimestre"), + ("2", "2ème trimestre"), + ("3", "3ème trimestre"), + ("4", "4ème trimestre"), ] class ScopCotisationExo(models.Model): _name = "scop.cotisation.cg.exo" _description = "Exonerations CG" - _inherit = ['mail.thread', 'mail.activity.mixin'] - _order = 'date_request desc' + _inherit = ["mail.thread", "mail.activity.mixin"] + _order = "date_request desc" @api.model def get_year_selection(self): return [ - (num, str(num)) for num in range((datetime.now().year + 3), (datetime.now().year - 10))] + (num, str(num)) + for num in range((datetime.now().year + 3), (datetime.now().year - 10)) + ] - name = fields.Char( - string='Nom', - compute='_compute_name', - search='_search_name') - number = fields.Char('Référence', readonly=1, index=True, default='New') + name = fields.Char(string="Nom", compute="_compute_name", search="_search_name") + number = fields.Char("Référence", readonly=1, index=True, default="New") partner_id = fields.Many2one( - comodel_name='res.partner', + comodel_name="res.partner", string="Coopérative", required=True, - domain=[('is_cooperative', '=', True), ('membership_status', '=', 'member')], - track_visibility='onchange') - date_request = fields.Date('Date de la demande', required=True, track_visibility='onchange') - motivation = fields.Text('Motivation de la SCOP') - source = fields.Selection([ - ('scop', 'SCOP'), - ('ur', 'UR')], + domain=[ + ("is_cooperative", "=", True), + ("membership_status", "=", "member"), + ], + tracking=1, + ) + date_request = fields.Date("Date de la demande", required=True, tracking=1) + motivation = fields.Text("Motivation de la SCOP") + source = fields.Selection( + [("scop", "SCOP"), ("ur", "UR")], string="Source", required=True, - track_visibility='onchange') - state = fields.Selection([ - ('todo', 'En cours de traitement'), - ('waiting', 'En attente présentation Instance'), - ('done', 'Traité'), - ('cancel', 'Annulé')], + tracking=1, + ) + state = fields.Selection( + [ + ("todo", "En cours de traitement"), + ("waiting", "En attente présentation Instance"), + ("done", "Traité"), + ("cancel", "Annulé"), + ], string="Statut", required=True, - default='todo', - track_visibility='onchange') - final_notice = fields.Selection([ - ('favorable', 'Favorable'), - ('unfavorable', 'Défavorable')], + default="todo", + tracking=1, + ) + final_notice = fields.Selection( + [("favorable", "Favorable"), ("unfavorable", "Défavorable")], string="Avis Final", - track_visibility='onchange') + tracking=1, + ) ur_notice = fields.Many2one( - comodel_name='scop.cotisation.cg.exo.ur.notice', + comodel_name="scop.cotisation.cg.exo.ur.notice", string="Avis UR", required=True, - track_visibility='onchange') + tracking=1, + ) quarter_exo_start = fields.Selection( - selection=QUARTER_SELECTION, - string='Trimestre initial' + selection=QUARTER_SELECTION, string="Trimestre initial" ) year_exo_start = fields.Selection( - selection=[(year, str(year)) for year in - range(2021, 2035)], - string='Année initiale' + selection=[(str(year), str(year)) for year in range(2021, 2035)], + string="Année initiale", ) quarter_exo_end = fields.Selection( - selection=QUARTER_SELECTION, - string='Trimestre final' + selection=QUARTER_SELECTION, string="Trimestre final" ) year_exo_end = fields.Selection( - selection=[(year, str(year)) for year in - range(2021, 2035)], - string='Année finale' + selection=[(str(year), str(year)) for year in range(2021, 2035)], + string="Année finale", ) date_exo_start = fields.Date( - string='Date Début Exo', - compute='_compute_exo_dates', - track_visibility='onchange', - store=True + string="Date Début Exo", + compute="_compute_exo_dates", + tracking=1, + store=True, ) date_exo_end = fields.Date( - string='Date Fin Exo', - compute='_compute_exo_dates', - track_visibility='onchange', - store=True + string="Date Fin Exo", + compute="_compute_exo_dates", + tracking=1, + store=True, ) nb_quarter = fields.Integer( - string='Nb trimestres exonérés', - compute='_compute_exo_dates', - store=True + string="Nb trimestres exonérés", + compute="_compute_exo_dates", + store=True, ) - type_exo = fields.Selection([ - ('amount', 'Montant'), - ('percent', 'Pourcentage')], + type_exo = fields.Selection( + [("amount", "Montant"), ("percent", "Pourcentage")], string="Type d'exonération", - track_visibility='onchange' - ) - amount_quarter = fields.Float('Montant souhaité pour les échéances') - percent_quarter = fields.Integer('Réduction appliquée aux échéances') - date_exo_ok = fields.Date('Date Acceptation Exo') - head_office_comment = fields.Text('Commentaire du bureau') - note = fields.Text('Notes internes') - instance_id = fields.Many2one( - comodel_name='scop.instance', - string="Instance" + tracking=1, ) + amount_quarter = fields.Float("Montant souhaité pour les échéances") + percent_quarter = fields.Integer("Réduction appliquée aux échéances") + date_exo_ok = fields.Date("Date Acceptation Exo") + head_office_comment = fields.Text("Commentaire du bureau") + note = fields.Text("Notes internes") + instance_id = fields.Many2one(comodel_name="scop.instance", string="Instance") bordereau_ids = fields.Many2many( - comodel_name='scop.bordereau', - relation='scop_bordereau_exo_rel', - column2='bordereau_id', - column1='exo_id', - string="Bordereaux" + comodel_name="scop.bordereau", + relation="scop_bordereau_exo_rel", + column2="bordereau_id", + column1="exo_id", + string="Bordereaux", ) company_id = fields.Many2one( - comodel_name='res.company', - string='Company', change_default=True, - required=True, readonly=True, - default=lambda self: self.env['res.company']._company_default_get('scop.cotisation.cg.followup')) + comodel_name="res.company", + string="Company", + change_default=True, + required=True, + readonly=True, + default=lambda self: self.env["res.company"]._company_default_get( + "scop.cotisation.cg.followup" + ), + ) exo_line_ids = fields.One2many( - comodel_name='scop.cotisation.cg.exo.line', - inverse_name='exo_id', - string='Ligne Exonération' + comodel_name="scop.cotisation.cg.exo.line", + inverse_name="exo_id", + string="Ligne Exonération", ) # ------------------------------------------------------ # Contraintes SQL # ------------------------------------------------------ - @api.constrains('date_exo_start', 'date_exo_end') + @api.constrains("date_exo_start", "date_exo_end") def _check_dates(self): for exo in self: if exo.date_exo_start and exo.date_exo_end: if exo.date_exo_start > exo.date_exo_end: raise ValidationError( - "La date de fin doit êre supérieure à la date de début d'exonération.") - intersect_exo_ids = self.search([ - ('partner_id', '=', exo.partner_id.id), - ('date_exo_end', '>=', exo.date_exo_start), - ('date_exo_start', '<=', exo.date_exo_end), - ('state', '=', 'done') - ]) + _( + "La date de fin doit êre supérieure à la " + "date de début d'exonération." + ) + ) + intersect_exo_ids = self.search( + [ + ("partner_id", "=", exo.partner_id.id), + ("date_exo_end", ">=", exo.date_exo_start), + ("date_exo_start", "<=", exo.date_exo_end), + ("state", "=", "done"), + ] + ) if intersect_exo_ids: raise ValidationError( - "Les périodes d'exonérations ne peuvent pas se chevaucher.") + _("Les périodes d'exonérations ne peuvent pas se chevaucher.") + ) - @api.constrains('percent_quarter') + @api.constrains("percent_quarter") def _check_description(self): for exo in self: if exo.percent_quarter < 0 or exo.percent_quarter > 100: raise ValidationError( - "La valeur de la réduction doit être comprise entre 1 et 100") + _("La valeur de la réduction doit être comprise entre 1 et 100") + ) # ------------------------------------------------------ # Onchange fields # ------------------------------------------------------ - @api.onchange('instance_id') + @api.onchange("instance_id") def _onchange_instance_id(self): - if self.state in ('todo', 'waiting'): + if self.state in ("todo", "waiting"): if self.instance_id: - self.state = 'waiting' + self.state = "waiting" if not self.number: prefix = 5 - len(str(self.id)) - self.number = 'EXO-' + str(datetime.now().year) + '-' + (prefix * '0') + str(self.id) + self.number = ( + "EXO-" + + str(datetime.now().year) + + "-" + + (prefix * "0") + + str(self.id) + ) else: - self.state = 'todo' + self.state = "todo" # ------------------------------------------------------ # Compute fields # ------------------------------------------------------ - @api.multi def _compute_name(self): for exo in self: - exo.name = datetime.strftime(exo.date_request, '%d/%m/%Y') + ' ' + exo.partner_id.name + exo.name = ( + datetime.strftime(exo.date_request, "%d/%m/%Y") + + " " + + exo.partner_id.name + ) @api.model def _search_name(self, operator, value): - partner_ids = self.partner_id.search([('name', operator, value)]) + partner_ids = self.partner_id.search([("name", operator, value)]) return [ - '|', - ('partner_id', 'in', partner_ids.ids), - ('date_request', operator, value), + "|", + ("partner_id", "in", partner_ids.ids), + ("date_request", operator, value), ] @api.depends( - 'quarter_exo_start', 'year_exo_start', - 'quarter_exo_end', 'year_exo_end', + "quarter_exo_start", + "year_exo_start", + "quarter_exo_end", + "year_exo_end", ) - @api.multi def _compute_exo_dates(self): for exo in self: if exo.year_exo_start and exo.quarter_exo_start: - exo.date_exo_start = date(int(exo.year_exo_start), exo.quarter_exo_start * 3 - 2, 1) + exo.date_exo_start = date( + int(exo.year_exo_start), int(exo.quarter_exo_start) * 3 - 2, 1 + ) if exo.year_exo_end and exo.quarter_exo_end: - end_day = 31 if exo.quarter_exo_end in (1, 4) else 30 - exo.date_exo_end = date(int(exo.year_exo_end), exo.quarter_exo_end * 3, end_day) + end_day = 31 if int(exo.quarter_exo_end) in (1, 4) else 30 + exo.date_exo_end = date( + int(exo.year_exo_end), int(exo.quarter_exo_end) * 3, end_day + ) if exo.date_exo_start and exo.date_exo_end: exo.nb_quarter = int( - ((exo.date_exo_end.year - exo.date_exo_start.year) * 12 + - exo.date_exo_end.month - exo.date_exo_start.month + 1) / 3) + ( + (exo.date_exo_end.year - exo.date_exo_start.year) * 12 + + exo.date_exo_end.month + - exo.date_exo_start.month + + 1 + ) + / 3 + ) # ------------------------------------------------------ # Button functions # ------------------------------------------------------ def action_view_bordereau(self): - years = list(range(self.year_exo_start, self.year_exo_end + 1)) + years = list(range(int(self.year_exo_start), int(self.year_exo_end) + 1)) return { - 'name': 'Bordereaux de cotisation - ' + self.partner_id.name, - 'type': 'ir.actions.act_window', - 'view_mode': 'tree,form', - 'res_model': 'scop.bordereau', - 'domain': [ - ('partner_id', '=', self.partner_id.id), - ('year', 'in', years), + "name": "Bordereaux de cotisation - " + self.partner_id.name, + "type": "ir.actions.act_window", + "view_mode": "tree,form", + "res_model": "scop.bordereau", + "domain": [ + ("partner_id", "=", self.partner_id.id), + ("year", "in", years), ], } def action_view_exo(self): return { - 'name': 'Bordereaux avec exonération - ' + self.partner_id.name, - 'type': 'ir.actions.act_window', - 'view_mode': 'tree,form', - 'res_model': 'scop.bordereau', - 'domain': [('id', 'in', self.bordereau_ids.ids)], + "name": "Bordereaux avec exonération - " + self.partner_id.name, + "type": "ir.actions.act_window", + "view_mode": "tree,form", + "res_model": "scop.bordereau", + "domain": [("id", "in", self.bordereau_ids.ids)], } def create_lines(self): @@ -236,99 +268,132 @@ class ScopCotisationExo(models.Model): contrib_type = self.partner_id.get_partner_contribution_type() # if exo is percent => affects percent to each line - if self.type_exo == 'percent': + if self.type_exo == "percent": for contrib in contrib_type: - self.exo_line_ids.create({ - 'exo_id': self.id, - 'contribution_id': contrib.id, - 'percent': self.percent_quarter - }) + self.exo_line_ids.create( + { + "exo_id": self.id, + "contribution_id": contrib.id, + "percent": self.percent_quarter, + } + ) # if exo is amount - if self.type_exo == 'amount': + if self.type_exo == "amount": # if various contribution type => affects prorate amount to each line if len(contrib_type) > 1: # Get last bdx for prorate calculation - last_bdx = self.env['scop.bordereau'].search([ - ('state', 'in', ['validated', 'paid']), - ('partner_id', '=', self.partner_id.id) - ], order='date_cotisation desc', limit=1) + last_bdx = self.env["scop.bordereau"].search( + [ + ("state", "in", ["validated", "paid"]), + ("partner_id", "=", self.partner_id.id), + ], + order="date_cotisation desc", + limit=1, + ) if last_bdx: last_amount = last_bdx.amount_total_cotiz amount_by_type = last_bdx.get_contribution_type() for contrib in contrib_type: for amount in amount_by_type: - if contrib.id == amount.get('type_contribution_id')[0]: - self.exo_line_ids.create({ - 'exo_id': self.id, - 'contribution_id': contrib.id, - 'amount': self.amount_quarter * amount.get('amount_total_signed') / last_amount - }) + if contrib.id == amount.get("type_contribution_id")[0]: + self.exo_line_ids.create( + { + "exo_id": self.id, + "contribution_id": contrib.id, + "amount": self.amount_quarter + * amount.get("amount_total_signed") + / last_amount, + } + ) else: for contrib in contrib_type: - self.exo_line_ids.create({ - 'exo_id': self.id, - 'contribution_id': contrib.id, - 'amount': round(self.amount_quarter / len(contrib_type), 2) - }) + self.exo_line_ids.create( + { + "exo_id": self.id, + "contribution_id": contrib.id, + "amount": round( + self.amount_quarter / len(contrib_type), 2 + ), + } + ) else: - self.exo_line_ids.create({ - 'exo_id': self.id, - 'contribution_id': contrib_type[0].id, - 'amount': self.amount_quarter - }) + self.exo_line_ids.create( + { + "exo_id": self.id, + "contribution_id": contrib_type[0].id, + "amount": self.amount_quarter, + } + ) def cancel_exo(self): - self.state = 'cancel' + self.state = "cancel" def validate_exo(self): if not self.date_exo_ok: - raise UserError("Il est nécessaire de renseigner une date d'acceptation pour valider") + raise UserError( + _("Il est nécessaire de renseigner une date d'acceptation pour valider") + ) else: # Unfavorable => nothing to do - if self.final_notice == 'unfavorable': - self.state = 'done' + if self.final_notice == "unfavorable": + self.state = "done" # Favorable - elif self.final_notice == 'favorable': - bordereau_ids = self.env['scop.bordereau'].search([ - ('partner_id', '=', self.partner_id.id), - ('year', 'in', list(range(self.year_exo_start, self.year_exo_end + 1))), - ('state', '!=', 'cancel') - ], order='year') + elif self.final_notice == "favorable": + bordereau_ids = self.env["scop.bordereau"].search( + [ + ("partner_id", "=", self.partner_id.id), + ( + "year", + "in", + list( + range( + int(self.year_exo_start), int(self.year_exo_end) + 1 + ) + ), + ), + ("state", "!=", "cancel"), + ], + order="year", + ) # If no bdx on period => nothing to do if not bordereau_ids: - self.state = 'done' + self.state = "done" else: for bdx in bordereau_ids: self.create_exo_refund(bdx) - self.state = 'done' + self.state = "done" else: - raise UserError("Il est nécessaire de renseigner un avis final pour valider") + raise UserError( + _("Il est nécessaire de renseigner un avis final pour valider") + ) def set_favorable(self): """ Button function to set exo favorable on instance tree view """ - self.final_notice = 'favorable' + self.final_notice = "favorable" def set_unfavorable(self): """ Button function to set exo unfavorable on instance tree view """ - self.final_notice = 'unfavorable' + self.final_notice = "unfavorable" # ------------------------------------------------------ # Override ORM # ------------------------------------------------------ @api.model def create(self, vals): - if vals.get('number', 'New' == 'New'): - vals['number'] = self.env['ir.sequence'].next_by_code('scop.cotisation.cg.exo') or 'New' + if vals.get("number", "New" == "New"): + vals["number"] = ( + self.env["ir.sequence"].next_by_code("scop.cotisation.cg.exo") or "New" + ) result = super(ScopCotisationExo, self).create(vals) return result @@ -342,15 +407,17 @@ class ScopCotisationExo(models.Model): """ quarters = {} if self.year_exo_start == self.year_exo_end: - quarters[str(self.year_exo_start)] = range(self.quarter_exo_start, self.quarter_exo_end + 1) + quarters[self.year_exo_start] = range( + int(self.quarter_exo_start), int(self.quarter_exo_end) + 1 + ) else: - for year in range(self.year_exo_start, self.year_exo_end + 1): - if year == self.year_exo_start: - quarters[str(year)] = list(range(self.quarter_exo_start, 5)) - elif year == self.year_exo_end: - quarters[str(year)] = list(range(1, self.quarter_exo_end + 1)) + for year in range(int(self.year_exo_start), int(self.year_exo_end) + 1): + if year == int(self.year_exo_start): + quarters[year] = list(range(int(self.quarter_exo_start), 5)) + elif year == int(self.year_exo_end): + quarters[year] = list(range(1, int(self.quarter_exo_end) + 1)) else: - quarters[str(year)] = list(range(1, 5)) + quarters[year] = list(range(1, 5)) return quarters def create_exo_refund(self, bordereau_id): @@ -361,17 +428,19 @@ class ScopCotisationExo(models.Model): bordereau_id.ensure_one() # Create version - if bordereau_id.state != 'new': - self.env['scop.bordereau.version'].create({ - 'bordereau_id': bordereau_id.id, - 'date': self.date_exo_ok, - 'comment': "Exonération", - 'version': bordereau_id.version, - 'liasse_fiscale_id_old': bordereau_id.liasse_fiscale_id.id, - 'type_assiette': bordereau_id.type_assiette, - 'montant_assiette': bordereau_id.montant_assiette, - 'amount_total_cotiz': bordereau_id.amount_total_cotiz, - }) + if bordereau_id.state != "new": + self.env["scop.bordereau.version"].create( + { + "bordereau_id": bordereau_id.id, + "date": self.date_exo_ok, + "comment": "Exonération", + "version": bordereau_id.version, + "liasse_fiscale_id_old": bordereau_id.liasse_fiscale_id.id, + "type_assiette": bordereau_id.type_assiette, + "montant_assiette": bordereau_id.montant_assiette, + "amount_total_cotiz": bordereau_id.amount_total_cotiz, + } + ) exo_quarters = self.get_quarters() # check exo period @@ -381,58 +450,73 @@ class ScopCotisationExo(models.Model): for quarter in exo_period: # Get all invoices on specific quarter amount_period = bordereau_id.invoice_ids.read_group( - [('bordereau_id', '=', bordereau_id.id), ('cotiz_quarter', '=', quarter)], - ['type_contribution_id', 'amount_total_signed'], - ['type_contribution_id']) - - # Get bdx schedule - base_cotiz = bordereau_id.base_cotisation_cg - bdx_quarters = [base_cotiz.trimester_1, base_cotiz.trimester_2, - base_cotiz.trimester_3, base_cotiz.trimester_4] + [ + ("bordereau_id", "=", bordereau_id.id), + ("cotiz_quarter", "=", quarter), + ], + ["type_contribution_id", "amount_total_signed"], + ["type_contribution_id"], + ) # Contribution type loop for amount_type in amount_period: - inv_type = amount_type.get('type_contribution_id')[0] - inv_amount = amount_type.get('amount_total_signed') + inv_type = amount_type.get("type_contribution_id")[0] + inv_amount = amount_type.get("amount_total_signed") # Get invoice on this type (for refund creation) - inv_id = bordereau_id.invoice_ids.filtered(lambda i: i.type_contribution_id.id == inv_type)[0] + inv_id = bordereau_id.invoice_ids.filtered( + lambda i: i.type_contribution_id.id == inv_type + )[0] - exo_line_id = self.exo_line_ids.filtered(lambda l: l.contribution_id.id == inv_type) + exo_line_id = self.exo_line_ids.filtered( + lambda l: l.contribution_id.id == inv_type + ) - if self.type_exo == 'percent': + if self.type_exo == "percent": exo_amount = round(inv_amount * (1 - exo_line_id.percent / 100), 2) - elif self.type_exo == 'amount': + elif self.type_exo == "amount": exo_amount = round(inv_amount - exo_line_id.amount, 2) else: - raise UserError("Erreur, le type d'exonération n'est pas configuré") + raise UserError( + _("Erreur, le type d'exonération n'est pas configuré") + ) if exo_amount != 0: - date_refund = bordereau_id.date_cotisation if bordereau_id.state == 'draft' else self.date_exo_ok + date_refund = ( + bordereau_id.date_cotisation + if bordereau_id.state == "draft" + else self.date_exo_ok + ) # Create refund - member_refund = bordereau_id.invoice_ids.create({ - 'partner_id': bordereau_id.partner_id.id, - 'liasse_fiscale_id': bordereau_id.liasse_fiscale_id.id, - 'type': 'out_refund', - 'year': bordereau_id.year, - 'is_contribution': True, - 'type_contribution_id': inv_type, - 'journal_id': inv_id.journal_id.id, - 'state': 'draft', - 'account_id': inv_id.account_id.id, - 'payment_mode_id': bordereau_id.payment_mode_id.id, - 'date_invoice': date_refund, - 'date_due': self.date_exo_ok, - 'bordereau_id': bordereau_id.id, - 'cotiz_quarter': quarter, - 'refund_invoice_id': inv_id.id, - 'name': 'Exonération ' + self.number - }) - member_refund.invoice_line_ids.create({ - 'invoice_id': member_refund.id, - 'product_id': inv_id.invoice_line_ids[0].product_id.id, - 'account_id': inv_id.invoice_line_ids[0].account_id.id, - 'name': inv_id.invoice_line_ids[0].product_id.name + " T" + str(quarter), - 'price_unit': exo_amount - }) + member_refund = bordereau_id.invoice_ids.create( + { + "partner_id": bordereau_id.partner_id.id, + "liasse_fiscale_id": bordereau_id.liasse_fiscale_id.id, + "type": "out_refund", + "year": bordereau_id.year, + "is_contribution": True, + "type_contribution_id": inv_type, + "journal_id": inv_id.journal_id.id, + "state": "draft", + "account_id": inv_id.account_id.id, + "payment_mode_id": bordereau_id.payment_mode_id.id, + "date_invoice": date_refund, + "date_due": self.date_exo_ok, + "bordereau_id": bordereau_id.id, + "cotiz_quarter": quarter, + "refund_invoice_id": inv_id.id, + "name": "Exonération " + self.number, + } + ) + member_refund.invoice_line_ids.create( + { + "invoice_id": member_refund.id, + "product_id": inv_id.invoice_line_ids[0].product_id.id, + "account_id": inv_id.invoice_line_ids[0].account_id.id, + "name": inv_id.invoice_line_ids[0].product_id.name + + " T" + + str(quarter), + "price_unit": exo_amount, + } + ) # Update link exo - bordereau - self.update({'bordereau_ids': [(4, bordereau_id.id)]}) + self.update({"bordereau_ids": [(4, bordereau_id.id)]}) diff --git a/models/scop_cotisation_cg_exo_line.py b/models/scop_cotisation_cg_exo_line.py index 4ba250c..bb1854d 100644 --- a/models/scop_cotisation_cg_exo_line.py +++ b/models/scop_cotisation_cg_exo_line.py @@ -1,10 +1,8 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from datetime import datetime, date -from odoo import models, fields, api -from odoo.exceptions import ValidationError, UserError +from odoo import fields, models class ScopCotisationExoLine(models.Model): @@ -13,20 +11,18 @@ class ScopCotisationExoLine(models.Model): _order = "create_date desc, contribution_id" exo_id = fields.Many2one( - comodel_name='scop.cotisation.cg.exo', + comodel_name="scop.cotisation.cg.exo", string="Exonération", - required=True) + required=True, + ) contribution_id = fields.Many2one( - comodel_name='scop.contribution.type', - required=True + comodel_name="scop.contribution.type", required=True ) - amount = fields.Float('Montant souhaité') - percent = fields.Integer('% réduction') - type_exo = fields.Selection([ - ('amount', 'Montant'), - ('percent', 'Pourcentage')], + amount = fields.Float("Montant souhaité") + percent = fields.Integer("% réduction") + type_exo = fields.Selection( string="Type d'exonération", - related='exo_id.type_exo' + related="exo_id.type_exo", ) # ------------------------------------------------------ diff --git a/models/scop_cotisation_cg_exo_ur_notice.py b/models/scop_cotisation_cg_exo_ur_notice.py index 704a0ae..3885a60 100644 --- a/models/scop_cotisation_cg_exo_ur_notice.py +++ b/models/scop_cotisation_cg_exo_ur_notice.py @@ -1,12 +1,12 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -from odoo import models, fields +from odoo import fields, models class ScopCotisationExoUrNotice(models.Model): _name = "scop.cotisation.cg.exo.ur.notice" _description = "Exonerations - Avis UR" - _order = 'name' + _order = "name" - name = fields.Char(string='Nom', required=True) + name = fields.Char(string="Nom", required=True) diff --git a/models/scop_instance.py b/models/scop_instance.py index 16ef1f3..f414e0d 100644 --- a/models/scop_instance.py +++ b/models/scop_instance.py @@ -1,32 +1,30 @@ # © 2021 Le Filament (<http://www.le-filament.com>) # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -import logging -from datetime import timedelta -from odoo import models, fields, api -from odoo.exceptions import UserError, ValidationError +from odoo import fields, models class ScopInstance(models.Model): _inherit = "scop.instance" - is_type_exo = fields.Boolean("Exonérations") + is_type_exo = fields.Boolean("Activer Exonérations") exo_ids = fields.One2many( comodel_name="scop.cotisation.cg.exo", inverse_name="instance_id", - string="Exonérations" + string="Exonérations", + ) + all_exo_validated = fields.Boolean( + compute="_compute_all_exo_validated", default=False ) - all_exo_validated = fields.Boolean(compute="_compute_all_exo_validated", default=False) # ------------------------------------------------------ # Computed fields / Search Fields # ------------------------------------------------------ - @api.multi def _compute_all_exo_validated(self): for instance in self: - exo_states = instance.exo_ids.mapped('state') - if not list(set(exo_states) - set(['done', 'cancel'])): + exo_states = instance.exo_ids.mapped("state") + if not list(set(exo_states) - {"done", "cancel"}): instance.all_exo_validated = True else: instance.all_exo_validated = False @@ -36,9 +34,9 @@ class ScopInstance(models.Model): # ------------------------------------------------------ def scop_valid_exo(self): for exo in self.exo_ids: - if exo.state not in ['done', 'cancel']: + if exo.state not in ["done", "cancel"]: if not exo.date_exo_ok: exo.date_exo_ok = fields.Date.to_date(self.date) if not exo.final_notice: - exo.final_notice = 'favorable' + exo.final_notice = "favorable" exo.validate_exo() diff --git a/security/ir.model.access.csv b/security/ir.model.access.csv old mode 100755 new mode 100644 diff --git a/security/security_rules.xml b/security/security_rules.xml index bb99099..0dbebc3 100644 --- a/security/security_rules.xml +++ b/security/security_rules.xml @@ -1,12 +1,14 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <odoo> <data noupdate="1"> <record id="invoice_comp_rule" model="ir.rule"> <field name="name">CG Scop - Cotisation - Exonérations multi-company</field> - <field name="model_id" ref="model_scop_cotisation_cg_exo"/> - <field name="global" eval="True"/> - <field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field> + <field name="model_id" ref="model_scop_cotisation_cg_exo" /> + <field name="global" eval="True" /> + <field + name="domain_force" + >['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field> </record> </data> </odoo> diff --git a/static/description/icon.png b/static/description/icon.png old mode 100755 new mode 100644 index 82ef47760a441cf229b5009f0a18ccf3842fbfa5..499652a2c9c0307f875bafc145b6fbafa133da72 GIT binary patch literal 15890 zcmeAS@N?(olHy`uVBq!ia0y~yVCVs14mJh`hII!V?HCwD&Q*m(lmsP~D-;yvr)B1( zDwI?fq$;FVWTr7NRNUG-D}7S*PSMu?$)a&gpIE0gM?96S`1$Xg@@`u%(@Abmm(5xt zA&_Umxc=_X^ZVET7PnWO{-$VSSoPX@^Y0Y*H>;oBUw5onzNYTo{Q2ANy>HczFQ1?9 z66a;J?7R4@-=F2zx1VQ><8MxXYR%mG^QpA${^R-aydv@Zp4yi_|CL*@pWW-@SGNj& zgSgwDwwnKbE%vO^cHjR0T+I9Z%6Hc8e3Sn#-z8uCnWy1Akx9?(mi>uxxRhU#Y2$zF zvl+MFH=FZ!o?p4&EI8r)(UbpEL*Kn#Q)9<%U-5VKk|n>Y?tVNp{otDU{r78ar>u{w z=YKIz;D73~Eq3Yu9+mF5yYwM-!q@8edGGFhzIFG+)Ct$VFSFbB$>wqM<O$24XHT8| zF}f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e0X<cn1}!1IX7W?lWOT9z4(d+d+Z zwCf2ZuoW`Og@3hUI-_t;K6#(BIEO*=4u<~KRq~8!0`L0`?=R#A6@CrJL-+PG7<YU> zKI8ob(7>ABfyb-vfl8m>$!E%6FfpbHh(9O{eXo3g=h0uoXVxW+48|SYA9k$zE||df z@t?$J*<B6|l1ISqsYiDZo!t|H?jX|K^GEv9vV=y3r!9R93=9mOu6{1-oD!M<ed5)w diff --git a/templates/report_scop_exo.xml b/templates/report_scop_exo.xml index d750eba..9178adf 100644 --- a/templates/report_scop_exo.xml +++ b/templates/report_scop_exo.xml @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <odoo> <data> @@ -9,12 +9,24 @@ <div class="row"> <div class="col-6 offset-6 mt64 mb64"> - <span t-field="o.partner_id.name" style="text-transform: uppercase; font-weight: 600;"/><br/> - <span t-field="o.partner_id.street" /><br/> - <t t-if="o.partner_id.street2"><span t-field="o.partner_id.street2"/><br/></t> - <t t-if="o.partner_id.street3"><span t-field="o.partner_id.street3"/><br/></t> - <span t-field="o.partner_id.zip" /> <span t-field="o.partner_id.city" style="text-transform: uppercase;"/> - <t t-if="o.partner_id.cedex"> <span t-field="o.partner_id.cedex"/></t> + <span + t-field="o.partner_id.name" + style="text-transform: uppercase; font-weight: 600;" + /><br /> + <span t-field="o.partner_id.street" /><br /> + <t t-if="o.partner_id.street2"><span + t-field="o.partner_id.street2" + /><br /></t> + <t t-if="o.partner_id.street3"><span + t-field="o.partner_id.street3" + /><br /></t> + <span t-field="o.partner_id.zip" /> <span + t-field="o.partner_id.city" + style="text-transform: uppercase;" + /> + <t t-if="o.partner_id.cedex"> <span + t-field="o.partner_id.cedex" + /></t> </div> </div> <div class="row"> @@ -27,11 +39,16 @@ <div class="row"> <div class="col-12 mb32"> <p> - Paris, le <span t-esc="o.date_exo_ok" t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}"/> + Paris, le <span + t-esc="o.date_exo_ok" + t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}" + /> </p> <p> - N° adhérent : <t t-esc="str(o.partner_id.member_number_int)"/><br/> - N° exonération : <span t-esc="o.number"/> + N° adhérent : <t + t-esc="str(o.partner_id.member_number_int)" + /><br /> + N° exonération : <span t-esc="o.number" /> </p> </div> </div> @@ -40,30 +57,46 @@ <p class="mb32">Cher Coopérateur,</p> <!-- Avis Favorable--> <t t-if="o.final_notice == 'favorable'"> - <p>Pour faire suite à votre dernier courrier, Le Bureau de la Direction Nationale qui s’est réuni le<span t-esc="o.instance_id.date" t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}"/> a décidé de vous accorder une exonération exceptionnelle de vos cotisations confédérales.</p> + <p + >Pour faire suite à votre dernier courrier, Le Bureau de la Direction Nationale qui s’est réuni le<span + t-esc="o.instance_id.date" + t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}" + /> a décidé de vous accorder une exonération exceptionnelle de vos cotisations confédérales.</p> <p> Le Bureau prend donc acte des modalités suivantes : </p> <p style="padding: 15px;"> <!-- Exonération totale--> - <t t-if="(o.type_exo == 'percent' and o.percent_quarter == 100) or (o.type_exo == 'amount' and o.amount_quarter == 0)"> + <t + t-if="(o.type_exo == 'percent' and o.percent_quarter == 100) or (o.type_exo == 'amount' and o.amount_quarter == 0)" + > Exonération totale des cotisations pour la période du </t> <t t-else=""> <!-- Réduction des échéances--> <t t-if="o.type_exo == 'percent'"> - Exonération de <span t-field="o.percent_quarter"/>% du montant des échéances trimestrielles sur la période du + Exonération de <span + t-field="o.percent_quarter" + />% du montant des échéances trimestrielles sur la période du </t> <!-- Montant fixe des échéances--> <t t-if="o.type_exo == 'amount'"> - Un montant des prochaines échéances fixé à <span t-field="o.amount_quarter"/>€ pour la période du + Un montant des prochaines échéances fixé à <span + t-field="o.amount_quarter" + />€ pour la période du </t> </t> <strong> - <t t-if="o.nb_quarter == 1"><span t-field="o.quarter_exo_start"/> <span t-field="o.year_exo_start"/>.</t> + <t t-if="o.nb_quarter == 1"><span + t-field="o.quarter_exo_start" + /> <span t-field="o.year_exo_start" />.</t> <t t-else=""> - <span t-field="o.quarter_exo_start"/> <span t-field="o.year_exo_start"/> au <span t-field="o.quarter_exo_end"/> <span t-field="o.year_exo_end"/>. + <span t-field="o.quarter_exo_start" /> <span + t-field="o.year_exo_start" + /> au <span + t-field="o.quarter_exo_end" + /> <span t-field="o.year_exo_end" />. </t> </strong> </p> @@ -71,16 +104,21 @@ <!-- Avis Défavorable--> <t t-if="o.final_notice == 'unfavorable'"> - <p>Pour faire suite à votre dernier courrier, Le Bureau de la Direction Nationale qui s’est réuni le<span t-esc="o.instance_id.date" t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}"/> a décidé de ne pas accorder d'exonération exceptionnelle de vos cotisations confédérales pour la raison suivante : </p> + <p + >Pour faire suite à votre dernier courrier, Le Bureau de la Direction Nationale qui s’est réuni le<span + t-esc="o.instance_id.date" + t-options="{'widget': 'date', 'format': 'd MMMM YYYY'}" + /> a décidé de ne pas accorder d'exonération exceptionnelle de vos cotisations confédérales pour la raison suivante : </p> <p> - <t t-esc="o.head_office_comment"/> + <t t-esc="o.head_office_comment" /> </p> </t> - <p>Je vous prie de croire, cher Coopérateur, en l’assurance de toute ma considération coopérative.</p> + <p + >Je vous prie de croire, cher Coopérateur, en l’assurance de toute ma considération coopérative.</p> <p>Le Président</p> <p>Jacques LANDRIOT</p> - <p>Copie : <t t-esc="o.partner_id.ur_id.name"/></p> + <p>Copie : <t t-esc="o.partner_id.ur_id.name" /></p> </div> </div> </div> @@ -89,22 +127,24 @@ <template id="report_exo"> <t t-call="web.html_container"> - <t t-set="docs" t-value="docs.with_context(lang='fr')"/> + <t t-set="docs" t-value="docs.with_context(lang='fr')" /> <t t-foreach="docs" t-as="o"> - <t t-call="cgscop_cotisation_cg_exo.report_exo_coop_document" t-lang="fr"/> + <t + t-call="cgscop_cotisation_cg_exo.report_exo_coop_document" + t-lang="fr" + /> </t> </t> </template> <!-- QWeb Reports --> - <report - id="cgscop_exo_report" - model="scop.cotisation.cg.exo" - string="Courrier d'exonération" - report_type="qweb-pdf" - name="cgscop_cotisation_cg_exo.report_exo" - file="cgscop_cotisation_cg_exo.report_exo" - /> + <record id="cgscop_exo_report" model="ir.actions.report"> + <field name="name">Courrier d'exonération</field> + <field name="model">scop.cotisation.cg.exo</field> + <field name="report_type">qweb-pdf</field> + <field name="report_name">cgscop_cotisation_cg_exo.report_exo</field> + <field name="report_file">cgscop_cotisation_cg_exo.report_exo</field> + </record> </data> </odoo> diff --git a/views/res_partner.xml b/views/res_partner.xml index 1d3c1ff..eebc325 100644 --- a/views/res_partner.xml +++ b/views/res_partner.xml @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <!-- Copyright 2021 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> @@ -7,44 +7,59 @@ <record id="scop_contact_view_form_inherit" model="ir.ui.view"> <field name="name">scop.contact.view.form.inherit</field> <field name="model">res.partner</field> - <field name="inherit_id" ref="cgscop_partner.scop_contact_view_form"/> + <field name="inherit_id" ref="cgscop_partner.scop_contact_view_form" /> <field name="arch" type="xml"> <xpath expr="//page[@name='contribution']" position="after"> - <page name='scop_exo' string="Exonérations" attrs="{'invisible': ['|', ('is_cooperative', '!=', True), ('project_status', '!=', '6_suivi')]}"> + <page + name='scop_exo' + string="Exonérations" + attrs="{'invisible': ['|', ('is_cooperative', '!=', True), ('project_status', '!=', '6_suivi')]}" + > <field name="exo_ids" mode="tree,form" readonly="1"> - <tree create="false" edit="false" delete="false" default_order="date desc"> - <field name="date_request"/> - <field name="source"/> - <field name="date_exo_start"/> - <field name="date_exo_end"/> - <field name="ur_notice"/> - <field name="final_notice"/> - <field name="date_exo_ok"/> + <tree + create="false" + edit="false" + delete="false" + default_order="date desc" + > + <field name="date_request" /> + <field name="source" /> + <field name="date_exo_start" /> + <field name="date_exo_end" /> + <field name="ur_notice" /> + <field name="final_notice" /> + <field name="date_exo_ok" /> </tree> <form> <group string="Demande initiale"> <group name="request"> - <field name="date_request"/> - <field name="source"/> - <field name="ur_notice" options="{'no_create': True, 'no_open': True}"/> + <field name="date_request" /> + <field name="source" /> + <field + name="ur_notice" + options="{'no_create': True, 'no_open': True}" + /> </group> <group> - <field name="date_exo_start"/> - <field name="date_exo_end"/> + <field name="date_exo_start" /> + <field name="date_exo_end" /> </group> </group> - <strong><label for="motivation"/></strong> - <field name="motivation" placeholder=""/> + <strong><label for="motivation" /></strong> + <field name="motivation" placeholder="" /> <group string="Bureau"> <group> - <field name="date_exo_ok"/> + <field name="date_exo_ok" /> </group> <group> - <field name="final_notice"/> + <field name="final_notice" /> </group> </group> - <strong><label for="head_office_comment"/></strong> - <field name="head_office_comment" placeholder="Commentaire du bureau"/> + <strong><label for="head_office_comment" /></strong> + <field + name="head_office_comment" + placeholder="Commentaire du bureau" + /> </form> </field> </page> @@ -52,4 +67,4 @@ </field> </record> </data> -</odoo> \ No newline at end of file +</odoo> diff --git a/views/scop_bordereau_cg.xml b/views/scop_bordereau_cg.xml index 8ffb246..1d087e9 100644 --- a/views/scop_bordereau_cg.xml +++ b/views/scop_bordereau_cg.xml @@ -1,4 +1,4 @@ -<?xml version="1.0" encoding="utf-8"?> +<?xml version="1.0" encoding="utf-8" ?> <!-- Copyright 2021 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> <odoo> @@ -8,15 +8,28 @@ <record id="scop_bordereau_exo_form_view" model="ir.ui.view"> <field name="name">scop.bordereau.exo.form</field> <field name="model">scop.bordereau</field> - <field name="inherit_id" ref="cgscop_cotisation_cg.scop_bordereau_form_view"/> + <field + name="inherit_id" + ref="cgscop_cotisation_cg.scop_bordereau_form_view" + /> <field name="arch" type="xml"> <xpath expr="//button[@name='action_show_cotiz']" position="after"> - <button name="action_show_exo" type="object" class="oe_stat_button" icon="fa-list" attrs="{'invisible':[('exo_count','=',0)]}"> - <field string="Exonération(s)" name="exo_count" widget="statinfo"/> + <button + name="action_show_exo" + type="object" + class="oe_stat_button" + icon="fa-list" + attrs="{'invisible':[('exo_count','=',0)]}" + > + <field + string="Exonération(s)" + name="exo_count" + widget="statinfo" + /> </button> </xpath> </field> </record> </data> -</odoo> \ No newline at end of file +</odoo> diff --git a/views/scop_cotisation_cg_exo.xml b/views/scop_cotisation_cg_exo.xml index 6a6f980..b817db0 100644 --- a/views/scop_cotisation_cg_exo.xml +++ b/views/scop_cotisation_cg_exo.xml @@ -1,7 +1,6 @@ -<?xml version="1.0"?> +<?xml version="1.0" ?> <!-- Copyright 2019 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> - <odoo> <data> @@ -11,19 +10,47 @@ <field name="model">scop.cotisation.cg.exo</field> <field name="arch" type="xml"> <search string="Exonerations"> - <field name="partner_id"/> - <field name="name"/> - <field name="date_request"/> - <separator/> - <filter name="on_going" domain="[('state', 'in', ('todo', 'waiting'))]" string="En cours de traitement"/> - <filter name="is_done" domain="[('state', '=', 'done')]" string="Traité"/> - <filter name="is_cancel" domain="[('state', '=', 'cancel')]" string="Annulé"/> - <separator/> - <filter name="is_favorable" domain="[('final_notice', '=', 'favorable')]" string="Favorable"/> - <filter name="is_unfavorable" domain="[('final_notice', '=', 'unfavorable')]" string="Défavorable"/> + <field name="partner_id" /> + <field name="name" /> + <field name="date_request" /> + <separator /> + <filter + name="on_going" + domain="[('state', 'in', ('todo', 'waiting'))]" + string="En cours de traitement" + /> + <filter + name="is_done" + domain="[('state', '=', 'done')]" + string="Traité" + /> + <filter + name="is_cancel" + domain="[('state', '=', 'cancel')]" + string="Annulé" + /> + <separator /> + <filter + name="is_favorable" + domain="[('final_notice', '=', 'favorable')]" + string="Favorable" + /> + <filter + name="is_unfavorable" + domain="[('final_notice', '=', 'unfavorable')]" + string="Défavorable" + /> <group expand="0" name="group_by" string="Group By"> - <filter name="group_state" string="Statut" context="{'group_by' : 'state'}"/> - <filter name="group_instance_id" string="Instance" context="{'group_by': 'instance_id'}"/> + <filter + name="group_state" + string="Statut" + context="{'group_by' : 'state'}" + /> + <filter + name="group_instance_id" + string="Instance" + context="{'group_by': 'instance_id'}" + /> </group> </search> </field> @@ -35,12 +62,12 @@ <field name="model">scop.cotisation.cg.exo</field> <field name="arch" type="xml"> <tree string="Exonerations"> - <field name="date_request"/> - <field name="partner_id"/> - <field name="state"/> - <field name="date_exo_start"/> - <field name="date_exo_end"/> - <field name="final_notice"/> + <field name="date_request" /> + <field name="partner_id" /> + <field name="state" /> + <field name="date_exo_start" /> + <field name="date_exo_end" /> + <field name="final_notice" /> </tree> </field> </record> @@ -53,75 +80,185 @@ <field name="arch" type="xml"> <form string="Exonerations"> <header> - <button name="validate_exo" type="object" string="Valider l'exonération" class="oe_highlight" confirm="Êtes-vous certain(e) de vouloir valider cette exonération ?" attrs="{'invisible': [('state', '!=', 'waiting')]}"/> - <button name="cancel_exo" type="object" string="Annuler" confirm="Êtes-vous certain(e) de vouloir annuler cette exonération ?" attrs="{'invisible': [('state', '=', 'cancel')]}"/> - <field name="state" widget="statusbar" readonly="1" force_save="1" /> + <button + name="validate_exo" + type="object" + string="Valider l'exonération" + class="oe_highlight" + confirm="Êtes-vous certain(e) de vouloir valider cette exonération ?" + attrs="{'invisible': [('state', '!=', 'waiting')]}" + /> + <button + name="cancel_exo" + type="object" + string="Annuler" + confirm="Êtes-vous certain(e) de vouloir annuler cette exonération ?" + attrs="{'invisible': [('state', '=', 'cancel')]}" + /> + <field + name="state" + widget="statusbar" + readonly="1" + force_save="1" + /> </header> <sheet> <div class="oe_button_box" name="button_box"> - <button name="action_view_bordereau" type="object" icon="fa-files-o" attrs="{'invisible': [('state', '=', 'done')]}" string="Borderaux en cours"/> - <button name="action_view_exo" type="object" class="oe_stat_button" icon="fa-list" attrs="{'invisible': [('state', '!=', 'done')]}" string="Bordereaux Exonérés"/> + <button + name="action_view_bordereau" + type="object" + icon="fa-files-o" + attrs="{'invisible': [('state', '=', 'done')]}" + string="Borderaux en cours" + /> + <button + name="action_view_exo" + type="object" + class="oe_stat_button" + icon="fa-list" + attrs="{'invisible': [('state', '!=', 'done')]}" + string="Bordereaux Exonérés" + /> </div> - <label for="partner_id" string="Coopérative"/> - <h1><field name="partner_id" options="{'no_create': True}"/></h1> - <label for="number" string="Référence de l'exonération"/> - <h3><field name="number"/></h3> + <label for="partner_id" string="Coopérative" /> + <h1><field + name="partner_id" + options="{'no_create': True}" + /></h1> + <label for="number" string="Référence de l'exonération" /> + <h3><field name="number" /></h3> <group string="Demande initiale"> <group name="request"> - <field name="date_request"/> - <field name="source"/> + <field name="date_request" /> + <field name="source" /> </group> <group> - <field name="ur_notice" options="{'no_create': True, 'no_open': True}"/> + <field + name="ur_notice" + options="{'no_create': True, 'no_open': True}" + /> </group> </group> - <strong><label for="motivation"/></strong> - <field name="motivation" placeholder=""/> + <strong><label for="motivation" /></strong> + <field name="motivation" placeholder="" /> <group string="Données de calcul"> <group> - <label for="quarter_exo_start" string="Début de l'exonération"/> + <label + for="quarter_exo_start" + string="Début de l'exonération" + /> <div> - <field name="quarter_exo_start" class="oe_inline" style="margin-right: 20px;" required="1"/> - <field name="year_exo_start" class="oe_inline" required="1"/> + <field + name="quarter_exo_start" + class="oe_inline" + style="margin-right: 20px;" + required="1" + /> + <field + name="year_exo_start" + class="oe_inline" + required="1" + /> </div> - <label for="quarter_exo_end" string="Fin de l'exonération"/> + <label + for="quarter_exo_end" + string="Fin de l'exonération" + /> <div> - <field name="quarter_exo_end" class="oe_inline" style="margin-right: 20px;" required="1"/> - <field name="year_exo_end" class="oe_inline" required="1"/> + <field + name="quarter_exo_end" + class="oe_inline" + style="margin-right: 20px;" + required="1" + /> + <field + name="year_exo_end" + class="oe_inline" + required="1" + /> </div> - <separator></separator> - <field name="date_exo_start"/> - <field name="date_exo_end"/> - <field name="nb_quarter"/> + <separator /> + <field name="date_exo_start" /> + <field name="date_exo_end" /> + <field name="nb_quarter" /> </group> <group> - <field name="type_exo"/> - <div class="alert alert-light oe_edit_only" role="alert" colspan="2" attrs="{'invisible': [('type_exo', '!=', 'amount')]}"> - Le montant saisi dans le champ ci-dessous correspond au <strong>montant de l'échéanche souhaité</strong> pour les échéances exonérées. + <field name="type_exo" /> + <div + class="alert alert-light oe_edit_only" + role="alert" + colspan="2" + attrs="{'invisible': [('type_exo', '!=', 'amount')]}" + > + Le montant saisi dans le champ ci-dessous correspond au <strong + >montant de l'échéanche souhaité</strong> pour les échéances exonérées. </div> - <field name="amount_quarter" attrs="{'invisible': [('type_exo', '!=', 'amount')]}"/> + <field + name="amount_quarter" + attrs="{'invisible': [('type_exo', '!=', 'amount')]}" + /> - <div class="alert alert-light oe_edit_only" role="alert" colspan="2" attrs="{'invisible': [('type_exo', '!=', 'percent')]}"> - Le nombre saisi dans le champ ci-dessous correspond au <strong>pourcentage de réduction</strong> appliqué aux échéances. + <div + class="alert alert-light oe_edit_only" + role="alert" + colspan="2" + attrs="{'invisible': [('type_exo', '!=', 'percent')]}" + > + Le nombre saisi dans le champ ci-dessous correspond au <strong + >pourcentage de réduction</strong> appliqué aux échéances. </div> - <field name="percent_quarter" attrs="{'invisible': [('type_exo', '!=', 'percent')]}"/> - <button name="create_lines" type="object" class="btn btn-info" string="Créer/Mettre à jour les lignes" - attrs="{'invisible': ['|', '|', ('state', 'in', ('done', 'cancel')), '&', ('amount_quarter', '<', 0), ('type_exo', '=', 'amount'), '&', ('percent_quarter', '=', 0), ('type_exo', '=', 'percent')]}"/> + <field + name="percent_quarter" + attrs="{'invisible': [('type_exo', '!=', 'percent')]}" + /> + <button + name="create_lines" + type="object" + class="btn btn-info" + string="Créer/Mettre à jour les lignes" + attrs="{'invisible': ['|', '|', ('state', 'in', ('done', 'cancel')), '&', ('amount_quarter', '<', 0), ('type_exo', '=', 'amount'), '&', ('percent_quarter', '=', 0), ('type_exo', '=', 'percent')]}" + /> <div colspan="2"> - <field name="exo_line_ids" attrs="{'readonly': [('state', 'in', ('done', 'cancel'))]}"> + <field + name="exo_line_ids" + attrs="{'readonly': [('state', 'in', ('done', 'cancel'))]}" + > <tree create="0" delete="0" editable="top"> - <field name="type_exo" invisible="1"/> - <field name="contribution_id" readonly="1" string="Type de cotisation" options="{'no_open': True}"/> - <field name="amount" attrs="{'readonly': [('type_exo', '!=', 'amount')], 'invisible': [('type_exo', '!=', 'amount')]}" sum="Total"/> - <field name="percent" attrs="{'readonly': [('type_exo', '!=', 'percent')], 'invisible': [('type_exo', '!=', 'percent')]}"/> + <field name="type_exo" invisible="1" /> + <field + name="contribution_id" + readonly="1" + string="Type de cotisation" + options="{'no_open': True}" + /> + <field + name="amount" + attrs="{'readonly': [('type_exo', '!=', 'amount')], 'invisible': [('type_exo', '!=', 'amount')]}" + sum="Total" + /> + <field + name="percent" + attrs="{'readonly': [('type_exo', '!=', 'percent')], 'invisible': [('type_exo', '!=', 'percent')]}" + /> </tree> <form> <group> - <field name="type_exo" invisible="1"/> - <field name="contribution_id" readonly="1" string="Type de cotisation" options="{'no_open': True}"/> - <field name="amount" attrs="{'readonly': [('type_exo', '!=', 'amount')], 'invisible': [('type_exo', '!=', 'amount')]}"/> - <field name="percent" attrs="{'readonly': [('type_exo', '!=', 'percent')], 'invisible': [('type_exo', '!=', 'percent')]}"/> + <field name="type_exo" invisible="1" /> + <field + name="contribution_id" + readonly="1" + string="Type de cotisation" + options="{'no_open': True}" + /> + <field + name="amount" + attrs="{'readonly': [('type_exo', '!=', 'amount')], 'invisible': [('type_exo', '!=', 'amount')]}" + /> + <field + name="percent" + attrs="{'readonly': [('type_exo', '!=', 'percent')], 'invisible': [('type_exo', '!=', 'percent')]}" + /> </group> </form> </field> @@ -132,23 +269,30 @@ <group string="Bureau"> <group> - <field name="instance_id" options="{'no_create': True}" string="Instance de présentation"/> + <field + name="instance_id" + options="{'no_create': True}" + string="Instance de présentation" + /> </group> <group> - <field name="date_exo_ok"/> - <field name="final_notice"/> + <field name="date_exo_ok" /> + <field name="final_notice" /> </group> </group> - <strong><label for="head_office_comment"/></strong> - <field name="head_office_comment" placeholder="Commentaire du bureau"/> - <hr/> - <strong><label for="note"/></strong> - <field name="note" placeholder="Note interne CG Scop"/> + <strong><label for="head_office_comment" /></strong> + <field + name="head_office_comment" + placeholder="Commentaire du bureau" + /> + <hr /> + <strong><label for="note" /></strong> + <field name="note" placeholder="Note interne CG Scop" /> </sheet> <div class="oe_chatter" disable_attachment_box="0"> - <field name="message_follower_ids" widget="mail_followers"/> - <field name="activity_ids" widget="mail_activity"/> - <field name="message_ids" widget="mail_thread"/> + <field name="message_follower_ids" widget="mail_followers" /> + <field name="activity_ids" widget="mail_activity" /> + <field name="message_ids" widget="mail_thread" /> </div> </form> </field> @@ -164,9 +308,11 @@ <!-- MENUS --> - <menuitem id="menu_scop_cotisation_cg_exo" - parent="cgscop_cotisation_cg.menu_scop_cotisation_cg_main" - action="action_scop_cotisation_cg_exo" - sequence="60"/> + <menuitem + id="menu_scop_cotisation_cg_exo" + parent="cgscop_cotisation_cg.menu_scop_cotisation_cg_main" + action="action_scop_cotisation_cg_exo" + sequence="60" + /> </data> </odoo> diff --git a/views/scop_cotisation_cg_exo_ur_notice.xml b/views/scop_cotisation_cg_exo_ur_notice.xml index 8c9b52d..587bda6 100644 --- a/views/scop_cotisation_cg_exo_ur_notice.xml +++ b/views/scop_cotisation_cg_exo_ur_notice.xml @@ -1,7 +1,6 @@ -<?xml version="1.0"?> +<?xml version="1.0" ?> <!-- Copyright 2019 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> - <odoo> <data> @@ -11,13 +10,16 @@ <field name="model">scop.cotisation.cg.exo.ur.notice</field> <field name="arch" type="xml"> <tree string="Avis UR" editable="top"> - <field name="name"/> + <field name="name" /> </tree> </field> </record> <!-- Action --> - <record id="action_scop_cotisation_cg_exo_ur_notice" model="ir.actions.act_window"> + <record + id="action_scop_cotisation_cg_exo_ur_notice" + model="ir.actions.act_window" + > <field name="name">Exonérations - Avis UR</field> <field name="res_model">scop.cotisation.cg.exo.ur.notice</field> <field name="view_mode">tree</field> @@ -25,13 +27,17 @@ <!-- MENUS --> - <menuitem id="menu_scop_cotisation_cg_exo_ur_notice_config" - parent="account.menu_finance_configuration" - name="Exonérations CG Scop" - sequence="90"/> - <menuitem id="menu_scop_cotisation_cg_exo_ur_notice" - parent="menu_scop_cotisation_cg_exo_ur_notice_config" - action="action_scop_cotisation_cg_exo_ur_notice" - sequence="10"/> + <menuitem + id="menu_scop_cotisation_cg_exo_ur_notice_config" + parent="account.menu_finance_configuration" + name="Exonérations CG Scop" + sequence="90" + /> + <menuitem + id="menu_scop_cotisation_cg_exo_ur_notice" + parent="menu_scop_cotisation_cg_exo_ur_notice_config" + action="action_scop_cotisation_cg_exo_ur_notice" + sequence="10" + /> </data> </odoo> diff --git a/views/scop_instance.xml b/views/scop_instance.xml index b109827..16df386 100644 --- a/views/scop_instance.xml +++ b/views/scop_instance.xml @@ -1,44 +1,66 @@ -<?xml version="1.0"?> +<?xml version="1.0" ?> <!-- Copyright 2021 Le Filament License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> - <odoo> <data> <record id="scop_instance_exo_form_view" model="ir.ui.view"> <field name="name">scop.instance.exo.form</field> <field name="model">scop.instance</field> - <field name="inherit_id" ref="cgscop_instance.scop_instance_form_view"/> + <field name="inherit_id" ref="cgscop_instance.scop_instance_form_view" /> <field name="arch" type="xml"> <xpath expr="//group[@name='instance_type']" position="inside"> - <field name="is_type_exo" widget="boolean_toggle"/> + <field name="is_type_exo" widget="boolean_toggle" /> </xpath> - <xpath expr="//page[@name='membership']" position="after"> - <page name="exo" string="Exonérations" attrs="{'invisible':[('is_type_exo','!=',True)]}"> - <field name="all_exo_validated" invisible="1"/> - <button name="scop_valid_exo" - type="object" - string="Valider toutes les exonérations" - confirm="Confirmez-vous la validation des exonérations ?" - class="btn-outline-info" - attrs="{'invisible': [('all_exo_validated', '=', True)]}" + <xpath expr="//notebook" position="inside"> + <page + name="exo" + string="Exonérations" + attrs="{'invisible':[('is_type_exo','!=',True)]}" + > + <field name="all_exo_validated" invisible="1" /> + <button + name="scop_valid_exo" + type="object" + string="Valider toutes les exonérations" + confirm="Confirmez-vous la validation des exonérations ?" + class="btn-outline-info" + attrs="{'invisible': [('all_exo_validated', '=', True)]}" /> - <field name="exo_ids" widget="many2many" domain="[('instance_id', '=', False)]" options="{'no_create': 1}"> - <tree decoration-danger="final_notice == 'unfavorable'" decoration-success="final_notice == 'favorable'"> - <field name="date_request"/> - <field name="partner_id"/> - <field name="source"/> - <field name="ur_notice"/> - <field name="date_exo_start"/> - <field name="date_exo_end"/> - <field name="nb_quarter"/> - <field name="amount_quarter" widget="monetary"/> - <field name="final_notice"/> - <field name="state"/> - <button name="set_favorable" type="object" icon="fa-check-circle-o" class="btn-outline-success" - attrs="{'invisible': ['|', ('final_notice', '=', 'favorable'), ('state', 'in', ['done', 'cancel'])]}"/> - <button name="set_unfavorable" type="object" icon="fa-times-circle-o" class="btn-outline-danger" - attrs="{'invisible': ['|', ('final_notice', '=', 'unfavorable'), ('state', 'in', ['done', 'cancel'])]}"/> + <field + name="exo_ids" + widget="many2many" + domain="[('instance_id', '=', False)]" + options="{'no_create': 1}" + > + <tree + decoration-danger="final_notice == 'unfavorable'" + decoration-success="final_notice == 'favorable'" + > + <field name="date_request" /> + <field name="partner_id" /> + <field name="source" /> + <field name="ur_notice" /> + <field name="date_exo_start" /> + <field name="date_exo_end" /> + <field name="nb_quarter" /> + <field name="amount_quarter" widget="monetary" /> + <field name="final_notice" /> + <field name="state" /> + <button + name="set_favorable" + type="object" + icon="fa-check-circle-o" + class="btn-outline-success" + attrs="{'invisible': ['|', ('final_notice', '=', 'favorable'), ('state', 'in', ['done', 'cancel'])]}" + /> + <button + name="set_unfavorable" + type="object" + icon="fa-times-circle-o" + class="btn-outline-danger" + attrs="{'invisible': ['|', ('final_notice', '=', 'unfavorable'), ('state', 'in', ['done', 'cancel'])]}" + /> </tree> </field> </page> @@ -47,4 +69,4 @@ </record> </data> -</odoo> \ No newline at end of file +</odoo> diff --git a/wizard/__init__.py b/wizard/__init__.py old mode 100755 new mode 100644 diff --git a/wizard/scop_bordereau_update_liasse_wizard.py b/wizard/scop_bordereau_update_liasse_wizard.py index 792f58e..2c076a4 100644 --- a/wizard/scop_bordereau_update_liasse_wizard.py +++ b/wizard/scop_bordereau_update_liasse_wizard.py @@ -5,7 +5,7 @@ from odoo import models class ScopBordereauChangeLiasse(models.TransientModel): - _inherit = 'scop.bordereau.change.liasse.wizard' + _inherit = "scop.bordereau.change.liasse.wizard" # ------------------------------------------------------ # Override Parent -- GitLab