[FIX] point_of_sale: allow opening the pos interface

The `cash_control` constraint [1] is only relevant when the field
`cash_control` is modified. Do not check it when opening the pos UI.

[1] added by 733fb360d2
This commit is contained in:
Christophe Simonis
2019-07-29 15:59:40 +02:00
parent ac5c493c37
commit 81f024b545
+1 -1
View File
@@ -461,7 +461,7 @@ class PosConfig(models.Model):
""" open the pos interface """
self.ensure_one()
# check all constraints, raises if any is not met
self._validate_fields(self._fields)
self._validate_fields(set(self._fields) - {"cash_control"})
return {
'type': 'ir.actions.act_url',
'url': '/pos/web/',