19 lines
657 B
Python
19 lines
657 B
Python
# -*- coding:utf-8 -*-
|
|
from odoo import api, fields, models, _
|
|
|
|
|
|
class YuthonInspection(models.Model):
|
|
_name = 'yuthon.inspection'
|
|
_description = "巡检任务"
|
|
|
|
name = fields.Char(string='巡检任务')
|
|
state = fields.Selection([('draft', '草稿'), ('will', '待巡检'), ('ing', '巡检中'), ('done', '已完成')], string="巡检状态")
|
|
inspection_code = fields.Char(string="任务号")
|
|
user_id = fields.Many2one('res.users', string='巡检人')
|
|
user_phone = fields.Char(string='电话')
|
|
start_plan_time = fields.Datetime(string='计划开始时间')
|
|
end_plan_time = fields.Datetime(string='计划结束时间')
|
|
|
|
|
|
|