Raphael Collet (OpenERP) has proposed merging 
lp:~openerp-dev/openobject-addons/trunk-addons7 into lp:openobject-addons.

Requested reviews:
  OpenERP Core Team (openerp)

For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-addons7/+merge/123754

Issues on mrp application (and dependent applications)
-- 
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-addons7/+merge/123754
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openobject-addons/trunk-addons7.
=== modified file 'crm/crm.py'
--- crm/crm.py	2012-08-14 10:51:14 +0000
+++ crm/crm.py	2012-09-11 14:21:43 +0000
@@ -75,7 +75,7 @@
         'requirements': fields.text('Requirements'),
         'section_ids':fields.many2many('crm.case.section', 'section_stage_rel', 'stage_id', 'section_id', string='Sections',
                         help="Link between stages and sales teams. When set, this limitate the current stage to the selected sales teams."),
-        'state': fields.selection(AVAILABLE_STATES, 'State', required=True, help="The related state for the stage. The state of your document will automatically change regarding the selected stage. For example, if a stage is related to the state 'Close', when your document reaches this stage, it will be automatically have the 'closed' state."),
+        'state': fields.selection(AVAILABLE_STATES, 'State', required=True, help="The related status for the stage. The state of your document will automatically change regarding the selected stage. For example, if a stage is related to the state 'Close', when your document reaches this stage, it will be automatically have the 'closed' state."),
         'case_default': fields.boolean('Common to All Teams',
                         help="If you check this field, this stage will be proposed by default on each sales team. It will not assign this stage to existing teams."),
         'fold': fields.boolean('Hide in Views when Empty',

=== modified file 'crm/crm_view.xml'
--- crm/crm_view.xml	2012-08-14 12:30:50 +0000
+++ crm/crm_view.xml	2012-09-11 14:21:43 +0000
@@ -183,7 +183,7 @@
                 <form string="Stage" version="7.0">
                     <group col="4">
                         <field name="name"/>
-                        <field name="state" string="Related State" />
+                        <field name="state" string="Related Status" />
                         <field name="probability"/>
                         <field name="type"/>
                         <field name="on_change"/>

=== modified file 'mrp/i18n/mrp.pot'
--- mrp/i18n/mrp.pot	2012-08-08 14:46:13 +0000
+++ mrp/i18n/mrp.pot	2012-09-11 14:21:43 +0000
@@ -197,11 +197,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,indice:0
-msgid "Revision"
-msgstr ""
-
-#. module: mrp
 #: model:ir.actions.act_window,help:mrp.product_form_config_action
 msgid "Create a product form for everything you buy or sell. Specify a supplier if the product can be purchased."
 msgstr ""
@@ -436,11 +431,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,date:0
-msgid "Modification Date"
-msgstr ""
-
-#. module: mrp
 #: help:mrp.workcenter,costs_cycle_account_id:0
 #: help:mrp.workcenter,costs_hour_account_id:0
 msgid "Complete this only if you want automatic analytic accounting entries on production orders."
@@ -494,11 +484,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,author_id:0
-msgid "Author"
-msgstr ""
-
-#. module: mrp
 #: field:report.mrp.inout,value:0
 msgid "Stock value"
 msgstr ""
@@ -762,11 +747,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,name:0
-msgid "Modification name"
-msgstr ""
-
-#. module: mrp
 #: view:mrp.bom:0
 #: view:mrp.production:0
 msgid "Date"
@@ -1295,11 +1275,6 @@
 msgstr ""
 
 #. module: mrp
-#: model:ir.model,name:mrp.model_mrp_bom_revision
-msgid "Bill of Material Revision"
-msgstr ""
-
-#. module: mrp
 #: help:mrp.production,origin:0
 msgid "Reference of the document that generated this production order request."
 msgstr ""
@@ -1773,12 +1748,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,bom_id:0
-#: field:procurement.order,bom_id:0
-msgid "BoM"
-msgstr ""
-
-#. module: mrp
 #: model:ir.model,name:mrp.model_report_mrp_inout
 #: view:report.mrp.inout:0
 msgid "Stock value variation"
@@ -1796,17 +1765,6 @@
 msgstr ""
 
 #. module: mrp
-#: field:mrp.bom.revision,last_indice:0
-msgid "last indice"
-msgstr ""
-
-#. module: mrp
-#: field:mrp.bom,revision_ids:0
-#: view:mrp.bom.revision:0
-msgid "BoM Revisions"
-msgstr ""
-
-#. module: mrp
 #: field:report.mrp.inout,date:0
 #: field:report.workcenter.load,name:0
 msgid "Week"
@@ -1988,19 +1946,6 @@
 msgstr ""
 
 #. module: mrp
-#: view:mrp.bom.revision:0
-#: field:mrp.bom.revision,description:0
-#: view:mrp.property:0
-#: view:mrp.property.group:0
-#: field:mrp.routing,note:0
-#: view:mrp.routing.workcenter:0
-#: field:mrp.routing.workcenter,note:0
-#: view:mrp.workcenter:0
-#: field:mrp.workcenter,note:0
-msgid "Description"
-msgstr ""
-
-#. module: mrp
 #: view:board.board:0
 msgid "Manufacturing board"
 msgstr ""

=== modified file 'mrp/mrp.py'
--- mrp/mrp.py	2012-08-22 15:31:45 +0000
+++ mrp/mrp.py	2012-09-11 14:21:43 +0000
@@ -214,7 +214,6 @@
         'bom_id': fields.many2one('mrp.bom', 'Parent BoM', ondelete='cascade', select=True),
         'routing_id': fields.many2one('mrp.routing', 'Routing', help="The list of operations (list of work centers) to produce the finished product. The routing is mainly used to compute work center costs during operations and to plan future loads on work centers based on production planning."),
         'property_ids': fields.many2many('mrp.property', 'mrp_bom_property_rel', 'bom_id','property_id', 'Properties'),
-        'revision_ids': fields.one2many('mrp.bom.revision', 'bom_id', 'BoM Revisions'),
         'child_complete_ids': fields.function(_child_compute, relation='mrp.bom', string="BoM Hierarchy", type='many2many'),
         'company_id': fields.many2one('res.company','Company',required=True),
     }
@@ -374,26 +373,6 @@
 
 mrp_bom()
 
-class mrp_bom_revision(osv.osv):
-    _name = 'mrp.bom.revision'
-    _description = 'Bill of Material Revision'
-    _columns = {
-        'name': fields.char('Modification name', size=64, required=True),
-        'description': fields.text('Description'),
-        'date': fields.date('Modification Date'),
-        'indice': fields.char('Revision', size=16),
-        'last_indice': fields.char('last indice', size=64),
-        'author_id': fields.many2one('res.users', 'Author'),
-        'bom_id': fields.many2one('mrp.bom', 'BoM', select=True),
-    }
-
-    _defaults = {
-        'author_id': lambda x, y, z, c: z,
-        'date': fields.date.context_today,
-    }
-
-mrp_bom_revision()
-
 def rounding(f, r):
     import math
     if not r:
@@ -457,8 +436,8 @@
         return dest_location_id.id
 
     _columns = {
-        'name': fields.char('Reference', size=64, required=True),
-        'origin': fields.char('Source Document', size=64, help="Reference of the document that generated this production order request."),
+        'name': fields.char('Reference', size=64, required=True, states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
+        'origin': fields.char('Source Document', size=64, help="Reference of the document that generated this production order request.", states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
         'priority': fields.selection([('0','Not urgent'),('1','Normal'),('2','Urgent'),('3','Very Urgent')], 'Priority', select=True),
 
         'product_id': fields.many2one('product.product', 'Product', required=True, readonly=True, states={'draft':[('readonly',False)]}),
@@ -473,9 +452,9 @@
             readonly=True, states={'draft':[('readonly',False)]}, help="Location where the system will stock the finished products."),
 
         'date_planned_end': fields.function(_production_date_end, type='date', string='Scheduled End Date'),
-        'date_planned_date': fields.function(_production_date, type='date', string='Scheduled Date'),
-        'date_planned': fields.datetime('Scheduled Date', required=True, select=1),
-        'date_start': fields.datetime('Start Date', select=True),
+        'date_planned_date': fields.function(_production_date, type='date', string='Scheduled Date', states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
+        'date_planned': fields.datetime('Scheduled Date', required=True, select=1, states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'confirmed':[('readonly',True)],'done':[('readonly',True)]}),
+        'date_start': fields.datetime('Start Date', select=True, states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
         'date_finished': fields.datetime('End Date', select=True),
 
         'bom_id': fields.many2one('mrp.bom', 'Bill of Material', domain=[('bom_id','=',False)], readonly=True, states={'draft':[('readonly',False)]}),
@@ -483,12 +462,12 @@
         'picking_id': fields.many2one('stock.picking', 'Picking List', readonly=True, ondelete="restrict",
             help="This is the Internal Picking List that brings the finished product to the production plan"),
         'move_prod_id': fields.many2one('stock.move', 'Product Move', readonly=True),
-        'move_lines': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Products to Consume', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)]}),
-        'move_lines2': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Consumed Products', domain=[('state','in', ('done', 'cancel'))]),
-        'move_created_ids': fields.one2many('stock.move', 'production_id', 'Products to Produce', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)]}),
+        'move_lines': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Products to Consume', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)],'in_production':[('readonly',True)],'ready':[('readonly',True)]}),
+        'move_lines2': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Consumed Products', domain=[('state','in', ('done', 'cancel'))], states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
+        'move_created_ids': fields.one2many('stock.move', 'production_id', 'Products to Produce', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)],'in_production':[('readonly',True)],'ready':[('readonly',True)]}),
         'move_created_ids2': fields.one2many('stock.move', 'production_id', 'Produced Products', domain=[('state','in', ('done', 'cancel'))]),
-        'product_lines': fields.one2many('mrp.production.product.line', 'production_id', 'Scheduled goods'),
-        'workcenter_lines': fields.one2many('mrp.production.workcenter.line', 'production_id', 'Work Centers Utilisation'),
+        'product_lines': fields.one2many('mrp.production.product.line', 'production_id', 'Scheduled goods',states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
+        'workcenter_lines': fields.one2many('mrp.production.workcenter.line', 'production_id', 'Work Centers Utilisation', states={'in_production':[('readonly',True)],'ready':[('readonly',True)],'done':[('readonly',True)]}),
         'state': fields.selection([('draft','New'),('cancel','Cancelled'),('picking_except', 'Picking Exception'),('confirmed','Waiting Goods'),('ready','Ready to Produce'),('in_production','Production Started'),('done','Done')],'Status', readonly=True,
                                     help='When the production order is created the state is set to \'Draft\'.\n If the order is confirmed the state is set to \'Waiting Goods\'.\n If any exceptions are there, the state is set to \'Picking Exception\'.\
                                     \nIf the stock is available then the state is set to \'Ready to Produce\'.\n When the production gets started then the state is set to \'In Production\'.\n When the production is over, the state is set to \'Done\'.'),

=== modified file 'mrp/mrp_view.xml'
--- mrp/mrp_view.xml	2012-09-04 07:51:42 +0000
+++ mrp/mrp_view.xml	2012-09-11 14:21:43 +0000
@@ -345,35 +345,35 @@
             <field name="model">mrp.bom</field>
             <field name="arch" type="xml">
                 <form string="Bill of Material" version="7.0">
-                    <label for="product_id" string="Product and Quantity" class="oe_edit_only"/>
-                    <h1>
-                        <field name="product_id" on_change="onchange_product_id(product_id, name, context)" class="oe_inline"/>:
-                        <field name="product_qty" class="oe_inline"/>
-                        <field name="product_uom" class="oe_inline" groups="product.group_uom"/>
-                    </h1>
-                    <div groups="mrp.group_mrp_routings">
-                        <label for="routing_id" class="oe_edit_only"/>
-                        <h2><field name="routing_id" class="oe_inline"/></h2>
-                    </div>
                     <group>
                         <group>
-                            <field name="name"/>
+                            <field name="product_id" on_change="onchange_product_id(product_id, name, context)" class="oe_inline"/>
+                            <label for="product_qty" string="Quantity"/>
+                            <div>
+                                <field name="product_qty" class="oe_inline"/>
+                                <field name="product_uom" class="oe_inline" groups="product.group_uom"/>
+                            </div>
+                            <label for="product_uos_qty" groups="product.group_uos"/>
+                            <div groups="product.group_uos" >
+                                <field name="product_uos_qty"
+                                    class="oe_inline"/>
+                                <label string="-" attrs="{'invisible':[('product_uos','=',False)]}" class="oe_inline"/>
+                                <field name="product_uos" class="oe_inline"/>
+                            </div>
+                            <div groups="mrp.group_mrp_routings">
+                                <label for="routing_id" class="oe_edit_only"/>
+                                <h2><field name="routing_id" class="oe_inline"/></h2>
+                            </div>
+                        </group>
+                        <group>
+                            <field name="name" class="oe_inline"/>
                             <field name="code" string="Reference"/>
-                        </group>
-                        <group>
                             <field name="type"/>
                             <p colspan="2" class="oe_grey" attrs="{'invisible': [('type','=','normal')]}">
                                 When processing a sale order for this product, the delivery order
                                 will contain the raw materials, instead of the finished product.
                             </p>
                             <field name="company_id" groups="base.group_multi_company" widget="selection"/>
-                            <label for="product_uos_qty" groups="product.group_uos"/>
-                            <div groups="product.group_uos" >
-                                <field name="product_uos_qty"
-                                    class="oe_inline"/>
-                                <label string="-" attrs="{'invisible':[('product_uos','=',False)]}" class="oe_inline"/>
-                                <field name="product_uos" class="oe_inline"/>
-                            </div>
                         </group>
                     </group>
                     <notebook>
@@ -389,9 +389,6 @@
                                 </tree>
                             </field>
                         </page>
-                        <page string="Revisions" attrs="{'invisible': [('bom_id','!=',False)]}">
-                            <field name="revision_ids"/>
-                        </page>
                         <page string="Properties" groups="product.group_mrp_properties">
                             <group>
                                 <group>
@@ -411,6 +408,10 @@
                             <field name="property_ids" widget="many2many_tags"/>
                         </page>
                     </notebook>
+                    <div class="oe_chatter">
+                         <field name="message_ids" colspan="4" widget="mail_thread" nolabel="1"/>
+                         <field name="message_follower_ids" widget="mail_followers"/>
+                    </div>
                 </form>
             </field>
         </record>
@@ -543,35 +544,6 @@
             <field eval="'ir.actions.act_window,'+str(action2)" name="value"/>
         </record>
 
-        <record id="mrp_bom_revision_tree" model="ir.ui.view">
-            <field name="name">mrp.bom.revision</field>
-            <field name="model">mrp.bom.revision</field>
-            <field name="arch" type="xml">
-                <tree string="BoM Revisions">
-                    <field name="indice"/>
-                    <field name="author_id"/>
-                    <field name="date"/>
-                    <field colspan="4" name="name"/>
-                </tree>
-            </field>
-        </record>
-        <record id="mrp_bom_revision_form" model="ir.ui.view">
-            <field name="name">mrp.bom.revision</field>
-            <field name="model">mrp.bom.revision</field>
-            <field name="arch" type="xml">
-                <form string="BoM Revisions" version="7.0">
-                    <group col="4">
-                        <field name="name"/>
-                        <field name="indice"/>
-                        <field name="date"/>
-                        <field name="author_id" readonly="1"/>
-                    </group>
-                    <separator string="Description"/>
-                    <field name="description"/>
-                </form>
-            </field>
-        </record>
-
         <!--
         Production Management
         -->
@@ -653,7 +625,7 @@
                     </div>
                     <group>
                         <group>
-                            <field name="product_id" on_change="product_id_change(product_id)" domain="[('bom_ids','&lt;&gt;',False),('bom_ids.bom_id','=',False)]" class="oe_inline"/>
+                            <field name="product_id" on_change="product_id_change(product_id)" domain="[('bom_ids','&lt;&gt;',False),('bom_ids.bom_id','=',False)]" class="oe_inline" context='{"default_supply_method":"produce", "default_type": "product"}'/>
                             <label for="product_qty"/>
                             <div>
                                 <field name="product_qty" class="oe_inline"/>
@@ -661,7 +633,7 @@
                                 <button type="action"
                                     icon="terp-accessories-archiver+"
                                     name="%(mrp.action_change_production_qty)d"
-                                    string="(Update)" states="ready,confirmed" class="oe_edit_only oe_link"/>
+                                    string="(Update)" states="confirmed" class="oe_edit_only oe_link"/>
                             </div>
                             <label for="product_uos_qty" groups="product.group_uos"/>
                             <div groups="product.group_uos">
@@ -687,11 +659,11 @@
                             <group>
                                 <group string="Products to Consume">
                                     <field name="move_lines" domain="[('state','&lt;&gt;', ('done', 'cancel'))]" nolabel="1">
-                                        <tree colors="blue:state == 'draft';black:state in ('picking_except','confirmed','ready','in_production');gray:state in ('cancel','done') " string="Products to Consume">
+                                        <tree colors="blue:state == 'draft';black:state in ('picking_except','confirmed','ready');gray:state in ('cancel','done') " string="Products to Consume">
                                             <field name="product_id"/>
                                             <field name="product_qty"  string="Quantity"/>
                                             <field name="product_uom" string="Unit of Measure" groups="product.group_uom"/>
-                                            <field name="location_id"  string="Source Loc." groups="stock.group_locations"/>
+                                            <field name="prodlot_id" groups="stock.group_production_lot"/>
                                             <field name="state" invisible="1"/>
                                             <button name="%(stock.move_consume)d"
                                                 string="Consume Products" type="action"
@@ -701,7 +673,8 @@
                                                    name="%(stock.track_line)d"
                                                    string="Split in Serial Numbers"
                                                    type="action" icon="gtk-justify-fill"
-                                                   states="draft,waiting,confirmed,assigned"/>
+                                                   states="draft,waiting,confirmed,assigned" 
+                                                   groups="stock.group_production_lot"/>
                                             <button name="%(stock.move_scrap)d"
                                                 string="Scrap Products" type="action"
                                                 icon="gtk-convert" context="{'scrap': True}"
@@ -715,7 +688,7 @@
                                            <field name="product_id" readonly="1"/>
                                            <field name="product_qty" readonly="1"/>
                                            <field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
-                                           <field name="prodlot_id" context="{'product_id': product_id}"/>
+                                           <field name="prodlot_id" context="{'product_id': product_id}" groups="stock.group_production_lot"/>
                                            <field name="state" invisible="1"/>
                                            <field name="scrapped" invisible="1"/>
                                            <button
@@ -755,7 +728,7 @@
                                             <field name="product_qty" readonly="1"/>
                                             <field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
                                             <field name="location_dest_id"  readonly="1" string="Destination Loc." widget="selection" groups="stock.group_locations"/>
-                                            <field name="prodlot_id" context="{'product_id': product_id}"/>
+                                            <field name="prodlot_id" context="{'product_id': product_id}" groups="stock.group_production_lot"/>
                                             <field name="scrapped" invisible="1"/>
                                             <field name="state" invisible="1"/>
                                             <button name="%(stock.track_line)d"

=== modified file 'mrp/res_config.py'
--- mrp/res_config.py	2012-08-01 15:47:01 +0000
+++ mrp/res_config.py	2012-09-11 14:21:43 +0000
@@ -65,7 +65,7 @@
             help="""Routings allow you to create and manage the manufacturing operations that should be followed
                 within your work centers in order to produce a product. They are attached to bills of materials
                 that will define the required raw materials."""),
-        'group_mrp_properties': fields.boolean("allow several bill of materials per products",
+        'group_mrp_properties': fields.boolean("allow several bill of materials per products using properties",
             implied_group='product.group_mrp_properties',
             help="""The selection of the right Bill of Material to use will depend on the  properties specified on the sale order and the Bill of Material."""),
         'module_product_manufacturer': fields.boolean("define manufacturers on products ",

=== modified file 'mrp/res_config_view.xml'
--- mrp/res_config_view.xml	2012-08-09 06:05:16 +0000
+++ mrp/res_config_view.xml	2012-09-11 14:21:43 +0000
@@ -12,6 +12,9 @@
             <field name="type">automatic</field>
             <field name="sequence">100</field>
         </record>
+         <record id="purchase.todo_open_purchase_menu" model="ir.actions.todo">
+                <field name="state">done</field>
+        </record>
     </data>
     <data>
         <record id="view_mrp_config" model="ir.ui.view">

=== modified file 'mrp/security/ir.model.access.csv'
--- mrp/security/ir.model.access.csv	2012-06-21 05:16:16 +0000
+++ mrp/security/ir.model.access.csv	2012-09-11 14:21:43 +0000
@@ -3,7 +3,6 @@
 access_mrp_routing,mrp.routing,model_mrp_routing,mrp.group_mrp_user,1,0,0,0
 access_mrp_routing_workcenter,mrp.routing.workcenter,model_mrp_routing_workcenter,mrp.group_mrp_user,1,0,0,0
 access_mrp_bom,mrp.bom,model_mrp_bom,group_mrp_user,1,0,0,0
-access_mrp_bom_revision,mrp.bom.revision,model_mrp_bom_revision,group_mrp_user,1,0,0,0
 access_mrp_production,mrp.production user,model_mrp_production,mrp.group_mrp_user,1,1,1,1
 access_mrp_production_salesman,mrp.production salesman,model_mrp_production,base.group_sale_salesman,1,1,1,0
 access_mrp_production_product_line_salesman,mrp.production.product.line salesman,model_mrp_production_product_line,base.group_sale_salesman,1,0,1,0
@@ -16,7 +15,6 @@
 access_mrp_routing_manager,mrp.routing.manager,model_mrp_routing,mrp.group_mrp_manager,1,1,1,1
 access_mrp_routing_workcenter_manager,mrp.routing.workcenter.manager,model_mrp_routing_workcenter,mrp.group_mrp_manager,1,1,1,1
 access_mrp_bom_manager,mrp.bom.manager,model_mrp_bom,mrp.group_mrp_manager,1,1,1,1
-access_mrp_bom_revision_manager,mrp.bom.revision.manager,model_mrp_bom_revision,mrp.group_mrp_manager,1,1,1,1
 access_stock_location_mrp_worker,stock.location mrp_worker,stock.model_stock_location,mrp.group_mrp_user,1,0,0,0
 access_stock_move_mrp_worker,stock.move mrp_worker,stock.model_stock_move,mrp.group_mrp_user,1,1,1,0
 access_stock_picking_mrp_worker,stock.picking mrp_worker,stock.model_stock_picking,mrp.group_mrp_user,1,1,1,1
@@ -33,9 +31,9 @@
 access_report_mrp_inout,report.mrp.inout,model_report_mrp_inout,mrp.group_mrp_manager,1,1,1,1
 access_ir_property_manager,ir.property manager,base.model_ir_property,mrp.group_mrp_manager,1,1,1,1
 access_account_sequence_fiscalyear,account.sequence.fiscalyear,account.model_account_sequence_fiscalyear,mrp.group_mrp_user,1,1,1,1
-access_product_product_user,product.product user,product.model_product_product,mrp.group_mrp_user,1,0,0,0
-access_product_template_user,product.template user,product.model_product_template,mrp.group_mrp_user,1,0,0,0
-access_product_uom_user,product.uom user,product.model_product_uom,mrp.group_mrp_user,1,0,0,0
+access_product_product_user,product.product user,product.model_product_product,mrp.group_mrp_user,1,1,1,0
+access_product_template_user,product.template user,product.model_product_template,mrp.group_mrp_user,1,1,1,0
+access_product_uom_user,product.uom user,product.model_product_uom,mrp.group_mrp_user,1,1,1,0
 access_product_supplierinfo_user,product.supplierinfo user,product.model_product_supplierinfo,mrp.group_mrp_user,1,1,1,1
 access_stock_tracking,stock.tracking,stock.model_stock_tracking,mrp.group_mrp_user,1,1,1,0
 access_res_partner,res.partner,base.model_res_partner,mrp.group_mrp_user,1,0,0,0

=== modified file 'mrp/wizard/change_production_qty.py'
--- mrp/wizard/change_production_qty.py	2012-08-06 17:08:41 +0000
+++ mrp/wizard/change_production_qty.py	2012-09-11 14:21:43 +0000
@@ -68,12 +68,12 @@
         assert record_id, _('Active Id not found')
         prod_obj = self.pool.get('mrp.production')
         bom_obj = self.pool.get('mrp.bom')
+        move_lines_obj = self.pool.get('stock.move')
         for wiz_qty in self.browse(cr, uid, ids, context=context):
             prod = prod_obj.browse(cr, uid, record_id, context=context)
             prod_obj.write(cr, uid, [prod.id], {'product_qty': wiz_qty.product_qty})
             prod_obj.action_compute(cr, uid, [prod.id])
 
-            move_lines_obj = self.pool.get('stock.move')
             for move in prod.move_lines:
                 bom_point = prod.bom_id
                 bom_id = prod.bom_id.id
@@ -89,11 +89,17 @@
 
                 factor = prod.product_qty * prod.product_uom.factor / bom_point.product_uom.factor
                 res = bom_obj._bom_explode(cr, uid, bom_point, factor / bom_point.product_qty, [])
+                pick_move = {}
+                for move_ln in prod.picking_id.move_lines:
+                    pick_move.update({move_ln.product_id.id: move_ln.id})
                 for r in res[0]:
                     if r['product_id'] == move.product_id.id:
                         move_lines_obj.write(cr, uid, [move.id], {'product_qty' :  r['product_qty']})
+                    if r['product_id'] in pick_move:
+                        move_lines_obj.write(cr, uid, [pick_move[r['product_id']]], {'product_qty' :  r['product_qty']})
+            if prod.move_prod_id:
+                move_lines_obj.write(cr, uid, [prod.move_prod_id.id], {'product_qty' :  wiz_qty.product_qty})
             self._update_product_to_produce(cr, uid, prod, wiz_qty.product_qty, context=context)
-
         return {}
 
 change_production_qty()

=== modified file 'project/project.py'
--- project/project.py	2012-09-06 16:18:12 +0000
+++ project/project.py	2012-09-11 14:21:43 +0000
@@ -42,7 +42,7 @@
                         help="If you check this field, this stage will be proposed by default on each new project. It will not assign this stage to existing projects."),
         'project_ids': fields.many2many('project.project', 'project_task_type_rel', 'type_id', 'project_id', 'Projects'),
         'state': fields.selection(_TASK_STATE, 'State', required=True,
-                        help="The related state for the stage. The state of your document will automatically change regarding the selected stage. Example, a stage is related to the state 'Close', when your document reach this stage, it will be automatically closed."),
+                        help="The related status for the stage. The state of your document will automatically change regarding the selected stage. Example, a stage is related to the state 'Close', when your document reach this stage, it will be automatically closed."),
         'fold': fields.boolean('Hide in views if empty',
                         help="This stage is not visible, for example in status bar or kanban view, when there are no records in that stage to display."),
     }
@@ -727,7 +727,7 @@
                       When the case is over, the state is set to \'Done\'.\
                       If the case needs to be reviewed then the state is \
                       set to \'Pending\'.'),
-        'categ_ids': fields.many2many('project.category', string='Categories'),
+        'categ_ids': fields.many2many('project.category', string='Tags'),
         'kanban_state': fields.selection([('normal', 'Normal'),('blocked', 'Blocked'),('done', 'Ready To Pull')], 'Kanban State',
                                          help="A task's kanban state indicates special situations affecting it:\n"
                                               " * Normal is the default situation\n"

=== modified file 'project/project_view.xml'
--- project/project_view.xml	2012-09-10 20:14:08 +0000
+++ project/project_view.xml	2012-09-11 14:21:43 +0000
@@ -779,7 +779,7 @@
                             <field name="case_default"/>
                         </group>
                         <group>
-                            <field name="state" string="Related State"/>
+                            <field name="state" string="Related Status"/>
                             <field name="sequence"/>
                             <field name="fold"/>
                         </group>

=== modified file 'purchase/board_purchase_view.xml'
--- purchase/board_purchase_view.xml	2012-09-10 09:31:52 +0000
+++ purchase/board_purchase_view.xml	2012-09-11 14:21:43 +0000
@@ -85,7 +85,8 @@
                   icon="terp-graph"
                   id="menu_board_purchase"
                   parent="base.menu_reporting_dashboard"
-                  sequence="20"/>
+                  sequence="20"
+                  groups="purchase.group_purchase_user"/>
 
     </data>
 </openerp>

=== modified file 'sale_mrp/security/ir.model.access.csv'
--- sale_mrp/security/ir.model.access.csv	2012-06-29 10:01:39 +0000
+++ sale_mrp/security/ir.model.access.csv	2012-09-11 14:21:43 +0000
@@ -2,4 +2,3 @@
 access_mrp_bom_user,mrp.bom,mrp.model_mrp_bom,base.group_sale_salesman,1,0,0,0
 access_sale_order_manufacturing_user,sale.order manufacturing.user,sale.model_sale_order,mrp.group_mrp_user,1,1,0,0
 access_sale_order_line_manufacturing_user,sale.order.line manufacturing.user,sale.model_sale_order_line,mrp.group_mrp_user,1,1,0,0
-access_mrp_bom_revision_salesman,mrp.bom.revision,mrp.model_mrp_bom_revision,base.group_sale_salesman,1,0,0,0

=== modified file 'stock/wizard/stock_inventory_line_split_view.xml'
--- stock/wizard/stock_inventory_line_split_view.xml	2012-08-09 06:05:16 +0000
+++ stock/wizard/stock_inventory_line_split_view.xml	2012-09-11 14:21:43 +0000
@@ -5,7 +5,7 @@
             <field name="name">Split Inventory Line</field>
             <field name="model">stock.inventory.line.split</field>
             <field name="arch" type="xml">
-                <form string="Split in Lots" version="7.0">
+                <form string="Split in Serial number" version="7.0">
                     <group>
                         <field name="product_id" colspan="4" readonly="1"/>
                         <label for="qty"/>

=== modified file 'stock/wizard/stock_move.py'
--- stock/wizard/stock_move.py	2012-07-25 10:14:28 +0000
+++ stock/wizard/stock_move.py	2012-09-11 14:21:43 +0000
@@ -170,7 +170,7 @@
         'product_uom': fields.many2one('product.uom', 'Unit of Measure'),
         'line_ids': fields.one2many('stock.move.split.lines', 'wizard_id', 'Serial Numbers'),
         'line_exist_ids': fields.one2many('stock.move.split.lines', 'wizard_exist_id', 'Serial Numbers'),
-        'use_exist' : fields.boolean('Existing Lots', help="Check this option to select existing lots in the list below, otherwise you should enter new ones line by line."),
+        'use_exist' : fields.boolean('Existing Serial Number', help="Check this option to select existing serial number in the list below, otherwise you should enter new ones line by line."),
         'location_id': fields.many2one('stock.location', 'Source Location')
      }
 
@@ -271,8 +271,8 @@
     }
 
     def onchange_lot_id(self, cr, uid, ids, prodlot_id=False, product_qty=False,
-                        loc_id=False, product_id=False, uom_id=False):
+                        loc_id=False, product_id=False, uom_id=False,context=None):
         return self.pool.get('stock.move').onchange_lot_id(cr, uid, [], prodlot_id, product_qty,
-                        loc_id, product_id, uom_id)
+                        loc_id, product_id, uom_id, context)
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

=== modified file 'stock/wizard/stock_move_view.xml'
--- stock/wizard/stock_move_view.xml	2012-08-09 06:05:16 +0000
+++ stock/wizard/stock_move_view.xml	2012-09-11 14:21:43 +0000
@@ -8,14 +8,15 @@
             <field name="model">stock.move.consume</field>
             <field name="arch" type="xml">
                 <form string="Consume Move" version="7.0">
-                    <group string="Consume Products">
+                    <seperator string="Consume Products"/>
+                    <group>
                         <field name="product_id" readonly="1"/>
                         <label for="product_qty"/>
                         <div>
-                            <field name="product_qty"/>
-                            <field name="product_uom" nolabel="1" readonly="1"/>
+                            <field name="product_qty" class="oe_inline"/>
+                            <field name="product_uom" class="oe_inline" readonly="1" groups="product.group_uom"/>
                         </div>
-                        <field name="location_id"/>
+                        <field name="location_id" groups="stock.group_locations"/>
                     </group>
                     <footer>
                         <button name="do_move_consume" string="Ok" type="object" class="oe_highlight"/>
@@ -46,9 +47,9 @@
                         <label for="product_qty"/>
                         <div>
                             <field name="product_qty" class="oe_inline"/>
-                            <field name="product_uom" class="oe_inline" readonly="1"/>
+                            <field name="product_uom" class="oe_inline" readonly="1" groups="product.group_uom"/>
                         </div>
-                        <field name="location_id" string="Scrap Location" domain="[('usage','&lt;&gt;','view'),('scrap_location','=',True)]" widget="selection"/>
+                        <field name="location_id" string="Scrap Location" domain="[('usage','&lt;&gt;','view'),('scrap_location','=',True)]" widget="selection" groups="stock.group_locations"/>
                     </group>
                     <footer>
                         <button name="move_scrap" string="Ok" type="object" class="oe_highlight"  />
@@ -69,10 +70,10 @@
         </record>
 
         <record id="view_split_in_lots" model="ir.ui.view">
-                <field name="name">Split in lots</field>
+                <field name="name">Split in Serial Numbers</field>
                 <field name="model">stock.move.split</field>
                 <field name="arch" type="xml">
-                <form string="Split in Lots" version="7.0">
+                <form string="Split in Serial number" version="7.0">
                     <group>
                         <field name="product_id" readonly="1"/>
                         <label for="qty"/>
@@ -85,7 +86,7 @@
                     </group>
                     <field name="line_ids" attrs="{'invisible':[('use_exist','=',True)]}">
                         <tree string="Serial Numbers" editable="bottom">
-                            <field name="name" string="Lots"/>
+                            <field name="name" string="Serial Number"/>
                             <field name="quantity" />
                         </tree>
                         <form string="Serial Number" version="7.0">
@@ -97,13 +98,13 @@
                     </field>
                     <field name="line_exist_ids" attrs="{'invisible':[('use_exist','!=',True)]}">
                         <tree string="Serial Numbers" editable="bottom">
-                            <field name="prodlot_id" string="Lot number" domain="[('product_id','=',parent.product_id)]" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom)"/>
-                            <field name="quantity" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom)" />
+                            <field name="prodlot_id" string="Serial Number" quick_create="false" domain="[('product_id','=',parent.product_id)]" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom, context)" context="{'product_id': parent.product_id}"/>
+                            <field name="quantity" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom,context)" />
                         </tree>
                         <form string="Serial Number" version="7.0">
                             <group>
-                                <field name="prodlot_id" string="Lot number" domain="[('product_id','=',parent.product_id)]" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom)"/>
-                                <field name="quantity" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom)" />
+                                <field name="prodlot_id" string="Serial Number" domain="[('product_id','=',parent.product_id)]" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom, context)"/>
+                                <field name="quantity" on_change="onchange_lot_id(prodlot_id, quantity, parent.location_id, parent.product_id, parent.product_uom, context)" />
                             </group>
                         </form>
                     </field>
@@ -115,7 +116,7 @@
             </record>
 
             <record id="track_line" model="ir.actions.act_window">
-                <field name="name">Split in lots</field>
+                <field name="name">Split in serial numbers</field>
                 <field name="type">ir.actions.act_window</field>
                 <field name="res_model">stock.move.split</field>
                 <field name="view_type">form</field>

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to