[FIX] point_of_sale: Sale Details report error corrected.

bzr revid: uco@tinyerp.com-20100810055845-uv3z65btr2wrliom
This commit is contained in:
uco (Open ERP) 2010-08-10 11:28:45 +05:30
parent db34a6bf10
commit e36a9b47a6
1 changed files with 3 additions and 3 deletions

View File

@ -27,9 +27,9 @@ class pos_details(report_sxw.rml_parse):
def _get_invoice(self,inv_id,user):
res={}
self.cr.execute("select name from account_invoice as ac where id = %d" %(inv_id))
res = self.cr.fetchone()
if res:
if inv_id:
self.cr.execute("select name from account_invoice as ac where id = %d" %(inv_id))
res = self.cr.fetchone()
return res[0]
else:
return ''