[fix] [patch]

This commit is contained in:
Rushabh Mehta 2015-07-16 14:16:48 +05:30
parent ea4d63cef3
commit f3791797d6

View File

@ -1,9 +1,9 @@
import frappe
def execute():
frappe.rename_doc("Role", "Material User", "Stock User",
merge=frappe.db.exists("Role", "Stock User"))
frappe.rename_doc("Role", "Material Manager", "Stock Manager",
merge=frappe.db.exists("Role", "Stock User"))
frappe.rename_doc("Role", "Material Master Manager", "Item Manager",
merge=frappe.db.exists("Role", "Stock User"))
if not frappe.db.exists("Role", "Stock User"):
frappe.rename_doc("Role", "Material User", "Stock User")
if not frappe.db.exists("Role", "Stock Manager"):
frappe.rename_doc("Role", "Material Manager", "Stock Manager")
if not frappe.db.exists("Role", "Stock Manager"):
frappe.rename_doc("Role", "Material Master Manager", "Item Manager")