Files
manufacture/mrp_calendar_view/model/mrp_repair.py
2015-07-31 10:26:28 +02:00

34 lines
1.9 KiB
Python

# -*- coding: utf-8 -*-
#########################################################################
# #
# Copyright (C) 2015 Agile Business Group #
# #
# This program is free software: you can redistribute it and/or modify #
# it under the terms of the GNU Affero General Public License as #
# published by the Free Software Foundation, either version 3 of the #
# License, or (at your option) any later version. #
# #
# This program is distributed in the hope that it will be useful, #
# but WITHOUT ANY WARRANTY; without even the implied warranty of #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
# GNU Affero General Public Licensefor more details. #
# #
# You should have received a copy of the #
# GNU Affero General Public License #
# along with this program. If not, see <http://www.gnu.org/licenses/>. #
# #
#########################################################################
from openerp import fields, models
class mrp_repair(models.Model):
_inherit = 'mrp.repair'
user_id = fields.Many2one('res.users', 'User',
default=lambda self: self.env.user,
help="Person in charge for the repair")
date_repair = fields.Datetime('Repair Date', default=fields.Datetime.now,
help="Date of the repair, this field"
"and user_id defines the calendar")