fix: Add patch for GST category field in Delivery Note
This commit is contained in:
parent
29997414ad
commit
f954ec7c78
@ -762,3 +762,4 @@ erpnext.patches.v13_0.setup_gratuity_rule_for_india_and_uae
|
||||
erpnext.patches.v13_0.setup_uae_vat_fields
|
||||
execute:frappe.db.set_value('System Settings', None, 'app_name', 'ERPNext')
|
||||
erpnext.patches.v13_0.rename_discharge_date_in_ip_record
|
||||
erpnext.patches.v12_0.add_gst_category_in_delivery_note
|
||||
|
19
erpnext/patches/v12_0/add_gst_category_in_delivery_note.py
Normal file
19
erpnext/patches/v12_0/add_gst_category_in_delivery_note.py
Normal file
@ -0,0 +1,19 @@
|
||||
from __future__ import unicode_literals
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
if not company:
|
||||
return
|
||||
|
||||
custom_fields = {
|
||||
'Delivery Note': [
|
||||
dict(fieldname='gst_category', label='GST Category',
|
||||
fieldtype='Select', insert_after='gst_vehicle_type', print_hide=1,
|
||||
options='\nRegistered Regular\nRegistered Composition\nUnregistered\nSEZ\nOverseas\nConsumer\nDeemed Export\nUIN Holders',
|
||||
fetch_from='customer.gst_category', fetch_if_empty=1),
|
||||
]
|
||||
}
|
||||
|
||||
create_custom_fields(custom_fields, update=True)
|
Loading…
x
Reference in New Issue
Block a user