[REM] product: Remove product_manager field
The product_manager field is existing since v6.0 and never displayed in any views. It is used in sale_timesheet module. A task created from a procurement_order (if it is a service and we track the service) is assigned to the product manager. It doesn't make a lot of sense as the value should be set directly in the database. We will remove the field and assign the current user to the task instead, which is the common behavior in Odoo.
This commit is contained in:
@@ -27,7 +27,6 @@ class ProductTemplate(models.Model):
|
||||
|
||||
name = fields.Char('Name', index=True, required=True, translate=True)
|
||||
sequence = fields.Integer('Sequence', default=1, help='Gives the sequence order when displaying a product list')
|
||||
product_manager = fields.Many2one('res.users', 'Product Manager')
|
||||
description = fields.Text(
|
||||
'Description', translate=True,
|
||||
help="A precise description of the Product, used only for internal information purposes.")
|
||||
|
||||
@@ -61,7 +61,7 @@ class ProcurementOrder(models.Model):
|
||||
'planned_hours': planned_hours,
|
||||
'remaining_hours': planned_hours,
|
||||
'partner_id': self.sale_line_id.order_id.partner_id.id or self.partner_dest_id.id,
|
||||
'user_id': self.product_id.product_manager.id,
|
||||
'user_id': self.env.uid,
|
||||
'procurement_id': self.id,
|
||||
'description': self.name + '\n',
|
||||
'project_id': project.id,
|
||||
|
||||
Reference in New Issue
Block a user