Ravish(OpenERP) has proposed merging lp:~openerp-dev/openobject-addons/trunk-bug-1101146-rmu into lp:openobject-addons.
Requested reviews: OpenERP Core Team (openerp) Related bugs: Bug #1101146 in OpenERP Addons: "Wrong product description copied to invoice lines" https://bugs.launchpad.net/openobject-addons/+bug/1101146 For more details, see: https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1101146-rmu/+merge/144690 Hello, I have solved the problem of "Wrong product description copied to invoice lines" Thanks, -- https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1101146-rmu/+merge/144690 Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/trunk-bug-1101146-rmu.
=== modified file 'account/account_invoice.py' --- account/account_invoice.py 2013-01-05 23:29:19 +0000 +++ account/account_invoice.py 2013-01-24 12:28:29 +0000 @@ -1439,7 +1439,7 @@ context.update({'lang': part.lang}) result = {} res = self.pool.get('product.product').browse(cr, uid, product, context=context) - + result['name'] = res.partner_ref if type in ('out_invoice','out_refund'): a = res.property_account_income.id if not a: @@ -1454,20 +1454,20 @@ if type in ('out_invoice', 'out_refund'): taxes = res.taxes_id and res.taxes_id or (a and self.pool.get('account.account').browse(cr, uid, a, context=context).tax_ids or False) + if res.description_sale: + result['name'] += '\n'+res.description_sale else: taxes = res.supplier_taxes_id and res.supplier_taxes_id or (a and self.pool.get('account.account').browse(cr, uid, a, context=context).tax_ids or False) + if res.description_purchase: + result['name'] += '\n'+res.description_purchase tax_id = fpos_obj.map_tax(cr, uid, fpos, taxes) if type in ('in_invoice', 'in_refund'): result.update( {'price_unit': price_unit or res.standard_price,'invoice_line_tax_id': tax_id} ) else: result.update({'price_unit': res.list_price, 'invoice_line_tax_id': tax_id}) - result['name'] = res.partner_ref result['uos_id'] = uom_id or res.uom_id.id - if res.description: - result['name'] += '\n'+res.description - domain = {'uos_id':[('category_id','=',res.uom_id.category_id.id)]} res_final = {'value':result, 'domain':domain} === modified file 'product/product.py' --- product/product.py 2012-12-18 22:06:17 +0000 +++ product/product.py 2013-01-24 12:28:29 +0000 @@ -296,9 +296,14 @@ _columns = { 'name': fields.char('Name', size=128, required=True, translate=True, select=True), 'product_manager': fields.many2one('res.users','Product Manager'), - 'description': fields.text('Description',translate=True), - 'description_purchase': fields.text('Purchase Description',translate=True), - 'description_sale': fields.text('Sale Description',translate=True), + 'description': fields.text('Description',translate=True, + help="A precise description of the Product, used only for internal information purposes."), + 'description_purchase': fields.text('Purchase Description',translate=True, + help="A description of the Product that you want to communicate to your suppliers. " + "This description will be copied to every Purchase Order, Reception and Supplier Invoice/Refund."), + 'description_sale': fields.text('Sale Description',translate=True, + help="A description of the Product that you want to communicate to your customers. " + "This description will be copied to every Sale Order, Delivery Order and Customer Invoice/Refund"), 'type': fields.selection([('consu', 'Consumable'),('service','Service')], 'Product Type', required=True, help="Consumable are product where you don't manage stock, a service is a non-material product provided by a company or an individual."), 'produce_delay': fields.float('Manufacturing Lead Time', help="Average delay in days to produce this product. In the case of multi-level BOM, the manufacturing lead times of the components will be added."), 'rental': fields.boolean('Can be Rent'),
_______________________________________________ Mailing list: https://launchpad.net/~openerp-dev-gtk Post to : openerp-dev-gtk@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-dev-gtk More help : https://help.launchpad.net/ListHelp