Skip to content

Commit

Permalink
chore(stock): format delivery stop json according to doctype builder
Browse files Browse the repository at this point in the history
  • Loading branch information
blaggacao committed Oct 10, 2023
1 parent 15cf93d commit 03d59d0
Show file tree
Hide file tree
Showing 3 changed files with 204 additions and 810 deletions.
1 change: 1 addition & 0 deletions erpnext/patches.txt
Original file line number Diff line number Diff line change
Expand Up @@ -344,5 +344,6 @@ erpnext.patches.v15_0.delete_woocommerce_settings_doctype
erpnext.patches.v14_0.migrate_deferred_accounts_to_item_defaults
erpnext.patches.v14_0.update_invoicing_period_in_subscription
execute:frappe.delete_doc("Page", "welcome-to-erpnext")
erpnext.patches.v14_0.migrate_delivery_stock_lock_field
# below migration patch should always run last
erpnext.patches.v14_0.migrate_gl_to_payment_ledger
11 changes: 11 additions & 0 deletions erpnext/patches/v14_0/migrate_delivery_stop_lock_field.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import frappe
from frappe.model.utils.rename_field import rename_field


def execute():
frappe.reload_doc("stock", "doctype", "Delivery Stop")
try:
rename_field("Delivery Stop", "lock", "locked")
except Exception:
frappe.db.rollback()
frappe.log_error("Failed to rename Delivery Stock field 'lock' to 'locked'.")
Loading

0 comments on commit 03d59d0

Please sign in to comment.