mirror of
https://github.com/OCA/manufacture.git
synced 2025-01-28 16:37:15 +02:00
[IMP] mrp_operations_extension: Put a "onchange" to calculate fields # Operators, and Operator average hour cost, of model mrp.workcenter.
22 lines
879 B
Python
22 lines
879 B
Python
# -*- coding: utf-8 -*-
|
|
##############################################################################
|
|
# For copyright and license notices, see __openerp__.py file in root directory
|
|
##############################################################################
|
|
from openerp import models, fields
|
|
|
|
|
|
class MrpRoutingOperation(models.Model):
|
|
_name = 'mrp.routing.operation'
|
|
_description = 'MRP Routing Operation'
|
|
|
|
name = fields.Char('Name', required=True)
|
|
code = fields.Char('Code')
|
|
description = fields.Text('Description')
|
|
steps = fields.Text('Relevant Steps')
|
|
workcenters = fields.Many2many(
|
|
'mrp.workcenter', 'mrp_operation_workcenter_rel', 'operation',
|
|
'workcenter', 'Work centers')
|
|
op_number = fields.Integer('# operators', default='0')
|
|
picking_type_id = fields.Many2one(
|
|
'stock.picking.type', string='Picking Type')
|