From c2a4ff2de07900e9b54c2c73c91a37a541d1a8fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Sun, 3 May 2015 22:11:36 +0200 Subject: [PATCH] [FIX] mis_builder: blind attempt to fix xls report which does not even start anymore :( --- mis_builder/report/mis_builder_xls.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mis_builder/report/mis_builder_xls.py b/mis_builder/report/mis_builder_xls.py index f1b659c6..88dcd1cf 100644 --- a/mis_builder/report/mis_builder_xls.py +++ b/mis_builder/report/mis_builder_xls.py @@ -87,7 +87,7 @@ class mis_builder_xls(report_xls): header_name_list = [''] col_specs_template = {'': {'header': [1, 30, 'text', ''], 'header_date': [1, 1, 'text', '']}} - for col in data['header']['']['cols']: + for col in data['header'][0]['cols']: col_specs_template[col['name']] = {'header': [1, 30, 'text', col['name']], 'header_date': [1, 1, 'text', @@ -109,8 +109,7 @@ class mis_builder_xls(report_xls): ws.set_horz_split_pos(row_pos) ws.set_vert_split_pos(1) - for key in data['content']: - line = data['content'][key] + for line in data['content']: col = 0 ws.write(row_pos, col, line['kpi_name'], self.mis_rh_cell_style) for value in line['cols']: