c2c-oerpscenario team mailing list archive
-
c2c-oerpscenario team
-
Mailing list archive
-
Message #17623
[Bug 719406] Re: Record rules with domain blank or [] result in application error
Hello Vo Minh Thu,
Thanks for the merge proposal and for the fix.
Well, the problem is fixed partially and your merge tends to fix the
problem only when the domain is '' (Blank).
There is a case where you can face the problem.
Go to the particular record rule,set the domain as [],and make sure your user is in the group given. If you have the similar configuration,you won't face any problem there is only one group.
When there are more than one groups given to the record rule, system
appends ['|'] to the domain ,but as the domain is [],no more operands
are appended.
So, the result of a domain is [' | ' ] * (no_of_groups -1). (e.g. for 3
groups to a rule ,domain will be ['|','|']), and so there is a pop
error.
Hope this is clear.
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/719406
Title:
Record rules with domain blank or [] result in application error
Status in OpenERP Server:
Confirmed
Bug description:
1. In v6.0.1, create any record rule with empty domain [].
2. Log in with user other than admin and pull up any view that invokes above rule, following application error will be reported:
File "C:\Program Files\OpenERP 6.0\Server\addons\base\ir\ir_rule.py", line 141, in domain_get
File "osv\orm.pyo", line 3823, in _where_calc
File "osv\expression.pyo", line 499, in to_sql
IndexError: pop from empty list
References