diff --git a/pms/models/account_move.py b/pms/models/account_move.py
index f8edf187e..014c335f8 100644
--- a/pms/models/account_move.py
+++ b/pms/models/account_move.py
@@ -344,6 +344,10 @@ class AccountMove(models.Model):
if (
self.pms_property_id
and self.amount_total > self.pms_property_id.max_amount_simplified_invoice
+ and (
+ not self.pms_property_id.avoid_simplified_max_amount_downpayment
+ or not self._is_downpayment()
+ )
):
mens = _(
"The total amount of the simplified invoice is higher than the "
diff --git a/pms/models/pms_property.py b/pms/models/pms_property.py
index 61d94fa43..e3aa603b6 100644
--- a/pms/models/pms_property.py
+++ b/pms/models/pms_property.py
@@ -194,6 +194,11 @@ class PmsProperty(models.Model):
help="Maximum amount to create the simplified invoice",
default=400.0,
)
+ avoid_simplified_max_amount_downpayment = fields.Boolean(
+ string="Downpayment Invoive without limit amount",
+ help="Avoid simplified invoice max amount downpayment",
+ default=True,
+ )
user_id = fields.Many2one(
string="Team Leader",
copy=False,
@@ -821,6 +826,6 @@ class PmsProperty(models.Model):
result.append((record.id, record.name))
else:
result.append(
- (record.id, record.name + " (" + record.pms_property_code + ")")
+ (record.id, "[" + record.pms_property_code + "] " + record.name)
)
return result
diff --git a/pms/views/pms_property_views.xml b/pms/views/pms_property_views.xml
index 08138f07c..4ca7578a4 100644
--- a/pms/views/pms_property_views.xml
+++ b/pms/views/pms_property_views.xml
@@ -117,6 +117,7 @@
]"
/>
+