← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 727162] Re: Problem with the pricelist of type "Partner section of the product form"

 

Jay,

I am using  the default pricelists for sale and purchase: ('Public Pricelist' and 'Default Purchase Pricelist')  and the 
default uom categories 

Step to produce this bug:
1. create a product: name=distance, sale price=1,cost price=1, default unit of measure= m
2. create a new order : customer: Openerp Sa
3. create a new order line: product:distance, uom=m, unit price=1 ( until here is everything oK)
4.Change the uom to km, the unit price is 1000000 and must be 1000

The same problem you have creating a purchase order.

in https://bugs.launchpad.net/openobject-addons/+bug/738146 i had
published a patch that fix both of this problems.

Thanks

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/727162

Title:
  Problem with the pricelist of type "Partner section of the product
  form"

Status in OpenERP Modules (addons):
  Fix Released

Bug description:
  Steps to reproduce:

  1) Set a public price-list (sale price-list) based on "Partner section of the product form"
  2) create a new product (procure method-> make to order -> buy) 
  3) define the supplier
  4) create a sale order and select the product in sale order line.

  I get the following traceback.

  
  [2011-03-01 18:33:20,124][db_trunk2] ERROR:web-services:Uncaught exception
  Traceback (most recent call last):
    File "/home/tiny/workspace/openobject-server/openerp/osv/osv.py", line 122, in wrapper
      return f(self, dbname, *args, **kwargs)
    File "/home/tiny/workspace/openobject-server/openerp/osv/osv.py", line 176, in execute
      res = self.execute_cr(cr, uid, obj, method, *args, **kw)
    File "/home/tiny/workspace/openobject-server/openerp/osv/osv.py", line 167, in execute_cr
      return getattr(object, method)(cr, uid, *args, **kw)
    File "/home/tiny/workspace/openobject-addons/sale/sale.py", line 1137, in product_id_change
      'date': date_order,
    File "/home/tiny/workspace/openobject-addons/product/pricelist.py", line 298, in price_get
      res_multi = self.price_get_multi(cr, uid, pricelist_ids=ids, products_by_qty_by_partner=[(prod_id, qty, partner)], context=context)
    File "/home/tiny/workspace/openobject-addons/product/pricelist.py", line 247, in price_get_multi
      product_default_uom = product_obj.read(cr, uid, [tmpl_id], ['uom_id'])[0]['uom_id'][0]
  IndexError: list index out of range

  Thanks.



References