openerp-dev-web team mailing list archive
-
openerp-dev-web team
-
Mailing list archive
-
Message #05311
lp:~openerp-dev/openobject-addons/addons-training-diagnostic-synthesis-range-ysa into lp:~openobject-training/openobject-addons/training
Yogesh(Open ERP) has proposed merging lp:~openerp-dev/openobject-addons/addons-training-diagnostic-synthesis-range-ysa into lp:~openobject-training/openobject-addons/training.
Requested reviews:
OpenObject Training (openobject-training)
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/addons-training-diagnostic-synthesis-range-ysa/+merge/57132
[FIX] training_diagnostic :- create get_list_range method in report py file and return range() instead of direct range() method call in rml report file.
--
https://code.launchpad.net/~openerp-dev/openobject-addons/addons-training-diagnostic-synthesis-range-ysa/+merge/57132
Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/addons-training-diagnostic-synthesis-range-ysa.
=== modified file 'training_diagnostic/report/diagnostic_synthesis.py'
--- training_diagnostic/report/diagnostic_synthesis.py 2011-04-07 13:04:11 +0000
+++ training_diagnostic/report/diagnostic_synthesis.py 2011-04-11 10:08:27 +0000
@@ -40,6 +40,7 @@
'get_max_domain_points': self.get_max_domain_points,
'get_remarks': self.get_remarks,
'assessor_filled': self.assessor_filled,
+ 'get_list_range': self.get_list_range,
})
def get_ctx(self):
@@ -49,6 +50,9 @@
return reduce(lambda acc, a: acc + a,
[ l.point_question_id for l in p.participation_line_ids ], 0.0)
+ def get_list_range(self, number):
+ return range(number)
+
def get_max_domain_points(self, p):
return reduce(lambda acc, a: acc + a,
[ l.ideal_score for l in p.domain_line_ids], 0.0)
=== modified file 'training_diagnostic/report/diagnostic_synthesis.rml'
--- training_diagnostic/report/diagnostic_synthesis.rml 2011-04-05 10:57:36 +0000
+++ training_diagnostic/report/diagnostic_synthesis.rml 2011-04-11 10:08:27 +0000
@@ -308,7 +308,7 @@
<tr>
<td><para style="std-12-left">[[ p.summary and p.summary or removeParentNode('tr') ]]</para></td>
</tr>
- <tr>[[ repeatIn(not p.summary and range(20) or [], 'x') ]]
+ <tr>[[ repeatIn(not p.summary and get_list_range(20) or [], 'x') ]]
<td></td>
</tr>
</blockTable>
@@ -320,7 +320,7 @@
<tr>
<td><para style="std-12-left">[[ p.diagnostic_extra_summary and p.diagnostic_extra_summary or removeParentNode('tr') ]]</para></td>
</tr>
- <tr>[[ repeatIn(not p.diagnostic_extra_summary and range(15) or [], 'x') ]]
+ <tr>[[ repeatIn(not p.diagnostic_extra_summary and get_list_range(15) or [], 'x') ]]
<td></td>
</tr>
</blockTable>
Follow ups