← Back to team overview

openerp-dev-web team mailing list archive

lp:~openerp-dev/openobject-addons/addons-training-evaaluation-report-evaluation-ysa into lp:~openobject-training/openobject-addons/training

 

Yogesh(Open ERP) has proposed merging lp:~openerp-dev/openobject-addons/addons-training-evaaluation-report-evaluation-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-evaaluation-report-evaluation-ysa/+merge/56932

training_evaluation :- change argument of resport_sxw.report_sxw object in report(pass osv object name insted of osv_memory object name as a argument in training.evaluation.organization.report). and improve wizard view.
-- 
https://code.launchpad.net/~openerp-dev/openobject-addons/addons-training-evaaluation-report-evaluation-ysa/+merge/56932
Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/addons-training-evaaluation-report-evaluation-ysa.
=== modified file 'training_evaluation/report/report_evaluation.py'
--- training_evaluation/report/report_evaluation.py	2011-04-07 11:11:57 +0000
+++ training_evaluation/report/report_evaluation.py	2011-04-08 13:31:12 +0000
@@ -196,7 +196,7 @@
         ]
 
 report_sxw.report_sxw('report.training.evaluation.organization.report',
-                      'training.evaluation.organization.report.wizard',
+                      'training.evaluation',
                       'addons/training_evaluation/report/report_evaluation_organization.rml',
                       parser=evaluation_organisation_report,
                       header=True)

=== modified file 'training_evaluation/report/report_evaluation_organization.rml'
--- training_evaluation/report/report_evaluation_organization.rml	2010-08-30 15:16:45 +0000
+++ training_evaluation/report/report_evaluation_organization.rml	2011-04-08 13:31:12 +0000
@@ -128,11 +128,11 @@
         <blockTable colWidths="100.0,380.0" style="Table2">
             <tr>
                 <td><para style="terp_tblheader_General">Organization</para></td>
-                <td><para style="terp_default_8">[[ ev.partner_id.name ]]</para></td>
+                <td><para style="terp_default_8">[[ data['partner_name'] ]]</para></td>
             </tr>
             <tr>
                 <td><para style="terp_tblheader_General">Number of Evaluations</para></td>
-                <td><para style="terp_default_8">[[ formatLang(get_categories(ev.id)['number_evaluations'], digits=0) ]]</para></td>
+                <td><para style="terp_default_8">[[ formatLang(get_categories(data['wizard_id'])['number_evaluations'], digits=0) ]]</para></td>
             </tr>
         </blockTable>
         <para style="Standard">
@@ -146,7 +146,7 @@
         </blockTable>
         <section>
             <blockTable colWidths="380.0,100.0" style="Table2">
-                <tr>[[ repeatIn(get_categories(ev.id)['categories'], 'category')]]
+                <tr>[[ repeatIn(get_categories(data['wizard_id'])['categories'], 'category')]
                     <td><para style="terp_tblheader_General">[[ (isinstance(category[0], bool) and category[0] == False) and translate('Total') or category[0].complete_name ]]</para></td>
                     <td><para style="terp_default_8">[[ formatLang(category[1]) ]]</para></td>
                 </tr>

=== modified file 'training_evaluation/wizard/wizard_organization_report.py'
--- training_evaluation/wizard/wizard_organization_report.py	2011-04-07 13:04:11 +0000
+++ training_evaluation/wizard/wizard_organization_report.py	2011-04-08 13:31:12 +0000
@@ -43,7 +43,7 @@
         if not ids:
             return {}
         wizard = self.browse(cr, uid, ids[0], context=context)
-        datas = {'ids': [ wizard.partner_id.id ]}
+        datas = {'ids': ids,'partner_name':wizard.partner_id.name, 'wizard_id': wizard.id}
         return {
             'type': 'ir.actions.report.xml',
             'report_name': 'training.evaluation.organization.report',

=== modified file 'training_evaluation/wizard/wizard_organization_report_view.xml'
--- training_evaluation/wizard/wizard_organization_report_view.xml	2011-03-21 10:41:55 +0000
+++ training_evaluation/wizard/wizard_organization_report_view.xml	2011-04-08 13:31:12 +0000
@@ -7,8 +7,14 @@
         <field name="type">form</field>
         <field name="arch" type="xml">
             <form string="Origanization Report" col="2">
-                <field name="partner_id"/>
-                <button name="do_print" type="object" string="Print" colspan="2" icon="gtk-print"/>
+                <field name="partner_id" required="True"/>
+                <newline />
+                <separator colspan="4" string=""/>
+                <group colspan="4">
+                    <label colspan="2"/>
+                    <button string="Cancel" special="cancel" colspan="1" type="object" icon="gtk-cancel"/>
+                    <button name="do_print" type="object" string="Print" colspan="1" icon="gtk-print"/>
+                </group>
             </form>
         </field>
     </record>


Follow ups