Merge lp:~unifield-team/unifield-wm/us-730 into lp:unifield-wm

Proposed by jftempo
Status: Merged
Merged at revision: 2691
Proposed branch: lp:~unifield-team/unifield-wm/us-730
Merge into: lp:unifield-wm
Diff against target: 21 lines (+11/-0)
1 file modified
product_nomenclature/product_nomenclature.py (+11/-0)
To merge this branch: bzr merge lp:~unifield-team/unifield-wm/us-730
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+278804@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'product_nomenclature/product_nomenclature.py'
--- product_nomenclature/product_nomenclature.py 2015-11-09 14:18:11 +0000
+++ product_nomenclature/product_nomenclature.py 2015-11-27 13:20:37 +0000
@@ -755,6 +755,17 @@
755 def get_sub_nomen(self, cr, uid, id, field):755 def get_sub_nomen(self, cr, uid, id, field):
756 return self.pool.get('product.nomenclature').get_sub_nomen(cr, uid, self, id, field)756 return self.pool.get('product.nomenclature').get_sub_nomen(cr, uid, self, id, field)
757757
758 def copy(self, cr, uid, old_id, new_vals=None, context=None):
759 res = super(product_product, self).copy(cr, uid, old_id, new_vals, context=context)
760 if new_vals.get('default_code', None) == 'XXX':
761 # Delete the translations linked to this new product
762 tr_obj = self.pool.get('ir.translation')
763 tr_ids = tr_obj.search(cr, uid, [('xml_id', '=', 'product_XXX')], context=context)
764 if tr_ids:
765 tr_obj.unlink(cr, uid, tr_ids, context=context)
766
767 return res
768
758 def create(self, cr, uid, vals, context=None):769 def create(self, cr, uid, vals, context=None):
759 '''770 '''
760 override to complete nomenclature_description771 override to complete nomenclature_description

Subscribers

People subscribed via source and target branches