From 623e84ada251e9997973eb053844b91ba6ebb2cb Mon Sep 17 00:00:00 2001 From: Ilyas Date: Fri, 8 Dec 2023 19:15:31 +0500 Subject: [PATCH 1/2] [FIX] sale_commission_geo_assign_product_domain: ondelete group --- sale_commission_geo_assign_product_domain/models/res_partner.py | 1 - .../models/res_partner_commission_group.py | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/sale_commission_geo_assign_product_domain/models/res_partner.py b/sale_commission_geo_assign_product_domain/models/res_partner.py index a09cd5eec..2431528bf 100644 --- a/sale_commission_geo_assign_product_domain/models/res_partner.py +++ b/sale_commission_geo_assign_product_domain/models/res_partner.py @@ -10,7 +10,6 @@ class ResPartner(models.Model): commission_geo_group_ids = fields.One2many( comodel_name="res.partner.commission.group", inverse_name="partner_id", - ondelete="cascade", ) @api.onchange("commission_type") diff --git a/sale_commission_geo_assign_product_domain/models/res_partner_commission_group.py b/sale_commission_geo_assign_product_domain/models/res_partner_commission_group.py index 97a1b993d..175960191 100644 --- a/sale_commission_geo_assign_product_domain/models/res_partner_commission_group.py +++ b/sale_commission_geo_assign_product_domain/models/res_partner_commission_group.py @@ -8,7 +8,7 @@ class ResPartnerCommissionGroup(models.Model): _name = "res.partner.commission.group" _description = "Partner Commission Groups by Geolocation" - partner_id = fields.Many2one("res.partner", required=True) + partner_id = fields.Many2one("res.partner", ondelete="cascade", required=True) country_ids = fields.Many2many("res.country", string="Country") state_ids = fields.Many2many("res.country.state", string="State") zip_from = fields.Char("Zip From", help="ZIP range where this agent operates") From 291882e13f4810ffff5af240ebd524c5b2a7d97c Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Mon, 11 Dec 2023 08:32:33 +0000 Subject: [PATCH 2/2] [BOT] post-merge updates --- README.md | 2 +- sale_commission_geo_assign_product_domain/README.rst | 2 +- sale_commission_geo_assign_product_domain/__manifest__.py | 2 +- .../static/description/index.html | 3 +-- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index d4dc3a2d9..68e39fc0c 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ addon | version | maintainers | summary [sale_commission_delegated_partner](sale_commission_delegated_partner/) | 14.0.1.0.1 | | Allow to delegate the invoices of agent to a delegate partner [sale_commission_formula](sale_commission_formula/) | 14.0.1.0.0 | | Sale commissions computed by formulas [sale_commission_geo_assign](sale_commission_geo_assign/) | 14.0.1.1.0 | [![eLBati](https://github.com/eLBati.png?size=30px)](https://github.com/eLBati) | Assign agents to partners according to their location -[sale_commission_geo_assign_product_domain](sale_commission_geo_assign_product_domain/) | 14.0.1.2.0 | [![aleuffre](https://github.com/aleuffre.png?size=30px)](https://github.com/aleuffre) [![renda-dev](https://github.com/renda-dev.png?size=30px)](https://github.com/renda-dev) | Bridge module between sale_commission_product_criteria_domain and sale_commission_geo_assign +[sale_commission_geo_assign_product_domain](sale_commission_geo_assign_product_domain/) | 14.0.1.2.1 | [![aleuffre](https://github.com/aleuffre.png?size=30px)](https://github.com/aleuffre) [![renda-dev](https://github.com/renda-dev.png?size=30px)](https://github.com/renda-dev) | Bridge module between sale_commission_product_criteria_domain and sale_commission_geo_assign [sale_commission_pricelist](sale_commission_pricelist/) | 14.0.1.0.0 | | Sales commissions by pricelist [sale_commission_product_criteria](sale_commission_product_criteria/) | 14.0.1.1.3 | [![ilyasProgrammer](https://github.com/ilyasProgrammer.png?size=30px)](https://github.com/ilyasProgrammer) | Advanced commissions rules [sale_commission_product_criteria_discount](sale_commission_product_criteria_discount/) | 14.0.1.0.2 | [![ilyasProgrammer](https://github.com/ilyasProgrammer.png?size=30px)](https://github.com/ilyasProgrammer) | Advanced commissions rules with discount diff --git a/sale_commission_geo_assign_product_domain/README.rst b/sale_commission_geo_assign_product_domain/README.rst index 51c589049..e9ef0bc5f 100644 --- a/sale_commission_geo_assign_product_domain/README.rst +++ b/sale_commission_geo_assign_product_domain/README.rst @@ -7,7 +7,7 @@ Sale Commission Geo Assign Product Domain !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:bf7525d9ac78c30aa36e222718f07855e96e9e58c2b92b5c7b65b545131c3e36 + !! source digest: sha256:04e0a92dddcd73025b0d16ac486fd49179385fa2cabd2e5f0bd6ab6243e3b5ed !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png diff --git a/sale_commission_geo_assign_product_domain/__manifest__.py b/sale_commission_geo_assign_product_domain/__manifest__.py index 806da77ef..3806116af 100644 --- a/sale_commission_geo_assign_product_domain/__manifest__.py +++ b/sale_commission_geo_assign_product_domain/__manifest__.py @@ -6,7 +6,7 @@ "summary": "Bridge module between " "sale_commission_product_criteria_domain and " "sale_commission_geo_assign", - "version": "14.0.1.2.0", + "version": "14.0.1.2.1", "author": "PyTech SRL, Ooops404, Odoo Community Association (OCA)", "maintainers": ["aleuffre", "renda-dev"], "website": "https://github.com/OCA/commission", diff --git a/sale_commission_geo_assign_product_domain/static/description/index.html b/sale_commission_geo_assign_product_domain/static/description/index.html index 39f5e4050..e6ed845e3 100644 --- a/sale_commission_geo_assign_product_domain/static/description/index.html +++ b/sale_commission_geo_assign_product_domain/static/description/index.html @@ -1,4 +1,3 @@ - @@ -367,7 +366,7 @@

Sale Commission Geo Assign Product Domain

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -!! source digest: sha256:bf7525d9ac78c30aa36e222718f07855e96e9e58c2b92b5c7b65b545131c3e36 +!! source digest: sha256:04e0a92dddcd73025b0d16ac486fd49179385fa2cabd2e5f0bd6ab6243e3b5ed !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runboat

This is a bridge module between sale_commission_product_criteria_domain and sale_commission_geo_assign. It allows to address the following use case: