clinic/netforce_clinic/models/make_apt_line.py

23 lines
930 B
Python
Raw Permalink Normal View History

2015-01-15 11:45:11 +00:00
from netforce.model import Model, fields
class MakeAPTLine(Model):
_name="clinic.make.apt.line"
_transient=True
_fields={
'apt_id': fields.Many2One("clinic.make.apt","APT", required=True,on_delete="cascade"),
2015-03-02 04:03:07 +00:00
'patient_id': fields.Many2One("clinic.patient","Patient",domain=[['state','=','admit']]),
2015-01-15 11:45:11 +00:00
'mon_cycle_id': fields.Many2One("clinic.cycle","Monday"),
2015-01-15 15:38:28 +00:00
'tue_cycle_id': fields.Many2One("clinic.cycle","Tuesday"),
2015-01-16 04:47:11 +00:00
'wed_cycle_id': fields.Many2One("clinic.cycle","Wednesday"),
2015-01-15 11:45:11 +00:00
'thu_cycle_id': fields.Many2One("clinic.cycle","Thursday"),
'fri_cycle_id': fields.Many2One("clinic.cycle","Friday"),
2015-01-16 04:47:11 +00:00
'sat_cycle_id': fields.Many2One("clinic.cycle","Saturday"),
2015-01-15 11:45:11 +00:00
'sun_cycle_id': fields.Many2One("clinic.cycle","Sunday"),
'department_id': fields.Many2One("clinic.department","Department"),
}
_order="patient_id"
MakeAPTLine.register()