Merge lp:~openerp-dev/openobject-addons/6.1-opw-580795-rha into lp:openobject-addons/6.1

Proposed by Rifakat Husen (OpenERP)
Status: Approved
Approved by: Naresh(OpenERP)
Approved revision: 7050
Proposed branch: lp:~openerp-dev/openobject-addons/6.1-opw-580795-rha
Merge into: lp:openobject-addons/6.1
Diff against target: 20 lines (+10/-0)
1 file modified
stock/stock.py (+10/-0)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/6.1-opw-580795-rha
Reviewer Review Type Date Requested Status
Numérigraphe (community) Approve
Naresh(OpenERP) Pending
Review via email: mp+131316@code.launchpad.net

Description of the change

Hello,

Duplication of Production Lot also duplicates its Creation Date, Stock Moves
and Revisions.

Creation Date should be current date, Stock Moves and Revisions should be reset
when we duplicate it, those information should not be copied.

Thanks for your review,
Rifakat Haradwala

To post a comment you must log in.
7044. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

7045. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

7046. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

7047. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

7048. By Xavier ALT

[MERGE] OPW 579331: base_vat: button check_vat should not return 'None' uppon success - this will cause error for clients using XML-RPC

Revision history for this message
Numérigraphe (numerigraphe) wrote :

Just nitpicking: you could replace:
    if default is None: default = {}
    default = default.copy()
by:
    if default is None:
        default = {}
    else:
        default.copy()

Lionel.

review: Approve
7049. By Rifakat Husen (OpenERP)

[IMP] improved fix

7050. By Rifakat Husen (OpenERP)

[fix] default.copy()

Revision history for this message
Naresh(OpenERP) (nch-openerp) wrote :

Hello,

This bug was qualified as Confirmed on Trunk (means still existing and reproducible). A Merge Proposal for trunk was created to fix it. Here is the link to follow the MP on Launchpad https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-opw-580795-port-mma/+merge/136355 and be informed once it's been merged in trunk: ... If this Merge Proposal could not be merged in v6.1 at the release of v7.0, it will be closed.

Thanks,
Naresh Soni

Unmerged revisions

7050. By Rifakat Husen (OpenERP)

[fix] default.copy()

7049. By Rifakat Husen (OpenERP)

[IMP] improved fix

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'stock/stock.py'
--- stock/stock.py 2012-10-05 07:47:57 +0000
+++ stock/stock.py 2012-10-29 10:16:21 +0000
@@ -1473,6 +1473,16 @@
1473 """1473 """
1474 value=self.pool.get('action.traceability').action_traceability(cr,uid,ids,context)1474 value=self.pool.get('action.traceability').action_traceability(cr,uid,ids,context)
1475 return value1475 return value
1476
1477 def copy(self, cr, uid, id, default=None, context=None):
1478 if context is None: context = {}
1479 if default is None:
1480 default = {}
1481 else:
1482 default = default.copy()
1483 default.update(date=time.strftime('%Y-%m-%d %H:%M:%S'), revisions=[], move_ids=[])
1484 return super(stock_production_lot, self).copy(cr, uid, id, default=default, context=context)
1485
1476stock_production_lot()1486stock_production_lot()
14771487
1478class stock_production_lot_revision(osv.osv):1488class stock_production_lot_revision(osv.osv):