From 9de7d7f497a636117bdc9ac9daf08b53c3713573 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=B9=8F=E5=AE=87?= Date: Tue, 9 Jun 2026 10:50:28 +0800 Subject: [PATCH 1/2] official --- yuthon_official/models/yuthon_official.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yuthon_official/models/yuthon_official.py b/yuthon_official/models/yuthon_official.py index 65850b06c..213da7ab6 100644 --- a/yuthon_official/models/yuthon_official.py +++ b/yuthon_official/models/yuthon_official.py @@ -26,7 +26,7 @@ class YuthonOfficial(models.Model): main_flats_ids = fields.Many2many( 'main.flats', 'yuthon_official_main_flats_rel', - 'official_id' + 'official_id', 'flat_id', string="主送单位" ) From 5c18ffdfe65525d288a330dc801834202b679ed5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=B9=8F=E5=AE=87?= Date: Tue, 9 Jun 2026 11:53:17 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=8A=A5=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yuthon_report/models/deposit_total_report.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/yuthon_report/models/deposit_total_report.py b/yuthon_report/models/deposit_total_report.py index dce6e57db..2be0077f4 100644 --- a/yuthon_report/models/deposit_total_report.py +++ b/yuthon_report/models/deposit_total_report.py @@ -15,7 +15,7 @@ class DepositTotalReport(models.Model): - 管理费用类型为"押金" - 押金状态为"已收" - 非作废记录 - - 支付日期(payout_date)在查询月内 + - 收款日期(payout_date)≤ 查询月末(累计逻辑,含提前预收) - 金额:original_amount - discount_amount - 排除已退款的押金(即property.bills.list中有actual_date的押金记录) """ @@ -37,7 +37,6 @@ class DepositTotalReport(models.Model): ('management_type_id.name', '=', '押金'), ('deposit_state', '=', 'paid'), ('is_invalid', '!=', True), - ('payout_date', '>=', month_first), ('payout_date', '<=', month_last), ] @@ -56,12 +55,24 @@ class DepositTotalReport(models.Model): condition = params.get('condition') partner_id = params.get('partner_id') company_id = params.get('company_id') + management_type_id = params.get('management_type_id') + property_id = params.get('property_id') + lessee_id = params.get('lessee_id') + contract_id = params.get('contract_id') if condition: domain.append(('tenure_type', '=', condition)) if partner_id: domain.append(('precinct_id', '=', partner_id)) if company_id: domain.append(('company_id', '=', company_id)) + if property_id: + domain.append(('property_ids', 'in', [property_id])) + if lessee_id: + domain.append(('lessee_id', '=', lessee_id)) + if contract_id: + domain.append(('contract_id', '=', contract_id)) + if management_type_id: + domain.append(('management_type_id', '=', management_type_id)) lines = self.sudo().search(domain, order="contract_id asc")