From d36117ed60af30ad32bc40438b24b782c8a7b2a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Sat, 6 Jun 2015 17:49:02 +0200 Subject: [PATCH] [IMP] mis_builder: pep8 --- mis_builder/models/mis_builder.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/mis_builder/models/mis_builder.py b/mis_builder/models/mis_builder.py index a217e826..ca688f86 100644 --- a/mis_builder/models/mis_builder.py +++ b/mis_builder/models/mis_builder.py @@ -183,29 +183,29 @@ class mis_report_kpi(orm.Model): if value is None or base_value is None: return '' if kpi.type == 'pct': - return self._render_num(cr, uid, lang_id, - value - base_value, - 0.01, kpi.dp, - _('pp'), sign='+', - context=context) + return self._render_num( + cr, uid, lang_id, + value - base_value, + 0.01, kpi.dp, _('pp'), sign='+', + context=context) elif kpi.type == 'num': if average_value: value = value / float(average_value) if average_base_value: base_value = base_value / float(average_base_value) if kpi.compare_method == 'diff': - return self._render_num(cr, uid, lang_id, - value - base_value, - kpi.divider, kpi.dp, - kpi.suffix, sign='+', - context=context) + return self._render_num( + cr, uid, lang_id, + value - base_value, + kpi.divider, kpi.dp, kpi.suffix, sign='+', + context=context) elif kpi.compare_method == 'pct': if round(base_value, kpi.dp) != 0: - return self._render_num(cr, uid, lang_id, - (value - base_value) / abs(base_value), - 0.01, kpi.dp, - '%', sign='+', - context=context) + return self._render_num( + cr, uid, lang_id, + (value - base_value) / abs(base_value), + 0.01, kpi.dp, '%', sign='+', + context=context) return '' def _render_num(self, cr, uid, lang_id, value, divider,