mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-29 18:04:46 +00:00
fix: conflicts while merging brnach version-13 to develop
This commit is contained in:
@@ -176,16 +176,16 @@ class Asset(AccountsController):
|
||||
|
||||
for d in self.get('finance_books'):
|
||||
self.validate_asset_finance_books(d)
|
||||
|
||||
|
||||
start = self.clear_depreciation_schedule()
|
||||
|
||||
# value_after_depreciation - current Asset value
|
||||
if d.value_after_depreciation:
|
||||
value_after_depreciation = (flt(d.value_after_depreciation) -
|
||||
flt(self.opening_accumulated_depreciation))
|
||||
flt(self.opening_accumulated_depreciation))
|
||||
else:
|
||||
value_after_depreciation = (flt(self.gross_purchase_amount) -
|
||||
flt(self.opening_accumulated_depreciation))
|
||||
flt(self.opening_accumulated_depreciation))
|
||||
|
||||
d.value_after_depreciation = value_after_depreciation
|
||||
|
||||
@@ -321,10 +321,10 @@ class Asset(AccountsController):
|
||||
def get_from_date(self, finance_book):
|
||||
if not self.get('schedules'):
|
||||
return self.available_for_use_date
|
||||
|
||||
|
||||
if len(self.finance_books) == 1:
|
||||
return self.schedules[-1].schedule_date
|
||||
|
||||
|
||||
from_date = ""
|
||||
for schedule in self.get('schedules'):
|
||||
if schedule.finance_book == finance_book:
|
||||
@@ -831,4 +831,4 @@ def get_depreciation_amount(asset, depreciable_value, row):
|
||||
else:
|
||||
depreciation_amount = flt(depreciable_value * (flt(row.rate_of_depreciation) / 100))
|
||||
|
||||
return depreciation_amount
|
||||
return depreciation_amount
|
||||
|
||||
Reference in New Issue
Block a user