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.

12 lines
472 B

6 years ago
  1. # Copyright 2014-2015 Grupo ESOC (<http://www.grupoesoc.es>)
  2. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
  3. from odoo import _, exceptions
  4. class EmptyNamesError(exceptions.ValidationError):
  5. def __init__(self, record, value=None):
  6. value = value or _("No name is set.")
  7. self.record = record
  8. self._value = value
  9. self._name = _("Error(s) with partner %d's name.") % record.id
  10. self.args = (self._name, value)