fix: patches were breaking during migration (#27213)
* fix: patches were breaking during migration (#27200)
* fix: patches were breaking during migrating
* fix: patches were breaking during migration
(cherry picked from commit 7433757489)
# Conflicts:
# erpnext/patches.txt
* fix: resolve conflicts
Co-authored-by: Shadrak Gurupnor <30501401+shadrak98@users.noreply.github.com>
Co-authored-by: Ankush Menat <ankush@iwebnotes.com>
This commit is contained in:
@@ -1086,3 +1086,14 @@ def get_journal_entry(account, stock_adjustment_account, amount):
|
||||
db_or_cr_stock_adjustment_account : abs(amount)
|
||||
}]
|
||||
}
|
||||
|
||||
def check_and_delete_linked_reports(report):
|
||||
""" Check if reports are referenced in Desktop Icon """
|
||||
icons = frappe.get_all("Desktop Icon",
|
||||
fields = ['name'],
|
||||
filters = {
|
||||
"_report": report
|
||||
})
|
||||
if icons:
|
||||
for icon in icons:
|
||||
frappe.delete_doc("Desktop Icon", icon)
|
||||
|
||||
Reference in New Issue
Block a user