brotherton-erpnext/patches/1311/p01_cleanup.py

23 lines
1.1 KiB
Python
Raw Normal View History

2013-11-15 10:39:45 +00:00
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd.
# License: GNU General Public License v3. See license.txt
2013-11-03 15:07:49 +00:00
import webnotes
def execute():
2013-11-11 12:31:37 +00:00
webnotes.reload_doc("stock", "doctype", "material_request")
webnotes.reload_doc("buying", "doctype", "purchase_order")
webnotes.reload_doc("selling", "doctype", "lead")
2013-11-13 12:00:10 +00:00
2013-11-06 05:59:47 +00:00
from core.doctype.custom_field.custom_field import create_custom_field_if_values_exist
2013-11-13 12:00:10 +00:00
2013-11-06 05:59:47 +00:00
create_custom_field_if_values_exist("Material Request",
{"fieldtype":"Text", "fieldname":"remark", "label":"Remarks","insert_after":"Fiscal Year"})
create_custom_field_if_values_exist("Purchase Order",
{"fieldtype":"Text", "fieldname":"instructions", "label":"Instructions","insert_after":"% Billed"})
create_custom_field_if_values_exist("Purchase Order",
{"fieldtype":"Text", "fieldname":"remarks", "label":"Remarks","insert_after":"% Billed"})
create_custom_field_if_values_exist("Purchase Order",
{"fieldtype":"Text", "fieldname":"payment_terms", "label":"Payment Terms","insert_after":"Print Heading"})
create_custom_field_if_values_exist("Lead",
{"fieldtype":"Text", "fieldname":"remark", "label":"Remark","insert_after":"Territory"})