Merge branch 'master' into develop
This commit is contained in:
commit
50616da905
@ -4,7 +4,7 @@ import inspect
|
||||
import frappe
|
||||
from erpnext.hooks import regional_overrides
|
||||
|
||||
__version__ = '9.2.11'
|
||||
__version__ = '9.2.12'
|
||||
|
||||
def get_default_company(user=None):
|
||||
'''Get default company for user'''
|
||||
|
@ -460,3 +460,4 @@ execute:frappe.delete_doc_if_exists("DocType", "Program Fee")
|
||||
erpnext.patches.v9_0.set_pos_profile_name
|
||||
erpnext.patches.v9_0.remove_non_existing_warehouse_from_stock_settings
|
||||
execute:frappe.delete_doc_if_exists("DocType", "Program Fee")
|
||||
erpnext.patches.v9_2.delete_healthcare_domain_default_items
|
0
erpnext/patches/v9_2/__init__.py
Normal file
0
erpnext/patches/v9_2/__init__.py
Normal file
@ -0,0 +1,16 @@
|
||||
import frappe
|
||||
from frappe.utils import getdate
|
||||
|
||||
def execute():
|
||||
domain_settings = frappe.get_doc('Domain Settings')
|
||||
active_domains = [d.domain for d in domain_settings.active_domains]
|
||||
|
||||
if "Healthcare" not in active_domains:
|
||||
items = ["TTT", "MCH", "LDL", "GTT", "HDL", "BILT", "BILD", "BP", "BS"]
|
||||
for item_code in items:
|
||||
try:
|
||||
item = frappe.db.get_value("Item", {"item_code": item_code}, ["name", "creation"], as_dict=1)
|
||||
if item and getdate(item.creation) >= getdate("2017-11-10"):
|
||||
frappe.delete_doc("Item", item.name)
|
||||
except:
|
||||
pass
|
Loading…
Reference in New Issue
Block a user