mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
[FIX] Manage jsonb fields
This commit is contained in:
@@ -110,6 +110,9 @@ class SqlExport(models.Model):
|
|||||||
col_position = 1
|
col_position = 1
|
||||||
for index, row in enumerate(res, row_position):
|
for index, row in enumerate(res, row_position):
|
||||||
for col, val in enumerate(row, col_position):
|
for col, val in enumerate(row, col_position):
|
||||||
|
# manage jsonb field as dict are not writable on the excel cell
|
||||||
|
if isinstance(val, dict):
|
||||||
|
val = str(val)
|
||||||
ws.cell(row=index, column=col).value = val
|
ws.cell(row=index, column=col).value = val
|
||||||
output = BytesIO()
|
output = BytesIO()
|
||||||
wb.save(output)
|
wb.save(output)
|
||||||
|
|||||||
Reference in New Issue
Block a user