[IMP]stock: improve code in separator in partial wizard
authorMayur Maheshwari (OpenERP) <mma@tinyerp.com>
Mon, 19 Mar 2012 06:10:57 +0000 (11:40 +0530)
committerMayur Maheshwari (OpenERP) <mma@tinyerp.com>
Mon, 19 Mar 2012 06:10:57 +0000 (11:40 +0530)
bzr revid: mma@tinyerp.com-20120319061057-xsrk64c4w9znuoww

addons/stock/wizard/stock_partial_picking.py

index 0a9f27f..2015cd3 100644 (file)
@@ -97,7 +97,8 @@ class stock_partial_picking(osv.osv_memory):
                     node.set('string', '_Deliver')
 
         res['arch'] = etree.tostring(doc)
-        res['arch'] = res['arch'].replace('<separator colspan="4" string="Products"/>', separator_extended)
+        if separator_extended:
+            res['arch'] = res['arch'].replace('<separator colspan="4" string="Products"/>', separator_extended)
         return res
 
     def default_get(self, cr, uid, fields, context=None):