Save default letterhead

This commit is contained in:
Anand Doshi 2014-06-09 18:01:14 +05:30
parent 534ebde638
commit c01db5fe9c
2 changed files with 14 additions and 0 deletions

View File

@ -56,3 +56,4 @@ erpnext.patches.v4_0.update_tax_amount_after_discount
execute:frappe.reset_perms("GL Entry") #2014-06-09
execute:frappe.reset_perms("Stock Ledger Entry") #2014-06-09
erpnext.patches.v4_0.create_custom_fields_for_india_specific_fields
erpnext.patches.v4_0.save_default_letterhead

View File

@ -0,0 +1,13 @@
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
from __future__ import unicode_literals
import frappe
def execute():
"""save default letterhead to set default_letter_head_content"""
try:
letter_head = frappe.get_doc("Letter Head", {"is_default": 1})
letter_head.save()
except frappe.DoesNotExistError:
pass