mirror of
https://github.com/OCA/knowledge.git
synced 2025-07-13 07:24:48 -06:00
Updated from template
This commit is contained in:
parent
caff15dac9
commit
245c2d2c2d
@ -47,7 +47,6 @@ except Exception:
|
||||
|
||||
|
||||
class DocumentPage(models.Model):
|
||||
|
||||
_inherit = "document.page"
|
||||
|
||||
reference = fields.Char(
|
||||
@ -144,7 +143,7 @@ class DocumentPage(models.Model):
|
||||
try:
|
||||
self._validate_reference(reference=reference)
|
||||
vals["reference"] = reference
|
||||
except ValidationError: # pylint: disable=W7938
|
||||
except ValidationError: # pylint: disable=W8138
|
||||
# Do not fill reference.
|
||||
pass
|
||||
return super(DocumentPage, self).create(vals_list)
|
||||
return super().create(vals_list)
|
||||
|
@ -8,7 +8,7 @@ from odoo.tests.common import TransactionCase
|
||||
class TestDocumentReference(TransactionCase):
|
||||
@classmethod
|
||||
def setUpClass(cls):
|
||||
super(TestDocumentReference, cls).setUpClass()
|
||||
super().setUpClass()
|
||||
cls.page_obj = cls.env["document.page"]
|
||||
cls.history_obj = cls.env["document.page.history"]
|
||||
cls.page1 = cls.page_obj.create(
|
||||
|
Loading…
Reference in New Issue
Block a user