Merge lp:~openerp-dev/openobject-addons/trunk-bug-1093038-atp into lp:openobject-addons

Proposed by Atul Patel(OpenERP)
Status: Needs review
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-bug-1093038-atp
Merge into: lp:openobject-addons
Diff against target: 23 lines (+3/-3)
1 file modified
share/wizard/share_wizard.py (+3/-3)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-bug-1093038-atp
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+141256@code.launchpad.net

Description of the change

Hello,

Remove argument "unused_params" from "has_share" function.

Replace normalize_leaf inplace of normalize in expression attribute.

To post a comment you must log in.
8483. By Atul Patel(OpenERP)

[MERGE]: Merged with lp:openobject-addons

8484. By Atul Patel(OpenERP)

[FIX]: Fix has_share() argument problem

8485. By Atul Patel(OpenERP)

[MERGE]: Merged with addons

8486. By Atul Patel(OpenERP)

[MERGE]: Merged with addons

Unmerged revisions

8486. By Atul Patel(OpenERP)

[MERGE]: Merged with addons

8485. By Atul Patel(OpenERP)

[MERGE]: Merged with addons

8484. By Atul Patel(OpenERP)

[FIX]: Fix has_share() argument problem

8483. By Atul Patel(OpenERP)

[MERGE]: Merged with lp:openobject-addons

8482. By Atul Patel(OpenERP)

[FIX]: Remove unused_param argument form has_share function.
Replace normalize_leaf inplace of normalize in expression attribute.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'share/wizard/share_wizard.py'
2--- share/wizard/share_wizard.py 2012-12-27 16:45:59 +0000
3+++ share/wizard/share_wizard.py 2013-02-18 05:13:28 +0000
4@@ -69,7 +69,7 @@
5 return False
6 return group_id in self.pool.get('res.users').read(cr, uid, uid, ['groups_id'], context=context)['groups_id']
7
8- def has_share(self, cr, uid, unused_param, context=None):
9+ def has_share(self, cr, uid, unused_param=False, context=None):
10 return self.has_group(cr, uid, module='share', group_xml_id='group_share_user', context=context)
11
12 def _user_type_selection(self, cr, uid, context=None):
13@@ -614,8 +614,8 @@
14 # other groups, so we duplicate if needed
15 rule = self._check_personal_rule_or_duplicate(cr, group_id, rule, context=context)
16 eval_ctx = rule_obj._eval_context_for_combinations()
17- org_domain = expression.normalize(eval(rule.domain_force, eval_ctx))
18- new_clause = expression.normalize(eval(domain, eval_ctx))
19+ org_domain = expression.normalize_leaf(eval(rule.domain_force, eval_ctx))
20+ new_clause = expression.normalize_leaf(eval(domain, eval_ctx))
21 combined_domain = expression.AND([new_clause, org_domain])
22 rule.write({'domain_force': combined_domain, 'name': rule.name + _('(Modified)')})
23 _logger.debug("Combining sharing rule %s on model %s with domain: %s", rule.id, model_id, domain)

Subscribers

People subscribed via source and target branches

to all changes: