28 lines
857 B
Python
28 lines
857 B
Python
# This file is part of Tryton. The COPYRIGHT file at the top level of
|
|
# this repository contains the full copyright notices and license terms.
|
|
from trytond.model import (ModelSQL, ModelView, fields)
|
|
from datetime import datetime
|
|
|
|
class Recepcion(ModelView, ModelSQL):
|
|
"Recepcion"
|
|
__name__= "taller.recepcion"
|
|
|
|
tercero = fields.Many2One("party.party", "Tercero")
|
|
metodo_contacto=fields.Many2One('party.contact_mechanism', "Contacto")
|
|
hora_entrada = fields.DateTime('Hora Entrada')
|
|
referencia = fields.Char("Referencia")
|
|
descripcion = fields.Text("Descripcion")
|
|
estado = fields.Selection([("borrador","Borrador"),("registrado", "Registrado")],"Estado")
|
|
|
|
@classmethod
|
|
def default_hora_entrada(cls):
|
|
return datetime.now()
|
|
|
|
@classmethod
|
|
def default_estado(cls):
|
|
return "borrador"
|
|
|
|
|
|
|
|
|