From f009674b13a621f6da1ba5594c67e551e3599707 Mon Sep 17 00:00:00 2001 From: Julien Aldon Date: Fri, 20 Feb 2026 16:02:51 +0100 Subject: [PATCH] fix contract dto --- backend/src/contracts/contracts.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/backend/src/contracts/contracts.py b/backend/src/contracts/contracts.py index 940fd5e..10ee6c6 100644 --- a/backend/src/contracts/contracts.py +++ b/backend/src/contracts/contracts.py @@ -117,13 +117,17 @@ async def get_base_contract_template( 'price': None, 'products': [{'product': pr, 'quantity': None} for pr in sh.products] } for sh in form.shipments] - empty_contract = models.Contract( + empty_contract = models.ContractPublic( firstname="", form=form, lastname="", email="", phone="", - payment_method="cheque" + products=[], + payment_method="cheque", + cheque_quantity=3, + total_price=0, + id=1 ) cheques = [{"name": None, "value": None}, {"name": None, "value": None}, {"name": None, "value": None}] try: