clinic/netforce_clinic/models/visit_plan.py

23 lines
673 B
Python
Raw Normal View History

2014-10-05 08:29:21 +00:00
from netforce.model import Model, fields
class VisitPlane(Model):
_name="clinic.visit.plane"
_string="Visit Plan"
_fieldname="visit_id"
_fields={
'visit_id': fields.Many2One("clinic.visit","Visit"),
'hd_case_id': fields.Many2One("clinic.hd.case","HD Case"),
"date": fields.Date("Date"),
"time_start": fields.DateTime("Time Start"),
"time_stop": fields.DateTime("Time Stop"),
"state": fields.Selection([("open","Open"),("close","Close")],"Status"),
'active': fields.Boolean("Active"), # to hide
}
_defaults={
'state': 'open',
'active': True,
}
VisitPlane.register()