-
Notifications
You must be signed in to change notification settings - Fork 7.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: account heads changed along with journal entry type and descrip… (
#42845) * feat: account heads changed along with journal entry type and description * feat: added patch for difference_amount for asset value adjustment and refactor --------- Co-authored-by: “rahulgupta8848” <“[email protected]”>
- Loading branch information
1 parent
9b4bb30
commit d4fdada
Showing
7 changed files
with
137 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
erpnext/patches/v15_0/set_difference_amount_in_asset_value_adjustment.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import frappe | ||
|
||
|
||
def execute(): | ||
AssetValueAdjustment = frappe.qb.DocType("Asset Value Adjustment") | ||
|
||
frappe.qb.update(AssetValueAdjustment).set( | ||
AssetValueAdjustment.difference_amount, | ||
AssetValueAdjustment.new_asset_value - AssetValueAdjustment.current_asset_value, | ||
).where(AssetValueAdjustment.docstatus != 2).run() |