From bf385f0d675c71d51b9537633ff9469e4bf0694d 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, 28 Oct 2025 11:11:14 +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/models/property_bank_statements.py | 2 +- yuthon_salary/models/inherit_hr_payslip.py | 2 +- yuthon_salary/views/inherit_hr_payslip_views.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/yuthon_property/models/property_bank_statements.py b/yuthon_property/models/property_bank_statements.py index 0ab93ac5b..c1f114129 100644 --- a/yuthon_property/models/property_bank_statements.py +++ b/yuthon_property/models/property_bank_statements.py @@ -50,7 +50,7 @@ class PropertyBankStatements(models.Model): @api.depends('yes_amount', 'original_amount') def _compute_no_amount(self): for rec in self: - rec.no_amount = rec.original_amount - rec.yes_amount + rec.no_amount = max((rec.original_amount - rec.yes_amount), 0) def update_lending_direction(self): bank_ids = self.env["property.bank.statements"].browse( diff --git a/yuthon_salary/models/inherit_hr_payslip.py b/yuthon_salary/models/inherit_hr_payslip.py index 7fe5c074b..afd21f693 100644 --- a/yuthon_salary/models/inherit_hr_payslip.py +++ b/yuthon_salary/models/inherit_hr_payslip.py @@ -818,7 +818,7 @@ class InheritHrPayslip(models.Model): "name": "薪资明细", "view_mode": "tree", "views": [(False, "tree")], - "domain": [("slip_id", "=", self.id), ("amount", "!=", 0)], + "domain": [("slip_id", "=", self.id), ("total", "!=", 0)], "target": "new", "context": { "tree_view_ref": "yuthon_salary.view_hr_payslip_line_tree_custom", diff --git a/yuthon_salary/views/inherit_hr_payslip_views.xml b/yuthon_salary/views/inherit_hr_payslip_views.xml index c1b875ff3..f2a5525a4 100644 --- a/yuthon_salary/views/inherit_hr_payslip_views.xml +++ b/yuthon_salary/views/inherit_hr_payslip_views.xml @@ -849,7 +849,7 @@ - + From ef2e53f1790af616a5ea4560898850308bdd2ce4 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, 28 Oct 2025 11:16:18 +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_approval/wizard/click_reconciliation_wizard.py | 1 + 1 file changed, 1 insertion(+) diff --git a/yuthon_property_approval/wizard/click_reconciliation_wizard.py b/yuthon_property_approval/wizard/click_reconciliation_wizard.py index 925a86e0f..8ff09615c 100644 --- a/yuthon_property_approval/wizard/click_reconciliation_wizard.py +++ b/yuthon_property_approval/wizard/click_reconciliation_wizard.py @@ -83,6 +83,7 @@ class ClickReconciliationWizard(models.Model): rec.write({ 'is_reconciliation': True, 'delivered1': rec.original_amount, + 'change_amount': rec.original_amount, 'reconciliation_time': fields.Datetime.now() - timedelta(hours=8), 'payout_date': statements[0].start_time.date() if statements else False, # 取第一笔流水日期 'receivable_log': f'当前登录人{self.env.user.name}于{fields.Datetime.now()}对户名为{statements[0].name_account}进行对账操作(多笔流水合并)'