[FIX] Remove unused code about the create method in the ir.ui.view
authorStephane Wirtel <stephane@openerp.com>
Fri, 16 Apr 2010 11:26:10 +0000 (13:26 +0200)
committerStephane Wirtel <stephane@openerp.com>
Fri, 16 Apr 2010 11:26:10 +0000 (13:26 +0200)
object

bzr revid: stephane@openerp.com-20100416112610-bvysh7lqaof3p4kj

bin/addons/base/ir/ir_ui_view.py

index 95ce993..f7264ac 100644 (file)
@@ -76,23 +76,6 @@ class view(osv.osv):
         (_check_xml, 'Invalid XML for View Architecture!', ['arch'])
     ]
 
-    def create(self, cr, uid, vals, context={}):
-       if 'inherit_id' in vals and vals['inherit_id']:
-           obj=self.browse(cr,uid,vals['inherit_id'])
-           child=self.pool.get(vals['model'])
-           error="Inherited view model [%s] and \
-                                 \n\n base view model [%s] do not match \
-                                 \n\n It should be same as base view model " \
-                                 %(vals['model'],obj.model)
-           try:
-               if obj.model==child._inherit:
-                pass
-           except:
-               if not obj.model==vals['model']:
-                raise Exception(error)
-
-       return super(view,self).create(cr, uid, vals, context={})
-
     def read(self, cr, uid, ids, fields=None, context={}, load='_classic_read'):
 
         if not isinstance(ids, (list, tuple)):