mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
@@ -136,4 +136,4 @@ class Py3oParserContext(object):
|
|||||||
no_break_space=True,
|
no_break_space=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
return self._format_date(self._env, value)
|
return self._format_date(value)
|
||||||
|
|||||||
@@ -207,8 +207,12 @@ class Py3oReport(models.TransientModel):
|
|||||||
def _create_single_report(self, model_instance, data):
|
def _create_single_report(self, model_instance, data):
|
||||||
"""This function to generate our py3o report"""
|
"""This function to generate our py3o report"""
|
||||||
self.ensure_one()
|
self.ensure_one()
|
||||||
|
action_report = self.ir_actions_report_id
|
||||||
|
filetype = action_report.py3o_filetype
|
||||||
|
if filetype not in ("odt", "ods", "odp", "fodt", "fods", "fodp"):
|
||||||
|
filetype = "ods"
|
||||||
result_fd, result_path = tempfile.mkstemp(
|
result_fd, result_path = tempfile.mkstemp(
|
||||||
suffix=".ods", prefix="p3o.report.tmp."
|
suffix="." + filetype, prefix="p3o.report.tmp."
|
||||||
)
|
)
|
||||||
tmpl_data = self.get_template(model_instance)
|
tmpl_data = self.get_template(model_instance)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user