[minor] move warehouse user to restrictions

This commit is contained in:
Anand Doshi
2013-12-09 12:04:49 +05:30
parent 57518fc5f1
commit 83638b5f05
14 changed files with 81 additions and 95 deletions

View File

@@ -0,0 +1,12 @@
# 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 webnotes
def execute():
from core.page.user_properties import user_properties
for warehouse, profile in webnotes.conn.sql("""select parent, user from `tabWarehouse User`"""):
user_properties.add(profile, "Warehouse", warehouse)
webnotes.delete_doc("DocType", "Warehouse User")

View File

@@ -263,4 +263,5 @@ patch_list = [
"patches.1311.p07_scheduler_errors_digest",
"patches.1311.p08_email_digest_recipients",
"execute:webnotes.delete_doc('DocType', 'Warehouse Type')",
"patches.1311.p07_move_warehouse_user_to_restrictions",
]