From f835f81cb2e58bafdd5b3487cfe3ffd3d7d08ced Mon Sep 17 00:00:00 2001 From: zhou <123@> Date: Fri, 7 Mar 2025 18:19:53 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yuthon_property/wizard/property_statements_wizard.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/yuthon_property/wizard/property_statements_wizard.py b/yuthon_property/wizard/property_statements_wizard.py index 083dd74c4..0128516bd 100644 --- a/yuthon_property/wizard/property_statements_wizard.py +++ b/yuthon_property/wizard/property_statements_wizard.py @@ -119,7 +119,8 @@ class PropertyStatementsWizard(models.Model): 'extract':extract, 'message':message, } - if float(original_amount) != 0: - self.env['property.bank.statements'].create(bank_data) - else: - pass \ No newline at end of file + if original_amount: + if float(original_amount) != 0: + self.env['property.bank.statements'].create(bank_data) + else: + pass \ No newline at end of file From 8aa333a7c16441e8fc1cd51930a8a4e59cea46a0 Mon Sep 17 00:00:00 2001 From: zhou <123@> Date: Fri, 7 Mar 2025 18:20:50 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yuthon_property/wizard/property_statements_wizard.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/yuthon_property/wizard/property_statements_wizard.py b/yuthon_property/wizard/property_statements_wizard.py index 0128516bd..fd7017d7b 100644 --- a/yuthon_property/wizard/property_statements_wizard.py +++ b/yuthon_property/wizard/property_statements_wizard.py @@ -120,7 +120,6 @@ class PropertyStatementsWizard(models.Model): 'message':message, } if original_amount: - if float(original_amount) != 0: - self.env['property.bank.statements'].create(bank_data) - else: - pass \ No newline at end of file + self.env['property.bank.statements'].create(bank_data) + else: + pass \ No newline at end of file