partner-contact/partner_tier_validation/models/res_partner.py

16 lines
464 B
Python
Raw Normal View History

2021-03-23 19:36:29 +00:00
# Copyright 2019 Open Source Integrators
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from flectra import fields, models
class ResPartner(models.Model):
_name = "res.partner"
_inherit = ["res.partner", "tier.validation", "mail.activity.mixin"]
_state_from = ["new", "to approve"]
_state_to = ["approved"]
state = fields.Selection(
[("new", "New"), ("approved", "Approved")], string="Status", default="new"
)