← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 803486] Re: option 'parent' can't be recognized when using widget="selection"!

 

Hi Vinay,

This is the code that makes error. The code in file openerp-
server/osv/orm.py, line 1240, in function __view_look_dom, in checking
widget="selection". With this code, it can only evaluate static domain,
not dynamic domain.

===
dom += eval(node.get('domain', '[]'), {'uid': user, 'time': time})
===

Thanks,

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/803486

Title:
  option 'parent' can't be recognized when using widget="selection"!

Status in OpenERP Server:
  Invalid

Bug description:
  Hi,

  I think this is a bug.

  In view definition of voucher_payment_receipt_form of module account_voucher, I wonder 'parent'  in the code below, how openerp server can understand what parent means? I understand the meaning of this definition, but does not know how to implement this in other views. I tried but openerp reports 
  "NameError: name 'parent' is not defined"

  ===
  domain="[
     ('account_id.type','in',('receivable','payable')), 
     ('reconcile_id','=', False), 
     ('partner_id','=',parent.partner_id)
  ]"
  ===

  Thanks,

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-server/+bug/803486/+subscriptions


References