From c9980c59e7870f200a8051617565c15a2f092781 Mon Sep 17 00:00:00 2001 From: Khushi Rawat <142375893+khushi8112@users.noreply.github.com> Date: Wed, 2 Apr 2025 01:02:07 +0530 Subject: [PATCH] chore: adjust regional depreciation logic after refactor --- .../asset_depreciation_schedule/depreciation_methods.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/erpnext/assets/doctype/asset_depreciation_schedule/depreciation_methods.py b/erpnext/assets/doctype/asset_depreciation_schedule/depreciation_methods.py index 4bea70e4049..daa3f0b0918 100644 --- a/erpnext/assets/doctype/asset_depreciation_schedule/depreciation_methods.py +++ b/erpnext/assets/doctype/asset_depreciation_schedule/depreciation_methods.py @@ -75,7 +75,12 @@ class StraightLineMethod(Document): class WDVMethod(Document): + @erpnext.allow_regional def get_wdv_or_dd_depr_amount(self, row_idx): + return self.calculate_wdv_or_dd_based_depreciation_amount(row_idx) + + @staticmethod + def calculate_wdv_or_dd_based_depreciation_amount(self, row_idx): if self.fb_row.daily_prorata_based: return self.get_daily_prorata_based_wdv_depr_amount(row_idx) else: