mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
[IMP] preview button
This commit is contained in:
committed by
David James
parent
f9420fcdc8
commit
1ff35f17f7
@@ -570,3 +570,9 @@ class BiSQLView(models.Model):
|
||||
sql_view.view_name)
|
||||
self.env.cr.execute(req)
|
||||
sql_view.size = self.env.cr.fetchone()[0]
|
||||
|
||||
@api.multi
|
||||
def button_preview_sql_expression(self):
|
||||
self.button_validate_sql_expression()
|
||||
res = self._execute_sql_request()
|
||||
raise UserError('\n'.join(map(lambda x: str(x), res[:100])))
|
||||
|
||||
Reference in New Issue
Block a user