model_wrapper is now bean, refactoring defaults

This commit is contained in:
Rushabh Mehta
2013-02-18 18:24:28 +05:30
parent 9c880da381
commit c53231a841
104 changed files with 351 additions and 163 deletions

View File

@@ -121,7 +121,7 @@ def add_ac(args=None):
args = webnotes.form_dict
args.pop("cmd")
ac = webnotes.model_wrapper(args)
ac = webnotes.bean(args)
ac.doc.doctype = "Account"
ac.doc.old_parent = ""
ac.doc.freeze_account = "No"
@@ -135,7 +135,7 @@ def add_cc(args=None):
args = webnotes.form_dict
args.pop("cmd")
cc = webnotes.model_wrapper(args)
cc = webnotes.bean(args)
cc.doc.doctype = "Cost Center"
cc.doc.old_parent = ""
cc.ignore_permissions = 1