Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Sharoon Thomas committed Dec 7, 2011
2 parents 4506910 + ee1906c commit 8edb1dc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion template.py
Original file line number Diff line number Diff line change
Expand Up @@ -953,7 +953,10 @@ def generate_mail(self,
if template.use_filter and template.filter:
filtered_record_ids=[]
for record in self.pool.get(template.object_name.model).browse(cursor, user, record_ids, context=context):
if safe_eval(template.filter, {'o':record, 'self':self, 'cr':cursor, 'context':context}):
if safe_eval(template.filter, {'o':record, 'self':self,
'cr':cursor,
'context':context,
'uid': user}):
filtered_record_ids.append(record.id)
record_ids=filtered_record_ids

Expand Down

0 comments on commit 8edb1dc

Please sign in to comment.