From c040b33c561e44ae080329e80f82dfaadffb4114 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=B9=8F=E5=AE=87?= <9664676+pengyuthon@user.noreply.gitee.com> Date: Tue, 3 Mar 2026 17:29:55 +0800 Subject: [PATCH] =?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 --- .../models/property_lease_contract.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/yuthon_property_approval/models/property_lease_contract.py b/yuthon_property_approval/models/property_lease_contract.py index 4197959b3..c4d59e362 100644 --- a/yuthon_property_approval/models/property_lease_contract.py +++ b/yuthon_property_approval/models/property_lease_contract.py @@ -652,12 +652,8 @@ class PropertyLeaseContract(models.Model): contract_ids = self.env["property.lease.contract"].browse( self._context.get('active_ids', self._context.get('active_id'))) for rec in contract_ids: - if rec.electricity_fee_ids: - for line in rec.electricity_fee_ids: - line.is_fix_loss = 'no' - if rec.water_fee_ids: - for line in rec.water_fee_ids: - line.is_fix_loss = 'no' + if rec.lessor_line: + rec.write({'lessor_line': [(5,)]}) def update_admin_id(self): contract_ids = self.env["property.lease.contract"].browse(