← Back to team overview

openerp-community team mailing list archive

[Merge] lp:~openerp-community/openobject-addons/addons-fix-finnished into lp:openobject-addons

 

Niels Huylebroeck has proposed merging lp:~openerp-community/openobject-addons/addons-fix-finnished into lp:openobject-addons.

Requested reviews:
  OpenERP Core Team (openerp)
Related bugs:
  #326160 Belgian(?) English word about to pollute the data model forever; PATCH INCLUDED
  https://bugs.launchpad.net/bugs/326160


I have not included translation updates in this merge as I believe they are generated automatically by Launchpad ?
-- 
https://code.launchpad.net/~openerp-community/openobject-addons/addons-fix-finnished/+merge/35523
Your team OpenERP Community is subscribed to branch lp:~openerp-community/openobject-addons/addons-fix-finnished.
=== modified file 'mrp/mrp.py'
--- mrp/mrp.py	2010-09-08 04:30:24 +0000
+++ mrp/mrp.py	2010-09-15 12:06:17 +0000
@@ -450,7 +450,7 @@
         'date_planned_date': fields.function(_production_date, method=True, type='date', string='Scheduled Date'),
         'date_planned': fields.datetime('Scheduled date', required=True, select=1),
         'date_start': fields.datetime('Start Date'),
-        'date_finnished': fields.datetime('End Date'),
+        'date_finished': fields.datetime('End Date'),
 
         'bom_id': fields.many2one('mrp.bom', 'Bill of Material', domain=[('bom_id','=',False)]),
         'routing_id': fields.many2one('mrp.routing', string='Routing', on_delete='set null', help="The list of operations (list of workcenters) to produce the finished product. The routing is mainly used to compute workcenter costs during operations and to plan future loads on workcenters based on production plannification."),
@@ -652,7 +652,7 @@
         """
         for production in self.browse(cr, uid, ids):
             self._costs_generate(cr, uid, production)
-        return self.write(cr, uid, ids, {'state': 'done', 'date_finnished': time.strftime('%Y-%m-%d %H:%M:%S')})
+        return self.write(cr, uid, ids, {'state': 'done', 'date_finished': time.strftime('%Y-%m-%d %H:%M:%S')})
 
     def test_production_done(self, cr, uid, ids):
         """ Tests whether production is done or not.

=== modified file 'mrp/mrp_view.xml'
--- mrp/mrp_view.xml	2010-09-13 16:26:41 +0000
+++ mrp/mrp_view.xml	2010-09-15 12:06:17 +0000
@@ -530,7 +530,7 @@
             <field name="model">mrp.production</field>
             <field name="type">gantt</field>
             <field name="arch" type="xml">
-                <gantt color="product_id" date_stop="date_finnished" date_start="date_start" string="Productions">
+                <gantt color="product_id" date_stop="date_finished" date_start="date_start" string="Productions">
                     <level object="mrp.routing" link="routing_id" domain="[]">
                         <field name="name"/>
                         <field name="origin"/>
@@ -696,7 +696,7 @@
                             <field name="priority" groups="base.group_extended"/>
                             <newline/>
                             <field name="date_start"/>
-                            <field name="date_finnished"/>
+                            <field name="date_finished"/>
                             <field name="picking_id" groups="base.group_extended"/>
                             <field name="move_prod_id" groups="base.group_extended"/>
                         </page>

=== modified file 'mrp/report/mrp_production_order.py'
--- mrp/report/mrp_production_order.py	2010-08-05 10:20:52 +0000
+++ mrp/report/mrp_production_order.py	2010-09-15 12:06:17 +0000
@@ -51,7 +51,7 @@
         'date_planned':fields.date('Scheduled Date'),
         'location_src_id': fields.many2one('stock.location', 'Raw Materials Location', readonly=True),
         'date_start': fields.datetime('Start Date',readonly=True),
-        'date_finnished': fields.datetime('End Date',readonly=True),
+        'date_finished': fields.datetime('End Date',readonly=True),
         'location_dest_id': fields.many2one('stock.location', 'Finished Products Location', readonly=True),
         'company_id': fields.many2one('res.company','Company',readonly=True),
         'bom_id': fields.many2one('mrp.bom', 'Bill of Material',readonly=True),
@@ -100,7 +100,7 @@
                      s.routing_id,
                      s.picking_id,
                      s.date_start,
-                     s.date_finnished,
+                     s.date_finished,
                      to_date(to_char(s.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY') as date_planned,
                      s.origin,
                      s.priority,
@@ -128,7 +128,7 @@
                      to_date(to_char(s.date_planned, 'dd-MM-YYYY'),'dd-MM-YYYY'),
                      s.origin,
                      s.date_start,
-                     s.date_finnished,
+                     s.date_finished,
                      s.company_id
             )""")
 mrp_production_order()

=== modified file 'mrp/report/mrp_production_order_view.xml'
--- mrp/report/mrp_production_order_view.xml	2010-07-30 11:04:14 +0000
+++ mrp/report/mrp_production_order_view.xml	2010-09-15 12:06:17 +0000
@@ -97,7 +97,7 @@
                       <newline/>
 	                    <field name="date_start"/>
                       <field name="date_planned"/>
-                      <field name="date_finnished"/>
+                      <field name="date_finished"/>
 	                </group>
                   </search>
             </field>

=== modified file 'mrp_operations/mrp_operations.py'
--- mrp_operations/mrp_operations.py	2010-09-07 06:33:16 +0000
+++ mrp_operations/mrp_operations.py	2010-09-15 12:06:17 +0000
@@ -85,7 +85,7 @@
        'date_planned': fields.datetime('Scheduled Date'),
        'date_planned_end': fields.function(_get_date_end, method=True, string='End Date', type='datetime'),
        'date_start': fields.datetime('Start Date'),
-       'date_finnished': fields.datetime('End Date'),
+       'date_finished': fields.datetime('End Date'),
        'delay': fields.float('Working Hours',help="This is lead time between operation start and stop in this workcenter",readonly=True),
        'production_state':fields.related('production_id','state',
             type='selection',
@@ -171,7 +171,7 @@
         delay += (date_finished-date_start).days * 24
         delay += (date_finished-date_start).seconds / float(60*60)
         
-        self.write(cr, uid, ids, {'state':'done', 'date_finnished': date_now,'delay':delay})
+        self.write(cr, uid, ids, {'state':'done', 'date_finished': date_now,'delay':delay})
         self.modify_production_order_state(cr,uid,ids,'done')
         return True
 
@@ -280,7 +280,7 @@
                     dt_end = DateTime.strptime(wc.date_planned_end, '%Y-%m-%d %H:%M:%S')
                 old = wc.sequence or 0
             super(mrp_production, self).write(cr, uid, [po.id], {
-                'date_finnished': dt_end
+                'date_finished': dt_end
             })
         return dt_end
 
@@ -298,7 +298,7 @@
                 if l.state in ('done','cancel','draft'):
                     continue
                 todo += l.move_dest_id_lines
-                if l.production_id and (l.production_id.date_finnished > dt):
+                if l.production_id and (l.production_id.date_finished > dt):
                     if l.production_id.state not in ('done','cancel'):
                         for wc in l.production_id.workcenter_lines:
                             i = self.pool.get('resource.calendar').interval_min_get(
@@ -327,8 +327,8 @@
                         break
                     if l.production_id.state in ('done','cancel'):
                         break
-                    if l.production_id and (l.production_id.date_start < po.date_finnished):
-                        self.write(cr, uid, [l.production_id.id], {'date_start': po.date_finnished})
+                    if l.production_id and (l.production_id.date_start < po.date_finished):
+                        self.write(cr, uid, [l.production_id.id], {'date_start': po.date_finished})
                         break
 
 
@@ -503,7 +503,7 @@
             if code.start_stop=='done':
                 tmp=self.pool.get('mrp.production.workcenter.line').action_done(cr,uid,wc_op_id)
                 wf_service.trg_validate(uid, 'mrp.production.workcenter.line', wc_op_id[0], 'button_done', cr)
-                self.pool.get('mrp.production').write(cr,uid,vals['production_id'],{'date_finnished':DateTime.now().strftime('%Y-%m-%d %H:%M:%S')})
+                self.pool.get('mrp.production').write(cr,uid,vals['production_id'],{'date_finished':DateTime.now().strftime('%Y-%m-%d %H:%M:%S')})
 
             if code.start_stop=='pause':
                 tmp=self.pool.get('mrp.production.workcenter.line').action_pause(cr,uid,wc_op_id)
@@ -524,7 +524,7 @@
         line_vals['delay'] = delay
         if vals.get('date_start',False):
             if code.start_stop == 'done':
-                line_vals['date_finnished'] = vals['date_start']
+                line_vals['date_finished'] = vals['date_start']
             elif code.start_stop == 'start':    
                 line_vals['date_start'] = vals['date_start']
 

=== modified file 'mrp_operations/mrp_operations_view.xml'
--- mrp_operations/mrp_operations_view.xml	2010-09-07 06:33:16 +0000
+++ mrp_operations/mrp_operations_view.xml	2010-09-15 12:06:17 +0000
@@ -101,7 +101,7 @@
                     <group colspan="2" col="2">
                         <separator string="Real" colspan="2"/>
                         <field name="date_start" readonly="1"/>
-                        <field name="date_finnished" readonly="1"/>
+                        <field name="date_finished" readonly="1"/>
                         <field name="delay" widget="float_time"/>
                     </group>
                     <group colspan="2" col="2">
@@ -170,7 +170,7 @@
         <field name="model">mrp.production.workcenter.line</field>
         <field name="type">calendar</field>
         <field name="arch" type="xml">
-            <calendar color="product" date_stop="date_finnished" date_start="date_start" string="Operations">
+            <calendar color="product" date_stop="date_finished" date_start="date_start" string="Operations">
                 <field name="workcenter_id"/>
                 <field name="production_id"/>
             </calendar>

=== modified file 'procurement/procurement.py'
--- procurement/procurement.py	2010-09-07 07:49:46 +0000
+++ procurement/procurement.py	2010-09-15 12:06:17 +0000
@@ -440,7 +440,7 @@
             wf_service.trg_trigger(uid, 'procurement.order', id, cr)
         return True
 
-    def action_check_finnished(self, cr, uid, ids):
+    def action_check_finished(self, cr, uid, ids):
         return self.check_move_done(cr, uid, ids)
 
     def action_check(self, cr, uid, ids):
@@ -493,9 +493,9 @@
 class StockPicking(osv.osv):
     _inherit = 'stock.picking'
 
-    def test_finnished(self, cursor, user, ids):
+    def test_finished(self, cursor, user, ids):
         wf_service = netsvc.LocalService("workflow")
-        res = super(StockPicking, self).test_finnished(cursor, user, ids)
+        res = super(StockPicking, self).test_finished(cursor, user, ids)
         for picking in self.browse(cursor, user, ids):
             for move in picking.move_lines:
                 if move.state == 'done' and move.procurements:

=== modified file 'procurement/procurement_workflow.xml'
--- procurement/procurement_workflow.xml	2010-09-01 21:53:24 +0000
+++ procurement/procurement_workflow.xml	2010-09-15 12:06:17 +0000
@@ -187,7 +187,7 @@
         <record id="trans_make_done_done" model="workflow.transition">
             <field name="act_from" ref="act_make_done"/>
             <field name="act_to" ref="act_done"/>
-            <field name="condition">action_check_finnished()</field>
+            <field name="condition">action_check_finished()</field>
 			<field name="trigger_model">stock.move</field>
             <field name="trigger_expr_id">[move_id.id]</field>            
         </record>

=== modified file 'sale/process/sale_process.xml'
--- sale/process/sale_process.xml	2010-08-17 06:27:57 +0000
+++ sale/process/sale_process.xml	2010-09-15 12:06:17 +0000
@@ -261,7 +261,7 @@
         </record>
 
         <record id="process_transition_action_validate0" model="process.transition.action">
-            <field eval="&quot;&quot;&quot;test_finnished&quot;&quot;&quot;" name="action"/>
+            <field eval="&quot;&quot;&quot;test_finished&quot;&quot;&quot;" name="action"/>
             <field eval="&quot;&quot;&quot;object&quot;&quot;&quot;" name="state"/>
             <field eval="&quot;&quot;&quot;Validate&quot;&quot;&quot;" name="name"/>
             <field name="transition_id" ref="process_transition_deliver0"/>

=== modified file 'stock/stock.py'
--- stock/stock.py	2010-09-07 13:20:08 +0000
+++ stock/stock.py	2010-09-15 12:06:17 +0000
@@ -786,7 +786,7 @@
         self.log_picking(cr, uid, ids, context=context)
         return True
 
-    def test_finnished(self, cr, uid, ids):
+    def test_finished(self, cr, uid, ids):
         """ Tests whether the move is in done or cancel state or not.
         @return: True or False
         """

=== modified file 'stock/stock_workflow.xml'
--- stock/stock_workflow.xml	2010-07-06 12:05:45 +0000
+++ stock/stock_workflow.xml	2010-09-15 12:06:17 +0000
@@ -86,12 +86,12 @@
         <record id="trans_move_done" model="workflow.transition">
             <field name="act_from" ref="act_move"/>
             <field name="act_to" ref="act_done"/>
-            <field name="condition">test_finnished()</field>
+            <field name="condition">test_finished()</field>
         </record>
         <record id="trans_move_confirmed" model="workflow.transition">
             <field name="act_from" ref="act_move"/>
             <field name="act_to" ref="act_confirmed"/>
-            <field name="condition">not test_finnished()</field>
+            <field name="condition">not test_finished()</field>
         </record>
         <record id="trans_assigned_cancel" model="workflow.transition">
             <field name="act_from" ref="act_assigned"/>


Follow ups