From a4409af1c2dbfc105d6eb53c94078ee9cd9c693f 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: Sat, 27 Sep 2025 10:17:14 +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 --- .../views/property_accounts_receivable_views.xml | 2 +- yuthon_property/views/property_bank_statements_views.xml | 2 +- yuthon_property/views/yuthon_epitope_values_views.xml | 1 - .../models/inherit_yuthon_property.py | 8 ++++++++ .../views/inherit_yuthon_property_views.xml | 4 ++-- 5 files changed, 12 insertions(+), 5 deletions(-) diff --git a/yuthon_property/views/property_accounts_receivable_views.xml b/yuthon_property/views/property_accounts_receivable_views.xml index 365119798..04b17a67a 100644 --- a/yuthon_property/views/property_accounts_receivable_views.xml +++ b/yuthon_property/views/property_accounts_receivable_views.xml @@ -8,11 +8,11 @@ - + diff --git a/yuthon_property/views/property_bank_statements_views.xml b/yuthon_property/views/property_bank_statements_views.xml index 15adb461b..db5319215 100644 --- a/yuthon_property/views/property_bank_statements_views.xml +++ b/yuthon_property/views/property_bank_statements_views.xml @@ -33,7 +33,7 @@ - + diff --git a/yuthon_property/views/yuthon_epitope_values_views.xml b/yuthon_property/views/yuthon_epitope_values_views.xml index 3152d741f..ed3728f8d 100644 --- a/yuthon_property/views/yuthon_epitope_values_views.xml +++ b/yuthon_property/views/yuthon_epitope_values_views.xml @@ -5,7 +5,6 @@ yuthon.epitope.values - diff --git a/yuthon_property_approval/models/inherit_yuthon_property.py b/yuthon_property_approval/models/inherit_yuthon_property.py index b4f33c417..bc73d233d 100644 --- a/yuthon_property_approval/models/inherit_yuthon_property.py +++ b/yuthon_property_approval/models/inherit_yuthon_property.py @@ -43,6 +43,7 @@ class PropertyBankStatements(models.Model): contract_id = fields.Many2one('property.lease.contract', string="关联租赁合同审批") contract_ids = fields.Many2many('property.lease.contract', string="租赁合同审批") + property_name = fields.Char(string="物业名称") accounts_id = fields.Many2one('property.accounts.approval', string="关联生成应收审批单") def batch_revocation(self): @@ -393,6 +394,13 @@ class PropertyAccountsReceivable(models.Model): actual_coping = fields.Float(string="实际应付") + def update_lessee_id(self): + accounts_ids = self.env["property.accounts.receivable"].browse( + self._context.get('active_ids', self._context.get('active_id'))) + for rec in accounts_ids: + rec.lessee_id = rec.contract_id.lessee_id + + @api.depends('management_type_id') def _compute_is_rent(self): for rec in self: diff --git a/yuthon_property_approval/views/inherit_yuthon_property_views.xml b/yuthon_property_approval/views/inherit_yuthon_property_views.xml index f5f1b973f..082e58d61 100644 --- a/yuthon_property_approval/views/inherit_yuthon_property_views.xml +++ b/yuthon_property_approval/views/inherit_yuthon_property_views.xml @@ -293,11 +293,11 @@ + + - -