Skip to content

Commit

Permalink
[MIG] partner_tier_validation: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
rven committed Sep 4, 2024
1 parent 928e118 commit 4e364e6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion partner_tier_validation/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{
"name": "Partner Tier Validation",
"summary": "Support a tier validation process for Contacts",
"version": "16.0.1.0.1",
"version": "17.0.1.0.0",
"website": "https://github.com/OCA/partner-contact",
"category": "Contact",
"author": "Open Source Integrators, Odoo Community Association (OCA)",
Expand Down
5 changes: 5 additions & 0 deletions partner_tier_validation/models/res_partner.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,8 @@ def write(self, vals):
if "stage_id" in vals and vals.get("stage_id") in self._state_from:
self.restart_validation()
return res

def _get_tier_validation_readonly_domain(self):
if self.env.context.get("form_view_ref") == "base.view_partner_simple_form":
return ""
return super()._get_tier_validation_readonly_domain()
2 changes: 1 addition & 1 deletion partner_tier_validation/models/tier_definition.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ class TierDefinition(models.Model):

@api.model
def _get_tier_validation_model_names(self):
res = super(TierDefinition, self)._get_tier_validation_model_names()
res = super()._get_tier_validation_model_names()
res.append("res.partner")
return res

0 comments on commit 4e364e6

Please sign in to comment.