← Back to team overview

savoirfairelinux-openerp team mailing list archive

[Merge] lp:~xclude/e-commerce-addons/fix1288719 into lp:e-commerce-addons/oerp6.1-stable

 

Daniel Stenlöv (XCLUDE) has proposed merging lp:~xclude/e-commerce-addons/fix1288719 into lp:e-commerce-addons/oerp6.1-stable.

Requested reviews:
  extra-addons-commiter (extra-addons-commiter)
Related bugs:
  Bug #1288719 in e-commerce-addons: "base_sale_multichannel: Fault select"
  https://bugs.launchpad.net/e-commerce-addons/+bug/1288719

For more details, see:
https://code.launchpad.net/~xclude/e-commerce-addons/fix1288719/+merge/209667

Fix bug lp:1288719, Wrong SQL-statement if product_m2mcategories is installed.
-- 
https://code.launchpad.net/~xclude/e-commerce-addons/fix1288719/+merge/209667
Your team extra-addons-commiter is requested to review the proposed merge of lp:~xclude/e-commerce-addons/fix1288719 into lp:e-commerce-addons/oerp6.1-stable.
=== modified file 'base_sale_multichannels/sale.py'
--- base_sale_multichannels/sale.py	2013-11-09 16:30:45 +0000
+++ base_sale_multichannels/sale.py	2014-03-06 13:00:42 +0000
@@ -106,8 +106,7 @@
 
             # If product_m2mcategories module is installed search in main category
             # and extra categories. If not, only in main category
-            cr.execute('select * from ir_module_module where name=%s and state=%s',
-                                                            ('product_m2mcategories','installed'))
+            cr.execute('select * from ir_module_module where name='product_m2mcategories' and state='installed')
             if cr.fetchone():
                 res[shop['id']] = self.pool.get("product.product").search(cr, uid, ['|',
                         ('categ_id', 'in', all_categories),('categ_ids', 'in', all_categories)])