"date" is not updated from "expected_date" as long as stock_move is not done

Bug #1184199 reported by Etienne Hirt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Confirmed
Low
OpenERP R&D Addons Team 2

Bug Description

the stock_move object of the stock module describes in 6.0 6.1 7.0 the date field as:
"Move date: scheduled date until move is done, then date of actual move processing"

However, there is no code that updates the "date" when "expected_date" is changed as long as not processed

I propose to add the following to the write method:

if move.state != 'done' and vals.get('date_expected'):
            vals['date'] = vals.get('date_expected')

Tags: 6.0 6.1 7.0
Revision history for this message
Etienne Hirt (hirt) wrote :

Version 6.1 features an on_change on "date_expected" to update "date". But as date is not readonly it possible to set any date!

The attached patch based on 6.1-ocb-addons revision 6732 sets the "date" field to readonly in the views and updates it to the to the "date_expected" as long as not processed.

Revision history for this message
Etienne Hirt (hirt) wrote :

Ordering of the stock moves now better be done from "date" also. See the attached patch that further adds readonly to all "date" fields. Again based on based on 6.1-ocb-addons revision 6732 replaces the previous patch

Amit Parik (amit-parik)
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 2 (openerp-dev-addons2)
importance: Undecided → Low
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.