You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
596 B

  1. # Copyright 2018 Eficent Business and IT Consulting Services S.L.
  2. # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
  3. from odoo import api, fields, models
  4. class TierValidationTester(models.Model):
  5. _name = 'tier.validation.tester'
  6. _inherit = ['tier.validation']
  7. state = fields.Selection(
  8. selection=[('draft', 'Draft'),
  9. ('confirmed', 'Confirmed'),
  10. ('cancel', 'Cancel')],
  11. default='draft',
  12. )
  13. test_field = fields.Float()
  14. @api.multi
  15. def action_confirm(self):
  16. self.write({'state': 'confirmed'})