Merge lp:~openerp-dev/openobject-addons/trunk-bug-1185696-Chandni into lp:openobject-addons

Proposed by Chandni Machchhar(OpenERP)
Status: Needs review
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-bug-1185696-Chandni
Merge into: lp:openobject-addons
Diff against target: 16 lines (+6/-0)
1 file modified
point_of_sale/res_partner.py (+6/-0)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-bug-1185696-Chandni
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+167909@code.launchpad.net

Description of the change

Hello,

  I have solve the issue of POS: two partners can have same EAN13.

Thanks,
Chandni.

To post a comment you must log in.

Unmerged revisions

8755. By Chandni Machchhar(OpenERP)

[FIX] POS: two partners can have same EAN13.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'point_of_sale/res_partner.py'
2--- point_of_sale/res_partner.py 2013-05-14 10:31:13 +0000
3+++ point_of_sale/res_partner.py 2013-06-07 08:40:36 +0000
4@@ -12,6 +12,12 @@
5 'ean13' : fields.char('EAN13', size=13, help="BarCode"),
6 }
7
8+ _sql_constraints = [
9+ ('ean13_uniq',
10+ 'unique (ean13)',
11+ 'The BarCode, EAN13 of the POS must be unique !')
12+ ]
13+
14 def _check_ean(self, cr, uid, ids, context=None):
15 return all(
16 openerp.addons.product.product.check_ean(user.ean13) == True

Subscribers

People subscribed via source and target branches

to all changes: