Mercurial > bottledash
diff modules/roundup_cc/__init__.py @ 13:63b9f41c3008
made the charts a bit more modular - can now define the div_name and the script name in the .conf data
author | sean |
---|---|
date | Wed, 05 Aug 2015 12:37:33 +0200 |
parents | 50f4c64834cb |
children |
line wrap: on
line diff
--- a/modules/roundup_cc/__init__.py Tue Aug 04 16:00:07 2015 +0200 +++ b/modules/roundup_cc/__init__.py Wed Aug 05 12:37:33 2015 +0200 @@ -23,10 +23,10 @@ # PATH = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))) -def make_chart(chart_data_file): +def make_chart(chart_data_file, target_div_name): + mod = importlib.import_module("roundup_cc." + chart_data_file) - mod = importlib.import_module("roundup_cc." + chart_data_file) - return mod.get_chart() + return mod.get_chart(target_div_name) # test = exec(open(PATH + "/" + chart_data_file+'.py').read())