Commit ab2a5d44 authored by mouadh's avatar mouadh

format

parent f6879c40
......@@ -136,7 +136,8 @@ class MdxEngine:
config_file_parser = ConfigParser(self.cube_path)
tables = {}
if config_file_parser.config_file_exist(
) and self.cube in config_file_parser.get_cubes_names() and self.client != 'web':
) and self.cube in config_file_parser.get_cubes_names(
) and self.client != 'web':
for cubes in config_file_parser.construct_cubes():
# TODO working with cubes.source == 'csv'
......@@ -172,7 +173,8 @@ class MdxEngine:
config_file_parser = ConfigParser(self.cube_path)
if config_file_parser.config_file_exist(
self.client
) and self.cube in config_file_parser.get_cubes_names(client_type='web'):
) and self.cube in config_file_parser.get_cubes_names(
client_type='web'):
for cubes in config_file_parser.construct_cubes(self.client):
# TODO cubes.source == 'csv'
if cubes.source == 'postgres':
......
......@@ -220,7 +220,8 @@ class ConfigParser:
:return: True | False
"""
if self.config_file_exist():
with open(os.path.join(self.cube_path, self.file_name)) as config_file:
with open(os.path.join(self.cube_path,
self.file_name)) as config_file:
parser = etree.XMLParser()
tree = etree.parse(config_file, parser)
......@@ -373,7 +374,8 @@ class ConfigParser:
global_table={
'columns':
dashboard.find('Global_table/columns').text.split(','),
'rows': dashboard.find('Global_table/rows').text.split(',')
'rows':
dashboard.find('Global_table/rows').text.split(',')
},
pie_charts=dashboard.find('PieCharts').text.split(','),
bar_charts=dashboard.find('BarCharts').text.split(','),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment